Transform Lecture Slides into Structured Knowledge
SlideMind AI is a production-grade, AI-powered smart learning platform that converts static lecture slides (PDF/PPTX) into dynamic, interactive study experiences β complete with summaries, topic breakdowns, AI chat tutoring, and custom practice exams.
SlideMind AI takes your lecture materials and runs them through a pipeline of AI features β all accessible through a clean, focused light-theme interface built for long study sessions.
Upload once. Summarize instantly. Study smarter.
- Executive Summaries β instantly distills lecture content into a concise overview with key bullet points and exam-critical focus areas
- Topic Extraction β automatically identifies 3β7 distinct topics from your slides and builds a structured knowledge map
- Deep-Dive Explanations β click any topic to get a teacher-style breakdown with real-world examples, formatted in clean Markdown
- AI Chat Tutor β a contextual assistant that has "read" your slides and answers your specific questions 24/7
- Smart Quiz Generator β generates configurable MCQ practice exams (Easy / Medium / Hard, 5β15 questions) with explanations for every answer
- AI results (summaries, topics) are saved to the database after the first generation
- Reopening a lecture from history never re-calls the AI β results load instantly at zero token cost
- A β AI cached badge appears on history cards so you always know what's pre-processed
- Upload PDF and PowerPoint (PPTX/PPT) files up to 50MB
- Full upload history per user account, sorted by most recent
- One-click delete to remove any lecture from your history
- Session-based document state so your active lecture persists across tabs
- Secure JWT-based signup and login
- All documents and AI cache are scoped to the authenticated user
- Demo mode available without login β try the full feature set with a sample lecture
- Premium light theme (Slate/White/Brand Blue) optimized for focus
- Smooth Framer Motion animations throughout
- Glassmorphism cards and custom scrollbar styling
- Fully responsive β works on desktop and mobile
| Technology | Purpose |
|---|---|
| Next.js 14 (App Router) | React framework with SSR |
| Tailwind CSS | Utility-first styling |
| Framer Motion | Animations and transitions |
| Lucide React | Icon library |
| React Hot Toast | Notification toasts |
| React Markdown | Rendering AI Markdown output |
| Axios | HTTP client with interceptors |
| Technology | Purpose |
|---|---|
| FastAPI | Async Python API framework |
| Google Gemini 2.5 Flash | AI summarization, chat, quiz |
| SQLAlchemy 2.0 | Async ORM |
| SQLite + aiosqlite | Local database (dev) |
| python-pptx | PowerPoint parsing |
| pdfminer.six | PDF text extraction |
| python-jose | JWT authentication |
| passlib + bcrypt | Password hashing |
| Uvicorn | ASGI server |
| Technology | Purpose |
|---|---|
| Google Cloud Run | Serverless container hosting |
| Google Cloud Build | Automated container builds |
| Google Artifact Registry | Container image storage |
| Docker | Containerization |
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β User's Browser β
β Next.js 14 Frontend (App Router) β
β Tailwind CSS Β· Framer Motion Β· Axios β
ββββββββββββββββββββββββ¬βββββββββββββββββββββββββββββββββββ
β HTTPS REST API
ββββββββββββββββββββββββΌβββββββββββββββββββββββββββββββββββ
β FastAPI Backend (Cloud Run) β
β β
β ββββββββββββ ββββββββββββ ββββββββββββ ββββββββββ β
β β /upload β β /ai β β /quiz β β /auth β β
β ββββββββββββ ββββββββββββ ββββββββββββ ββββββββββ β
β β β
β ββββββββββββ΄βββββββββββ β
β β β β
β ββββββββΌβββββββ ββββββββββΌβββββββββ β
β β SQLite DB β β Gemini 2.5 β β
β β (Users, β β Flash API β β
β β Documents, β β (Summarize, β β
β β AI Cache) β β Chat, Quiz) β β
β βββββββββββββββ βββββββββββββββββββ β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
| Method | Endpoint | Description | Auth |
|---|---|---|---|
POST |
/api/auth/signup |
Create new account | β |
POST |
/api/auth/login |
Login, returns JWT | β |
GET |
/api/auth/me |
Get current user | β |
POST |
/api/upload/ |
Upload and parse PDF/PPTX | β |
GET |
/api/upload/history |
Get user's document history | β |
DELETE |
/api/upload/{id} |
Delete a document | β |
POST |
/api/ai/summarize |
Generate AI summary (cached) | Optional |
POST |
/api/ai/topics |
Extract topic structure (cached) | Optional |
POST |
/api/ai/explain |
Deep-dive explanation | Optional |
POST |
/api/ai/chat |
Chat with slide content | Optional |
POST |
/api/quiz/generate |
Generate MCQ quiz | Optional |
- Node.js v18+
- Python v3.10+
- A Google Gemini API Key
git clone https://github.com/Ahtisham992/slidemind-ai.git
cd slidemind-aicd backend
# Create and activate virtual environment
python -m venv venv
# Windows:
.\venv\Scripts\activate
# Linux/Mac:
source venv/bin/activate
# Install dependencies
pip install -r requirements.txt
# Create environment file
echo "GOOGLE_API_KEY=your_gemini_api_key_here" > .env
echo "SECRET_KEY=your_jwt_secret_here" >> .env
# Start the server
uvicorn main:app --reloadBackend runs at http://localhost:8000 Β· API docs at http://localhost:8000/docs
cd frontend
# Install dependencies
npm install
# Create environment file
echo "NEXT_PUBLIC_API_URL=http://localhost:8000" > .env.local
# Start dev server
npm run devFrontend runs at http://localhost:3000
- gcloud CLI installed and authenticated
- A GCP project with billing enabled
- Gemini API enabled:
gcloud services enable generativelanguage.googleapis.com
cd backend
gcloud run deploy slidemind-api \
--source . \
--allow-unauthenticated \
--region us-central1 \
--set-env-vars GOOGLE_API_KEY=your_key,SECRET_KEY=your_secretcd frontend
gcloud run deploy slidemind-ui \
--source . \
--allow-unauthenticated \
--region us-central1 \
--set-env-vars NEXT_PUBLIC_API_URL=https://your-backend-url.run.appgcloud run services update slidemind-api \
--region us-central1 \
--update-env-vars GOOGLE_API_KEY=new_key_hereThe current setup uses SQLite stored inside the container, which means data is wiped on every deployment or container restart. For production, migrate to a persistent database:
Option A β Google Cloud SQL (PostgreSQL)
gcloud sql instances create slidemind-db \
--database-version=POSTGRES_15 \
--tier=db-f1-micro \
--region=us-central1Then update DATABASE_URL in backend/database.py to use postgresql+asyncpg://.
Option B β Supabase (Free tier) Sign up at supabase.com, create a project, and use the provided PostgreSQL connection string.
SlideMind AI uses Gemini 2.5 Flash which is highly cost-efficient:
| Operation | Est. tokens | Notes |
|---|---|---|
| Summarize | ~1,500 | Cached after first call |
| Topic extraction | ~2,000 | Cached after first call |
| Topic explanation | ~1,200 | Per topic click |
| Quiz (10 questions) | ~2,500 | Per quiz attempt |
| Chat message | ~800 | Always live |
At $0.15 / 1M input tokens, you can run approximately 80,000 summarizations for $1. The DB caching system ensures AI is only called once per document for summaries and topics.
slidemind-ai/
βββ backend/
β βββ models/
β β βββ db_models.py # SQLAlchemy ORM models (User, Document)
β β βββ schemas.py # Pydantic request/response schemas
β βββ routers/
β β βββ ai.py # AI endpoints (summarize, topics, chat, explain)
β β βββ auth.py # JWT authentication endpoints
β β βββ quiz.py # Quiz generation endpoint
β β βββ upload.py # File upload, history, delete endpoints
β βββ services/
β β βββ auth_service.py # Password hashing, JWT encode/decode
β β βββ file_parser.py # PDF and PPTX parsing logic
β β βββ gemini_service.py # All Gemini AI API calls
β βββ database.py # SQLAlchemy engine and session setup
β βββ main.py # FastAPI app, middleware, router registration
β βββ requirements.txt # Python dependencies
β βββ Dockerfile # Container definition
β
βββ frontend/
β βββ src/
β βββ app/
β β βββ page.js # Landing page with demo mode
β β βββ upload/ # Upload page with history and delete
β β βββ learn/ # Main study interface (tabs)
β β βββ login/ # Login page
β β βββ signup/ # Signup page
β βββ components/
β β βββ ChatAssistant.js # AI chat sidebar
β β βββ SummaryPanel.js # Summary + key points display
β β βββ TopicsPanel.js # Topic cards + deep-dive view
β β βββ QuizPanel.js # Interactive MCQ quiz
β β βββ UploadZone.js # Drag-and-drop file upload
β β βββ Navbar.js # Top navigation with auth state
β β βββ Footer.js # Site footer
β βββ context/
β β βββ AuthContext.js # Global auth state (login, logout, user)
β βββ lib/
β βββ api.js # Axios API client with auth interceptor
β βββ demoData.js # Static demo document for unauthenticated demo
β
βββ docker-compose.yml # Local multi-service development
βββ DEPLOYMENT.md # Step-by-step Cloud Run deployment guide
βββ README.md # This file
- SQLite database is ephemeral on Cloud Run (data lost on redeploy)
- Quiz results are not cached or saved to history
- No support for image-heavy slides (text extraction only)
- Single language support (English)
- Persistent PostgreSQL database (Cloud SQL / Supabase)
- Quiz result history and score tracking
- Flashcard generation mode
- Multi-language support
- Slide image OCR for scanned PDFs
- Study session scheduling and reminders
- Export summaries as PDF or Word documents
- Collaborative study rooms
Contributions are welcome! Please feel free to open an issue or submit a pull request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
This project is licensed under the MIT License β see the LICENSE file for details.
Muhammad Ahtisham
Crafted with π§ and β by Muhammad Ahtisham
If this project helped you, consider giving it a β on GitHub!