Protocol schemas, shared types, and generated contracts
Protocol schemas, shared types, and generated contracts stage-18 (cross-cutting infrastructure)
This stage is shared behind-the-scenes support for the whole system. It defines the “contracts” that clients, servers, plugins, storage, and tools all rely on when they exchange data. A contract is the agreed shape of a message, like a standard form everyone fills out the same way.
The core protocol and domain types provide the common vocabulary: sessions, threads, events, approvals, tools, permissions, errors, settings, plugins, and saved conversation state. The app-server schemas define how the desktop or web client talks to the app server, including JSON-RPC envelopes, which are simple wrappers for requests, replies, and errors. The generated backend and protobuf contracts cover messages produced from outside specifications, such as OpenAPI web models and protobuf service messages. The API, extension, hook, MCP, sandbox, and trace schemas define public and cross-process messages for tools, plugins, execution, realtime streams, and saved run histories. Finally, the annotation macros run during compilation to mark experimental API pieces consistently. Together, these parts keep every component speaking the same language.
Sub-stages
State registers touched2
reg-collaboration-mode-catalogBuilt-in and configured collaboration-mode presets/templates that clients can list and apply to choose model, mode, reasoning, and prompt behavior.reg-windows-sandbox-readinessPrepared Windows sandbox accounts, helper readiness, setup status, and client-visible sandbox availability separate from the policy rules themselves.