drydock-sdk
Python SDK for drydock — build and test AI agents and agentic workflows locally, one binary, with or without Docker.
Write an agent, tool, or MCP server as a plain Python function, decorate it, and the drydock runtime launches it as an isolated node: hot-reloaded during development, wired to other agents (A2A) and MCP servers, and fully traced.
from drydock import node
@node(name="greeter", role="agent")
async def greet(ctx, name: str = "world"):
await ctx.emit({"status": "thinking"}) # stream a partial update
return {"message": f"hello, {name}"}
Requires the drydock runtime
This package is the author-side SDK only. It has no effect on its own — nodes
are launched and orchestrated by the separate drydock binary (the runtime, HTTP
API, web UI, and tracing all live there). Install the runtime first:
# macOS / Linux
curl -fsSL https://raw.githubusercontent.com/scionoftech/drydock/main/scripts/install.sh | sh
See the project README for tarball and build-from-source options.
Install
pip install drydock-sdk
Zero runtime dependencies, pure Python, ships type hints (PEP 561). Install it into the virtualenv of each node you author.
Write a node
A node is a directory with your handler and a node.yaml manifest:
# handler.py
from drydock import node
@node(name="hello", role="agent") # role: "agent" | "tool" | "mcp"
async def hi(ctx, name: str = "world"):
return {"message": f"hello, {name}"}
# node.yaml
name: hello
version: 0.1.0
role: agent
runtime: python
entry: handler.py:hi
drydock dev # hot-reload daemon + web UI
drydock invoke hello --input '{"name":"Sai"}'
The ctx object
Every handler receives a context as its first argument:
| Call | Does |
|---|---|
await ctx.a2a.call(target, input) |
Invoke another node by name (agent-to-agent) |
await ctx.mcp.call(alias, tool, args) |
Call a tool on a declared MCP server |
await ctx.mcp.list(alias) |
List an MCP server's tools |
await ctx.session.append(role, content) |
Append to the persistent transcript |
await ctx.session.history(limit) |
Read recent transcript entries |
await ctx.emit(data) |
Stream a partial chunk (no-op on plain invoke) |
ctx.session_id, ctx.streaming, ctx.trace |
Invocation metadata |
Handlers may be async def (served concurrently) or plain def (run in a thread
pool). A JSON-object input is spread onto handler kwargs; return any
JSON-serializable value.
Full reference — input mapping, session semantics, the error model, streaming, and environment scrubbing — is in docs/SDK.md.
Links
- Project & docs: https://github.com/scionoftech/drydock
- SDK reference: https://github.com/scionoftech/drydock/blob/main/docs/SDK.md
- Issues: https://github.com/scionoftech/drydock/issues
License
MIT
Release files for drydock-sdk 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| drydock_sdk-0.1.0.tar.gz | 10.5 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| drydock_sdk-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 21.2 kB
Release files / drydock_sdk-0.1.0.tar.gz
| Download URL | drydock_sdk-0.1.0.tar.gz |
|---|---|
| Size | 10.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
6fbd82ee7ad2ea12ef44db431210804f976fb2525e1ce6f509d776c4f1ae7945
|
|
BLAKE2b-256 checksum How to use checksums |
2c2d2b07a694d995f931f7cc00bda15f8b6c3ef9143fccdc00ca43526c7f82f6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.14
|
Release files / drydock_sdk-0.1.0-py3-none-any.whl
| Download URL | drydock_sdk-0.1.0-py3-none-any.whl |
|---|---|
| Size | 10.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
c259b3c402178e54c42c526e3193d38ed57352edb133096b8027bd2dcee22ea7
|
|
BLAKE2b-256 checksum How to use checksums |
9878bc5c7ffc940d216f5e141841c733c51c6899a4e3595f05de3fdc8357a443
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.14
|