Skip to main content

Crate behest_runtime

Crate behest_runtime 

Source
Expand description

Async runtime kernel for the behest agent runtime.

During migration from behest::runtime, some doc and pub lint warnings are temporarily relaxed. They will be re-enabled once the migration is complete.

Re-exports§

pub use error::RuntimeError;

Modules§

accumulator
Streaming accumulator for text and tool calls.
agent
Agent runtime — streaming-first execution kernel.
cache_stats
Aggregated prompt cache statistics for a run or a window of events.
compaction
Context compaction — LLM-driven conversation summarisation.
component
The Component trait: lifecycle contract for every pluggable runtime building block.
component_factory
Adapters that wrap existing runtime traits as Components.
components
Self-contained Component implementations that construct providers, stores, and adapters from JSON configuration.
context
Context pipeline for runtime.
doom_loop
Doom loop detection for agent runs.
error
Runtime error types.
event
Re-export of the canonical AgentEvent and its payload structs from behest_event.
event_publisher
External event publishing boundary for runtime events.
event_store
Reliable runtime event log.
extension
ExtensionPoint<T>: a typed, name-indexed, hot-swappable collection.
extensions
Extensions: the composable, hot-pluggable facade over every pluggable runtime element.
factory_registry
Factory registry for runtime components.
input
Input admission and promotion pipeline.
invocation
Transport-neutral runtime invocation facade.
lifecycle
Cooperative shutdown primitives.
managed
ManagedRuntime: unified container orchestrating AgentRuntime, ComponentRegistry, and ShutdownToken into a single lifecycle.
memory
In-memory implementations of runtime stores.
policy
Runtime policy configuration.
registry
ComponentRegistry: ordered, dependency-aware, type-erased registry for every Component in the runtime.
router
Model router for runtime.
run
Run lifecycle types.
run_loop
Agent run loop — the core iterative execution engine.
session_gate
Per-session concurrency gate.
snapshot
Agent execution snapshotting and recovery.
state
Event-sourced run state reconstruction.
store
Runtime store facade.
stream
Transport-neutral runtime stream primitives.
stream_adapter
Best-effort live fanout for runtime events.
subscription
Coordination layer combining replay and live fanout.
token
Token estimation using character-based heuristics.
tool_output
Tool output truncation with head+tail sampling.
tool_runtime
Tool runtime layer with validation, timeout, and bounded parallelism.
tool_scope
LIFO scoped tool registry with shadow-stack semantics.
turn
Turn-based state machine for agent control flow.