interplane.Get Omega
Read in your language

aien-sovereign-core-mv

AienOS host runtime: inference scheduling, paged KV state, the aien CLI and Spark verification tooling. Its inference engine is in alpha testing (DGX Spark GB10); Omega is the implementation destination.

Brought by drakestapleton

branch main Branches Tags History

aien-sovereign-core-mv / crates / aien-trace / README.md

57 lines · 2570 bytes Raw Blame History Rendered
1# aien-trace
2
3Correlation-only execution trace for AIEN (aien-sovereign-core#398).
4
5## What it is
6
7Typed events (`TraceEvent`) that say "this boundary was crossed" and carry the
8ids needed to join a swarm, its sequences, model turns, tool decisions, effect
9results and Interplane messages into one run. It is observational. It is not
10evidence and it is not authorization: the effect receipt ledger, the compose
11ledger, the generation record and the independent receipt verifier keep
12governing. Events point at those artifacts by digest or relative path.
13A trace id is a correlation key, never a secret and never a proof.
14
15## Default
16
17`NullSink` discards everything and is the default. Tracing is off until a
18caller installs another sink. The crate starts no thread unless
19`BoundedJsonlSink::spawn_flusher` is called.
20
21## Cardinality
22
23One event per boundary crossing: swarm launch, branch fork, sequence
24admit/preempt/finish, model turn, tool request, authority decision, effect
25execution, result, cancel, timeout. Bounded by sequences times stages. There
26are no per-token or per-kernel events, so GPU hot paths are untouched.
27
28## Buffering and backpressure
29
30`BoundedJsonlSink` holds a bounded queue (default 4096 events). `emit` takes a
31mutex only for one push and does no I/O. When the queue is full the event is
32dropped and counted. The next `flush` appends one `trace_dropped` event whose
33note says how many were dropped. `dropped_total()` is the lifetime count.
34Security-critical records live in the ledgers, not here, so dropping a trace
35event never loses evidence.
36
37## Retention
38
39Append-only JSONL, one object per line, created with mode 0600 on unix. The
40operator rotates or deletes files. The crate deletes nothing.
41
42## What is never exported
43
44No prompts, tool arguments, model output, memory items or secrets. Enforced by
45type: the only free text is `BoundedNote` (64 bytes, control characters and
46`<` `>` removed). Ids are `BoundedId` (64 characters, small alphabet), digests
47are hex, paths are relative without `..`. Deserialization applies the same
48rules, so edited files cannot widen a field.
49
50## Rebuilding one run
51
52Read the JSONL lines into `Vec<TraceEvent>` and call `reconstruct(&events)`.
53It checks one trace id, unique event ids and a valid parent for every child,
54then gives `Tree::children(id)` and `Tree::chronological()`. Statuses map to
55the AEGIS failure vocabulary plus `ok`; `uncertain` means the request may have
56reached the server and is never retried automatically. To verify anything,
57follow the digest or path to the independent artifact.