Skip to content

Graphorin API reference v0.7.0


Graphorin API reference / @graphorin/tools / / TruncationOutcome

Interface: TruncationOutcome

Defined in: packages/tools/src/result/truncate.ts:53

Outcome of truncateBody. Carries the truncated body and the metadata the audit emitter writes into the tool:result:truncated row.

Stable

Properties

PropertyModifierTypeDescriptionDefined in
artifactBytes?readonlynumberBytes written to the spill artifact (only set for 'spill-to-file').packages/tools/src/result/truncate.ts:63
artifactPath?readonlystringPath of the spill artifact (only set for 'spill-to-file').packages/tools/src/result/truncate.ts:61
bodyreadonlystring-packages/tools/src/result/truncate.ts:55
droppedTokensreadonlynumber-packages/tools/src/result/truncate.ts:58
keptTokensreadonlynumber-packages/tools/src/result/truncate.ts:57
originalTokensreadonlynumber-packages/tools/src/result/truncate.ts:56
resultHandle?readonlystringOpaque, run-scoped handle URI for the spill artifact - e.g. graphorin-spill:<runId>/<toolCallId>.<ext> (only set for 'spill-to-file'). This is the model-facing reference embedded in the truncation annotation; unlike artifactPath it carries no raw filesystem path. Resolve it with createFileResultReader / the built-in read_result tool.packages/tools/src/result/truncate.ts:72
spillImperativePatternsPresent?readonlybooleanW-156: result of the single spill-time imperative-pattern scan over the FULL body (only set for 'spill-to-file', and only when the scan completed within budget). true means the artifact contains at least one catalogued imperative pattern - including one a future read_result page boundary would split, which the per-page strip pass cannot see. The executor stores it in the handle taint map and the default writer persists it in the taint sidecar.packages/tools/src/result/truncate.ts:83
strategyAppliedreadonlyTruncationStrategy-packages/tools/src/result/truncate.ts:59
summarizerModel?readonlystringModel name of the summarizer (only set for 'summarize').packages/tools/src/result/truncate.ts:85
truncatedreadonlyboolean-packages/tools/src/result/truncate.ts:54