# raniaakrout/khallinetfaker architecture

> Architecture diagram of the GitHub repository raniaakrout/khallinetfaker, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-06). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/raniaakrout/khallinetfaker
- Repository: https://github.com/raniaakrout/khallinetfaker

## Overview

KhalliNetfaker accepts meeting transcripts, indexes and summarizes them, then supports cited question answering through a tool-using agent. The main runtime path is upload → deduplication and processing → vector indexing and minutes → chat retrieval or summary. Separate capabilities include authentication, evaluation, and configurable benchmarking. The graph reflects the README and available excerpts; some frontend/API and benchmark wiring is documented but not visible in sampled source, so those links are documented rather than inferred from imports.

Main entry points: [`meeting_rag/src/api/main.py`](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/api/main.py) (Transcript and chat API), [`meeting_rag/src/services/transcript_service.py`](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/services/transcript_service.py) (Upload orchestration), [`meeting_rag/database/crud.py`](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/database/crud.py) (Database operations), [`meeting_rag/src/rag/indexer.py`](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/rag/indexer.py) (Transcript indexer)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_frontend["Web interface"]
  node_web["Chat and upload UI<br/>[chat-interface.tsx]"]
  node_upload_ui["Upload dialog<br/>[upload-modal.tsx]"]
  node_benchmark_ui["Benchmark interface"]
  node_api_client["API client<br/>[api.ts]"]
end

subgraph group_api["API and access"]
  node_auth_api["Authentication routes<br/>[auth.py]"]
  node_main_api["Transcript and chat API<br/>[main.py]"]
  node_security["JWT and password security<br/>[security.py]"]
end

subgraph group_ingestion["Transcript processing"]
  node_transcript_service["Upload orchestration"]
  node_indexer["Transcript indexer<br/>[indexer.py]"]
  node_loader["Transcript loader<br/>[loader.py]"]
  node_chunking["Chunking strategies<br/>[chunker.py]"]
  node_summarizer["Minutes summarizer<br/>[summarizer.py]"]
  node_schemas["Minutes and API schemas<br/>[schemas.py]"]
end

subgraph group_intelligence["Answering and evaluation"]
  node_agent["LangGraph agent<br/>[agent.py]"]
  node_rag_tools["Search and summary tools<br/>[tools.py]"]
  node_retriever["Chunk retrieval<br/>[retriever.py]"]
  node_vector_store[("FAISS vector store<br/>[vector_store.py]")]
  node_embeddings["Text embeddings<br/>[embeddings.py]"]
  node_evaluation["Quality evaluation"]
  node_benchmark_api["RAG benchmarking"]
end

subgraph group_persistence["Stored data"]
  node_db_crud["Database operations<br/>[crud.py]"]
  node_db_models["Relational data models<br/>[models.py]"]
  node_postgres[("PostgreSQL<br/>[db.py]")]
  node_file_store[("Transcript files")]
end

node_user(("Meeting user"))

node_user -->|"uses"| node_web
node_web -->|"opens"| node_upload_ui
node_web -.->|"requests"| node_api_client
node_upload_ui -.->|"uploads through"| node_api_client
node_api_client -->|"calls API"| node_main_api
node_user -->|"authenticates"| node_auth_api
node_auth_api -->|"creates tokens"| node_security
node_auth_api -->|"looks up and creates users"| node_db_crud
node_security -->|"loads user"| node_db_crud
node_main_api -->|"processes upload"| node_transcript_service
node_transcript_service -->|"builds index"| node_indexer
node_indexer -->|"loads transcript"| node_loader
node_indexer -->|"chunks text"| node_chunking
node_indexer -->|"builds vectors"| node_vector_store
node_transcript_service -->|"generates minutes"| node_summarizer
node_summarizer -->|"loads transcript"| node_loader
node_summarizer -->|"chunks text"| node_chunking
node_transcript_service -->|"persists minutes and metadata"| node_db_crud
node_transcript_service -->|"writes transcript"| node_file_store
node_main_api -->|"invokes"| node_agent
node_agent -->|"selects tools"| node_rag_tools
node_rag_tools -.->|"searches chunks"| node_retriever
node_retriever -->|"retrieves vectors"| node_vector_store
node_vector_store -->|"uses embeddings"| node_embeddings
node_main_api -->|"saves chat"| node_db_crud
node_db_crud -->|"queries and updates"| node_db_models
node_db_models -->|"maps tables"| node_postgres
node_main_api -->|"runs evaluation"| node_evaluation
node_evaluation -->|"uses retrieved context"| node_retriever
node_user -->|"configures benchmark"| node_benchmark_ui
node_benchmark_ui -.->|"starts comparison"| node_benchmark_api
node_main_api -->|"registers routes"| node_benchmark_api

click node_web "https://github.com/raniaakrout/khallinetfaker/blob/main/transcript-upload-pipeline/components/chat-interface.tsx"
click node_upload_ui "https://github.com/raniaakrout/khallinetfaker/blob/main/transcript-upload-pipeline/components/upload-modal.tsx"
click node_benchmark_ui "https://github.com/raniaakrout/khallinetfaker/blob/main/transcript-upload-pipeline/components/benchmark-modal.tsx"
click node_api_client "https://github.com/raniaakrout/khallinetfaker/blob/main/transcript-upload-pipeline/lib/api.ts"
click node_auth_api "https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/api/auth.py"
click node_main_api "https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/api/main.py"
click node_security "https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/utils/security.py"
click node_transcript_service "https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/services/transcript_service.py"
click node_indexer "https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/rag/indexer.py"
click node_loader "https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/loader.py"
click node_chunking "https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/chunker.py"
click node_summarizer "https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/summarizer.py"
click node_schemas "https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/schemas.py"
click node_agent "https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/agent.py"
click node_rag_tools "https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/rag/tools.py"
click node_retriever "https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/rag/retriever.py"
click node_vector_store "https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/rag/vector_store.py"
click node_embeddings "https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/rag/embeddings.py"
click node_evaluation "https://github.com/raniaakrout/khallinetfaker/tree/main/meeting_rag/src/evaluation"
click node_benchmark_api "https://github.com/raniaakrout/khallinetfaker/tree/main/meeting_rag/src/api"
click node_db_crud "https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/database/crud.py"
click node_db_models "https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/database/models.py"
click node_postgres "https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/database/db.py"
click node_file_store "https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/services/transcript_service.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_web,node_upload_ui,node_benchmark_ui,node_api_client,node_user toneBlue
class node_auth_api,node_main_api,node_security toneAmber
class node_transcript_service,node_indexer,node_loader,node_chunking,node_summarizer,node_schemas toneMint
class node_agent,node_rag_tools,node_retriever,node_vector_store,node_embeddings,node_evaluation,node_benchmark_api toneRose
class node_db_crud,node_db_models,node_postgres,node_file_store toneIndigo
```

## Components

### Web interface

- [Chat and upload UI](https://github.com/raniaakrout/khallinetfaker/blob/main/transcript-upload-pipeline/components/chat-interface.tsx): `transcript-upload-pipeline/components/chat-interface.tsx`
- [Upload dialog](https://github.com/raniaakrout/khallinetfaker/blob/main/transcript-upload-pipeline/components/upload-modal.tsx): `transcript-upload-pipeline/components/upload-modal.tsx`
- [Benchmark interface](https://github.com/raniaakrout/khallinetfaker/blob/main/transcript-upload-pipeline/components/benchmark-modal.tsx): `transcript-upload-pipeline/components/benchmark-modal.tsx`
- [API client](https://github.com/raniaakrout/khallinetfaker/blob/main/transcript-upload-pipeline/lib/api.ts): `transcript-upload-pipeline/lib/api.ts`

### API and access

- [Authentication routes](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/api/auth.py): `meeting_rag/src/api/auth.py`
- [Transcript and chat API](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/api/main.py): `meeting_rag/src/api/main.py`
- [JWT and password security](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/utils/security.py): `meeting_rag/src/utils/security.py`

### Transcript processing

- [Upload orchestration](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/services/transcript_service.py): `meeting_rag/src/services/transcript_service.py`
- [Transcript indexer](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/rag/indexer.py): `meeting_rag/src/rag/indexer.py`
- [Transcript loader](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/loader.py): `meeting_rag/src/loader.py`
- [Chunking strategies](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/chunker.py): `meeting_rag/src/chunker.py`
- [Minutes summarizer](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/summarizer.py): `meeting_rag/src/summarizer.py`
- [Minutes and API schemas](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/schemas.py): `meeting_rag/src/schemas.py`

### Answering and evaluation

- [LangGraph agent](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/agent.py): `meeting_rag/src/agent.py`
- [Search and summary tools](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/rag/tools.py): `meeting_rag/src/rag/tools.py`
- [Chunk retrieval](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/rag/retriever.py): `meeting_rag/src/rag/retriever.py`
- [FAISS vector store](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/rag/vector_store.py): `meeting_rag/src/rag/vector_store.py`
- [Text embeddings](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/rag/embeddings.py): `meeting_rag/src/rag/embeddings.py`
- [Quality evaluation](https://github.com/raniaakrout/khallinetfaker/tree/main/meeting_rag/src/evaluation): `meeting_rag/src/evaluation`
- [RAG benchmarking](https://github.com/raniaakrout/khallinetfaker/tree/main/meeting_rag/src/api): `meeting_rag/src/api`

### Stored data

- [Database operations](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/database/crud.py): `meeting_rag/database/crud.py`
- [Relational data models](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/database/models.py): `meeting_rag/database/models.py`
- [PostgreSQL](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/database/db.py): `meeting_rag/database/db.py`
- [Transcript files](https://github.com/raniaakrout/khallinetfaker/blob/main/meeting_rag/src/services/transcript_service.py): `meeting_rag/src/services/transcript_service.py`

### Other components

- **Meeting user**

## Connections

- Meeting user → Chat and upload UI: uses (evidence: `README.md`)
- Chat and upload UI → Upload dialog: opens (evidence: `README.md`)
- Chat and upload UI → API client: requests
- Upload dialog → API client: uploads through
- API client → Transcript and chat API: calls API (evidence: `README.md`)
- Meeting user → Authentication routes: authenticates (evidence: `README.md`)
- Authentication routes → JWT and password security: creates tokens (evidence: `meeting_rag/src/api/auth.py`)
- Authentication routes → Database operations: looks up and creates users (evidence: `meeting_rag/src/api/auth.py`)
- JWT and password security → Database operations: loads user (evidence: `meeting_rag/src/utils/security.py`)
- Transcript and chat API → Upload orchestration: processes upload (evidence: `meeting_rag/src/api/main.py`)
- Upload orchestration → Transcript indexer: builds index (evidence: `meeting_rag/src/services/transcript_service.py`)
- Transcript indexer → Transcript loader: loads transcript (evidence: `meeting_rag/src/rag/indexer.py`)
- Transcript indexer → Chunking strategies: chunks text (evidence: `meeting_rag/src/rag/indexer.py`)
- Transcript indexer → FAISS vector store: builds vectors (evidence: `meeting_rag/src/rag/indexer.py`)
- Upload orchestration → Minutes summarizer: generates minutes (evidence: `meeting_rag/src/services/transcript_service.py`)
- Minutes summarizer → Transcript loader: loads transcript (evidence: `meeting_rag/src/summarizer.py`)
- Minutes summarizer → Chunking strategies: chunks text (evidence: `meeting_rag/src/summarizer.py`)
- Upload orchestration → Database operations: persists minutes and metadata (evidence: `meeting_rag/src/services/transcript_service.py`)
- Upload orchestration → Transcript files: writes transcript (evidence: `meeting_rag/src/services/transcript_service.py`)
- Transcript and chat API → LangGraph agent: invokes (evidence: `meeting_rag/src/api/main.py`)
- LangGraph agent → Search and summary tools: selects tools (evidence: `README.md`)
- Search and summary tools → Chunk retrieval: searches chunks
- Chunk retrieval → FAISS vector store: retrieves vectors (evidence: `meeting_rag/src/rag/retriever.py`)
- FAISS vector store → Text embeddings: uses embeddings (evidence: `meeting_rag/src/rag/vector_store.py`)
- Transcript and chat API → Database operations: saves chat (evidence: `meeting_rag/src/api/main.py`)
- Database operations → Relational data models: queries and updates (evidence: `meeting_rag/database/crud.py`)
- Relational data models → PostgreSQL: maps tables (evidence: `meeting_rag/database/models.py`)
- Transcript and chat API → Quality evaluation: runs evaluation (evidence: `meeting_rag/src/api/main.py`)
- Quality evaluation → Chunk retrieval: uses retrieved context (evidence: `meeting_rag/src/evaluation/summarization_eval.py`)
- Meeting user → Benchmark interface: configures benchmark (evidence: `README.md`)
- Benchmark interface → RAG benchmarking: starts comparison
- Transcript and chat API → RAG benchmarking: registers routes (evidence: `meeting_rag/src/api/main.py`)
