Skip to main content

Crate aios_protocol

Crate aios_protocol 

Source
Expand description

§aios-protocol — Canonical Agent OS Protocol

This crate defines the shared types, event taxonomy, and trait interfaces that all Agent OS projects (Arcan, Lago, Autonomic) depend on.

It is intentionally dependency-light (no runtime deps like tokio, axum, or redb) so it can be used as a pure contract crate.

§Module Overview

  • ids — Typed ID wrappers (SessionId, EventId, BranchId, BlobHash, etc.)
  • event — EventEnvelope + EventKind (~55 variants, forward-compatible)
  • state — AgentStateVector, BudgetState (homeostasis vitals)
  • mode — OperatingMode, GatingProfile (operating constraints)
  • policy — Capability, PolicySet, PolicyEvaluation
  • tool — ToolCall, ToolOutcome
  • memory — SoulProfile, Observation, Provenance, MemoryScope
  • session — SessionManifest, BranchInfo, CheckpointManifest
  • ports — Runtime boundary ports (event store, provider, tools, policy, approvals, memory)
  • error — KernelError, KernelResult

Re-exports§

pub use error::KernelError;
pub use error::KernelResult;
pub use event::ActorType;
pub use event::ApprovalDecision;
pub use event::EventActor;
pub use event::EventEnvelope;
pub use event::EventKind;
pub use event::EventRecord;
pub use event::EventSchema;
pub use event::LoopPhase;
pub use event::PolicyDecisionKind;
pub use event::RiskLevel;
pub use event::SnapshotType;
pub use event::SpanStatus;
pub use event::TokenUsage;
pub use ids::AgentId;
pub use ids::ApprovalId;
pub use ids::BlobHash;
pub use ids::BranchId;
pub use ids::CheckpointId;
pub use ids::EventId;
pub use ids::MemoryId;
pub use ids::RunId;
pub use ids::SeqNo;
pub use ids::SessionId;
pub use ids::SnapshotId;
pub use ids::ToolRunId;
pub use memory::FileProvenance;
pub use memory::MemoryScope;
pub use memory::Observation;
pub use memory::Provenance;
pub use memory::SoulProfile;
pub use mode::GatingProfile;
pub use mode::OperatingMode;
pub use policy::Capability;
pub use policy::PolicyEvaluation;
pub use policy::PolicySet;
pub use ports::ApprovalPort;
pub use ports::ApprovalRequest;
pub use ports::ApprovalResolution;
pub use ports::ApprovalTicket;
pub use ports::EventRecordStream;
pub use ports::EventStorePort;
pub use ports::ModelCompletion;
pub use ports::ModelCompletionRequest;
pub use ports::ModelDirective;
pub use ports::ModelProviderPort;
pub use ports::ModelStopReason;
pub use ports::PolicyGateDecision;
pub use ports::PolicyGatePort;
pub use ports::ToolExecutionReport;
pub use ports::ToolExecutionRequest;
pub use ports::ToolHarnessPort;
pub use session::BranchInfo;
pub use session::BranchMergeResult;
pub use session::CheckpointManifest;
pub use session::ModelRouting;
pub use session::SessionManifest;
pub use state::AgentStateVector;
pub use state::BlobRef;
pub use state::BudgetState;
pub use state::CanonicalState;
pub use state::MemoryNamespace;
pub use state::PatchApplyError;
pub use state::PatchOp;
pub use state::ProvenanceRef;
pub use state::StatePatch;
pub use state::VersionedCanonicalState;
pub use tool::ToolCall;
pub use tool::ToolOutcome;

Modules§

error
Error types for the Agent OS protocol.
event
Canonical event types for the Agent OS.
ids
Canonical ID types for the Agent OS.
memory
Memory types: soul profile, observations, and provenance.
mode
Operating modes and gating profiles.
policy
Policy types: capabilities, policy sets, and evaluation results.
ports
Canonical runtime ports for Agent OS integrations.
session
Session and checkpoint types.
state
Canonical state and patch types for the Agent OS.
tool
Tool types: calls, outcomes, and definitions.