Skip to main content
Every Noēsis episode produces a set of structured artifacts that capture the complete cognitive trace. These files enable replay, debugging, auditing, and analysis.

Artifact structure

Episode IDs use ULID format (monotonic, sortable, 48-bit timestamp + 80-bit entropy). Directive and governance IDs use deterministic UUIDv5 for reproducible lineage tracking.
Paused approval workflows are intentionally not sealed. While a run is waiting for approval, expect events.jsonl, state.json, learn.jsonl, and checkpoint or tool-invocation records to exist, but not terminal-only files such as final.json, summary.json, or manifest.json. Those terminal artifacts are written after the run resumes and completes.

Tool invocation state

Protocol-first tool integrations persist review and idempotency state under the episode directory: For approval-gated subprocess tools, the runtime bridge prepares the draft, emits tool.approval.pending, interrupts the run, and writes a checkpoint. After an approved ToolApprovalDecision is persisted, ns.resume_run(...) continues the same run and executes the existing draft without re-preparing it. Constraints to check during incident response:
  • there should be exactly one pending_approval prepared draft for the run
  • unsupported bridge protocols (http, mcp) fail before draft persistence on prepare or before run.resume is emitted on resume
  • missing final.json or manifest.json is expected until the resumed run reaches a terminal state

summary.json

The summary captures episode outcomes, metrics, and cross-references.

Schema

Key fields

Reading summaries

state.json

The state captures the cognitive context at the end of the episode.

Schema

Step kinds

Step statuses

Outcome statuses

Reading state

events.jsonl

The event timeline records every phase transition with timing and lineage.

Format

Events are stored as newline-delimited JSON (JSONL):

Event structure

Event metrics always include started_at, completed_at, and duration_ms, which you can aggregate for per-phase latency. Plan derivability contract: state.json.plan can be reconstructed from the latest plan event (steps + step_records + source) plus subsequent act events carrying step_id and step_status.

Event phases

The phase field stores the phase emitted into the trace.

Reading events

CLI access

manifest.json

The manifest provides integrity verification for all artifacts with SHA-256 hashes and optional signatures.

Schema

Artifact immutability guarantees

All artifacts are written atomically using this pattern:
  1. Write to temporary file
  2. Call fsync() to ensure durability
  3. Atomic rename to final path
This ensures no partial writes survive system crashes.

Verifying integrity

JSON serialization uses canonical_dumps() with sorted keys for byte-identical output, ensuring consistent hashes across runs.

learn.jsonl (optional)

Learning signals are stored separately when the learn phase emits proposals.

Schema

Reading learn signals

prompts.jsonl (opt-in)

When prompt provenance is enabled (ADR-005, experimental), all prompts are recorded for debugging and auditing.

Schema

Experimental feature (ADR-005): Enable prompt logging carefully—prompts may contain sensitive data. Use ns.set(log_prompts=True) only when needed for debugging or compliance.

Use cases

  • Debugging: Trace exactly what prompts were sent to LLMs
  • Compliance: Audit trail for regulated industries
  • Cost analysis: Track token usage per episode
  • Prompt optimization: Analyze prompt patterns across runs

Storage configuration

Runs directory

Labels

Organize episodes with labels:

Retention

Control artifact retention:

Best practices

Back up production artifacts. The runs directory contains valuable audit data—include it in your backup strategy.
Redact sensitive data. Tasks and prompts may contain PII. Consider scrubbing before long-term storage.
Use manifests for compliance. The SHA-256 checksums in manifest.json provide tamper evidence for audits.

Next steps

Events reference

Complete event schema documentation.

State reference

Complete state schema documentation.

Export metrics

Send metrics to observability tools.

Summary reference

Complete summary schema documentation.