StudyMate AI
Your course, your pace, your personal tutor.
Inspiration
A student's study material is scattered: recorded lectures in one place, a PDF textbook in another, the professor's slides somewhere else. When you get stuck, you lose time scrubbing through hours of video or flipping through hundreds of pages. General-purpose AI chatbots help, but they answer from the open internet, sometimes confidently wrong, with no way to check where an answer came from. And most quizzes treat every student the same, so weak areas never really get fixed.
We wanted a tutor that learns only from your own course material, shows exactly where every answer comes from, and adapts to what you actually understand.
What it does
StudyMate AI turns lecture videos, textbooks and slides into one source-cited knowledge base, then uses it to teach, test and track each student.
- Subjects as folders: create subjects like OS, ML or DBMS and upload material into each one.
- Upload anything: PDFs, PowerPoint slides, MP4 lectures and YouTube links. Videos are transcribed with timestamps; PDFs and slides keep their page and slide numbers.
- Automatic topic extraction: the AI reads each source and organises it into study topics.
- Two ways to learn:
- Understand it simply: a connected, beginner-friendly story of the whole material, with everyday analogies.
- Key topics in detail: the most important topics ranked, each with a detailed explanation, examples, common mistakes, exam tips and a practice question.
- Source citations everywhere: every explanation points back to the exact page, slide or video timestamp it came from.
- Highlighted learning: keywords and key sentences are highlighted, with a glossary of terms.
- Adaptive quizzes: questions are generated from your own material across Bloom's levels (remember, understand, apply). Get it right and it gets harder; get it wrong and it gives an easier question on the same topic with an explanation.
- Concept evaluation (Feynman technique): explain a topic in your own words; the answer is graded against a rubric built from the source material, flagging missed ideas and misconceptions.
- Understanding ranking: every topic gets a score from 0 to 100 combining quiz and evaluation results, ranked weakest to strongest with a recommended next step.
- Accounts: sign up and log in; each student's material and progress stay private.
The core loop: Explain → Quiz → Evaluate → Rank → re-teach weak topics.
How we built it
- Frontend: React + Vite with Tailwind CSS, React Router, Axios, Recharts for mastery charts and react-player for jumping to video timestamps.
- Backend: Python FastAPI with SQLModel on SQLite for users, subjects, sources, topics, quiz attempts and mastery scores; JWT authentication with bcrypt password hashing.
- Ingestion: PyMuPDF for PDFs, python-pptx for slides, FFmpeg and yt-dlp for audio, and Groq's Whisper Large v3 for timestamped transcription.
- Knowledge base (RAG): text is chunked with its source location attached, embedded with BAAI bge-small-en-v1.5 via fastembed, and stored in ChromaDB, filtered per user and subject.
- AI: Groq running GPT-OSS-20B for topic extraction, explanations, quiz generation and grading. Responses are requested as JSON and validated with Pydantic, and citations are built from chunk metadata in code, so the model never invents a source.
- Adaptive engine: per-topic mastery scores that rise on correct answers and fall on wrong ones, weighted by difficulty, which pick the next topic and difficulty.
- Deployment: Docker, with the frontend on Vercel and the backend on Render.
Challenges we ran into
- A changing model landscape: Groq retired the Llama models many tutorials still use, so we moved to GPT-OSS-20B mid-build.
- Unreliable structured output: large nested JSON replies were sometimes cut off or slightly malformed. We built a helper that detects truncated replies, recovers JSON, retries, and uses lenient validation so one missing field never breaks a whole explanation.
- Topic extraction: strict rules and trusting the model to remember chunk IDs caused valid sources to fail. We switched to assigning chunks to topics by embedding similarity, with a fallback so every upload still becomes usable.
- Deployment: CORS mismatches, Python version conflicts in Docker, duplicate backend services, and the free hosting tier running out of memory when loading the embedding model, which also wiped the temporary storage. We learned to debug systematically with logs, preflight tests and the browser network panel.
Accomplishments that we're proud of
- Every answer is grounded in the student's own material and cited down to the page, slide or timestamp.
- A full adaptive loop, not just a chatbot: it explains, tests, evaluates deep understanding and re-teaches weak spots.
- Concept evaluation that grades open-ended answers against a source-backed rubric instead of a vague "is this good?".
- An end-to-end product with accounts, subjects and a clean, student-friendly interface, built in a short time.
What we learned
- Retrieval-augmented generation is only as trustworthy as its metadata: keeping source locations attached to every chunk is what makes citations possible.
- Never trust an LLM to return perfect structure; validate, recover and fail gracefully.
- Deployment is its own engineering problem: memory limits, ephemeral storage and CORS matter as much as the code.
What's next for StudyMate AI
- Bayesian Knowledge Tracing for more accurate mastery estimates.
- An exam-date revision planner that schedules weak topics first.
- Hinglish and regional-language explanations.
- OCR for scanned PDFs and handwritten notes.
- Persistent cloud storage and lighter hosted embeddings for reliable production hosting.
- Shared class spaces so a teacher can upload once and see where the whole class is struggling.
Log in or sign up for Devpost to join the conversation.