End-to-end offline LLM learning platform PoC: generate grounded lesson plans from curriculum + teacher profiles, classify student intents, and document how to scale the same stack to on-device Android with Yoruba support.
# Codematic AI/ML Engineer Assignment
Python PoC for Codematic Labs **Options 1 and 2**. This README walks through each deliverable, where to find the answer in code or docs, and how to run a quick demo.
**Live demo:**
offline-llm-api-5brde4y4ba-… (presentation UI + API)
**Live API:**
offline-llm-api-5brde4y4ba-…
**Repository:** Olamilekan002/offline-llm-learning-platform
**AI tooling disclosure:** AI_JOURNEY.md
---
## What this system does
The system generates a **single classroom lesson plan** from a larger curriculum document. The curriculum may represent a unit, term, or syllabus. The lesson generator extracts relevant concepts and produces a teacher-ready plan for **one instructional session**, not the full term or unit.
**Stack:** Gemma 3 1B Instruct (`gemma3:1b-it-qat`) via Ollama · FastAPI · Google Cloud Run
---
## Submission map
| # | Assignment deliverable | Answer location |
|---|------------------------|-----------------|
| 1 | Lesson pipeline (chunking, extraction, generation, guardrails) | Option 1 Part 1 |
| 2 | Intent classifier (10 queries + scaling) | Option 1 Part 2 |
| 3 | Code review (7B unquantized on VM) | Option 1 Part 3 |
| 4 | Offline LLM system design (Android) | Option 2 Part 1 |
| 5 | Yoruba/Hausa fine-tuning roadmap | Option 2 Part 2 |
| 6 | Founder stakeholder email | Option 2 Part 3 |
| 7 | `AI_JOURNEY.md`, docker-compose, live GCP URL | Run & deploy · Deploy to GCP |
---
## Option 1 Part 1: Lesson generation pipeline
### Requirement: Turn curriculum + teacher profile into a structured lesson plan
`POST /lesson-plan` accepts `teacher_id` + `curriculum_id`, loads catalogs from `data/`, runs the pipeline, saves the result, and returns a `StoredLessonPlan`.
| Step | What it does | Code |
|------|--------------|------|
| 1. Load inputs | Teacher profile + curriculum by ID | `teacher_store.py` · `curriculum_store.py` · `data/` |
| 2. Verify subject | Teacher `subjects` must include cur …