Agent
Blueprints
Architecture-first patterns for building LLM workflow and agent systems. Learn to design before you code.
How to navigate this repo
Three entry points, one through line.
12 Patterns, 3 Levels of Depth
Every pattern is documented from high-level overview to implementation detail.
LLM Workflows
The code controls the flow. Developer-defined structure, LLM-filled content.
Prompt Chaining
Sequential LLM calls with validation gates between steps.
Parallel Calls
Concurrent LLM calls on independent inputs, aggregated at the end.
Orchestrator-Worker
LLM decomposes a task and delegates to specialized workers.
Evaluator-Optimizer
Generate-evaluate feedback loop that iteratively improves output.
Agent Patterns
The LLM controls the flow. Developer-provided tools and constraints, LLM-decided actions.
ReAct
Reason-act loop: the LLM reasons, calls a tool, observes, and repeats until done.
Plan & Execute
LLM creates a full plan upfront, then executes each step sequentially.
Tool Use
Structured function calling with schema-validated tool dispatch.
Memory
Persistent state across sessions: short-term, long-term, and semantic memory.
RAG
Retrieval-augmented generation: retrieve relevant context before generating.
Reflection
LLM critiques its own output and self-improves through structured feedback.
Routing
Intent classification dispatches inputs to specialized handlers.
Multi-Agent
Supervisor-worker delegation across multiple autonomous agents.
Ready to design your agent?
Use the decision flowchart to find the right pattern, or explore the evolution explorer to understand the full design space.