Skip to main content

Module compat

Module compat 

Source
Expand description

Claude Code stream-json compatibility layer.

Maps pixie-pi’s AgentEvent stream to the NDJSON wire format Claude Code emits under --output-format stream-json, so callers that spawn the claude CLI (e.g. Pixie) can drive pixie-pi as a drop-in replacement.

The mapper is intentionally pure (no I/O): map_events turns a single event into zero or more ClaudeLines, and to_ndjson serializes one. SDK users and unit tests reuse it directly. The binary’s modes::stream_json driver is what wires stdin/stdout around it.

Re-exports§

pub use claude::map_events;
pub use claude::system_init;
pub use claude::to_ndjson;
pub use claude::ClaudeLine;
pub use claude::MapCtx;

Modules§

claude
Claude Code stream-json envelope shapes + the pixie→Claude event mapper.