Skip to content

Yugenjr/College_Companion

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

123 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

πŸŽ“ College Companion

Your AI-Powered Academic Success Platform

GitHub stars GitHub forks GitHub issues GitHub license PRs Welcome

Live Demo β€’ Features β€’ Tech Stack β€’ Installation β€’ Contributing


πŸ“– About

College Companion is a comprehensive full-stack MERN application designed to help college students excel academically. Powered by advanced AI technologies, it offers intelligent tools for attendance management, syllabus analysis, question generation, and collaborative studyingβ€”all in one platform.

✨ Why College Companion?

  • AI-Powered Intelligence - Leverage Groq, Google Gemini, and Perplexity AI for smart academic assistance
  • Real-Time Collaboration - Study together with Socket.io-powered study rooms
  • Beautiful UI - Modern, responsive design with smooth animations
  • All-in-One Solution - Everything a student needs in a single platform

πŸš€ Features

πŸ” Authentication & Security

  • Firebase Authentication with Google Sign-In
  • Secure user profiles and session management
  • Seamless onboarding experience

πŸ€– AI-Powered Tools

Feature Description
Attendance Advisor AI-driven attendance tracking with smart predictions and recommendations
Syllabus Essentials Extract key topics from syllabus images/PDFs using Perplexity AI
Question Generator Generate exam questions automatically using Groq AI
Survival Plan Create personalized study plans based on your schedule

πŸ‘₯ Study Arena

  • Create and join collaborative study rooms
  • Real-time chat and collaboration
  • Share room codes with classmates
  • Socket.io integration for seamless communication

πŸ“Š Dashboard

  • Personalized academic overview
  • Profile management
  • Quick access to all tools

πŸ› οΈ Tech Stack

Frontend

  • Framework: React 19 + TypeScript
  • Build Tool: Vite
  • Styling: TailwindCSS
  • Animations: Framer Motion
  • Routing: React Router v7
  • Charts: Recharts
  • Icons: Lucide React

Backend

  • Runtime: Node.js + Express
  • Database: MongoDB + Mongoose
  • Authentication: Firebase Auth
  • Real-time: Socket.io
  • AI/ML: Groq SDK, Google Gemini, Perplexity AI
  • OCR: Tesseract.js

πŸ“¦ Installation

Prerequisites

  • Node.js (v18 or higher)
  • MongoDB Atlas account
  • Firebase project with authentication enabled
  • API Keys: Groq, Google Gemini, Perplexity

Quick Start

  1. Clone the repository

    git clone https://github.com/Yugenjr/College_Companion.git
    cd College_Companion
  2. Install dependencies

    # Root (Frontend)
    npm install
    
    # Main Backend
    cd backend
    npm install
    cd ..
    
    # Question Generator Backend
    cd backend-question-generator
    npm install
    cd ..
  3. Configure environment variables

    Create .env in the root directory:

    VITE_FIREBASE_API_KEY=your_firebase_api_key
    VITE_FIREBASE_AUTH_DOMAIN=your_project.firebaseapp.com
    VITE_FIREBASE_PROJECT_ID=your_project_id
    VITE_FIREBASE_STORAGE_BUCKET=your_project.appspot.com
    VITE_FIREBASE_MESSAGING_SENDER_ID=your_sender_id
    VITE_FIREBASE_APP_ID=your_app_id
    VITE_API_URL=http://localhost:5000
    VITE_QUESTION_API_URL=http://localhost:5001

    Create .env in backend/:

    MONGO_URI=your_mongodb_connection_string
    GROQ_API_KEY=your_groq_api_key
    PERPLEXITY_API_KEY=your_perplexity_api_key
    GOOGLE_API_KEY=your_google_gemini_key
    PORT=5000

    Create .env in backend-question-generator/:

    MONGO_URI=your_mongodb_connection_string
    GROQ_API_KEY=your_groq_api_key
    PORT=5001
  4. Start all services

    Option A - PowerShell Script (Windows):

    .\start-all.ps1

    Option B - Manual Start:

    # Terminal 1 - Main Backend
    cd backend
    npm start
    
    # Terminal 2 - Question Generator Backend
    cd backend-question-generator
    npm start
    
    # Terminal 3 - Frontend
    npm run dev
  5. Access the application

    • Frontend: http://localhost:5173
    • Main Backend: http://localhost:5000
    • Question Generator: http://localhost:5001

πŸ’‘ Usage

  1. Sign Up/Login - Create an account or sign in with Google
  2. Complete Onboarding - Set up your profile and preferences
  3. Explore Dashboard - Access all features from the main dashboard
  4. Track Attendance - Use Attendance Advisor for smart tracking
  5. Extract Essentials - Upload syllabus to get key topics
  6. Generate Questions - Create practice questions automatically
  7. Join Study Rooms - Collaborate with peers in real-time

