AI Knowledge · Architecture Map

From AI concepts to real AI systems.

A visual roadmap showing how AI learns, runs, creates, retrieves information, takes action, reaches production, and fits into today’s ecosystem.

You do not need to memorize every topic. Read the relationships: each layer answers a different system question.

The master roadmap

FROM AI CONCEPTS TO REAL AI SYSTEMS

This is a learning map, not one literal runtime pipeline.

AIThe broad field of systems that perform tasks associated with intelligence.
↓
LEARN · 01–04Models, architectures, training, adaptation
RUN · 05–06Tokens, context, inference, prompts
CREATE & RETRIEVE · 07–08Generation, search, grounding
ACT · 09–12Agents, serving, safety, deployment
↓
ECOSYSTEM · 13–20Models, products, runtimes, frameworks, automation, advanced engineering
AI Request Runtime Map

From User Request to AI Action

A practical map of what can happen when a user sends a request to a modern AI application.

USER REQUEST“Check our refund policy and tell me whether this order qualifies.”
↓
APPLICATION → TOKENIZATIONThe app receives the request and converts text into tokens.
↓
CONTEXT ASSEMBLYSystem Prompt + User Prompt + History + Memory / State + Retrieved Knowledge + Tool Results.
↓
MODEL INFERENCENext-token prediction → Sampling → Generated token → Repeat.
↓
FINAL RESPONSE → APPLICATION UI → USERAnswer, action result, or structured output.

OPTIONAL · RAG / KNOWLEDGE BASE

Knowledge Base: policies, documents, manuals, product data.

Chunking / Index → Embeddings / Search → Retrieval → Reranking → Add relevant chunks to context.

OPTIONAL · AGENT LOOP

Observe → Plan / Decide → Act → Tool → Observe Result → Update State → repeat.

State / Memory can feed useful information back into Context Assembly.

OPTIONAL · TOOL CALLING

The model requests a structured tool call; the application or runtime executes it through MCP / API and returns the result to context.

Tool Calling ≠ Tool Execution · MCP ≠ Agent.

CONTROL · VALIDATION / HUMAN REVIEW

Proposed Action → Permission Check → Validation → Human Approval when required → Execute.

FEEDBACK → NEXT RUN

User Feedback → Conversation History / State → Context Assembly. Feedback in a conversation ≠ immediate model training.

Not every request uses retrieval, tools, memory, or an agent loop.

ONE REQUEST, STEP BY STEP

  1. Request enters the application and becomes tokens.
  2. Context is assembled with relevant policy.
  3. If order information is needed, the model requests a tool.
  4. The application queries the order system and returns the result.
  5. The model combines policy and order information into a response.
  6. A real refund action may require permission or human approval.
DO NOT CONFUSE: Token ≠ Word · Context ≠ Memory · Knowledge Base ≠ RAG · Agent ≠ Model · Human Approval ≠ Every AI Request
Layer 1 · How AI learns · Modules 01–04

From intelligence to adaptable models

Artificial IntelligenceThe broad field
↓
Machine LearningLearning patterns from data
Supervised LearningLabeled examples guide predictions
Unsupervised LearningFinds structure without labels
Reinforcement LearningLearns from rewards
Deep LearningLayered neural-network approach
↓
Neural Networks → Layers → ArchitecturesCNN · RNN / LSTM · Transformer · Attention
Foundation ModelsLLMs · Vision · Speech / Audio · Multimodal · Scientific Models
Diffusion Models are another important generative model family, not a child of Transformer.

Training

Training Data → Pre-training → Foundation Model

ParametersLearned internal values.

Adaptation

Fine-tuning → Instruction Tuning → Preference Learning / RLHF

Prompting + RAGUsually do not change base parameters.
Layer 2 · How a model runs · Modules 05–06

How a prompt becomes an answer

“Explain RAG simply.”User input
↓
Tokenization → Tokens → Context WindowContext may contain system prompt, user prompt, examples, retrieved context, history, tool results.
Context Engineering → InferenceWhat information the model receives, then running the trained model.
Next-token Prediction → Sampling → Generated Token → Repeat → ResponseSampling selects among candidate next tokens.
Structured OutputModel output becomes application-readable.
Prompt Design = how the request is written. Context Engineering = what information the model receives. KV Cache reuses earlier attention calculations; it is an efficiency mechanism.
Layer 3 · Create & retrieve · Modules 07–08

Generation creates; retrieval finds

Generative AI

Creates output.

Text · Image · Audio · Video · Code GenerationDifferent output capabilities.

Multimodal AI

Works across text, image, audio, and video; it overlaps with generation.

↓

Retrieval / RAG

Documents → Chunking → Embeddings → Index / Vector Database → Search → Retrieval → Reranking → Relevant Context → RAG → Model → Grounded Answer

Embedding ≠ Vector Database · Search ≠ Retrieval · Retrieval ≠ RAG · RAG ≠ Fine-tuning · Grounding ≠ guaranteed truth
Layer 4 · How AI becomes a system · Modules 09–12

From model to production

Agent architecture

Model + Instructions + Tools + State / Memory + Agent Loop.

Observe → Plan → Act → Tool → ObservePlanning, tool calling, MCP, skills, approvals, multi-agent coordination.

Serving stack

Application → API → Runtime (Ollama / vLLM) → Model → Hardware.

GPU · VRAM · Quantization · Latency · Tokens per SecondRuntime and performance constraints.
↓

VERIFY

Evaluation → Functional Tests → Failure Modes → Failure Handling → Deployment Readiness.

Safety: Hallucination · Prompt Injection · Guardrails · Permissions & Safety · Benchmarks.

DEPLOY

Workflow Discovery → Technical Scoping → Integration → Evaluation → Deployment → Adoption → Monitoring → Continuous Improvement.

Layer 5 · The AI ecosystem · Modules 13–16

A landscape, not one pipeline

MODELS

GPT · Claude · Gemini · Grok · Qwen · DeepSeek · Llama · Mistral · GLM · MiniMax · Image / Video / Speech / Music Models

RUNTIMES

Ollama · vLLM

CODING PRODUCTS

Codex · Claude Code · Cursor · Windsurf · GitHub Copilot · Gemini CLI · OpenCode · Cline · Roo Code · Aider

GENERAL AGENTS

ChatGPT Work · OpenClaw · Manus · WorkBuddy · Computer Use · Browser Agents · Desktop Agents

AGENT FRAMEWORKS

LangGraph · LangChain · AutoGen · CrewAI · OpenAI Agents SDK · Google ADK · Semantic Kernel

AUTOMATION

n8n · Dify · Flowise · Coze · Zapier · Make

Qwen = Model · Ollama = Runtime · Codex = Coding Agent / Product · LangGraph = Agent Framework · n8n = Workflow Automation Platform
The AI system stack

One-screen master map

USER / BUSINESS
AI APPLICATION
AGENT / WORKFLOW
PROMPTS + CONTEXT + RAG + TOOLS
MODEL
INFERENCE RUNTIME
GPU / MEMORY / CLOUD
EVALUATION + MONITORING
Suggested learning path

Five stages

STAGE 1BasicsModules 01–03
STAGE 2Learn and runModules 04–06
STAGE 3Create and retrieveModules 07–08
STAGE 4Build systemsModules 09–12
STAGE 5Understand the ecosystemModules 13–16