# shouzhengai/cs146s_cn architecture

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

- Interactive diagram: https://gitdiagram.com/shouzhengai/cs146s_cn
- Repository: https://github.com/shouzhengai/cs146s_cn

## Overview

This repository is a Chinese-language CS146S course resource, not one unified application. The learner’s path runs from prompting and tool-use exercises to progressively richer app assignments and alternative task-board stacks. The README describes broader course topics—such as MCP, agent skills, security, and software factories—but the supplied tree represents only some of them; edges below show documented learner progression or sampled runtime calls, not inferred links between assignments.

Main entry points: [`Assignments/week2/app/main.py`](https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week2/app/main.py) (Action Extractor), [`assignments/week8/stack3-flask-sqlite/app.py`](https://github.com/shouzhengai/cs146s_cn/blob/main/assignments/week8/stack3-flask-sqlite/app.py) (Flask Task Board), [`assignments/week3/server/main.py`](https://github.com/shouzhengai/cs146s_cn/blob/main/assignments/week3/server/main.py) (GitHub MCP Server), [`assignments/week8/stack1-bolt-react/frontend/src/App.jsx`](https://github.com/shouzhengai/cs146s_cn/blob/main/assignments/week8/stack1-bolt-react/frontend/src/App.jsx) (React Task Board)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_learning["Learning Exercises"]
  node_chain["Reasoning"]
  node_prompting["Prompting"]
  node_consistency["Self Consistency"]
  node_rag["RAG<br/>[rag.py]"]
  node_reflexion["Reflexion<br/>[reflexion.py]"]
  node_toolcalling["Tool Calling<br/>[tool_calling.py]"]
end

subgraph group_notes["Notes App"]
  node_notesapp["Action Extractor<br/>[main.py]"]
  node_noteapi["Notes Routes<br/>[notes.py]"]
  node_actionsapi["Action Routes<br/>[action_items.py]"]
  node_extract["Extraction Service<br/>[extract.py]"]
  node_evolvingapp["Notes App Iterations<br/>[main.py]"]
  node_notesui["Notes Frontend<br/>[app.js]"]
  node_secureapp["Secured Notes App<br/>[main.py]"]
end

subgraph group_projects["Project Examples"]
  node_githubmcp["GitHub MCP Server<br/>[main.py]"]
  node_stackreact["React Task Board<br/>[App.jsx]"]
  node_taskapi["Task API<br/>[main.py]"]
  node_stackdjango["Django Task Board<br/>[views.py]"]
  node_stackflask["Flask Task Board<br/>[app.py]"]
  node_flaskui["Task Board UI<br/>[app.js]"]
end

node_learner(("Learner"))
node_github["GitHub API"]
node_sqlite[("SQLite Tasks")]

node_learner -->|"studies"| node_chain
node_learner -->|"studies"| node_prompting
node_learner -->|"studies"| node_consistency
node_learner -->|"studies"| node_rag
node_learner -->|"studies"| node_reflexion
node_learner -->|"studies"| node_toolcalling
node_learner -->|"builds"| node_notesapp
node_learner -->|"studies"| node_githubmcp
node_learner -->|"compares"| node_stackreact
node_learner -->|"compares"| node_stackdjango
node_learner -->|"compares"| node_stackflask
node_notesapp -->|"mounts"| node_noteapi
node_notesapp -->|"mounts"| node_actionsapi
node_notesapp -->|"initializes"| node_extract
node_githubmcp -->|"queries"| node_github
node_notesui -->|"requests"| node_evolvingapp
node_secureapp -->|"includes"| node_noteapi
node_stackreact -->|"requests"| node_taskapi
node_stackflask -->|"reads/writes"| node_sqlite
node_flaskui -->|"requests"| node_stackflask

click node_chain "https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week1/chain_of_thought.py"
click node_prompting "https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week1/k_shot_prompting.py"
click node_consistency "https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week1/self_consistency_prompting.py"
click node_rag "https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week1/rag.py"
click node_reflexion "https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week1/reflexion.py"
click node_toolcalling "https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week1/tool_calling.py"
click node_notesapp "https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week2/app/main.py"
click node_noteapi "https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week2/app/routers/notes.py"
click node_actionsapi "https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week2/app/routers/action_items.py"
click node_extract "https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week2/app/services/extract.py"
click node_githubmcp "https://github.com/shouzhengai/cs146s_cn/blob/main/assignments/week3/server/main.py"
click node_evolvingapp "https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week5/backend/app/main.py"
click node_notesui "https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week5/frontend/app.js"
click node_secureapp "https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week6/backend/app/main.py"
click node_stackreact "https://github.com/shouzhengai/cs146s_cn/blob/main/assignments/week8/stack1-bolt-react/frontend/src/App.jsx"
click node_taskapi "https://github.com/shouzhengai/cs146s_cn/blob/main/assignments/week8/stack1-bolt-react/backend/main.py"
click node_stackdjango "https://github.com/shouzhengai/cs146s_cn/blob/main/assignments/week8/stack2-django/taskboard/views.py"
click node_stackflask "https://github.com/shouzhengai/cs146s_cn/blob/main/assignments/week8/stack3-flask-sqlite/app.py"
click node_flaskui "https://github.com/shouzhengai/cs146s_cn/blob/main/assignments/week8/stack3-flask-sqlite/static/app.js"

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_chain,node_prompting,node_consistency,node_rag,node_reflexion,node_toolcalling toneBlue
class node_notesapp,node_noteapi,node_actionsapi,node_extract,node_evolvingapp,node_notesui,node_secureapp,node_sqlite toneAmber
class node_githubmcp,node_stackreact,node_taskapi,node_stackdjango,node_stackflask,node_flaskui,node_github toneMint
class node_learner toneIndigo
```

## Components

### Learning Exercises

- [Reasoning](https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week1/chain_of_thought.py): `Assignments/week1/chain_of_thought.py`
- [Prompting](https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week1/k_shot_prompting.py): `Assignments/week1/k_shot_prompting.py`
- [Self Consistency](https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week1/self_consistency_prompting.py): `Assignments/week1/self_consistency_prompting.py`
- [RAG](https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week1/rag.py): `Assignments/week1/rag.py`
- [Reflexion](https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week1/reflexion.py): `Assignments/week1/reflexion.py`
- [Tool Calling](https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week1/tool_calling.py): `Assignments/week1/tool_calling.py`

### Notes App

- [Action Extractor](https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week2/app/main.py): `Assignments/week2/app/main.py`
- [Notes Routes](https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week2/app/routers/notes.py): `Assignments/week2/app/routers/notes.py`
- [Action Routes](https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week2/app/routers/action_items.py): `Assignments/week2/app/routers/action_items.py`
- [Extraction Service](https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week2/app/services/extract.py): `Assignments/week2/app/services/extract.py`
- [Notes App Iterations](https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week5/backend/app/main.py): `Assignments/week5/backend/app/main.py`
- [Notes Frontend](https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week5/frontend/app.js): `Assignments/week5/frontend/app.js`
- [Secured Notes App](https://github.com/shouzhengai/cs146s_cn/blob/main/Assignments/week6/backend/app/main.py): `Assignments/week6/backend/app/main.py`

### Project Examples

- [GitHub MCP Server](https://github.com/shouzhengai/cs146s_cn/blob/main/assignments/week3/server/main.py): `assignments/week3/server/main.py`
- [React Task Board](https://github.com/shouzhengai/cs146s_cn/blob/main/assignments/week8/stack1-bolt-react/frontend/src/App.jsx): `assignments/week8/stack1-bolt-react/frontend/src/App.jsx`
- [Task API](https://github.com/shouzhengai/cs146s_cn/blob/main/assignments/week8/stack1-bolt-react/backend/main.py): `assignments/week8/stack1-bolt-react/backend/main.py`
- [Django Task Board](https://github.com/shouzhengai/cs146s_cn/blob/main/assignments/week8/stack2-django/taskboard/views.py): `assignments/week8/stack2-django/taskboard/views.py`
- [Flask Task Board](https://github.com/shouzhengai/cs146s_cn/blob/main/assignments/week8/stack3-flask-sqlite/app.py): `assignments/week8/stack3-flask-sqlite/app.py`
- [Task Board UI](https://github.com/shouzhengai/cs146s_cn/blob/main/assignments/week8/stack3-flask-sqlite/static/app.js): `assignments/week8/stack3-flask-sqlite/static/app.js`

### Other components

- **Learner**
- **GitHub API**
- **SQLite Tasks**

## Connections

- Learner → Reasoning: studies
- Learner → Prompting: studies
- Learner → Self Consistency: studies
- Learner → RAG: studies
- Learner → Reflexion: studies
- Learner → Tool Calling: studies
- Learner → Action Extractor: builds
- Learner → GitHub MCP Server: studies
- Learner → React Task Board: compares
- Learner → Django Task Board: compares
- Learner → Flask Task Board: compares
- Action Extractor → Notes Routes: mounts
- Action Extractor → Action Routes: mounts
- Action Extractor → Extraction Service: initializes
- GitHub MCP Server → GitHub API: queries
- Notes Frontend → Notes App Iterations: requests
- Secured Notes App → Notes Routes: includes
- React Task Board → Task API: requests
- Flask Task Board → SQLite Tasks: reads/writes
- Task Board UI → Flask Task Board: requests
