Learn Agents from 0 to 1

Learn Agents from 0 to 1

An agent engineering learning path

Build the right mental model through short lessons, then use Pi to ship an evidence-first technical research agent.

For developers who know basic TypeScript but have not built an agent system end to end.

Start with lesson 1
What you will ship

The final project is not a chat wrapper. It plans, researches, verifies evidence, resumes work, and produces cited reports.

01

See the map first

Separate Chat, Workflow, and Agent, then understand what each agent taxonomy is actually describing.

2/3
  1. 01 Chat, Workflow, or Agent? Choose the right control model by asking who decides the next step. Published
  2. 02 Agents Come in Different Shapes Understand the decision spectrum and run a constrained Agent Loop with Pi. Published
  3. 03 The Agent Architecture Map Put classical agents, LLM agents, and multi-agent systems into the right coordinate systems. Planned
02

Understand the LLM runtime

Understand model input and output before adding an agent loop.

0/3
  1. 04 What Actually Happens in an LLM Call Build a small but accurate model of requests, sampling, and responses. Planned
  2. 05 Messages, Roles, Tokens, and Context Windows See what the agent actually sends to the model on every turn. Planned
  3. 06 Build a Minimal Agent Loop with Pi Connect streaming, structured results, state, and stopping conditions. Planned
03

Give the agent hands

Tools define capability boundaries and introduce side effects and risk.

0/4
  1. 07 Tool Calling Is Not an Agent Separate a single function call from a loop that keeps observing results. Planned
  2. 08 How to Design a Good Tool Schema Reduce misuse with clear names, parameter boundaries, and result contracts. Planned
  3. 09 Tool Errors, Retries, Timeouts, and Result Semantics Make failures understandable to the model and reliable for the program. Planned
  4. 10 Side Effects, Idempotency, Approval, Parallelism, and Cancellation Put explicit engineering guardrails around real actions. Planned
04

Manage context and memory

A good agent does not remember everything; it receives the right information at the right step.

0/4
  1. 11 Prompt Engineering vs. Context Engineering Prompts define rules; context supplies what the current task needs. Planned
  2. 12 Sessions, Message History, and Context Compaction Keep long tasks moving without endlessly filling the context window. Planned
  3. 13 Should RAG Be a Tool or Automatic Context? Choose based on retrieval timing, visibility, and cost. Planned
  4. 14 Working, Episodic, Semantic, and Procedural Memory Separate four memory types through write, retrieval, and forgetting policies. Planned
05

Learn agent patterns

Patterns are control structures for different uncertainty, not levels in an upgrade tree.

0/5
  1. 15 ReAct: Observe, Then Act Again Reconsider the next step after every real tool result. Planned
  2. 16 Plan-and-Execute: Plan Before Acting Separate decomposition from execution while letting evidence revise the plan. Planned
  3. 17 Reflection and Evaluator-Optimizer Know when self-correction helps and when it only adds another model call. Planned
  4. 18 Router, Parallel, and Blackboard Patterns Compare routing, parallel work, and shared-state coordination. Planned
  5. 19 Supervisor, Handoff, and Multi-Agent Systems Add agents only when context isolation or real parallelism pays off. Planned
06

Move from demo to reliable system

Protocols, safety, observability, and evaluation determine whether an agent can ship.

0/4
  1. 20 MCP: Connect External Capabilities Understand the roles of tools, resources, prompts, and transports. Planned
  2. 21 Prompt Injection and Tool Injection Why external content must not automatically gain instruction or tool authority. Planned
  3. 22 Sandboxes, Permissions, Budgets, and Humans in the Loop Constrain the agent with system boundaries instead of polite prompt requests. Planned
  4. 23 Tracing, Observability, and Agent Evaluation Trace every step from the result and build a reusable regression set. Planned
07

Ship the complete agent project

Combine the earlier capabilities into a real project with explicit acceptance criteria.

0/5
  1. 24 Project Spec, Architecture, and Acceptance Criteria Define what complete research means before choosing an agent structure. Planned
  2. 25 Search, Reading, Normalization, and Citation Tools Make every important claim traceable to a real source. Planned
  3. 26 Planner, Researcher, and Task Recovery Decompose research questions and resume interrupted work from evidence state. Planned
  4. 27 Citations, Evaluation, Context, and Persistence Independently check source coverage, conclusion consistency, and context budgets. Planned
  5. 28 CLI, HTTP/SSE API, Evaluation Set, and Release Gates Finish with a runnable, testable, and demonstrable delivery. Planned

Reference baseline

These sources support the concepts and terminology. The articles use original explanations and Pi implementations.

Search this language Open