# aggarwalakshay2509/teleassist architecture

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

- Interactive diagram: https://gitdiagram.com/aggarwalakshay2509/teleassist
- Repository: https://github.com/aggarwalakshay2509/teleassist

## Overview

TeleAssist is a telecom-support API whose main workflow accepts a customer chat message, routes it to one or more billing, network, or plans specialists, and returns a merged response. The API and manager lead into LangGraph orchestration; specialist agents use domain tools and services backed by repositories and SQLite. The graph also shows shared LLM integration and conversation state. The README documents the broad workflow and capabilities; source excerpts and the index support selected implementation links, while some internal dispatch details are not shown.

Main entry points: [`src/orchestrator/graph.py`](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/orchestrator/graph.py) (LangGraph workflow), [`src/orchestrator/manager.py`](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/orchestrator/manager.py) (Graph manager), [`src/api/routes.py`](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/api/routes.py) (Chat API), [`src/database/database.py`](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/database/database.py) (SQLite database)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_api_orchestration["API and orchestration"]
  node_chat_api["Chat API<br/>[routes.py]"]
  node_manager["Graph manager<br/>[manager.py]"]
  node_workflow["LangGraph workflow<br/>[graph.py]"]
  node_router["Request router<br/>[router.py]"]
  node_merge["Response merge<br/>[merge.py]"]
  node_state["Conversation state<br/>[state.py]"]
end

subgraph group_specialists["Support specialists"]
  node_billing_agent["Billing agent<br/>[agent.py]"]
  node_billing_tools["Billing tools<br/>[tools.py]"]
  node_billing_service["Billing service<br/>[service.py]"]
  node_network_agent["Network agent<br/>[agent.py]"]
  node_network_tools["Network tools<br/>[tools.py]"]
  node_network_service["Network service<br/>[service.py]"]
  node_plans_agent["Plans agent<br/>[agent.py]"]
  node_plans_tools["Plans tools<br/>[tools.py]"]
  node_plans_service["Plans service<br/>[service.py]"]
end

subgraph group_data["Data access"]
  node_billing_repo["Billing repository"]
  node_network_repo["Network repository"]
  node_plans_repo["Plans repository"]
  node_sqlite[("SQLite database<br/>[database.py]")]
end

subgraph group_integrations["Shared integrations"]
  node_llm["Azure OpenAI<br/>[llm.py]"]
end

node_customer(("Customer"))

node_customer -->|"sends chat"| node_chat_api
node_chat_api -->|"invokes"| node_manager
node_manager -->|"invokes"| node_workflow
node_workflow -->|"routes through"| node_router
node_workflow -->|"dispatches"| node_billing_agent
node_workflow -->|"dispatches"| node_network_agent
node_workflow -->|"dispatches"| node_plans_agent
node_router -->|"classifies with"| node_llm
node_billing_agent -->|"uses"| node_billing_tools
node_billing_tools -->|"calls"| node_billing_service
node_billing_service -->|"queries"| node_billing_repo
node_billing_repo -->|"accesses"| node_sqlite
node_network_agent -->|"uses"| node_network_tools
node_network_tools -->|"calls"| node_network_service
node_network_service -->|"queries"| node_network_repo
node_network_repo -->|"accesses"| node_sqlite
node_plans_agent -->|"uses"| node_plans_tools
node_plans_tools -->|"calls"| node_plans_service
node_plans_service -->|"queries"| node_plans_repo
node_plans_repo -->|"accesses"| node_sqlite
node_workflow -->|"merges outputs"| node_merge
node_merge -->|"summarizes with"| node_llm
node_workflow -->|"maintains"| node_state
node_manager -->|"initializes"| node_state
node_manager -->|"returns response"| node_chat_api
node_chat_api -->|"returns response"| node_customer

