ai-control-protocol.wire.tcp-stream |
TCP byte stream |
A bridge accepts an explicitly configured TCP endpoint; clients must not assume service discovery, TLS, HTTP, or WebSocket framing. |
The common project implementations are local tooling channels, not an internet service protocol. |
Examples/AiControlSample/ai_control_sample.py |
ai-control-protocol.wire.ndjson |
One JSON object per line |
Each request and response is one JSON object terminated by LF; peers process lines in connection order. |
Line framing is streamable, inspectable, and shared by both audited project bridges. |
BuildTools/ai_control_client.py |
ai-control-protocol.wire.utf8 |
UTF-8 encoding |
JSON lines are encoded and decoded as strict UTF-8; malformed input receives a parse error or closes the connection. |
Project observations and action payloads may contain localized text. |
BuildTools/ai_control_client.py |
ai-control-protocol.wire.line-limit |
Bounded line size |
A request or response JSON payload is at most 1 MiB before the LF terminator; oversized input is rejected and the connection may close. |
A local automation channel still needs deterministic memory bounds. |
BuildTools/ai_control_client.py |
ai-control-protocol.wire.request-envelope |
Request envelope |
A request object carries jsonrpc=2.0, a caller-chosen id, a non-empty method string, and an object-valued params member. |
A small JSON-RPC-shaped envelope gives correlation without claiming the full JSON-RPC specification. |
BuildTools/ai_control_client.py |
ai-control-protocol.wire.response-envelope |
Response envelope |
A response echoes jsonrpc=2.0 and the request id, then contains exactly one of result or error; error contains an integer code and string message. |
Strict correlation prevents one automation step from consuming another step’s result. |
BuildTools/ai_control_client.py |
ai-control-protocol.wire.sequential-connection |
Sequential request processing |
A client sends a request and consumes its matching response before reusing that connection; clients must not require multiplexing or concurrent in-flight requests. |
The contract remains implementable by a single project-owned listener and avoids hidden ordering races. |
BuildTools/ai_control_client.py |