Expand description
AXON runtime library — exposes the full AXON runtime: compiler
frontend (re-exported from axon-frontend), handlers, runtime
primitives, ESK, HTTP/WebSocket servers, persistence, OTS pipelines.
Used by the axon binary and by integration tests.
§Frontend vs runtime
§Fase 12.a — the compiler frontend (lexer, parser, AST, type checker,
IR generator, top-level checker, and the closed catalogs used by the
type checker) lives in the sibling crate axon-frontend, which has
zero runtime dependencies. This crate re-exports those modules
transparently so every existing caller (76 call sites across 26
files) keeps compiling without changes. The crate axon-lsp
consumes axon-frontend directly, skipping the runtime surface.
Modules§
- anchor_
checker - Anchor runtime checkers — validate LLM output against AXON anchor constraints.
- api_
keys - API Key Management — multi-tenant key registry for AxonServer.
- ast
- AXON AST node definitions — direct port of axon/compiler/ast_nodes.py.
- audit_
cli - CLI handlers for the ESK audit commands (dossier, sbom, audit, evidence-package). AXON CLI — ESK audit commands (§Fase 8.6 CLI parity).
- audit_
trail - Audit Trail — append-only log of administrative operations on AxonServer.
- auth_
middleware - Auth Middleware — role-based authentication gate for AxonServer.
- auth_
scope - §Fase 32.g — Auth scope (capability subset matching) for first-class axonendpoint routes.
- axon_
server - AxonServer — native reactive daemon platform.
- axonendpoint_
replay - §Fase 32.h — Replay-token binding for first-class axonendpoint routes.
- backend
- AXON Backend — Multi-provider LLM API clients.
- backend_
error - Backend Error Classification — structured error types for LLM API calls.
- backend_
resolution - §Fase 36.b — the Backend Resolution Contract (D1): the pure,
deterministic precedence ladder that resolves a flow’s execution
backend (request → axonendpoint
backend:→ server default → environment-availableauto→ honest failure). §Fase 36.b — the Backend Resolution Contract (D1). - backends
- §Fase 24.b — Native Rust LLM backends. Per-provider async clients
behind a
Backendtrait +Registry. Per-provider modules (anthropic.rs / openai.rs / gemini.rs / kimi.rs / glm.rs / ollama.rs / openrouter.rs) land in 24.c–24.i; this module ships the shared infra (trait + types + error + retry + observability + locked_model - buffer
- Zero-copy multimodal buffers — §λ-L-E Fase 11.b.
- cancel_
token - §Fase 33.f — Cancellation primitives (D6 cancel-safety).
- checker
axon checknative implementation.- circuit_
breaker - Circuit Breaker — per-provider failure protection for LLM API calls.
- cli_fmt
- §Fase 39.f —
axon fmtsubcommand (Rust binary parity). - cli_
parse - §Fase 39.f —
axon parsesubcommand (Rust binary parity). - compiler
axon compilenative implementation.- config_
persistence - Config Persistence — save and restore AxonServer runtime configuration.
- conversation
- Conversation history — multi-turn message accumulation between steps.
- cors
- CORS Middleware — Cross-Origin Resource Sharing configuration for AxonServer.
- cost_
estimator - Execution Cost Estimator — estimate token usage and USD cost before running a flow.
- db_pool
- Database Pool — PostgreSQL connection pool management for AxonServer.
- deployer
axon deploy— hot-deploy .axon source to a running AxonServer.- effects
- §Fase 23.f — Algebraic effects runtime. FSM dispatch loop + handler stack + Free-Monad interpretation of CPS-lowered IR (consumes the JSON IR emitted by the Python frontend in 23.b/c/d). AXON Algebraic Effects Runtime — Fase 23.f
- emcp
- ℰMCP Transducer — Epistemic Model Context Protocol runtime bridge.
- epistemic
- AXON Epistemic Lattice — type subsumption, join, meet, uncertainty propagation.
- epistemic_
capture - §Fase 55.a — capture the epistemic envelope from a tool’s effect row.
- esk
- §ESK Fase 6 — Epistemic Security Kernel. Port of
axon/runtime/esk/. AXON Runtime — Epistemic Security Kernel (§ESK Fase 6). - event_
bus - Event Bus + Daemon Supervisor — reactive infrastructure for AxonServer.
- exec_
context - Execution context — runtime variables accessible between steps.
- flow_
dispatcher - §Fase 33.y.b — Per-IRFlowNode async dispatcher skeleton. Closed-
catalog, compiler-enforced exhaustive match over the 45-variant
IRFlowNodeenum. Subsequent sub-fases 33.y.c–j replace the transitional legacy shim with real per-variant async handlers. 33.y.l retires the shim + theLegacyShimHandledoutcome variant once every IR variant has its real handler. §Fase 33.y.b — Per-IRFlowNode async dispatcher skeleton. - flow_
execution_ event - §Fase 33.b — Flow execution event stream (Layer 1: data-flow integrity).
- flow_
inspect - Flow Inspector — runtime introspection for deployed AXON flows.
- flow_
plan - §Fase 33.x.b — Streaming-shaped execution plan extractor. Builds
StreamingExecutionPlanfrom.axonsource for the production async SSE path; pre-resolves per-stepBackpressurePolicyviastream_effect_dispatcherso the hot per-chunk loop inaxon_server::server_execute_streaming_asyncdoes not re-walk the AST per chunk. Rejects flows that use 33.x.b-unsupported features (anchors / lambda apply / let bindings / mid-stream use_tool / hibernate / pix) with a closed-catalogPlanFallbackso the SSE handler can route them to the legacy synchronous path. §Fase 33.x.b + 33.x.c — Streaming execution plan extraction + unified.axonsource compilation pipeline. - flow_
version - Flow Versioning — version tracking and rollback for deployed flows.
- graceful_
shutdown - Graceful Shutdown — signal handling and orderly server termination.
- graph_
export - Graph Export — render dependency graphs as DOT (Graphviz) or Mermaid.
- handlers
- §λ-L-E Fase 2 — Handler layer (Free Monad + CPS). Port of
axon/runtime/handlers/. AXON Runtime — Handler layer (§λ-L-E Fase 2). - health_
check - Health Check — structured health assessment for AxonServer subsystems.
- hooks
- Execution hooks — pre/post step callbacks for instrumentation.
- http_
tool - HTTP tool provider — executes tool calls as REST requests via reqwest.
- idempotency
- §Fase 32.f — Idempotency-Key store for first-class axonendpoint routes.
- ingest
- Network ingest paths that deposit bytes directly into
crate::buffer::ZeroCopyBuffers. - inspect
axon inspectnative implementation — introspect the AXON standard library.- ir_
generator - AXON IR Generator — AST → IR transformation.
- ir_
nodes - AXON IR node definitions — direct port of axon/compiler/ir_nodes.py.
- jwt_
verifier - JWT signature verification + JWKS client.
- lambda_
data - Lambda Data (ΛD) — Epistemic State Vector codec.
- lambda_
runtime - AXON Runtime — Lambda Data (ΛD) Apply (Fase 15.c — Rust mirror).
- legal_
basis - Legal-basis catalogue — §λ-L-E Fase 11.c.
- lexer
- AXON Lexer — direct port of axon/compiler/lexer.py.
- logging
- Logging — production-grade structured logging for AxonServer.
- migrations
- Migrations — embedded database schema migration runner.
- multiparty
- Multiparty session types — the global view + projection.
- ots
- Ontological Tool Synthesis — §λ-L-E Fase 11.e binary pipeline synthesis.
- output
- Execution output formats — structured report for programmatic integration.
- parallel
- Parallel step scheduler — depth-based wave execution with threads.
- parser
- AXON Parser — recursive descent, fail-fast.
- pcc
- §Fase 51 — Proof-Carrying Code. apx/axonendpoint carry a portable,
machine-checkable proof object an INDEPENDENT verifier checks
against the artifact WITHOUT trusting the compiler that produced it
(the move from
esk’s builder-signed attestation to a consumer- verifiable proof). §51.a ships the kernel + the ComplianceCoverage property class. §Fase 51 — Proof-Carrying Code (PCC). - pcc_cli
- §Fase 51.f — CLI handlers for the PCC commands (
axon pcc prove/axon pcc verify). Closes the Proof-Carrying Code loop at the command line: generate a proof bundle from source, then independently verify it against a recompile of that source. §Fase 51.f —axon pccCLI: prove + verify. - pem
- Persistent Epistemic Modeling (PEM) — §λ-L-E Fase 11.d.
- plan_
diff - Plan Diff — compare two exported execution plans.
- plan_
export - Execution plan export — JSONB-compatible structured output.
- rate_
limiter - Rate Limiter — sliding window rate limiting for AxonServer.
- refinement
- Refinement types —
Trusted<T>/Untrusted<T>+ closed Trust Catalog. - repl
axon replnative implementation — interactive Read-Eval-Print Loop.- replay
- Execution Replay — reconstruct and analyze recorded traces.
- replay_
token - Deterministic replay tokens — §λ-L-E Fase 11.c.
- request_
binding - §Fase 37 — The Request Binding Contract (runtime delivery).
- request_
log - Request Logger — structured audit log for AxonServer API requests.
- request_
middleware - Request Middleware — automatic request ID, timing, and logging for AxonServer.
- request_
tracing - Request Tracing — Tower middleware layer for structured request observability.
- resilient_
backend - Resilient Backend — production-grade LLM call wrapper with retry, circuit breaker, and fallback.
- retry_
policy - Retry Policy — exponential backoff with jitter for LLM API calls.
- route_
schema - §Fase 32.c + 32.d — Schema validation for first-class axonendpoint routes.
- runner
axon runnative implementation — stub + real execution.- runtime
- §λ-L-E Fase 3 + 5 runtime primitives. Port of
axon/runtime/(lease kernel, reconcile loop, ensemble aggregator, immune kernels). AXON Runtime primitives (§λ-L-E Fases 3 + 5; §Fase 13.f.2 typed channels). - runtime_
flags - §Fase 33.x.h — Process-wide runtime opt-in flags. Today carries
the
tokenizer_fallbackflag that gates BPE-tokenized chunking on the SSE LEGACY path (D9 — opt-in; defaults OFF for v1.24.0 wire byte-compat). §Fase 33.x.h — Process-wide runtime opt-in flags. - runtime_
warnings - §Fase 33.x.g — Closed-catalog runtime warnings for the SSE
production path. Surfaces
axon-W002 streaming-not-supportedwhen the async streaming path falls back to legacy synchronous delivery (D5 — no silent degradation). §Fase 33.x.g — Closed-catalog runtime warnings for the streaming production path. - server_
config - Server Config API — runtime-adjustable configuration for AxonServer.
- server_
metrics - Server Metrics — Prometheus exposition format for live AxonServer metrics.
- session
- Session types — the algebra of typed bidirectional dialogue.
- session_
runtime - §Fase 41.d — the runtime of a session-typed dialogue. The static
algebra (
axon_frontend::session: duality, regular-coinductive equality, credit-refined backpressure index!ⁿA.S) gets a dynamic counterpart here: an operational state machine (SessionRuntime) with one method per algebra rule, a wire envelope (Frame), and an RFC 6455 WebSocket carrier (ws::drive) that runs a session type against a peer. Carrier-agnostic core; the WS layer is one binding. §Fase 41.d — the runtime of a session-typed dialogue. - session_
scope - Session Scoping — namespaced session isolation for AxonServer.
- session_
store - Session state / memory persistence — file-backed key-value store.
- shield_
registry - §Fase 40.b — Shield scanner extension point.
- stdlib
- AXON Standard Library — built-in personas, anchors, flows, and tools.
- step_
deps - Step dependency analysis — variable-based dependency graph between steps.
- storage
- Storage Backend — trait abstraction for persistent state in AxonServer.
- storage_
postgres - PostgreSQL Storage Backend — full persistent storage for AxonServer.
- store
- §Fase 35 — the
axonstorecognitive data plane runtime. - store_
introspect - §Fase 38.h (D10) — pure manifest-building logic for the
axon store introspect <store>CLI. - store_
schema - §Fase 38.b (D1) — the closed
axonstorecolumn-schema catalog, Rust frontend side. - store_
schema_ manifest - §Fase 38.c (D4, D6) — The
.axon-schema.jsonmanifest format + resolver. - stream_
effect Stream<T>— temporal algebraic effect with mandatory backpressure.- stream_
effect_ dispatcher - §Fase 33.e — Stream-effect dispatcher (Layer 4).
- stream_
runtime - Runtime implementation of
Stream<T>with the four closed backpressure policies fromcrate::stream_effect. - streaming_
via_ dispatcher - §Fase 33.z.b — Streaming-via-dispatcher graft skeleton. Lifts
flow_dispatcher::dispatch_node(Fase 33.y, 45/45 structurally complete) into the production SSE hot path behind theAXON_STREAMING_VIA_DISPATCHERruntime flag (default OFF; flip to ON for v1.27.0 stable in 33.z.c; legacy path retired in 33.z.e). §Fase 33.z.b — Streaming-via-dispatcher graft skeleton. - tenant
- tenant_
secrets - Per-tenant API key resolution via AWS Secrets Manager (M3).
- tokens
- AXON token types and keyword lookup table. Direct port of axon/compiler/tokens.py.
- tool_
dispatch_ bridge - §Fase 34.d (v1.29.0) — Bridge between
ToolEntry(the registry shape) andTooltrait impls (the dispatcher’s streaming surface). - tool_
executor - Native tool executors — Calculator and DateTimeTool.
- tool_
registry - Tool registry — extensible tool dispatch for AXON execution.
- tool_
trait - §Fase 34.b (v1.29.0) —
Tooltrait +ToolChunkclosed-catalog struct. - tool_
validator - Tool result validation and effect tracking.
- trace_
export - Trace Export — export analytics as Prometheus exposition format or CSV.
- trace_
stats - Trace Analytics — aggregate statistics across multiple execution traces.
- trace_
store - Trace Store — in-memory execution trace buffer for AxonServer.
- tracer
axon tracenative implementation — pretty-print execution traces.- trust_
verifiers - Runtime implementations of the closed
crate::refinement::TrustProofcatalogue. - type_
checker - AXON Type Checker — Phase 1: symbol table, duplicates, references, field validation.
- version_
diff - Version Diff — line-based source diff between flow versions.
- webhook_
delivery - Webhook Delivery — async HTTP delivery with retry and exponential backoff.
- webhooks
- Webhooks — outgoing HTTP notification system for AxonServer events.
- wire_
envelope - §Fase 39.b — Pure Silicon Cognition: the canonical wire payload type
for axonendpoint responses on
transport: json. - wire_
envelope_ producers - §Fase 39.c.y + 39.c.z — Wire envelope producer helpers.
- wire_
format - §Fase 33.z.k (v1.28.0) — Wire-format adapter framework.