CS4241 AI Exam 2026: Custom RAG chatbot (manual pipeline) for Ghana election results and 2025 budget analysis.
# Academic Insights Assistant (Next.js + FastAPI Manual RAG)
> **CS4241 – Introduction to Artificial Intelligence**
> Academic City University — End of Second Semester Examination, 2026
**Student Name:** Lawrence Effah
**Index Number:** 10022200083
This project is a full custom RAG chatbot system for academic evaluation, built without LangChain, LlamaIndex, or any prebuilt RAG framework.
Frontend:
- Next.js App Router UI for chat, retrieval inspection, prompt inspection, and logs.
Backend:
- FastAPI with manual ingestion, chunking, embeddings, FAISS indexing, hybrid retrieval, prompt construction, generation, and request-level logging.
## Live Deployment
- Frontend (production):
academic-insights-assistant…
- Backend API (production):
backend-lake-delta-78.verce…
- Backend API Docs (Swagger):
backend-lake-delta-78.verce…
## Backend API Quick Links
- Swagger Docs:
backend-lake-delta-78.verce…
- OpenAPI JSON:
backend-lake-delta-78.verce…
## Video Walkthrough
- 2-minute walkthrough link:
drive.google.com
## Rubric Coverage (A-G)
| Part | Requirement | Status | Primary Evidence |
|---|---|---|---|
| A | Comparative chunking impact analysis write-up | Complete | part_a_chunking_analysis.md |
| B | Advanced retrieval | Complete (hybrid TF-IDF + FAISS) | retrieval.py |
| C | Prompt experiments + evidence | Complete | part_c_prompt_experiments.md |
| D | End-to-end API pipeline and logs | Complete | api.py, pipeline.py |
| E | Adversarial testing + RAG vs pure-LLM | Complete | part_e_adversarial_eval.md |
| F | Architecture diagram + explanation | Complete | part_f_architecture.md |
| G | Innovation component | Complete (feedback-aware retrieval memory) | part_g_innovation.md |
## Repository Structure
```text
academic-insights-assistant-nextjs/
app/ # Next.js app entry
src/ …