π‘ The Inspiration & Weekend Theme ("Build for a Friend")
As computer science students, my friends and I often find ourselves overwhelmed before semester exams and viva voce evaluations. We spend hours reading lengthy PDFs, scattered Markdown summaries, and messy lecture slidesβwishing we had a dedicated tutor to quiz us, point out missing details, and conduct practice mock vivas.
Existing cloud-based AI tools can generate quizzes, but they come with significant drawbacks for students:
- API Costs & Rate Limits: Most freemium AI tools quickly hit token limits or require recurring monthly subscriptions.
- Privacy Concerns: Class notes, proprietary course slides, and personal summaries get uploaded to centralized servers.
- Connectivity Issues: Campus Wi-Fi and hostel networks can be notoriously spotty, rendering web-based AI tools unusable right when you need to cram before an exam.
This weekend, I built StudyBuddy AI for my friends and classmates to solve this exact problem: a 100% local, offline-first study companion that turns any lecture note into interactive practice quizzes, 3D flashcards, and mock viva sessions using open-weight Gemma models.
π οΈ What I Built: StudyBuddy AI
StudyBuddy AI is a full-stack, local-first web application designed to run seamlessly on a student's laptop without sending a single byte of data to the cloud.
π Key Features
- π― Interactive Quiz Mode: Automatically extracts key concepts from notes to generate multiple-choice questions (MCQs) with instant visual feedback, step-by-step hints, and explanations.
- π 3D Flashcard Deck: Interactive term/definition cards with smooth 3D flip animations powered by Framer Motion for rapid retention review.
- π Mock Viva Practice: Open-ended conceptual prompts where students can practice answering viva questions and evaluate their responses against model answers.
- π Multi-Format Ingestion: Drag-and-drop parsing for PDF documents, Markdown files, and plain text notes.
- π Zero-Cloud & Offline-First: Powered locally by Ollama running open-weight Gemma models (
gemma:2b,gemma2:2b, orgemma:7b).
π» Tech Stack & Architecture
- Frontend: React 19, Vite, Tailwind CSS v4, Framer Motion, Lucide Icons
- Backend: Node.js, Express.js (custom file stream parsers & JSON repair middleware)
- Local AI Inference: Ollama orchestrating Google's Gemma open-weight models
Architecture
βββββββββββββββββββ βββββββββββββββββββ ββββββββββββββββββββ
β π Upload Notes β ββββ> β π Node Parser β ββββ> β π€ Ollama / Gemma β
β (PDF / MD / TXT)β β & Text Cleaner β β (Local Engine) β
βββββββββββββββββββ βββββββββββββββββββ ββββββββββ¬ββββββββββ
β
βΌ
βββββββββββββββββββ βββββββββββββββββββ
β π Interactive β <ββββ β π§ Robust JSON β <ββββββββββββββββ
β React 19 UI β β Repair Layer β
βββββββββββββββββββ βββββββββββββββββββ
π Why Open Innovation Matters for StudyBuddy AI
Building StudyBuddy AI on open-source foundations wasn't just a technical choiceβit was essential to fulfilling the project's purpose:
Zero Financial Barriers for Students: By leveraging Google's open-weight Gemma models running via Ollama, StudyBuddy AI delivers AI inference without requiring expensive API keys or recurring subscription fees. Any student with a compatible laptop can run smaller Gemma models locally.
Total Data Privacy: Personal class notes, assignment solutions, and university materials can remain entirely on the user's local machine. No cloud-based AI service is required for inference.
True Offline Resilience: University hostels, libraries, and remote areas often lack stable internet access. Because StudyBuddy AI executes inference locally through Ollama, students can study without depending on a continuous internet connection.
Resilience via Open Ecosystems: If a proprietary AI API changes pricing, availability, or access requirements, cloud-dependent applications can be affected. Open-weight models give developers greater control over the AI layer of their applications.
π Prize Category Opt-In
Best Use of Gemma ($200)
StudyBuddy AI relies on Google's Gemma family of open-weight models (gemma:2b, gemma2:2b, and gemma:7b) served locally via Ollama.
It uses structured prompts and JSON-oriented generation to transform unstructured student notes into:
- Interactive quiz decks
- Multiple-choice questions
- Flashcards
- Viva questions
- Model answers
- Explanations
- Hints
A JSON repair layer helps make model-generated responses more robust before they are consumed by the frontend.
π Code Repository & Demo
- GitHub Repository: StudyBuddy AI on GitHub
- Author: Babin Bid
π Quick Start Guide
Want to run StudyBuddy AI locally on your machine?
1. Install & Run Gemma via Ollama
Ensure Ollama is installed, then pull your preferred Gemma model.
For standard laptops, a smaller model such as gemma2:2b can be used:
ollama pull gemma2:2b
You can also use:
ollama pull gemma:2b
or:
ollama pull gemma:7b
Start the Ollama local server:
ollama serve
2. Clone & Install StudyBuddy AI
Clone the repository:
git clone https://github.com/Babin123456/StudyBuddy_AI.git
cd StudyBuddy_AI
Install the frontend dependencies:
npm install
Install the backend dependencies:
cd backend
npm install
cd ..
3. Launch the Application
Open two terminal windows.
Terminal 1 β Backend
cd backend
npm run dev
Terminal 2 β Frontend
npm run dev
4. Open the Application
Navigate to:
in your browser.
Drag and drop your lecture notes and start preparing for your exams locally.
π How StudyBuddy AI Works
The complete workflow looks like this:
π Lecture Notes
β
βΌ
ββββββββββββββββββββββββ
β PDF / Markdown / TXT β
ββββββββββββ¬ββββββββββββ
β
βΌ
π Text Extraction
β
βΌ
π§Ή Text Cleaning
β
βΌ
π§ Structured Prompt
β
βΌ
π€ Gemma via Ollama
β
βΌ
π§ JSON Repair Layer
β
βΌ
π React 19 Interface
β
βββββββΌββββββ
βΌ βΌ βΌ
Quiz Cards Viva
π― The Learning Experience
Instead of simply reading notes repeatedly:
Read β Highlight β Read Again β Forget β Panic
StudyBuddy AI turns the same material into an active learning workflow:
Upload Notes
β
Extract Concepts
β
Generate Questions
β
Practice
β
Identify Weak Areas
β
Review
β
Practice Again
The goal is not to replace studying.
The goal is to make the material students already have more interactive and useful for active recall.
π Privacy-First Design
StudyBuddy AI is designed around a local-first architecture.
The intended processing pipeline is:
βββββββββββββββββββββββββββββββββββββββ
β Student's Computer β
β β
β π Lecture Notes β
β β β
β βΌ β
β π Node.js Parser β
β β β
β βΌ β
β π§Ή Text Cleaner β
β β β
β βΌ β
β π€ Ollama + Gemma β
β β β
β βΌ β
β π§ JSON Repair β
β β β
β βΌ β
β π React Interface β
β β
βββββββββββββββββββββββββββββββββββββββ
No required
cloud AI inference
This means the application can be used without sending lecture notes to a remote AI provider for inference.
π§ Why Local AI?
Local AI provides several practical advantages for a student-focused application.
Privacy
Study materials can contain:
- University lecture slides
- Assignment solutions
- Personal notes
- Research material
- Course-specific documents
Keeping inference local reduces the need to upload these materials to third-party AI services.
Cost
Running an open-weight model locally eliminates the need for a paid AI API for the core inference workflow.
Availability
Once the required software, dependencies, and models are installed, the application can continue operating without requiring a continuous internet connection.
Control
The developer controls:
- The AI runtime
- The model selection
- The prompts
- The application logic
- The document-processing pipeline
π§© Supported Study Modes
π― Interactive Quiz Mode
StudyBuddy AI can transform lecture material into multiple-choice questions.
Each question can include:
- Question
- Multiple options
- Correct answer
- Explanation
- Hint
This allows students to immediately test their understanding.
π 3D Flashcards
Important concepts can be converted into interactive flashcards.
The interface uses smooth 3D animations to create a more engaging revision experience.
A typical card contains:
βββββββββββββββββββββββββββ
β β
β QUESTION β
β β
β What is a process? β
β β
βββββββββββββββββββββββββββ
β Flip
βββββββββββββββββββββββββββ
β β
β ANSWER β
β β
β A program in execution. β
β β
βββββββββββββββββββββββββββ
π Mock Viva Practice
Students can practice open-ended questions similar to those they might encounter during a viva.
The workflow is:
Viva Question
β
Student's Answer
β
Model Answer
β
Comparison
β
Identify Missing Concepts
This encourages students to practice explaining concepts rather than simply recognizing correct answers.
π οΈ Technology Stack
| Layer | Technology |
|---|---|
| Frontend | React 19 |
| Build Tool | Vite |
| Styling | Tailwind CSS v4 |
| Animation | Framer Motion |
| Icons | Lucide Icons |
| Backend | Node.js |
| API Framework | Express.js |
| AI Runtime | Ollama |
| AI Model | Google Gemma |
| Document Inputs | PDF, Markdown, TXT |
| Architecture | Local-first / Offline-first |
π What Makes StudyBuddy AI Different?
| Traditional Cloud AI Workflow | StudyBuddy AI |
|---|---|
| Cloud AI service | Local AI inference |
| Internet dependency | Offline-first design |
| API keys may be required | No AI API key required |
| Recurring API costs may apply | Local model usage |
| Notes may be uploaded | Local processing |
| General-purpose AI | Study-focused workflow |
| Generic interaction | Quiz, flashcards & viva |
π Future Roadmap
Future versions of StudyBuddy AI could include:
- π Personalized learning progress
- π§ Adaptive question difficulty
- π― Weak-topic detection
- π Subject-wise study libraries
- π Advanced document parsing
- π€ Voice-based mock viva
- π£οΈ Speech-to-text answers
- π Detailed performance analytics
- π§© Additional open-weight models
- πΎ Persistent local study history
- π΄ Improved offline application packaging
- π₯οΈ Desktop application support
The long-term goal is to evolve StudyBuddy AI into a complete private local AI study environment.
π Why I Built It
The idea came from a simple observation:
Students already have the study material. What they often lack is an interactive way to practice it.
Instead of requiring students to upload their notes to another company's servers, StudyBuddy AI brings the AI directly to the student's machine.
That makes the project particularly useful for students who value:
- Privacy
- Accessibility
- Offline availability
- Low cost
- Data ownership
- Open-source technology
ποΈ Project Philosophy
StudyBuddy AI follows three simple principles:
1. AI Should Be Accessible
Students shouldn't need expensive subscriptions to experiment with AI-powered learning.
2. Privacy Should Be Built In
A student's lecture notes shouldn't need to leave their computer simply to generate a quiz.
3. Open Technology Creates More Possibilities
Open-weight models such as Gemma allow developers to experiment, build, modify, and integrate AI into applications without depending entirely on proprietary APIs.
π Project Summary
βββββββββββββββββββββββββββββββββββββββββββββββββ
β STUDYBUDDY AI β
βββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
β π Input β
β PDF / Markdown / TXT β
β β
β β β
β β
β π Processing β
β Node.js + Express β
β β
β β β
β β
β π€ Intelligence β
β Ollama + Gemma β
β β
β β β
β β
β π§ Structured Output β
β JSON Repair / Validation β
β β
β β β
β β
β π Learning β
β Quiz + Flashcards + Viva β
β β
β β β
β β
β π§ Active Revision β
β β
βββββββββββββββββββββββββββββββββββββββββββββββββ
π Final Thoughts
StudyBuddy AI started with a simple weekend challenge:
What if a student could have an AI study companion without sending their notes anywhere?
The result is a local-first learning platform powered by open-weight Gemma models and Ollama.
It combines:
Open AI Models + Local Inference + Student Notes + Interactive Learning
into one privacy-focused study workflow.
The bigger idea is simple:
AI should not always require the cloud.
For students, developers, and privacy-conscious users, local AI can provide a practical alternative to cloud-only applications.
π Links
- GitHub Repository: https://github.com/Babin123456/StudyBuddy_AI
- Author: https://github.com/Babin123456
- Ollama: https://ollama.com/
β€οΈ Built for Students
Built with passion by Babin Bid for the Hacktoberfest 2026 Weekend Challenge.
Because every student deserves a private, offline, and accessible AI study companion.
Top comments (0)