Rust shadow reader #
This small reader consumes the debugger's closed v1 JSONL record union. It reports record/gap/non-completed-operation counts and rejects malformed versions, kinds, unknown fields and availability values. It is not a combat simulator, action-policy interpreter or proof of native/Rust equivalence.
cargo build --locked --offline --manifest-path readers/shadow-rust/Cargo.toml
w3dev debug export /path/to/journal/manifest.json \
--format rust-jsonl --output /path/to/new-export
w3dev debug evidence-verify /path/to/new-export/manifest.json
readers/shadow-rust/target/debug/witcher-debug-shadow-reader \
/path/to/new-export/shadow.jsonl
--offline works when the locked dependencies are cached; otherwise omit it for a
normal Cargo fetch. The Python verifier checks the hashed sidecars/raw journal and
normalized correspondence. This reader checks the stream contract; use both.
window_start/window_end delimit explicit recording windows. An interrupted or
open window does not acquire a fabricated end row. session.json retains open
windows and pending operation IDs. Rejected/uncertain operations and gaps remain
in the stream. Sample/example rows are not automatically eligible combat outcomes.
Raw native payloads are retained in observations. Their sentinels and nullable fields are raw engine data; inspect the explicit native availability flags and capability registry before interpreting them. Normalized clock values carry typed availability and hook stage. Native ticks/engine time are scoped to one world generation; host monotonic timestamps require the same host-clock identity.
A live 364-record export passed this reader and Python verification. Unit fixtures also exercise preserved gaps/uncertain operations and rejection of an unknown kind. Full task-lifecycle transitions and batch episode/aggregate output remain gated; the reader does not invent those missing rows.