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:
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.
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.
gemma:2b, gemma2:2b, or gemma:7b).
βββββββββββββββββββ βββββββββββββββββββ ββββββββββββββββββββ
β π Upload Notes β ββββ> β π Node Parser β ββββ> β π€ Ollama / Gemma β
β (PDF / MD / TXT)β β & Text Cleaner β β (Local Engine) β
βββββββββββββββββββ βββββββββββββββββββ ββββββββββ¬ββββββββββ
β
βΌ
βββββββββββββββββββ βββββββββββββββββββ
β π Interactive β <ββββ β π§ Robust JSON β <ββββββββββββββββ
β React 19 UI β β Repair Layer β
βββββββββββββββββββ βββββββββββββββββββ
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.
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:
A JSON repair layer helps make model-generated responses more robust before they are consumed by the frontend.
Want to run StudyBuddy AI locally on your machine?
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
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 ..
Open two terminal windows.
cd backend
npm run dev
npm run dev
Navigate to:
in your browser.
Drag and drop your lecture notes and start preparing for your exams locally.
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
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.
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.
Local AI provides several practical advantages for a student-focused application.
Study materials can contain:
Keeping inference local reduces the need to upload these materials to third-party AI services.
Running an open-weight model locally eliminates the need for a paid AI API for the core inference workflow.
Once the required software, dependencies, and models are installed, the application can continue operating without requiring a continuous internet connection.
The developer controls:
StudyBuddy AI can transform lecture material into multiple-choice questions.
Each question can include:
This allows students to immediately test their understanding.
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. β
β β
βββββββββββββββββββββββββββ
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.
| 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 |
| 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 versions of StudyBuddy AI could include:
The long-term goal is to evolve StudyBuddy AI into a complete private local AI study environment.
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:
StudyBuddy AI follows three simple principles:
Students shouldn't need expensive subscriptions to experiment with AI-powered learning.
A student's lecture notes shouldn't need to leave their computer simply to generate a quiz.
Open-weight models such as Gemma allow developers to experiment, build, modify, and integrate AI into applications without depending entirely on proprietary APIs.
βββββββββββββββββββββββββββββββββββββββββββββββββ
β STUDYBUDDY AI β
βββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
β π Input β
β PDF / Markdown / TXT β
β β
β β β
β β
β π Processing β
β Node.js + Express β
β β
β β β
β β
β π€ Intelligence β
β Ollama + Gemma β
β β
β β β
β β
β π§ Structured Output β
β JSON Repair / Validation β
β β
β β β
β β
β π Learning β
β Quiz + Flashcards + Viva β
β β
β β β
β β
β π§ Active Revision β
β β
βββββββββββββββββββββββββββββββββββββββββββββββββ
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.
Built with passion by Babin Bid for the Hacktoberfest 2026 Weekend Challenge.
Because every student deserves a private, offline, and accessible AI study companion.