Skip to content

haniigupta/ai-learning-assistant

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

121 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

React Node.js MongoDB Groq RAG License

AI Learning Assistant

An AI-powered learning platform that helps students learn from their study materials by generating summaries, flashcards, quizzes, and document-based answers using Retrieval-Augmented Generation (RAG).

Live Demo

Frontend: https://ai-learning-assistant-kohl-iota.vercel.app

Features

Authentication

  • Secure user registration and login
  • JWT-based authentication
  • Protected routes

Document Management

  • Upload PDF documents
  • Automatic text extraction
  • Intelligent document chunking
  • Document history and management

AI-Powered Learning

  • Generate concise document summaries
  • Create educational flashcards automatically
  • Generate multiple-choice quizzes
  • Explain concepts from uploaded documents
  • Ask questions and chat with documents

Retrieval-Augmented Generation (RAG)

  • Document chunking pipeline
  • Vector embeddings for semantic search
  • Context-aware document retrieval
  • AI responses grounded in uploaded content

Progress Tracking

  • Track generated learning resources
  • Monitor study activity
  • Manage learning sessions efficiently

Tech Stack

Frontend

  • React.js
  • React Router
  • Axios
  • Tailwind CSS
  • React Hot Toast

Backend

  • Node.js
  • Express.js
  • MongoDB
  • Mongoose
  • JWT Authentication

AI & RAG

  • Groq API (LLM Generation)
  • Google Gemini Embeddings
  • Vector Similarity Search
  • Retrieval-Augmented Generation (RAG)

Deployment

  • Vercel (Frontend)
  • Render (Backend)
  • MongoDB Atlas

System Architecture

User Uploads Document ↓ PDF Text Extraction ↓ Text Chunking ↓ Generate Embeddings ↓ Store Chunks + Vectors ↓ Semantic Retrieval ↓ Relevant Context Selection ↓ Groq LLM ↓ Summary / Flashcards / Quiz / Chat Response


Installation

Clone Repository

git clone https://github.com/haniigupta/ai-learning-assistant.git
cd ai-learning-assistant

Backend Setup

cd backend
npm install

Create a .env file:

PORT=8000

MONGODB_URI=your_mongodb_connection_string

JWT_SECRET=your_jwt_secret

GROQ_API_KEY=your_groq_api_key

GEMINI_API_KEY=your_gemini_api_key

Start Backend:

npm run dev

Frontend Setup

cd frontend
npm install

Create a .env file:

VITE_API_URL=http://localhost:8000/api

Start Frontend:

npm run dev

Key Features Implemented

AI Summary Generation

Generate concise summaries from uploaded study materials.

Flashcard Generation

Automatically create question-answer flashcards for revision.

Quiz Generation

Generate multiple-choice quizzes from document content.

Document Q&A

Ask questions about uploaded documents and receive context-aware answers.

Concept Explanation

Get simplified explanations of concepts extracted from study materials.


Future Improvements

  • Multi-document search
  • Cloud storage integration (AWS S3 / Cloudinary)
  • Study analytics dashboard
  • Spaced repetition flashcards
  • OCR support for scanned PDFs
  • Voice-based learning assistant

Author

Hani Gupta

GitHub: https://github.com/haniigupta

LinkedIn: https://www.linkedin.com/in/hani-gupta-3916b931b/


License

This project is licensed under the MIT License.

About

AI-powered MERN learning assistant that helps students study smarter using personalized learning paths, document-based Q&A, flashcards, quizzes, and real-time progress tracking.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages