{"id":27134644,"url":"https://github.com/work-manas/studynest","last_synced_at":"2026-04-02T03:11:18.341Z","repository":{"id":286474692,"uuid":"961513509","full_name":"work-Manas/StudyNest","owner":"work-Manas","description":"StudyNest is an innovative web application inspired by Google Classroom, offering AI-driven personalized quizzes, real-time proctoring with CNN-based webcam monitoring, and interactive class chats, built with Flask, MongoDB, and Google Generative AI for a dynamic and secure learning experience.","archived":false,"fork":false,"pushed_at":"2025-04-06T17:54:09.000Z","size":183,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-10-08T23:05:25.011Z","etag":null,"topics":["axios","flask","jwt-authentication","mongodb","nextjs","react","shadcn-ui"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/work-Manas.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-04-06T17:14:37.000Z","updated_at":"2025-04-06T17:54:12.000Z","dependencies_parsed_at":"2025-04-06T18:36:33.379Z","dependency_job_id":null,"html_url":"https://github.com/work-Manas/StudyNest","commit_stats":null,"previous_names":["work-manas/study-nest"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/work-Manas/StudyNest","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/work-Manas%2FStudyNest","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/work-Manas%2FStudyNest/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/work-Manas%2FStudyNest/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/work-Manas%2FStudyNest/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/work-Manas","download_url":"https://codeload.github.com/work-Manas/StudyNest/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/work-Manas%2FStudyNest/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279000732,"owners_count":26082862,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-08T02:00:06.501Z","response_time":56,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["axios","flask","jwt-authentication","mongodb","nextjs","react","shadcn-ui"],"created_at":"2025-04-08T00:49:02.752Z","updated_at":"2025-10-08T23:05:26.345Z","avatar_url":"https://github.com/work-Manas.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# StudyNest\n\nWelcome to **StudyNest**, a comprehensive platform designed for seamless collaboration between teachers and students. This application integrates modern technologies to provide features like class management, note sharing, quiz generation, and real-time communication.\n\n---\n\n## Table of Contents\n\n1. [Features](#features)\n2. [Workflow Diagram](#workflow-diagram)\n3. [Technologies Used](#technologies-used)\n4. [Frontend Overview](#frontend-overview)\n5. [Backend Overview](#backend-overview)\n6. [Setup Instructions](#setup-instructions)\n7. [Environment Variables](#environment-variables)\n8. [Endpoints](#endpoints)\n9. [Running the Application](#running-the-application)\n10. [Notes](#notes)\n\n---\n\n## Features\n\n- User authentication (teacher and student roles).\n- Class creation and management.\n- Notes upload and retrieval (text and PDF).\n- Quiz generation based on uploaded notes.\n- Real-time chat functionality for classes.\n\n---\n\n## Workflow Diagram\n\n![Untitled-2025-04-06-2210](https://github.com/user-attachments/assets/52b8da1b-76d4-40cb-a538-fb01ea5bfbcd)\n\n---\n\n## Technologies Used\n\n### Frontend\n\n- **Framework**: Next.js\n- **Styling**: Tailwind CSS\n- **State Management**: React Context API\n- **Real-time Communication**: WebSocket integration\n\n### Backend\n\n- **Framework**: Flask\n- **Database**: MongoDB\n- **Authentication**: JWT\n- **File Storage**: GridFS\n- **Real-time Communication**: Flask-SocketIO\n- **AI Integration**: Google Generative AI (Gemini API)\n\n---\n\n## Frontend Overview\n\nThe frontend is built using **Next.js**, providing a fast and responsive user interface. Key features include:\n\n- Dynamic routing for pages.\n- Integration with the backend for seamless data exchange.\n- Real-time updates using WebSocket.\n\nTo start the frontend:\n\n```bash\ncd frontend\nnpm install\nnpm run dev\n```\n\n---\n\n## Backend Overview\n\nThe backend is powered by **Flask**, offering robust APIs for managing classes, notes, quizzes, and chat functionality. It also integrates AI for quiz generation.\n\n### DB Diagram\n\n![image](https://github.com/user-attachments/assets/70a2faad-b240-49d3-abb3-20ded82b0f52)\n\n\n---\n\n## Setup Instructions\n\n### Clone the repository:\n\n```bash\ngit clone \u003crepository-url\u003e\ncd StudyNest\n```\n\n### Install dependencies:\n\n#### Frontend:\n\n```bash\ncd frontend\nnpm install\n```\n\n#### Backend:\n\n```bash\ncd backend\npip install -r requirements.txt\n```\n\n### Set up the environment variables:\n\nCreate a `.env` file in the `backend` directory and add the following:\n\n```\nGEMINI_API_KEY=\u003cyour-gemini-api-key\u003e\nJWT_SECRET_KEY=\u003cyour-jwt-secret-key\u003e\nMONGO_URI=mongodb://localhost:27017\n```\n\n### Start the MongoDB server:\n\n```bash\nmongod\n```\n\n### Run the application:\n\n#### Frontend:\n\n```bash\nnpm run dev\n```\n\n#### Backend:\n\n```bash\npython backend/app.py\n```\n\n---\n\n## Environment Variables\n\n| Variable           | Description                        |\n| ------------------ | ---------------------------------- |\n| `GEMINI_API_KEY` | API key for Google Generative AI.  |\n| `JWT_SECRET_KEY` | Secret key for JWT authentication. |\n| `MONGO_URI`      | MongoDB connection URI.            |\n\n---\n\n## Endpoints\n\n### Authentication\n\n| Method | Endpoint         | Description                 |\n| ------ | ---------------- | --------------------------- |\n| POST   | `/auth/signup` | Register a new user.        |\n| POST   | `/auth/login`  | Log in and get a JWT token. |\n\n### Classes\n\n| Method | Endpoint             | Description                    |\n| ------ | -------------------- | ------------------------------ |\n| POST   | `/classes/`        | Create a new class (teacher).  |\n| POST   | `/classes/join`    | Join a class using a code.     |\n| GET    | `/classes/teacher` | Get all classes for a teacher. |\n| GET    | `/classes/student` | Get all classes for a student. |\n\n### Notes\n\n| Method | Endpoint                      | Description                 |\n| ------ | ----------------------------- | --------------------------- |\n| POST   | `/notes/`                   | Upload notes (text or PDF). |\n| GET    | `/notes/class/\u003cclass_id\u003e`   | Get all notes for a class.  |\n| GET    | `/notes/\u003cnote_id\u003e/download` | Download a PDF note.        |\n\n### Quizzes\n\n| Method | Endpoint                                  | Description                        |\n| ------ | ----------------------------------------- | ---------------------------------- |\n| POST   | `/quizzes/generate`                     | Generate a quiz (teacher only).    |\n| GET    | `/quizzes/\u003cquiz_id\u003e`                    | Get a student's personalized quiz. |\n| POST   | `/quizzes/\u003cquiz_id\u003e/submit`             | Submit a quiz (student only).      |\n| GET    | `/quizzes/assignments/\u003cquiz_id\u003e/scores` | Get quiz scores (teacher).         |\n\n### Chat\n\n| Method | Endpoint                      | Description                        |\n| ------ | ----------------------------- | ---------------------------------- |\n| POST   | `/chat/messages`            | Post a message in a class chat.    |\n| GET    | `/chat/messages/\u003cclass_id\u003e` | Get all messages for a class chat. |\n\n---\n\n## Running the Application\n\n1. Ensure MongoDB is running locally.\n2. Start the Flask backend:\n   ```bash\n   python backend/app.py\n   ```\n3. Start the Next.js frontend:\n   ```bash\n   npm run dev\n   ```\n4. Access the application at [http://127.0.0.1:5000](http://127.0.0.1:5000).\n\n---\n\n## Notes\n\n- Ensure you have the required API keys and environment variables set up before running the application.\n- Use tools like Postman or cURL to test the endpoints.\n- For real-time chat, use a WebSocket client to connect to the `/chat` namespace.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwork-manas%2Fstudynest","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwork-manas%2Fstudynest","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwork-manas%2Fstudynest/lists"}