Skip to main content

Crate codeswarm_core

Crate codeswarm_core 

Source
Expand description

Framework-independent CodeSwarm domain state.

The terminal UI and each CLI protocol adapter communicate through this event vocabulary. The reducer remains synchronous and deterministic so recorded sessions can be replayed without a terminal or subprocess.

Modules§

agents
Agent catalog and user configuration.
collaboration
Bounded public context shared between sequential relay participants.
contract
Tolerant normalization helpers for external adapter state.
details
Replay-safe state for expensive tool, thought, terminal, and diff details.
history
Durable prompt history compatible with the retired Python client.
launcher
Startup configuration and saved-roster restoration.
persistence
Versioned persistence for the Rust client.
policy
Adapter-independent permission policy resolution.
relay
Deterministic sequential roster scheduling.
resources
Safe, bounded workspace resources for prompt attachments.
settings
Small, atomic JSON settings store.
trace
Deterministic scripted traces for adapter cutover and dogfooding.

Structs§

AgentCapabilities
AgentCommand
A slash command advertised by an ACP session. The renderer intentionally keeps only the command name at the shared event boundary; descriptions and input hints are provider-specific presentation data and are not needed to dispatch or complete a command.
AgentSlot
BufferedEventLog
Background event-log writer used to keep terminal input/render handling independent from filesystem latency. The channel is intentionally unbounded: dropping normalized events during a streamed turn would make replay and recovery incomplete, while the writer drains ordinary event rates faster than adapters produce them.
EventLog
A newline-delimited event log. It deliberately records normalized events rather than UI operations, so sessions can be replayed by a future renderer or adapter host. Each append closes its file handle but does not force a storage sync; the terminal input/render loop must never block on fsync.
Mode
PermissionRequest
SessionState
ToolUpdate
UsageUpdate
The latest context-window counters reported by an ACP session.

Enums§

AgentEvent
Effect
PermissionAnswer
The normalized answer to an adapter permission request. Native adapters may reject this explicitly when their protocol has no permission control.
RosterUpdate
TerminalEvent
ToolStatus

Functions§

reduce
Apply one normalized event. I/O and rendering are represented by effects, never performed in the reducer.

Type Aliases§

RosterSlot
Stable roster position; slot zero is always the owner.