Files
cp1-agents/sub-agents/ALZ-F01: Discovery Workflow Agent/cp1-alz-discovery-orchestrator-agent/docs/adr/0014-fetch-in-code.md
Jonathan Boniface 8bb62a4a42 ALZ-F01 Discovery sub-agent pattern: report phase and fetch in code
Orchestrator report phase (ADR 0013) and fetching in code (ADR 0014), with the report renderer.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-05 22:13:25 +00:00

1.0 KiB

ADR 0014: MCP results are fetched and stored in code

Status: Proposed. Date: 2026-11-01. Changes how ADR 0003 works.

Context

The orchestrator's model copied each MCP result into workspace_put. On SUB-002 it stored only the first 7 entries of the call log, despite being told to store results unchanged. The critic then reported five real scans as unmatched. The hash chain protects a record once stored, but can't show that it matches what the tool returned.

Decision

The model names the calls through fetch. Code makes them, stores the results exactly as they came back, and returns a receipt. agent.yaml still declares the MCP tools so that code can call them, and before_model withholds them from the model. workspace_put is no longer offered.

Consequences

A stored result is what the tool returned, and a refused call is stored and reported. The model reads a record only when a step needs it, which saves tokens and suits large estates. It has less freedom, and every call must be one fetch allows. The sub-agents are unchanged.