An AI-powered Somali Quran Tafsiir assistant that provides grounded, accurate answers from Somali Quranic interpretation.
# Somali Tafsiir Agent
> **A high-performance, AI-driven assistant for Somali Quranic Tafsiir.**
An AI-powered Somali Quran Tafsiir assistant that provides grounded, accurate answers from Somali Quranic interpretation. Designed for the Somali AI community to make religious knowledge more accessible through state-of-the-art retrieval technology.
---
## 📖 Knowledge Base & Support
### 🧠 Model Memory
The intelligence of this agent is anchored by `data/trained.json`. This dataset serves as the primary source for creating the model's semantic memory, ensuring that every response is derived from authenticated Somali Tafsiir.
### 🎯 Supported Scope
* **Current AI Agent Focus**: Optimized for **Surah Al-Fatiha** and the **30th Juz (Juz Amma)**.
* **System Capability**: While the AI agent is currently tuned for these sections, the underlying **API and architecture support the entire Holy Quran (all 114 Surahs)**. You can easily extend the agent's memory to include the full Quran.
---
## ✨ Key Features
- **🎯 Semantic Precision**: Leverages `gemini-embedding-001` to understand deep religious context and Somali nuances.
- **⚡ Hybrid Retrieval**: Integrates **Memvid** for a powerful combination of vector similarity and lexical matching, ensuring exact verse lookups.
- **🛡️ Hallucination-Free**: strictly grounded in provided tafsiir data. If the information isn't in the context, the agent won't invent it.
- **📱 Premium Experience**: A modern, responsive interface with Islamic-inspired aesthetics, smooth micro-animations, and full dark mode support.
---
## 🛠 Tech Stack
- **Core**: Next.js 15 (App Router, React 19)
- **Styling**: Tailwind CSS 4 (Modern CSS engine)
- **Vector Memory**: @memvid/sdk (Local `.mv2` storage)
- **Intelligence**: Google Gemini 2.0 Flash
- **Data Source**: Custom Somali Tafsiir JSON (`data/trained.json`)
---
## 📁 Project Structure
```bash
├── data/ # Model memory source (trained.json) & Memvid DB
├── src/
│ ├── app/ …