pi

Identity

  • Names: pi / io.github.badlogic.pi.
  • Native format: pi-jsonl, header {type: session, version, id, cwd, parentSession?}. OMP can place a mutable title slot before the header.
  • Session ID: Header id, verbatim; no namespace. Paths and T3 thread locators are not session identity.
  • Entity keys: Entry id; toolCall.id and toolResult.toolCallId; assistant responseId identifies inference. Missing v1 IDs are capture-scoped. Version 2 tree/copy semantics remain unqualified; the contracts below apply to v3.
  • Notes: User role alone does not prove human authorship. Custom injections are harness messages. excludeFromContext keeps direct-shell output out of model context. Usage input and caches are disjoint; cost is harness-estimated USD. The writer’s responseModel, falling back to model, supplies the served model; model also records the request. Mutable title slots belong at the snapshot tail. Evidence of a write does not establish whether it added or overwrote a file. When a write is established but its operation is unknown, use op: "unknown".

Position basis

Use only positions established by the stated format and mapping evidence. Current-state rows without transcript positions form the snapshot tail. A protocol commit boundary takes precedence over physical EOF; uncommitted bytes are not a gap.

Destinations

pi: native facts without a standard field

  • Lineage: At the pinned v3 forkFrom writer, parentSession identifies the source. A path-valued parent requires authorized reading of its native header or index to recover id. Readers never open arbitrary paths automatically. This fork operation copies selected entries without changing their IDs. Only within that documented operation do unique matching IDs in the resolved parent prove copiedFrom with native_id, including inference projections. A parent pointer alone or repeated IDs elsewhere do not prove copies. No root claim is qualified.
  • Tree and compaction: parentId is the parent, responseId the response key. Apply the mechanical-sibling rule to native units. Only persisted active-leaf evidence supplies a head. For v3 compaction, parentId supplies replaces.throughId; firstKeptEntryId supplies keptFromId and insertAt.beforeId. Resolve both on the local active path, translating a native unit to its appropriate first/last context projection. Otherwise record the replacement as unknown. branch_summary.fromId names a leaf; without a qualified covered set, retain it and use unknown extent.
When parentSession contains a path, resolve it only by reading the referenced native header with authorized access to the source. Keep the path in native metadata. Never parse a parent ID from a filename. Reading the referenced header establishes the parent ID. Copy claims still require the pinned fork contract.

Usage

Select one report per native accounting identity only when this entry establishes that identity. Keep unjoinable or overlapping reports as native evidence. Declare incomplete semantic coverage. Schema defaults and placeholder zeros are not reported usage. Rules for what the backend includes in usage counts require evidence; do not infer them from a model name. Use the recorded assistant response report once per response. Native input and cache components are disjoint. Keep unjoined accounting as native evidence.

Lane and unassigned facts

Facts without established session ownership use manifest _meta["io.github.badlogic.pi/unassigned"] with the common shape. A selection may retain these facts alongside any subset of sessions, including an empty subset, but must not imply that any session owns them. State the selection policy in the export report.

Losses

Declare every applicable loss under ASR-157. Missing model rendering, accounting joins, lineage or exact context boundaries remain losses when this entry does not qualify them. Unknown ownership is not itself lost data. Report omitted unassigned facts using a documented vendor loss category or report rather than a new core category.

Evidence

Basis: source-verified at commit 54d22b74b3b538836f997ad0903fd44eaac45c93, JSONL header versions 1 to 3. Native Pi 1.3.0 persistence API capture and sanitized OMP 18.0.10 fork fixtures provide separate persistence evidence. Version 4 lanes are outside this entry. Evidence applies only to the named formats and explicit mappings above. A real capture covers only exercised behavior. A no-model writer probe covers persistence, not model or tool execution. Authored tests do not qualify an agent version. Unlisted formats and link mappings remain unqualified.