examples/ directory contains runnable demos for every major feature. Each example includes a NotImplementedError placeholder - replace it with your LLM of choice.
Core Examples
| Example | What it demonstrates |
|---|---|
basic_agent.py | Minimal agent with a single tool |
streaming_agent.py | AgentTool sub-agent streaming with real-time event bubbling |
multi_agent.py | SequentialAgent pipeline (researcher -> writer) |
parallel_agent.py | ParallelAgent running 3 research agents concurrently |
loop_agent.py | LoopAgent with writer/reviewer iterative refinement |
transfer_agent.py | Agent handoff via make_transfer_tool (triage -> specialists) |
planner_agent.py | PlanReActPlanner with structured chain-of-thought |
memory_agent.py | Persistent memory with InMemoryMemoryStore |
structured_output.py | Typed Pydantic output via output_schema |
human_in_the_loop.py | Interactive ask_human tool for user input |
task_orchestration.py | TaskPlanner with managed task board |
mcp_agent.py | MCP tool server integration |
langfuse_tracing.py | Langfuse tracing integration |
a2a_server.py | A2A protocol server endpoint |
Composer Examples
YAML-based agent composition examples inexamples/composer/:
| Example | What it demonstrates |
|---|---|
composer/simple/ | Single agent, minimal YAML config |
composer/pipeline/ | Sequential researcher -> writer pipeline with tools |
composer/loop/ | Draft/review loop with exit_loop termination |
composer/transfer/ | Triage agent with transfer routing to specialists |
composer/a2a-server/ | A2A endpoint with Dockerfile for deployment |