# huanche/agentic-class-pilot architecture

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

- Interactive diagram: https://gitdiagram.com/huanche/agentic-class-pilot
- Repository: https://github.com/huanche/agentic-class-pilot

## Overview

Agentic Class Pilot is a three-service AI education platform. Users enter through the platform for unified login and role-based access, then build or publish courses as teachers or enroll and learn as students; trusted platform bridges provide service access and student launch context. The graph preserves the documented course-building, classroom, playback, and learning branches. Backend and student-agent links use sampled source references; teacher-agent internals were not sampled, so those capabilities are represented at their documented service boundary.

Main entry points: [`platform/backend/app/api`](https://github.com/huanche/agentic-class-pilot/tree/main/platform/backend/app/api) (Platform API), [`platform/backend/app/api/routes/student_bridge.py`](https://github.com/huanche/agentic-class-pilot/blob/main/platform/backend/app/api/routes/student_bridge.py) (Agent bridges), [`student_agent/apps/server.py`](https://github.com/huanche/agentic-class-pilot/blob/main/student_agent/apps/server.py) (Student service), [`teacher_agent/app`](https://github.com/huanche/agentic-class-pilot/tree/main/teacher_agent/app) (Teacher workspace)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_platform["Platform and identity"]
  node_platform_ui["Platform UI"]
  node_platform_api["Platform API"]
  node_auth["Login and roles<br/>[login.py]"]
  node_bridge["Agent bridges<br/>[student_bridge.py]"]
  node_course_access["Course access<br/>[course_access.py]"]
  node_platform_db[("Platform records<br/>[models.py]")]
  node_agent_sessions["Agent sessions<br/>[agent_sessions.py]"]
end

subgraph group_teacher["Teacher experience"]
  node_teacher_ui["Teacher workspace"]
  node_course_authoring["Course authoring"]
  node_content_generation["Content generation"]
  node_course_publication["Course publishing"]
  node_classroom["Classroom and player"]
  node_playback["Playback engine<br/>[engine.ts]"]
end

subgraph group_student["Student learning"]
  node_student_app["Student experience"]
  node_student_server["Student service<br/>[server.py]"]
  node_student_integration["Platform integration"]
end

subgraph group_agentcore["Agent runtime"]
  node_orchestrator{{"Lesson orchestrator<br/>[agent.py]"}}
  node_chat_graph{{"Chat graph<br/>[graph.py]"}}
  node_outline_agent{{"Outline agent<br/>[outline.py]"}}
  node_checkpoints[("Graph checkpoints<br/>[checkpoint.py]")]
  node_llm_config["LLM configuration<br/>[config.py]"]
end

node_users(("Users"))
node_external_services[("PostgreSQL and object storage")]

node_users -->|"use"| node_platform_ui
node_platform_ui -->|"request"| node_platform_api
node_platform_api -->|"routes login"| node_auth
node_platform_api -->|"routes bridges"| node_bridge
node_auth -->|"read account"| node_platform_db
node_bridge -->|"check access"| node_course_access
node_bridge -->|"read records"| node_platform_db
node_bridge -->|"resolve sessions"| node_agent_sessions
node_platform_api -.->|"trusted service access"| node_teacher_ui
node_bridge -.->|"launch context"| node_student_server
node_teacher_ui -.->|"build courses"| node_course_authoring
node_course_authoring -.->|"generate materials"| node_content_generation
node_course_authoring -.->|"publish content"| node_course_publication
node_teacher_ui -.->|"teach classes"| node_classroom
node_classroom -.->|"run playback"| node_playback
node_users -->|"learn"| node_student_app
node_student_app -->|"send turns"| node_student_server
node_student_server -->|"delegate lessons"| node_orchestrator
node_student_server -->|"use platform adapters"| node_student_integration
node_student_integration -.->|"trusted requests"| node_platform_api
node_platform_api -->|"embed agent runtime"| node_chat_graph
node_platform_api -->|"embed agent runtime"| node_outline_agent
node_chat_graph -->|"persist state"| node_checkpoints
node_outline_agent -->|"persist state"| node_checkpoints
node_chat_graph -->|"configure model"| node_llm_config
node_outline_agent -->|"configure model"| node_llm_config
node_course_publication -.->|"store course data"| node_external_services
node_student_server -.->|"persist learning data"| node_external_services

click node_platform_ui "https://github.com/huanche/agentic-class-pilot/tree/main/platform/frontend/src"
click node_platform_api "https://github.com/huanche/agentic-class-pilot/tree/main/platform/backend/app/api"
click node_auth "https://github.com/huanche/agentic-class-pilot/blob/main/platform/backend/app/api/routes/login.py"
click node_bridge "https://github.com/huanche/agentic-class-pilot/blob/main/platform/backend/app/api/routes/student_bridge.py"
click node_course_access "https://github.com/huanche/agentic-class-pilot/blob/main/platform/backend/app/services/course_access.py"
click node_platform_db "https://github.com/huanche/agentic-class-pilot/blob/main/platform/backend/app/models.py"
click node_agent_sessions "https://github.com/huanche/agentic-class-pilot/blob/main/platform/backend/app/services/agent_sessions.py"
click node_teacher_ui "https://github.com/huanche/agentic-class-pilot/tree/main/teacher_agent/app"
click node_course_authoring "https://github.com/huanche/agentic-class-pilot/tree/main/teacher_agent/components/course-space"
click node_content_generation "https://github.com/huanche/agentic-class-pilot/tree/main/teacher_agent/app/api/generate"
click node_course_publication "https://github.com/huanche/agentic-class-pilot/tree/main/teacher_agent/app/api/course-space"
click node_classroom "https://github.com/huanche/agentic-class-pilot/tree/main/teacher_agent/app/classroom"
click node_playback "https://github.com/huanche/agentic-class-pilot/blob/main/teacher_agent/lib/playback/engine.ts"
click node_student_app "https://github.com/huanche/agentic-class-pilot/tree/main/student_agent/frontend/src"
click node_student_server "https://github.com/huanche/agentic-class-pilot/blob/main/student_agent/apps/server.py"
click node_student_integration "https://github.com/huanche/agentic-class-pilot/tree/main/student_agent/apps/integration"
click node_orchestrator "https://github.com/huanche/agentic-class-pilot/blob/main/student_agent/orchestrator/agent.py"
click node_chat_graph "https://github.com/huanche/agentic-class-pilot/blob/main/platform/backend/app/core/langgraph/graph.py"
click node_outline_agent "https://github.com/huanche/agentic-class-pilot/blob/main/platform/backend/app/core/langgraph/outline.py"
click node_checkpoints "https://github.com/huanche/agentic-class-pilot/blob/main/platform/backend/app/core/langgraph/checkpoint.py"
click node_llm_config "https://github.com/huanche/agentic-class-pilot/blob/main/platform/backend/app/core/config.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_platform_ui,node_platform_api,node_auth,node_bridge,node_course_access,node_platform_db,node_agent_sessions,node_users toneBlue
class node_teacher_ui,node_course_authoring,node_content_generation,node_course_publication,node_classroom,node_playback,node_external_services toneAmber
class node_student_app,node_student_server,node_student_integration toneMint
class node_orchestrator,node_chat_graph,node_outline_agent,node_checkpoints,node_llm_config toneRose
```

## Components

### Platform and identity

- [Platform UI](https://github.com/huanche/agentic-class-pilot/tree/main/platform/frontend/src): `platform/frontend/src`
- [Platform API](https://github.com/huanche/agentic-class-pilot/tree/main/platform/backend/app/api): `platform/backend/app/api`
- [Login and roles](https://github.com/huanche/agentic-class-pilot/blob/main/platform/backend/app/api/routes/login.py): `platform/backend/app/api/routes/login.py`
- [Agent bridges](https://github.com/huanche/agentic-class-pilot/blob/main/platform/backend/app/api/routes/student_bridge.py): `platform/backend/app/api/routes/student_bridge.py`
- [Course access](https://github.com/huanche/agentic-class-pilot/blob/main/platform/backend/app/services/course_access.py): `platform/backend/app/services/course_access.py`
- [Platform records](https://github.com/huanche/agentic-class-pilot/blob/main/platform/backend/app/models.py): `platform/backend/app/models.py`
- [Agent sessions](https://github.com/huanche/agentic-class-pilot/blob/main/platform/backend/app/services/agent_sessions.py): `platform/backend/app/services/agent_sessions.py`

### Teacher experience

- [Teacher workspace](https://github.com/huanche/agentic-class-pilot/tree/main/teacher_agent/app): `teacher_agent/app`
- [Course authoring](https://github.com/huanche/agentic-class-pilot/tree/main/teacher_agent/components/course-space): `teacher_agent/components/course-space`
- [Content generation](https://github.com/huanche/agentic-class-pilot/tree/main/teacher_agent/app/api/generate): `teacher_agent/app/api/generate`
- [Course publishing](https://github.com/huanche/agentic-class-pilot/tree/main/teacher_agent/app/api/course-space): `teacher_agent/app/api/course-space`
- [Classroom and player](https://github.com/huanche/agentic-class-pilot/tree/main/teacher_agent/app/classroom): `teacher_agent/app/classroom`
- [Playback engine](https://github.com/huanche/agentic-class-pilot/blob/main/teacher_agent/lib/playback/engine.ts): `teacher_agent/lib/playback/engine.ts`

### Student learning

- [Student experience](https://github.com/huanche/agentic-class-pilot/tree/main/student_agent/frontend/src): `student_agent/frontend/src`
- [Student service](https://github.com/huanche/agentic-class-pilot/blob/main/student_agent/apps/server.py): `student_agent/apps/server.py`
- [Platform integration](https://github.com/huanche/agentic-class-pilot/tree/main/student_agent/apps/integration): `student_agent/apps/integration`

### Agent runtime

- [Lesson orchestrator](https://github.com/huanche/agentic-class-pilot/blob/main/student_agent/orchestrator/agent.py): `student_agent/orchestrator/agent.py`
- [Chat graph](https://github.com/huanche/agentic-class-pilot/blob/main/platform/backend/app/core/langgraph/graph.py): `platform/backend/app/core/langgraph/graph.py`
- [Outline agent](https://github.com/huanche/agentic-class-pilot/blob/main/platform/backend/app/core/langgraph/outline.py): `platform/backend/app/core/langgraph/outline.py`
- [Graph checkpoints](https://github.com/huanche/agentic-class-pilot/blob/main/platform/backend/app/core/langgraph/checkpoint.py): `platform/backend/app/core/langgraph/checkpoint.py`
- [LLM configuration](https://github.com/huanche/agentic-class-pilot/blob/main/platform/backend/app/core/config.py): `platform/backend/app/core/config.py`

### Other components

- **Users**
- **PostgreSQL and object storage**

## Connections

- Users → Platform UI: use (evidence: `README.md`)
- Platform UI → Platform API: request (evidence: `platform/frontend/src/main.tsx`)
- Platform API → Login and roles: routes login (evidence: `platform/backend/app/api/main.py`)
- Platform API → Agent bridges: routes bridges (evidence: `platform/backend/app/api/main.py`)
- Login and roles → Platform records: read account (evidence: `platform/backend/app/api/routes/login.py`)
- Agent bridges → Course access: check access (evidence: `platform/backend/app/api/routes/student_bridge.py`)
- Agent bridges → Platform records: read records (evidence: `platform/backend/app/api/routes/student_bridge.py`)
- Agent bridges → Agent sessions: resolve sessions
- Platform API → Teacher workspace: trusted service access (evidence: `README.md`)
- Agent bridges → Student service: launch context (evidence: `README.md`)
- Teacher workspace → Course authoring: build courses (evidence: `README.md`)
- Course authoring → Content generation: generate materials (evidence: `README.md`)
- Course authoring → Course publishing: publish content (evidence: `README.md`)
- Teacher workspace → Classroom and player: teach classes (evidence: `README.md`)
- Classroom and player → Playback engine: run playback
- Users → Student experience: learn (evidence: `README.md`)
- Student experience → Student service: send turns (evidence: `student_agent/frontend/src/legacy/app.js`)
- Student service → Lesson orchestrator: delegate lessons (evidence: `student_agent/apps/server.py`)
- Student service → Platform integration: use platform adapters (evidence: `student_agent/apps/server.py`)
- Platform integration → Platform API: trusted requests (evidence: `README.md`)
- Platform API → Chat graph: embed agent runtime (evidence: `platform/backend/app/main.py`)
- Platform API → Outline agent: embed agent runtime (evidence: `platform/backend/app/main.py`)
- Chat graph → Graph checkpoints: persist state (evidence: `platform/backend/app/core/langgraph/graph.py`)
- Outline agent → Graph checkpoints: persist state (evidence: `platform/backend/app/core/langgraph/outline.py`)
- Chat graph → LLM configuration: configure model (evidence: `platform/backend/app/core/langgraph/graph.py`)
- Outline agent → LLM configuration: configure model (evidence: `platform/backend/app/core/langgraph/outline.py`)
- Course publishing → PostgreSQL and object storage: store course data (evidence: `README.md`)
- Student service → PostgreSQL and object storage: persist learning data (evidence: `README.md`)
