Skip to content

akash15072004/FLASHCARD-ENGINE

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

37 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿง  Flashcard Engine

An intelligent flashcard application that transforms PDFs into comprehensive study decks using AI, with spaced repetition and progress tracking.


๐Ÿ‘จโ€๐Ÿ’ป Developed By

Akash Chaudhary ๐ŸŽ“ B.Tech Final Year (Information Technology) ๐Ÿ’ป Full Stack Developer | React | FastAPI | AI Enthusiast


๐Ÿš€ About Me

I am a final-year B.Tech IT student passionate about building scalable full-stack applications and integrating AI into real-world solutions. This project showcases my ability to design and develop an end-to-end system using modern technologies like FastAPI, React, and AI APIs.


๐ŸŒ Live Demo

๐Ÿš€ Frontend (Vercel)

๐Ÿ‘‰ https://flashcard-engine-steel.vercel.app

โš™๏ธ Backend API (Render)

๐Ÿ‘‰ https://flashcard-engine-qflr.onrender.com

๐Ÿ“˜ API Docs (Swagger)

๐Ÿ‘‰ https://flashcard-engine-qflr.onrender.com/docs

โœจ Features

๐ŸŽฏ Core Functionality

  • PDF to Flashcards: Upload any PDF and automatically generate comprehensive flashcards
  • RAG-Powered Generation: Semantic chunking ensures thorough coverage (237 cards from 8972 words)
  • Spaced Repetition: SM-2 algorithm schedules reviews based on your performance
  • Time-Based Analytics: Track how long you spend on each card to identify mastery levels
  • Active Recall: Type your answer before revealing to test true understanding

๐Ÿ“Š Progress Tracking

  • Mastery Dashboard: Track cards across 4 stages (New โ†’ Learning โ†’ Review โ†’ Mastered)
  • Streak Counter: Build daily study habits with streak tracking ๐Ÿ”ฅ
  • Weak Areas: Automatically identifies decks that need more attention
  • Activity Charts: Visualize your study patterns over the last 7 days
  • Time Analytics: See which cards are quick (mastered) vs slow (need practice)

๐ŸŽจ User Experience

  • Simplified Feedback: 3 clear options (Hard/Medium/Easy) with smart suggestions
  • Dark Mode: Toggle between light and dark themes
  • Real-time Search: Find decks and cards instantly
  • Mobile Responsive: Study anywhere on any device
  • Smooth Animations: Delightful transitions and card flips

๐Ÿš€ Quick Start

Prerequisites

Local Development

Backend Setup

cd backend

# Create virtual environment
python -m venv .venv
.venv\Scripts\activate  # On Windows

# Install dependencies
pip install -r requirements.txt

# Configure environment
cp .env.example .env
# Edit .env and add your GROQ_API_KEY

# Create test user (optional)
python create_test_user.py

# Start server
python -m uvicorn main:app --reload --host 0.0.0.0 --port 8000

Backend will be available at http://localhost:8000


Frontend Setup

cd frontend

# Install dependencies
npm install

# Start development server
npm run dev

Frontend will be available at http://localhost:5173


๐ŸŒ Deployment

Backend (Render)

  1. Create a new Web Service on Render

  2. Connect your GitHub repository

  3. Configure:

    • Root Directory: backend
    • Build Command: pip install -r requirements.txt
    • Start Command: uvicorn main:app --host 0.0.0.0 --port $PORT
  4. Add environment variables:

    • GROQ_API_KEY
    • JWT_SECRET
    • FRONTEND_URL

Frontend (Vercel)

  1. Import project on Vercel

  2. Configure:

    • Root Directory: frontend
    • Framework: Vite
  3. Add environment variable:

    • VITE_API_URL

๐Ÿ”‘ Test Credentials

Email: a@gmail.com
Password: 123456

๐Ÿ“– Usage Guide

Creating a Deck

  1. Click "New Deck" button
  2. Enter deck name and description
  3. Upload PDF OR enter topic
  4. Generate flashcards

Studying Cards

  • Read โ†’ Think โ†’ Flip โ†’ Rate
  • Difficulty: Hard / Medium / Easy

Tracking Progress

  • Monitor mastery levels
  • Check weak areas
  • Analyze performance

๐Ÿ—๏ธ Architecture

Tech Stack

Backend

  • FastAPI
  • SQLAlchemy
  • SQLite
  • Groq API
  • PyPDF2

Frontend

  • React + TypeScript
  • Vite
  • Tailwind CSS
  • Framer Motion
  • React Router

๐Ÿ“ Project Structure

flashcard-engine/
โ”œโ”€โ”€ backend/
โ”‚   โ”œโ”€โ”€ database/
โ”‚   โ”œโ”€โ”€ models/
โ”‚   โ”œโ”€โ”€ routes/
โ”‚   โ”œโ”€โ”€ services/
โ”‚   โ”œโ”€โ”€ main.py
โ”‚   โ””โ”€โ”€ requirements.txt
โ”‚
โ”œโ”€โ”€ frontend/
โ”‚   โ”œโ”€โ”€ src/
โ”‚   โ”‚   โ”œโ”€โ”€ components/
โ”‚   โ”‚   โ”œโ”€โ”€ pages/
โ”‚   โ”‚   โ”œโ”€โ”€ lib/
โ”‚   โ”‚   โ””โ”€โ”€ App.tsx
โ”‚   โ”œโ”€โ”€ package.json
โ”‚   โ””โ”€โ”€ vite.config.ts
โ”‚
โ””โ”€โ”€ README.md

๐Ÿ”ง API Endpoints

Authentication

  • POST /auth/register
  • POST /auth/login
  • GET /auth/me

Decks

  • GET /decks
  • POST /decks
  • GET /decks/{id}
  • DELETE /decks/{id}
  • POST /decks/{id}/upload-pdf
  • POST /decks/{id}/generate

Cards

  • GET /cards/deck/{id}
  • POST /cards/{id}/rate

๐Ÿงช How It Works

  1. Upload PDF
  2. Extract text
  3. AI generates flashcards
  4. Study using spaced repetition
  5. Track performance

๐ŸŽฏ Problem Statement

Convert static PDFs into interactive learning using AI and spaced repetition.


๐Ÿ“Š Results

  • ๐Ÿš€ Efficient AI-based flashcard generation
  • ๐Ÿ“ˆ Improved retention
  • ๐Ÿง  Smart learning tracking

๐Ÿ”ฎ Future Enhancements

  • Mobile app
  • Collaboration
  • Gamification
  • AI hints

๐Ÿ“ License

MIT License


๐Ÿค Contributing

Contributions are welcome!


๐Ÿ“ฌ Contact

๐Ÿ“ง akashchaudhary5100@gmail.com ๐Ÿ“ฑ 9140814285


โญ Built with โค๏ธ by Akash Chaudhary

About

AI-powered flashcard app that converts PDFs into smart study decks using FastAPI, React, and spaced repetition.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors