# ship1220/intervista_updated architecture

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

- Interactive diagram: https://gitdiagram.com/ship1220/intervista_updated
- Repository: https://github.com/ship1220/intervista_updated

## Overview

This is an AI job-preparation application for interview practice and personalized course generation. Its user-facing workflow is served by the FastAPI application: users provide interview or career context, practice and submit answers, and receive feedback; the application also supports audio transcription and course/resource features. Internally, interview chains can retrieve supporting material from a RAG index, while a separate resource-discovery pipeline and contextual bandit service support learning and adaptation. The README only names the product, and sampled excerpts are partial, so uncertain connections between API routes and services are omitted.

Main entry points: [`services/rag/rag_pipeline.py`](https://github.com/ship1220/intervista_updated/blob/main/services/rag/rag_pipeline.py) (RAG coordinator), [`services/learning_resources/pipeline.py`](https://github.com/ship1220/intervista_updated/blob/main/services/learning_resources/pipeline.py) (Resource discovery), [`main.py`](https://github.com/ship1220/intervista_updated/blob/main/main.py) (FastAPI application), [`services/learning_resources/query_generator.py`](https://github.com/ship1220/intervista_updated/blob/main/services/learning_resources/query_generator.py) (Search query generation)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["Application"]
  node_api["FastAPI application<br/>[main.py]"]
  node_speech["Audio transcription<br/>[transcription.py]"]
end

subgraph group_interview["Interview Practice"]
  node_chains["Interview chains<br/>[base_chain.py]"]
  node_prompts["Prompt templates<br/>[prompt_manager.py]"]
  node_evaluation["Answer evaluation<br/>[evaluator.py]"]
  node_profile["Skill profile"]
  node_skill_integration["Skill integration"]
  node_bandit["Adaptive selection<br/>[rl_service.py]"]
end

subgraph group_learning["Learning Support"]
  node_rag_pipeline["RAG coordinator<br/>[rag_pipeline.py]"]
  node_ingester["Document ingestion"]
  node_retriever["Document retrieval<br/>[retriever.py]"]
  node_vector_store[("Vector index<br/>[vector_store.py]")]
  node_seed_data["RAG seed data<br/>[seed_data.py]"]
  node_resource_pipeline["Resource discovery<br/>[pipeline.py]"]
  node_query_generator["Search query generation<br/>[query_generator.py]"]
  node_fetchers["Resource fetchers"]
  node_normalizer["Resource normalization<br/>[normalizer.py]"]
  node_ranker["Resource ranking<br/>[ranker.py]"]
end

subgraph group_platform["Shared Services"]
  node_llm["LLM service<br/>[llm_service.py]"]
  node_database[("Application database<br/>[database.py]")]
end

node_candidate(("Candidate"))
node_groq["Groq API"]

node_candidate -->|"uses"| node_api
node_api -->|"reads and writes"| node_database
node_api -->|"transcribes audio"| node_speech
node_chains -->|"retrieves context"| node_retriever
node_chains -->|"formats prompts"| node_prompts
node_llm -->|"requests completions"| node_groq
node_query_generator -->|"generates queries"| node_llm
node_query_generator -->|"uses templates"| node_prompts
node_rag_pipeline -->|"processes documents"| node_ingester
node_rag_pipeline -->|"indexes documents"| node_vector_store
node_rag_pipeline -->|"coordinates retrieval"| node_retriever
node_rag_pipeline -->|"loads seed data"| node_seed_data
node_retriever -->|"searches index"| node_vector_store
node_ingester -->|"supplies chunks"| node_vector_store
node_resource_pipeline -->|"generates searches"| node_query_generator
node_resource_pipeline -->|"retrieves resources"| node_fetchers
node_resource_pipeline -->|"normalizes results"| node_normalizer
node_resource_pipeline -->|"ranks results"| node_ranker

click node_api "https://github.com/ship1220/intervista_updated/blob/main/main.py"
click node_speech "https://github.com/ship1220/intervista_updated/blob/main/speech/transcription.py"
click node_chains "https://github.com/ship1220/intervista_updated/blob/main/core/chains/base_chain.py"
click node_prompts "https://github.com/ship1220/intervista_updated/blob/main/core/prompts/prompt_manager.py"
click node_evaluation "https://github.com/ship1220/intervista_updated/blob/main/evaluation/evaluator.py"
click node_profile "https://github.com/ship1220/intervista_updated/blob/main/user_skill_profile.py"
click node_skill_integration "https://github.com/ship1220/intervista_updated/blob/main/user_skill_integration.py"
click node_bandit "https://github.com/ship1220/intervista_updated/blob/main/services/rl/rl_service.py"
click node_rag_pipeline "https://github.com/ship1220/intervista_updated/blob/main/services/rag/rag_pipeline.py"
click node_ingester "https://github.com/ship1220/intervista_updated/blob/main/services/rag/document_ingester.py"
click node_retriever "https://github.com/ship1220/intervista_updated/blob/main/services/rag/retriever.py"
click node_vector_store "https://github.com/ship1220/intervista_updated/blob/main/services/rag/vector_store.py"
click node_seed_data "https://github.com/ship1220/intervista_updated/blob/main/services/rag/seed_data.py"
click node_resource_pipeline "https://github.com/ship1220/intervista_updated/blob/main/services/learning_resources/pipeline.py"
click node_query_generator "https://github.com/ship1220/intervista_updated/blob/main/services/learning_resources/query_generator.py"
click node_fetchers "https://github.com/ship1220/intervista_updated/tree/main/services/learning_resources/fetchers"
click node_normalizer "https://github.com/ship1220/intervista_updated/blob/main/services/learning_resources/normalizer.py"
click node_ranker "https://github.com/ship1220/intervista_updated/blob/main/services/learning_resources/ranker.py"
click node_llm "https://github.com/ship1220/intervista_updated/blob/main/core/llm/llm_service.py"
click node_database "https://github.com/ship1220/intervista_updated/blob/main/database.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_api,node_speech toneBlue
class node_chains,node_prompts,node_evaluation,node_profile,node_skill_integration,node_bandit toneAmber
class node_rag_pipeline,node_ingester,node_retriever,node_vector_store,node_seed_data,node_resource_pipeline,node_query_generator,node_fetchers,node_normalizer,node_ranker,node_groq toneMint
class node_llm,node_database toneRose
class node_candidate toneIndigo
```

## Components

### Application

- [FastAPI application](https://github.com/ship1220/intervista_updated/blob/main/main.py): `main.py`
- [Audio transcription](https://github.com/ship1220/intervista_updated/blob/main/speech/transcription.py): `speech/transcription.py`

### Interview Practice

- [Interview chains](https://github.com/ship1220/intervista_updated/blob/main/core/chains/base_chain.py): `core/chains/base_chain.py`
- [Prompt templates](https://github.com/ship1220/intervista_updated/blob/main/core/prompts/prompt_manager.py): `core/prompts/prompt_manager.py`
- [Answer evaluation](https://github.com/ship1220/intervista_updated/blob/main/evaluation/evaluator.py): `evaluation/evaluator.py`
- [Skill profile](https://github.com/ship1220/intervista_updated/blob/main/user_skill_profile.py): `user_skill_profile.py`
- [Skill integration](https://github.com/ship1220/intervista_updated/blob/main/user_skill_integration.py): `user_skill_integration.py`
- [Adaptive selection](https://github.com/ship1220/intervista_updated/blob/main/services/rl/rl_service.py): `services/rl/rl_service.py`

### Learning Support

- [RAG coordinator](https://github.com/ship1220/intervista_updated/blob/main/services/rag/rag_pipeline.py): `services/rag/rag_pipeline.py`
- [Document ingestion](https://github.com/ship1220/intervista_updated/blob/main/services/rag/document_ingester.py): `services/rag/document_ingester.py`
- [Document retrieval](https://github.com/ship1220/intervista_updated/blob/main/services/rag/retriever.py): `services/rag/retriever.py`
- [Vector index](https://github.com/ship1220/intervista_updated/blob/main/services/rag/vector_store.py): `services/rag/vector_store.py`
- [RAG seed data](https://github.com/ship1220/intervista_updated/blob/main/services/rag/seed_data.py): `services/rag/seed_data.py`
- [Resource discovery](https://github.com/ship1220/intervista_updated/blob/main/services/learning_resources/pipeline.py): `services/learning_resources/pipeline.py`
- [Search query generation](https://github.com/ship1220/intervista_updated/blob/main/services/learning_resources/query_generator.py): `services/learning_resources/query_generator.py`
- [Resource fetchers](https://github.com/ship1220/intervista_updated/tree/main/services/learning_resources/fetchers): `services/learning_resources/fetchers`
- [Resource normalization](https://github.com/ship1220/intervista_updated/blob/main/services/learning_resources/normalizer.py): `services/learning_resources/normalizer.py`
- [Resource ranking](https://github.com/ship1220/intervista_updated/blob/main/services/learning_resources/ranker.py): `services/learning_resources/ranker.py`

### Shared Services

- [LLM service](https://github.com/ship1220/intervista_updated/blob/main/core/llm/llm_service.py): `core/llm/llm_service.py`
- [Application database](https://github.com/ship1220/intervista_updated/blob/main/database.py): `database.py`

### Other components

- **Candidate**
- **Groq API**

## Connections

- Candidate → FastAPI application: uses
- FastAPI application → Application database: reads and writes
- FastAPI application → Audio transcription: transcribes audio
- Interview chains → Document retrieval: retrieves context
- Interview chains → Prompt templates: formats prompts
- LLM service → Groq API: requests completions
- Search query generation → LLM service: generates queries
- Search query generation → Prompt templates: uses templates
- RAG coordinator → Document ingestion: processes documents
- RAG coordinator → Vector index: indexes documents
- RAG coordinator → Document retrieval: coordinates retrieval
- RAG coordinator → RAG seed data: loads seed data
- Document retrieval → Vector index: searches index
- Document ingestion → Vector index: supplies chunks
- Resource discovery → Search query generation: generates searches
- Resource discovery → Resource fetchers: retrieves resources
- Resource discovery → Resource normalization: normalizes results
- Resource discovery → Resource ranking: ranks results
