Result projection — configurable worker output fidelity (T328)
By default every worker returns a full Result: the complete output text, usage stats, and any raw
provider payload. When a judge or downstream step only needs a summary (e.g. an LLM judge that scans
a one-line verdict) or just the diff artifact (e.g. a DiffJudge that only reads result.raw.diff),
forcing full transcripts into context wastes tokens and increases judge latency.
Set projection on a workflow step or directly on a Task to control how much of each assembled
Result is materialised:
| Level | What you get | Best for |
|---|---|---|
full (default) | All fields — complete output, usage, raw payload | General-purpose; backward-compatible default |
summary | First 500 chars of output + [N chars omitted]; raw dropped | LLM judges that scan short answers; chat summariser steps |
artifact-only | output cleared; raw (diff/artifact) kept; usage kept | isolate: true build steps where the git diff is the deliverable |
structured | Full output kept; raw dropped | JSON-parsing judges that parse output text but do not need provenance |
Workflow step — apply projection to all workers in a step:
// In a workflow definition (TypeScript):
const def: WorkflowDef = {
name: 'implement-and-judge',
steps: [
{
id: 'implement',
prompt: '...',
isolate: true,
// Only the diff matters — drop full text output to keep context lean.
projection: 'artifact-only',
},
{
id: 'evaluate',
prompt: 'Evaluate the diff from {{implement}}.',
// Short summary is enough for the LLM judge.
projection: 'summary',
},
],
};Programmatic Task — per-call override when dispatching adapters directly:
import { applyProjection } from './src/core/projection.ts';
const result = await adapter.run({
id: crypto.randomUUID(),
prompt: task,
projection: 'structured', // output kept, raw dropped
});
// result.projection === 'structured'
// result.raw === undefinedReading truncation metadata — when projection: 'summary' trimmed the output:
if (result.projection === 'summary' && result.originalOutputLength !== undefined) {
console.log(`Output was ${result.originalOutputLength} chars; judge saw ${result.output.length}`);
}Backward compatibility — absent projection (the default) reproduces today's behavior exactly.
Existing workflows, adapters, and judges are unaffected. The projection and originalOutputLength
fields on Result are optional; their absence means the full result was returned.
Tool-call pipeline — batch multi-tool sequences in one model turn (T319)
Implementer-class loop workers (loop--build) automatically get a runpipeline tool that lets a worker express a predictable multi-step tool sequence as a single tool call, collapsing N sequential...
Stateful session reuse — warm CLI-agent bindings + session tree ingestion (T333)
By default every CLI worker cold-spawns a brand-new session for every task. With warm bindings enabled the adapter records the session ID returned by the first successful dispatch, then passes it...