Skip to main content

cel_contracts/
lib.rs

1//! Shared AI agent boundary contracts.
2//!
3//! This crate holds the data types that span the planner/runtime boundary so
4//! neither side needs to depend on the other's implementation. Planners produce
5//! these contract types; runtimes execute them and emit receipts.
6//!
7//! **Strict policy:** depends only on `cel-context`, `serde`, `serde_json`, and
8//! `async-trait`. No runtime, no prompt logic, no LLM dependencies. Anything
9//! that needs more belongs in a downstream planner or runtime crate.
10
11pub mod actions;
12pub mod canonical;
13pub mod producer;
14pub mod receipt;
15pub mod view;
16
17pub use actions::{CellWrite, EffectExpectation, PlannedAction};
18pub use canonical::{
19    AttemptRecord, FailureReport, GoalOutcome, NextMove, RunLimits, RuntimeCaps, Step, StepKind,
20    StepResult,
21};
22pub use producer::{DoneVerdict, NextActionHint, PlanProducer};
23pub use receipt::{
24    DispatchRoute, ExecutionReceipt, ObservedEffect, ObservedKind, ObservedStatus, ReceiptStatus,
25};
26pub use view::{
27    AdapterActionRef, AdapterFactRef, AnomalyRef, Blocker, CapabilityRef, EventRef, EvidenceRef,
28    KnowledgeRef, MemoryRef, OmittedCounts, PlanningBudget, PlanningElement, PlanningElementState,
29    PlanningScreen, PlanningView, RunProgress,
30};