Skip to content
Pilotoo
v0.1

@pilotoo/chat-protocol

@pilotoo/chat-protocol defines what the server and the clients say to each other: commands, events, envelopes and errors, as Zod schemas with every type inferred from them. It is strict about what a client sends and permissive about what it reads. Every other package depends on it, and it depends only on zod. You rarely install it by hand; you import it when you validate messages yourself or write a custom transport.

@pilotoo/chat-protocol is at version 0.1.0 and is not published to a registry yet. A host gets it today by packing the tarballs from the kit repository:

Terminal window
pnpm install
pnpm release:check

release:check builds the release packages and writes one .tgz per package to node_modules/.cache/release-check/. Copy the tarballs you need into your project (for example vendor/) and depend on them as files:

package.json
{
"dependencies": {
"@pilotoo/chat-protocol": "file:vendor/pilotoo-chat-protocol-0.1.0.tgz"
}
}

The release set (chat-protocol, chat-core, chat-ui, ui, agent-runtime, server, local-server) is versioned together: install every kit package you use at the same version. See Installation for the full setup.

import { PROTOCOL_VERSION, startRunCommandSchema, type StartRunCommand } from '@pilotoo/chat-protocol';
const command: StartRunCommand = startRunCommandSchema.parse(input);
console.log(PROTOCOL_VERSION); // { major: 1, minor: 17 }

The package has no exports map; it has a single entry, the package root (main: dist/index.js).

Import Provides
@pilotoo/chat-protocol PROTOCOL_VERSION, the command schemas (startRunCommandSchema, resumeRunCommandSchema, …), agUiEventSchema, streamEnvelopeSchema, protocolErrorSchema, threadMessagesResponseSchema and the inferred types.

None. zod (4.3.6) is a regular dependency.