Logo Lanfrica

Guy0Kana/AI-Tutor

Domaine:

natural language processingeducation

Type de record:

software
Créateur:
Guy
Hôte:
A bilingual AI-powered curriculum assistant that helps students summarize chapters, answer revision questions, and ask general questions in both English and Swahili. Built with FastAPI for the backend and Next.js for the frontend, featuring interactive UI, theming, and real-time AI responses. ## Swahili–English AI Curriculum Tutor A bilingual AI-powered tutor for Form 1 students in Kenya (Biology and Geography). It summarizes chapters, answers official revision questions, and handles free-form questions—returning English and Swahili side-by-side using a RAG pipeline (Pinecone + OpenAI + LangChain). ## What’s new (Nov 2025) - Faster, smoother answers by switching default model to GPT‑4o‑mini (keeps quality with noticeably lower latency) - Snappier UX: optimized rendering, loading states, and input handling (no more UI loops; fluid transitions) - Cleaner, more formal interface (emoji-free), with consistent dark‑mode on both panels and a unified black gradient - Revision flow upgraded: all chapter questions grouped in one place with clear numbering and bilingual answers - Precision retrieval: better chapter filtering and noise suppression (header/boilerplate filtering, deduplication) - Backend translates questions to Swahili for the Swahili panel while preserving the original English on the left - Safer Pinecone usage: namespace safeguards and re‑index stability improvements for consistent results - One‑click history clear, improved empty states, and a modernized Tutor page aligned with the landing page ## Tech stack - Frontend: Next.js, React, Tailwind CSS, next-themes - Backend: FastAPI (Uvicorn) - AI: OpenAI (GPT-4o-mini by default) via LangChain - Vector DB: Pinecone ## Project structure (high level) ``` ai_tutor/ ├─ backend/ │ ├─ main.py # FastAPI app entry │ └─ app/ │ ├─ routes.py # REST endpoints │ └─ schemas.py # Pydantic models ├─ frontend/ │ ├─ pages/ │ │ ├─ index.js # Landing page (matrix effect) │ │ └─ tutor.js # Tutor UI (modes: summarize, revision, ask) │ └─ styles/globals.css # Tailwind + animations ├─ src/ │ ├─ ai_engine.py # Core RAG + bilingual output │ ├─ chunk_and_embed.py # Ingestion + embedding to Pinecone │ └─ utils/ # prompts, token utils, filtering ├─ data/ …

Languages