Babble 2

Messaging contract

Draft; no stable package export yet.

OperationIntended semantics
startCreate an authorized session/run and return capabilities
sendAccept a message with a stable command ID
eventsStream typed events with a recovery cursor
inspect / searchReturn only authorized session state
stopRequest cancellation and report its actual outcome
killTerminate only supported, supervised processes

The proposed envelope includes version, session ID, run ID, message/command ID, type, payload, correlation and timestamp. Identity is derived from authenticated server context. Errors, tool requests, approval requests and completion are typed events.

Existing core vocabulary includes OPEN, APPEND, BLOCK, CLOSE, atomic POST, SUBSCRIBE, and ephemeral SIGNAL. Mapping lifecycle commands to these primitives is a POC decision, not an implemented guarantee.