Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,26 @@ Shorter compile-checked examples: [`example_test.go`](example_test.go) and
- [MCP tools](docs/docs/reference/mcp-tools.md)
- [Security model](docs/docs/explanation/security-model.md)

## How this differs from Cloudflare's Code Mode

Cloudflare's [Code Mode](https://blog.cloudflare.com/code-mode/) and CodeMode
share a thesis: models are better at writing code than at emitting tool
calls. They apply it on opposite sides of the protocol.

Cloudflare's Code Mode is agent-side. Their Agents SDK converts the tool
schemas of the MCP servers an agent already uses into a TypeScript API; the
model writes TypeScript that runs in a V8 isolate on the Workers platform,
and each call proxies back to the original servers.

CodeMode is server-side. You author the server itself: capabilities are
native typed Go functions, not wrapped remote tools, and the server runs the
agent's program in a local worker process. Because code execution is part of
the server's own contract, any MCP client gets one-round-trip composition
without a special agent framework or hosting platform. The server also
enforces its own policy: every capability call is authorized before it
dispatches, and a deployment can disable capabilities it does not want to
expose.

## Security boundary

Each `execute` request runs Starlark in a fresh worker process that CodeMode
Expand Down