Foundry reduces "agent amnesia" and token waste.
Only the last few completed tasks (ID, intent, success status) are injected into the runtime context - not the full project history. That keeps prompts focused and cheaper.
Helper agent sessions are isolated per project (e.g. helper:validation:<projectId>). Sessions are reused across invocations so the helper doesn't re-ingest huge context every time. When a provider hits token limits, Foundry rotates the session automatically.
helper:validation:<projectId>
Validation results are cached (e.g. in Redis). If file content and criterion haven't changed, the previous result is reused so you avoid repeated AI validation.