# nalini-krishna/ai-engineering-from-scratch architecture

> Architecture diagram of the GitHub repository nalini-krishna/ai-engineering-from-scratch, 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/nalini-krishna/ai-engineering-from-scratch
- Repository: https://github.com/nalini-krishna/ai-engineering-from-scratch

## Overview

This repository is an open AI-engineering curriculum with a companion website and certification tracks. The principal learner workflow is to choose a learning route, study a lesson, run its code, and keep evidence of the result. The graph reflects the README’s documented learning flow and major curriculum branches; API and frontend wiring is limited because their implementation was not sampled.

Main entry points: [`site/app.js`](https://github.com/nalini-krishna/ai-engineering-from-scratch/blob/main/site/app.js) (Curriculum Site), [`phases/11-llm-engineering`](https://github.com/nalini-krishna/ai-engineering-from-scratch/tree/main/phases/11-llm-engineering) (LLM Engineering), [`phases/01-math-foundations`](https://github.com/nalini-krishna/ai-engineering-from-scratch/tree/main/phases/01-math-foundations) (Foundations), [`phases/02-ml-fundamentals`](https://github.com/nalini-krishna/ai-engineering-from-scratch/tree/main/phases/02-ml-fundamentals) (ML Foundations)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_curriculum["Curriculum"]
  node_foundations["Foundations"]
  node_ml["ML Foundations"]
  node_deepai["Deep AI"]
  node_llm["LLM Engineering"]
  node_agents["Agents"]
  node_protocols["Tools Protocols"]
end

subgraph group_web["Website"]
  node_website["Curriculum Site<br/>[app.js]"]
  node_lesson_api["Lesson API<br/>[lesson.js]"]
  node_cert_api["Certification API<br/>[certification.js]"]
  node_markdown_api["Markdown API<br/>[markdown.js]"]
  node_markdown_v1["Markdown v1 API<br/>[markdown.js]"]
end

subgraph group_certs["Certifications"]
  node_claude["Claude Track"]
  node_mcpa["MCPA Track"]
end

subgraph group_applied["Applied Labs"]
  node_capstones["Capstones"]
  node_lesson_code["Runnable Lesson Code"]
  node_rag_lab["RAG System Lab<br/>[main.py]"]
end

node_learner(("Learner"))

node_learner -->|"browses curriculum"| node_website
node_learner -->|"studies lessons"| node_foundations
node_learner -->|"prepares for"| node_claude
node_learner -->|"prepares for"| node_mcpa
node_website -->|"lesson requests"| node_lesson_api
node_website -->|"certification requests"| node_cert_api
node_website -->|"presents curriculum"| node_foundations
node_foundations -->|"continues learning"| node_ml
node_ml -->|"continues learning"| node_deepai
node_deepai -->|"continues learning"| node_llm
node_llm -->|"continues learning"| node_agents
node_llm -->|"continues learning"| node_protocols
node_learner -->|"runs lesson code"| node_lesson_code
node_learner -->|"builds capstone"| node_rag_lab
node_lesson_api -.->|"uses markdown"| node_markdown_api
node_markdown_v1 -.->|"versioned access"| node_markdown_api

click node_foundations "https://github.com/nalini-krishna/ai-engineering-from-scratch/tree/main/phases/01-math-foundations"
click node_ml "https://github.com/nalini-krishna/ai-engineering-from-scratch/tree/main/phases/02-ml-fundamentals"
click node_deepai "https://github.com/nalini-krishna/ai-engineering-from-scratch/tree/main/phases/03-deep-learning-core"
click node_llm "https://github.com/nalini-krishna/ai-engineering-from-scratch/tree/main/phases/11-llm-engineering"
click node_agents "https://github.com/nalini-krishna/ai-engineering-from-scratch/tree/main/phases/14-agent-engineering"
click node_protocols "https://github.com/nalini-krishna/ai-engineering-from-scratch/tree/main/phases/13-tools-and-protocols"
click node_capstones "https://github.com/nalini-krishna/ai-engineering-from-scratch/tree/main/phases/19-capstone-projects"
click node_claude "https://github.com/nalini-krishna/ai-engineering-from-scratch/tree/main/certifications/claude"
click node_mcpa "https://github.com/nalini-krishna/ai-engineering-from-scratch/tree/main/certifications/mcpa"
click node_website "https://github.com/nalini-krishna/ai-engineering-from-scratch/blob/main/site/app.js"
click node_lesson_api "https://github.com/nalini-krishna/ai-engineering-from-scratch/blob/main/api/lesson.js"
click node_cert_api "https://github.com/nalini-krishna/ai-engineering-from-scratch/blob/main/api/certification.js"
click node_markdown_api "https://github.com/nalini-krishna/ai-engineering-from-scratch/blob/main/api/markdown.js"
click node_markdown_v1 "https://github.com/nalini-krishna/ai-engineering-from-scratch/blob/main/api/v1/markdown.js"
click node_lesson_code "https://github.com/nalini-krishna/ai-engineering-from-scratch/blob/main/phases/11-llm-engineering/01-prompt-engineering/code/prompt_engineering.py"
click node_rag_lab "https://github.com/nalini-krishna/ai-engineering-from-scratch/blob/main/phases/19-capstone-projects/69-end-to-end-rag-system/code/main.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_foundations,node_ml,node_deepai,node_llm,node_agents,node_protocols toneBlue
class node_website,node_lesson_api,node_cert_api,node_markdown_api,node_markdown_v1 toneAmber
class node_claude,node_mcpa toneMint
class node_capstones,node_lesson_code,node_rag_lab toneRose
class node_learner toneIndigo
```

## Components

### Curriculum

- [Foundations](https://github.com/nalini-krishna/ai-engineering-from-scratch/tree/main/phases/01-math-foundations): `phases/01-math-foundations`
- [ML Foundations](https://github.com/nalini-krishna/ai-engineering-from-scratch/tree/main/phases/02-ml-fundamentals): `phases/02-ml-fundamentals`
- [Deep AI](https://github.com/nalini-krishna/ai-engineering-from-scratch/tree/main/phases/03-deep-learning-core): `phases/03-deep-learning-core`
- [LLM Engineering](https://github.com/nalini-krishna/ai-engineering-from-scratch/tree/main/phases/11-llm-engineering): `phases/11-llm-engineering`
- [Agents](https://github.com/nalini-krishna/ai-engineering-from-scratch/tree/main/phases/14-agent-engineering): `phases/14-agent-engineering`
- [Tools Protocols](https://github.com/nalini-krishna/ai-engineering-from-scratch/tree/main/phases/13-tools-and-protocols): `phases/13-tools-and-protocols`

### Website

- [Curriculum Site](https://github.com/nalini-krishna/ai-engineering-from-scratch/blob/main/site/app.js): `site/app.js`
- [Lesson API](https://github.com/nalini-krishna/ai-engineering-from-scratch/blob/main/api/lesson.js): `api/lesson.js`
- [Certification API](https://github.com/nalini-krishna/ai-engineering-from-scratch/blob/main/api/certification.js): `api/certification.js`
- [Markdown API](https://github.com/nalini-krishna/ai-engineering-from-scratch/blob/main/api/markdown.js): `api/markdown.js`
- [Markdown v1 API](https://github.com/nalini-krishna/ai-engineering-from-scratch/blob/main/api/v1/markdown.js): `api/v1/markdown.js`

### Certifications

- [Claude Track](https://github.com/nalini-krishna/ai-engineering-from-scratch/tree/main/certifications/claude): `certifications/claude`
- [MCPA Track](https://github.com/nalini-krishna/ai-engineering-from-scratch/tree/main/certifications/mcpa): `certifications/mcpa`

### Applied Labs

- [Capstones](https://github.com/nalini-krishna/ai-engineering-from-scratch/tree/main/phases/19-capstone-projects): `phases/19-capstone-projects`
- [Runnable Lesson Code](https://github.com/nalini-krishna/ai-engineering-from-scratch/blob/main/phases/11-llm-engineering/01-prompt-engineering/code/prompt_engineering.py): `phases/11-llm-engineering/01-prompt-engineering/code/prompt_engineering.py`
- [RAG System Lab](https://github.com/nalini-krishna/ai-engineering-from-scratch/blob/main/phases/19-capstone-projects/69-end-to-end-rag-system/code/main.py): `phases/19-capstone-projects/69-end-to-end-rag-system/code/main.py`

### Other components

- **Learner**

## Connections

- Learner → Curriculum Site: browses curriculum
- Learner → Foundations: studies lessons
- Learner → Claude Track: prepares for
- Learner → MCPA Track: prepares for
- Curriculum Site → Lesson API: lesson requests
- Curriculum Site → Certification API: certification requests
- Curriculum Site → Foundations: presents curriculum
- Foundations → ML Foundations: continues learning
- ML Foundations → Deep AI: continues learning
- Deep AI → LLM Engineering: continues learning
- LLM Engineering → Agents: continues learning
- LLM Engineering → Tools Protocols: continues learning
- Learner → Runnable Lesson Code: runs lesson code
- Learner → RAG System Lab: builds capstone
- Lesson API → Markdown API: uses markdown
- Markdown v1 API → Markdown API: versioned access
