AI engineering / Advanced / 03.01
Agent SDKs
What agent kits package for you, four of them in their own words, and a 45-line mini SDK you can run to see the parts.
11 min readFree
Ready-made kits for agents
The last lesson, Frameworks for AI apps, ended with a pointer: next, agent SDKs, ready-made kits for building agents. Here they are.
Think of a flat-pack bookshelf. You could cut every plank yourself. Or you could buy the pack, with the planks cut, the screws counted and the steps printed. An agent SDK is the second option for agents. It gives you the loop, the hooks and the record-keeping, so you write only the parts that are yours.
By the end you will know what these kits have in common, what four of them say about themselves, how to choose between them, and how a tiny one works inside. You will run that tiny one yourself.
Key words
- Agent
- A program that asks a model what to do next, does it, and repeats until the job is done.
- SDK
- Software development kit: a bundle of ready-made code you add to your project so you do not write the basics yourself.
- Instructions
- The standing orders you give an agent, like a job description.
- Tool
- A function the agent is allowed to call, such as looking up an invoice.
- Handoff
- One agent passing the conversation to another agent, like a receptionist passing you to the right desk.
- Guardrail
- A check that can stop bad input or bad output before it goes any further.
- Session
- The saved memory of a conversation, so the agent can carry on where it left off.
- Trace
- A written record of every step a run took, used to debug it.
Four kits, in their own words
Every fact here comes from the kit's own documentation page, read on 16 November 2026. Quotes are exact. Where a page does not use a word, I say so instead of guessing.
Tip
SDK facts were checked on 16 November 2026, and these products change fast. Names, features and even whole products come and go, as you will see in a moment. Always check the current docs before you commit to one.
OpenAI: Agents SDK and Agent Builder
The OpenAI Agents SDK page says it "enables you to build agentic AI apps in a lightweight, easy-to-use package with very few abstractions". It lists three primitives, which are its basic building blocks.
What it is for
Agents, which it calls "LLMs equipped with instructions and tools"; "Agents as tools / Handoffs", for delegating to other agents; and "Guardrails", which "enable validation of agent inputs and outputs".
Other blocks it names
A "built-in loop that continues until the task is complete", "Sessions" as "a persistent memory layer", and "built-in tracing" for visualizing and debugging.
Language and models
It describes itself as "Python-first". The quickstart has you set an OpenAI API key, and the docs index has a page titled "Use OpenAI models, websocket transport, or non-OpenAI providers".
The planned topic here also names AgentKit. The AgentKit announcement page returned an error when I tried to open it, so I use no facts from it. The OpenAI docs page I could open covers Agent Builder, the visual part. It calls it "a visual canvas for building multi-step agent workflows".
That page also carries a notice: "OpenAI is deprecating Agent Builder", and the product "is scheduled to shut down on November 30, 2026". It says ChatKit remains available. So a drag-and-drop builder, two weeks from today, is on its way out. The code kits' pages I read carried no such notice.
Claude Agent SDK
The overview page defines an agent as "an application that completes a task by planning its own steps and calling tools that read files, run commands, or edit code". It says the SDK gives you "the same tools, agent loop, and context management that power Claude Code, programmable in Python and TypeScript".
What it is for
Its comparison table calls it "a library that runs the Claude Code binary", for embedding that agent "in your own Python or TypeScript application, in a process you operate".
Blocks it names
Subagents ("Spawn specialized agents for focused subtasks"), Sessions ("Maintain context across exchanges, resume or fork later"), Hooks and Permissions. The overview does not use the words guardrails or tracing.
Models and hosting
The quickstart sets an Anthropic API key. It also gives environment variables for Amazon Bedrock and for Google Cloud's Agent Platform. A separate row, Managed Agents, is Anthropic hosting the agent for you.
Vertex AI Agent Builder
This one moved. The old Vertex AI Agent Builder address on Google Cloud now opens a page named Gemini platform, and the docs overview is called Agent Platform overview. It says the platform is "a unified platform to build, deploy, govern, and optimize enterprise-grade AI agents and model-based solutions" and "an evolution of Vertex AI". The pages I read never use the name Agent Builder.
What it is for
A whole cloud platform, not only a code kit. Its Build area lists Agent Studio, "a low-code visual canvas", and the Agent Development Kit.
Blocks it names
Agent Platform Sessions, Agent Platform Memory Bank for memory "across multiple sessions", Agent Gateway as "a central policy enforcement point" for agent tool calls, and tracing tools including a Unified Trace Viewer.
Models and hosting
It runs on Google Cloud, with an Agent Runtime to deploy agents. Model Garden offers Google's models plus "third-party, and open-source models".
Google ADK
The Agent Development Kit docs call ADK "the open-source agent development framework that lets you build, debug, and deploy reliable AI agents at enterprise scale". It is available in Python, TypeScript, Go, Java and Kotlin.
What it is for
Building agents that start with prompts and tool calls, then grow into "multi-agent orchestration, graph-based workflows, performance evaluation, and deployment".
Blocks it names
Sessions and memory in its context management, plus pages on callbacks, guardrails and evaluation. When deployed on Google Cloud, it says agents inherit "Cloud Trace observability".
Models and hosting
It says ADK "can work with almost any generative AI model", with adapters for other providers and local models. You can "containerize and run ADK on your own infrastructure" or deploy to Google Cloud in one command.
Notice the link: Google's platform page lists ADK as one of its own building tools, and ADK can also run on your own servers. Kits and platforms often stack like this.
A peek at two quickstarts
Here is how little code it takes to define an agent in two of these kits. Both are copied straight from the docs. I did not run them, because they need an account key and a real model.
# From the OpenAI Agents SDK quickstart, shown without its output (not run here)
from agents import Agent
agent = Agent(
name="History Tutor",
instructions="You answer history questions clearly and concisely.",
)# From the Agent Development Kit docs home page, shown without its output (not run here)
from google.adk import Agent
from google.adk.tools import google_search
agent = Agent(
name="researcher",
model="gemini-flash-latest",
instruction="You help users research topics thoroughly.",
tools=[google_search],
)Same shape in both: a name and instructions. The second one also sets a model and a list of tools. Only the spelling differs. Once you know one kit, the next takes an afternoon to learn, not a month.
A mini SDK you can run
To see what the kits really do, here is a toy of about 45 lines in plain Python. It has an Agent with a name, instructions and tools, a Runner that loops with a step limit, a handoff from a triage agent to a billing agent, and a trace list.
There is no real model here. The function fake_model is a stand-in with fixed answers, so the code runs free, with no key and no network. A real model is slower, costs money for every token, can give a different answer each run, and can fail or refuse. The stand-in does none of that, so treat the output as a picture of the plumbing, not of a model. The invoice amount is made up.
from dataclasses import dataclass, field
@dataclass
class Agent:
name: str
instructions: str
tools: dict = field(default_factory=dict) # tool name -> Python function
handoffs: list = field(default_factory=list) # other agents it may pass the chat to
def fake_model(agent, messages):
# Stand-in for a real model: fixed decisions, so the code runs free.
if agent.name == "triage":
return {"handoff": "billing"}
if not any(m["role"] == "tool" for m in messages):
return {"tool": "lookup_invoice", "args": {"id": 42}}
return {"final": "Invoice 42 is 30.00 (made up) and was paid on 2 May."}
class Runner:
def __init__(self, max_steps=5):
self.max_steps = max_steps
self.trace = []
def run(self, agent, text):
messages = [{"role": "user", "content": text}]
for step in range(1, self.max_steps + 1):
move = fake_model(agent, messages)
kind = next(iter(move))
self.trace.append(f"step {step}: {agent.name} -> {kind}")
if kind == "final":
return move["final"]
if kind == "tool":
result = agent.tools[move["tool"]](**move["args"])
messages.append({"role": "tool", "content": result})
else:
agent = next(a for a in agent.handoffs if a.name == move["handoff"])
return "Stopped: step limit reached"
def lookup_invoice(id):
return f"invoice {id}: 30.00, paid 2 May"
billing = Agent("billing", "Answer invoice questions.", tools={"lookup_invoice": lookup_invoice})
triage = Agent("triage", "Send each customer to the right agent.", handoffs=[billing])
for limit in (5, 2):
runner = Runner(max_steps=limit)
print("limit", limit, "->", runner.run(triage, "Where is my invoice?"))
print("\n".join(runner.trace))Output
limit 5 -> Invoice 42 is 30.00 (made up) and was paid on 2 May. step 1: triage -> handoff step 2: billing -> tool step 3: billing -> final limit 2 -> Stopped: step limit reached step 1: triage -> handoff step 2: billing -> tool
Read the output. In the first run the triage agent hands off to billing at step 1. Billing calls its tool at step 2 and gives the final answer at step 3. The three trace lines are the receipt of that run.
The second run used a limit of 2 steps. The work needed 3, so the Runner stopped and returned "Stopped: step limit reached". That limit is why a confused agent cannot loop forever and burn tokens.
Tip
Real SDKs add much more: streaming, many turns of history, retries, checks on the agent's output, and saved sessions. The shape is the same: a loop, tools, handoffs and a trace.
Quick check
In the toy, what does a handoff do?
How to choose
Pick by your own situation, not by which name you hear most. Four questions sort most cases.
Language
Python only, or also TypeScript, Go, Java or Kotlin? From the pages above: the OpenAI SDK says Python-first, the Claude SDK says Python and TypeScript, ADK lists five languages.
Hosting
Do you run it yourself, or does a vendor host it? The Claude docs offer both a library in your process and hosted Managed Agents. ADK can run on your own infrastructure. The Google platform adds a managed runtime.
Models and lock-in
Which models do you need today, and which might you want later? If a kit mostly speaks one maker's models, switching later means rewriting. Read the model-support page before you start, and keep your tools as plain functions you can move.
A fair extra test is the one from the last lesson: could you explain in a minute what your app does between the user's message and the answer? Also remember the Agent Builder notice. A kit that is easy today can be gone next year, so keep your own logic small and portable.
Quick check
Your team uses TypeScript and wants to run agents on its own servers. Which question matters first?
What to remember
- 1
A kit is a flat-pack agent
It packs the loop, tools, handoffs, checks, memory and a trace, so you write the parts that are yours.
- 2
Read each kit's own words
Names differ. Handoffs, subagents and agents as tools are close cousins.
- 3
Check the date
One builder in this lesson is scheduled to shut down, and another changed its name. Facts here were checked on 16 November 2026.
Next: MCP hosts, clients and servers, who does what.
Sources
- OpenAI Agents SDK docs (home)
- OpenAI Agents SDK docs (quickstart)
- OpenAI API docs: Agent Builder
- Claude Agent SDK overview
- Claude Agent SDK quickstart
- Google Cloud: Agent Platform overview (successor to Vertex AI)
- Google Cloud: Vertex AI Agent Builder product page (now the Gemini platform page)
- Agent Development Kit (ADK) docs
Last updated on 16 November 2026
Learn with me
Every lesson is free. I add new ones as I learn. Have a question, or want help with your own work? Book a short call.