How yesh-is-here2/teachai works
TeachAI is a Python tutoring app: learners can add notes, ask questions answered with retrieved note context, or request a structured lesson. The web app calls a FastAPI backend; the backend handles guest identity, note ingestion, retrieval, and lesson generation, with SQLite persistence and an in-memory vector index. The graph follows documented capabilities and excerpted calls; unsampled UI and backend details are not expanded beyond README evidence.
Main entry points: main.py FastAPI routes · page.tsx Tutor interface · crud.py User and notes CRUD · llm.py Embeddings and answers
Components 10
Web client
- Tutor interface
mobile_app/app/page.tsx
Backend API
- FastAPI routes
backend/main.py
Notes and retrieval
- Text chunking
backend/rag/chunking.py - Vector search
backend/rag/vectorstore.py
Persistence and AI
- User and notes CRUD
backend/db/crud.py - Relational schema
backend/db/models.py - SQLite database
backend/db/database.py - Embeddings and answers
backend/services/llm.py
Other components
- Learner
- OpenAI API
Connections 14
- Learner → Tutor interface: uses
README.md - Tutor interface → FastAPI routes: asks
mobile_app/app/page.tsx - Tutor interface → FastAPI routes: requests lessons
mobile_app/app/page.tsx - Tutor interface → FastAPI routes: submits notes
README.md - FastAPI routes → User and notes CRUD: checks and stores
backend/main.py - User and notes CRUD → Relational schema: queries and creates
backend/db/crud.py - FastAPI routes → SQLite database: opens sessions
backend/main.py - Relational schema → SQLite database: uses base
backend/db/models.py - FastAPI routes → Text chunking: chunks notes
backend/main.py - FastAPI routes → Embeddings and answers: embeds text
backend/main.py - FastAPI routes → Vector search: adds and searches
backend/main.py - FastAPI routes → User and notes CRUD: loads chunks
backend/main.py - FastAPI routes → Embeddings and answers: generates responses
backend/main.py - Embeddings and answers → OpenAI API: calls
backend/services/llm.py