click node_chat_api "https://github.com/aggarwalakshay2509/teleassist/blob/main/src/api/routes.py"
click node_manager "https://github.com/aggarwalakshay2509/teleassist/blob/main/src/orchestrator/manager.py"
click node_workflow "https://github.com/aggarwalakshay2509/teleassist/blob/main/src/orchestrator/graph.py"
click node_router "https://github.com/aggarwalakshay2509/teleassist/blob/main/src/orchestrator/router.py"
click node_merge "https://github.com/aggarwalakshay2509/teleassist/blob/main/src/orchestrator/merge.py"
click node_state "https://github.com/aggarwalakshay2509/teleassist/blob/main/src/orchestrator/state.py"
click node_billing_agent "https://github.com/aggarwalakshay2509/teleassist/blob/main/src/modules/billing/agent.py"
click node_billing_tools "https://github.com/aggarwalakshay2509/teleassist/blob/main/src/modules/billing/tools.py"
click node_billing_service "https://github.com/aggarwalakshay2509/teleassist/blob/main/src/modules/billing/service.py"
click node_network_agent "https://github.com/aggarwalakshay2509/teleassist/blob/main/src/modules/network/agent.py"
click node_network_tools "https://github.com/aggarwalakshay2509/teleassist/blob/main/src/modules/network/tools.py"
click node_network_service "https://github.com/aggarwalakshay2509/teleassist/blob/main/src/modules/network/service.py"
click node_plans_agent "https://github.com/aggarwalakshay2509/teleassist/blob/main/src/modules/plans/agent.py"
click node_plans_tools "https://github.com/aggarwalakshay2509/teleassist/blob/main/src/modules/plans/tools.py"
click node_plans_service "https://github.com/aggarwalakshay2509/teleassist/blob/main/src/modules/plans/service.py"
click node_billing_repo "https://github.com/aggarwalakshay2509/teleassist/blob/main/src/database/repositories/billing_repository.py"
click node_network_repo "https://github.com/aggarwalakshay2509/teleassist/blob/main/src/database/repositories/network_repository.py"
click node_plans_repo "https://github.com/aggarwalakshay2509/teleassist/blob/main/src/database/repositories/plans_repository.py"
click node_sqlite "https://github.com/aggarwalakshay2509/teleassist/blob/main/src/database/database.py"
click node_llm "https://github.com/aggarwalakshay2509/teleassist/blob/main/src/integrations/llm.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_chat_api,node_manager,node_workflow,node_router,node_merge,node_state toneBlue
class node_billing_agent,node_billing_tools,node_billing_service,node_network_agent,node_network_tools,node_network_service,node_plans_agent,node_plans_tools,node_plans_service toneAmber
class node_billing_repo,node_network_repo,node_plans_repo,node_sqlite toneMint
class node_llm toneRose
class node_customer toneIndigo
```

## Components

### API and orchestration

- [Chat API](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/api/routes.py): `src/api/routes.py`
- [Graph manager](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/orchestrator/manager.py): `src/orchestrator/manager.py`
- [LangGraph workflow](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/orchestrator/graph.py): `src/orchestrator/graph.py`
- [Request router](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/orchestrator/router.py): `src/orchestrator/router.py`
- [Response merge](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/orchestrator/merge.py): `src/orchestrator/merge.py`
- [Conversation state](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/orchestrator/state.py): `src/orchestrator/state.py`

### Support specialists

- [Billing agent](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/modules/billing/agent.py): `src/modules/billing/agent.py`
- [Billing tools](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/modules/billing/tools.py): `src/modules/billing/tools.py`
- [Billing service](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/modules/billing/service.py): `src/modules/billing/service.py`
- [Network agent](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/modules/network/agent.py): `src/modules/network/agent.py`
- [Network tools](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/modules/network/tools.py): `src/modules/network/tools.py`
- [Network service](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/modules/network/service.py): `src/modules/network/service.py`
- [Plans agent](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/modules/plans/agent.py): `src/modules/plans/agent.py`
- [Plans tools](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/modules/plans/tools.py): `src/modules/plans/tools.py`
- [Plans service](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/modules/plans/service.py): `src/modules/plans/service.py`

### Data access

- [Billing repository](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/database/repositories/billing_repository.py): `src/database/repositories/billing_repository.py`
- [Network repository](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/database/repositories/network_repository.py): `src/database/repositories/network_repository.py`
- [Plans repository](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/database/repositories/plans_repository.py): `src/database/repositories/plans_repository.py`
- [SQLite database](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/database/database.py): `src/database/database.py`

### Shared integrations

- [Azure OpenAI](https://github.com/aggarwalakshay2509/teleassist/blob/main/src/integrations/llm.py): `src/integrations/llm.py`

### Other components

- **Customer**

## Connections

- Customer → Chat API: sends chat
- Chat API → Graph manager: invokes (evidence: `src/api/routes.py`)
- Graph manager → LangGraph workflow: invokes (evidence: `src/orchestrator/manager.py`)
- LangGraph workflow → Request router: routes through (evidence: `src/orchestrator/graph.py`)
- LangGraph workflow → Billing agent: dispatches
- LangGraph workflow → Network agent: dispatches
- LangGraph workflow → Plans agent: dispatches
- Request router → Azure OpenAI: classifies with (evidence: `src/orchestrator/router.py`)
- Billing agent → Billing tools: uses (evidence: `src/modules/billing/agent.py`)
- Billing tools → Billing service: calls (evidence: `src/modules/billing/tools.py`)
- Billing service → Billing repository: queries (evidence: `src/modules/billing/service.py`)
- Billing repository → SQLite database: accesses
- Network agent → Network tools: uses (evidence: `src/modules/network/agent.py`)
- Network tools → Network service: calls (evidence: `src/modules/network/tools.py`)
- Network service → Network repository: queries (evidence: `src/modules/network/service.py`)
- Network repository → SQLite database: accesses
- Plans agent → Plans tools: uses (evidence: `src/modules/plans/agent.py`)
- Plans tools → Plans service: calls (evidence: `src/modules/plans/tools.py`)
- Plans service → Plans repository: queries (evidence: `src/modules/plans/service.py`)
- Plans repository → SQLite database: accesses
- LangGraph workflow → Response merge: merges outputs (evidence: `src/orchestrator/graph.py`)
- Response merge → Azure OpenAI: summarizes with (evidence: `src/orchestrator/merge.py`)
- LangGraph workflow → Conversation state: maintains (evidence: `src/orchestrator/graph.py`)
- Graph manager → Conversation state: initializes (evidence: `src/orchestrator/manager.py`)
- Graph manager → Chat API: returns response (evidence: `src/api/routes.py`)
- Chat API → Customer: returns response