πŸ“‘ API Documentation

Main Backend (Port 5000)

πŸ“š Complete API Reference

β†’ COMPLETE_API_REFERENCE.md ⭐ START HERE

API Endpoints by Module:

Module Endpoints Details
πŸ” Profile GET/PUT/POST/DELETE /api/profile/* View
πŸ“š Survival Kit POST/GET/DELETE /api/survival/* View
πŸ“ Notes POST/GET/PUT/DELETE /api/notes/* View
❓ Questions POST/GET/DELETE /api/questions/* View
πŸ“Š Attendance POST/GET/DELETE /api/attendance/* View
πŸ“– Essentials POST/GET /api/essentials/* View
πŸ”„ Revision POST/GET /api/revision/* View
πŸ’¬ Doubt Solver POST/GET /api/doubt/* View
πŸ’» Study Room Socket.io /api/study-room-chat View

Quick Examples:

# Get user profile
curl -X GET http://localhost:5000/api/profile/me \
  -H "Authorization: Bearer YOUR_TOKEN"

# Create a note
curl -X POST http://localhost:5000/api/notes \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"title":"My Note","content":"..."}'

Other Documentation:

Question Generator Backend (Port 5001)

Endpoint Method Description
/api/questions/generate POST Generate questions
/api/questions/history GET Get generation history

πŸ“ Project Structure

College_Companion/
β”œβ”€β”€ src/                          # Frontend source code
β”‚   β”œβ”€β”€ components/               # Reusable React components
β”‚   β”œβ”€β”€ pages/                    # Page components
β”‚   β”‚   β”œβ”€β”€ Auth/                # Login, Register, Onboarding
β”‚   β”‚   β”œβ”€β”€ Dashboard/           # Dashboard pages
β”‚   β”‚   β”œβ”€β”€ AttendanceAdvisor/   # Attendance tracking
β”‚   β”‚   β”œβ”€β”€ SemesterSurvival/    # Study tools
β”‚   β”‚   β”œβ”€β”€ StudyArena/          # Collaborative rooms
β”‚   β”‚   └── Profile/             # User profile
β”‚   β”œβ”€β”€ contexts/                # React Context providers
β”‚   β”œβ”€β”€ hooks/                   # Custom React hooks
β”‚   └── services/                # API services
β”œβ”€β”€ backend/                     # Main backend (Port 5000)
β”‚   β”œβ”€β”€ models/                  # MongoDB models
β”‚   β”œβ”€β”€ routes/                  # API routes
β”‚   β”œβ”€β”€ config/                  # Configuration files
β”‚   └── server.js               # Entry point
β”œβ”€β”€ backend-question-generator/  # Question generator (Port 5001)
└── public/                      # Static assets

🀝 Contributing

We welcome contributions! Here's how you can help:

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/AmazingFeature)
  3. Commit your changes (git commit -m 'Add some AmazingFeature')
  4. Push to the branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

Contribution Guidelines

  • Follow the existing code style
  • Write meaningful commit messages
  • Add tests for new features
  • Update documentation as needed
  • Ensure all tests pass before submitting PR

πŸ› Troubleshooting

MongoDB Connection Failed
  • Verify your MongoDB URI in .env files
  • Check if your IP is whitelisted in MongoDB Atlas
  • Ensure the database name is correct
Firebase Authentication Error
  • Verify all Firebase credentials in .env
  • Ensure Firebase Authentication is enabled in your Firebase console
  • Check Google Sign-In is configured properly
Port Already in Use
  • Kill processes on ports 5000, 5001, or 5173
  • Windows: netstat -ano | findstr :5000 then taskkill /PID <PID> /F
  • Linux/Mac: lsof -ti:5000 | xargs kill -9

πŸ“ License

This project is licensed under the MIT License - see the LICENSE file for details.


πŸ‘₯ Contributors

Yugendra N
Yugendra N
Project Admin

Want to contribute? Check out our Contributing Guidelines and add yourself to this list! πŸŽ‰


πŸ™ Acknowledgments

  • AI Services: Groq, Google Gemini, Perplexity AI
  • Icons: Lucide React
  • UI Inspiration: Modern web design best practices
  • Community: All our contributors and users

πŸ“§ Support


Firestore Schema Refactor

The Firestore schema for study rooms has been updated:

  • Typing status is now stored in each user document as isTyping.
  • Old typing node is still supported for backward compatibility.
  • See MIGRATION_GUIDE.md for migration steps and details.

All CRUD operations have been refactored to support both schemas during the transition.


Made with ❀️ for students, by students

⭐ Star us on GitHub β€” it helps!

⬆ Back to Top

About

Resources

License

Code of conduct

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors