Covers the SDK's core end-to-end: the provider registry, request shaping and prompt caching per provider, the agent loop with its tools (client tools, approvals, argument validation, parallel execution, cancellation), sub-agents as tools, middleware, structured output, conversations, failover, observer events, and the testing fake.

## Before writing SPEC.md files

Read https://raw.githubusercontent.com/brillout/sdd/refs/heads/main/sdd.md
