Expand description
Slash-command framework and the M1 command set.
Commands are routed by the TUI’s prompt, the command palette,
and the non-interactive zero <command> entrypoint. All three
paths produce the same DispatchOutput, which downstream
renders as text, JSON, or a typed widget.
The crate enforces ADR-014 (risk asymmetry) at the type level
via risk::FrictionGate: only Increases-classified commands
can be friction-wrapped. Risk-reducing actions (/quit,
/kill, /flatten-all, /pause-entries, /break) are
instant and cannot be gated — the compiler refuses.
Re-exports§
pub use command::AutoAction;pub use command::COMMAND_CATALOG;pub use command::Command;pub use command::CommandInfo;pub use command::HeadlessAction;pub use command::ModeTarget;pub use command::OverlayTarget;pub use command::resolve;pub use config::ConfigDoctorFinding;pub use config::ConfigShowRow;pub use config::ConfigSource;pub use config::DoctorSeverity;pub use dispatch::DispatchContext;pub use dispatch::DispatchOutput;pub use dispatch::Never;pub use dispatch::OutputLine;pub use dispatch::ReplayLine;pub use dispatch::StateSource;pub use dispatch::StaticLabel;pub use dispatch::dispatch;pub use dispatch::run_bypass_friction;pub use friction::FALLBACK_REREAD_PHRASE;pub use friction::FrictionDecision;pub use friction::TYPED_CONFIRM_WORD;pub use friction::decide;pub use friction::decide_with_risk;pub use parse::ParsedLine;pub use parse::parse_line;pub use risk::FrictionGate;pub use risk::Gateable;pub use risk::Increases;pub use risk::RiskDirection;pub use session::ReplayEvent;pub use session::ReplayKind;pub use session::SessionError;pub use session::SessionSource;pub use session::SessionSummary;pub use supervisor::AutoMode;pub use supervisor::AutoReply;pub use supervisor::AutoRequest;pub use supervisor::AutoSource;pub use supervisor::MockAutoSource;pub use supervisor::MockSupervisorSource;pub use supervisor::SupervisorAction;pub use supervisor::SupervisorError;pub use supervisor::SupervisorReply;pub use supervisor::SupervisorSource;pub use supervisor::SupervisorState;
Modules§
- command
- The
Commandenum — exhaustive list of what the TUI, command palette, and non-interactive entrypoint can dispatch. - config
/config show+/config doctortrait + value types.- dispatch
- Dispatcher — resolves a
Commandinto aDispatchOutput. - friction
- Friction decisions — the runtime half of the risk-asymmetry invariant (ADR-013 / ADR-014, Addendum A §3 and §6.3).
- parse
- Command-line parser.
- risk
- Risk direction + friction gate invariant (ADR-014).
- session
- Session-store abstraction for the dispatcher.
- supervisor
- Supervisor + Auto-mode dispatch surfaces.