@inhuman.tools/arrival-provenance
v0.9.9
Published
The trace-capture substrate (re-exported from @inhuman.tools/arrival's `/provenance` subpath) plus the full render-model analysis stack — forest, statechart, region tree, flow graph, reverse-chain slicer — owned natively here (provenance analysis-stack re
Maintainers
Readme
@inhuman.tools/arrival-provenance
After an @inhuman.tools/arrival eval, this package turns a finished EvalTrace into a forest, graph, or slice. It never drives the evaluator. Core @inhuman.tools/arrival/provenance is capture only (EvalTrace, stamping at the membrane); this package re-exports that capture and owns the analysis stack — forest, statechart, region tree, flow graph, reverse-chain slicer (buildUneval), grounding seal.
Install
pnpm add @inhuman.tools/arrival-provenanceUsage
Hand the evaluator a tap; analysis runs on the finished trace:
import { exec } from "@inhuman.tools/arrival";
import { EvalTrace, traceToForest } from "@inhuman.tools/arrival-provenance";
const trace = new EvalTrace();
await exec(`(filter (lambda (x) (> x 5)) (list 1 3 7 9 2))`, { tap: trace });
const forest = traceToForest(trace);The heavier analysis stack lives at the ./analysis subpath:
import { traceToStatechart, buildSlice, buildUneval } from "@inhuman.tools/arrival-provenance/analysis";
const statechart = traceToStatechart(trace);The surface, in four subpaths:
.— capture + region-model primitives:EvalTrace(this package's export is the mobx-reactiveObservableEvalTrace; core stays mobx-free),Invocation(each carries its own computed.provenance; dataflow minted at boundaries),traceToForest,traceToRegionswith an incrementalTraceRegionFold. Plustrace-snapshot/trace-artifactserialization../analysis— turn a finished trace into render-models: a statechart, a flow graph, forest-collapse (collapseMDL), and the reverse-chain slicer (buildSlice/buildUneval)../verdict—groundingVerdict, the whole-result grounding seal: a lineage-completeness oracle over a finished traced run (not a truth oracle — it signs a provably-traced fabrication from a lying tool just as readily as a fact)../reflect— the query layer over a finished run:ResultHandle(causal value now, teleological provenance on demand),why/where/how/dag/blast(named projections of/analysis), the wire-safe choke, and thearrival/reflectScheme capability. Not re-exported from..
