klieo-ops 0.41.0

Operational layer above klieo-core: supervisor, governor, gates, escalation, worklog, handoff.
Documentation

klieo-ops

Operations layer above klieo-core: run supervision, policy gates, escalation chains, durable worklog, agent handoff, and PII redaction.

Every primitive emits structured events into the existing Merkle-chained EpisodicMemory, so compliance evidence is a byproduct of normal operation rather than a separate instrumentation concern.

Part of the klieo Rust agent framework.

Features

Feature What it enables
supervisor Kill-switch, budget enforcement, run lifecycle management
governor Concurrency limits and rate controls at the pre-effect boundary
gates Cedar policy-as-code approval gates
escalation Four-eyes review and escalation chains
worklog Durable operation audit log
handoff Structured agent handoff protocol
crypter AES-GCM envelope encryption for worklog entries
hot-reload Live policy reload without process restart
full All of the above

All features in default except hot-reload (opt-in) and test-utils (dev-only).

Usage

[dependencies]
klieo-ops = { version = "0.38", features = ["full"] }

Wire an OpsRuntime around your agent run:

use klieo_ops::{OpsRuntime, RunContext, scope_run_context, TenantId, AgentId};

let runtime = OpsRuntime::builder()
    .tenant_id(TenantId::new("acme"))
    .agent_id(AgentId::new("my-agent"))
    .build()
    .await?;

scope_run_context(RunContext::new(runtime), async {
    // agent work here — supervisor, governor, gates, worklog all active
}).await;

Key public exports

  • OpsRuntime — main entry point; wires all enabled primitives together
  • RunContext, scope_run_context, spawn_with_run_context, current_run_context — async context propagation
  • OpsEvent, emit_ops_event — structured event emission into EpisodicMemory
  • TenantId, AgentId, AgentMeta, ProviderId, RuntimeState — domain ID newtypes and state types
  • TenantResolver, spawn_with_context — multi-tenant context routing
  • BuildError, OpsError — typed errors

What is out of scope

This crate does not assess agent decision quality, bias, or accuracy. Those are user-owned concerns (EU AI Act Art 10, Art 15).

Status

0.38.x — pre-1.0; patch releases are backward-compatible. See docs/SEMVER.md.

License

MIT — see LICENSE.