Agentic AI Notebook
Context Engineering
Phase 6Module 10 of 15

Tool Result Management

Most context explosions are tool dumps, not user chat.

A lab printout: pin the number on the board and file the forty pages.

Visual Workflows

Start here — scroll inside each diagram frame to explore, then use + / to zoom up to 200% if needed.

Overview

100%
Loading diagram...

Scroll inside the frame to explore · use + / − to zoom up to 200%

100%
Loading diagram...

Scroll inside the frame to explore · use + / − to zoom up to 200%

This turn

100%
Loading diagram...

Scroll inside the frame to explore · use + / − to zoom up to 200%

A lab printout: pin the number on the board and file the forty pages.

Key Takeaways

  • 1.Tool results are data, often huge, and often hostile.
  • 2.Parse, validate, trim, then pack a short observation.
  • 3.Keep the raw result in a store keyed by call id.
  • 4.Never paste a fifty-page HTML response into the next prompt.
  • 5.Most context explosions are tool dumps, not user chat.

Learn elsewhere

  • Tool Calling — Phase 7

Real Example

Scenario

Tool results: pack only what this turn needs.

What you would do

In Context Engineering, apply Tool Result Management to this scenario: Tool results: pack only what this turn needs. Identify the inputs, run the technique, validate the output, and note one thing you would monitor in production.

Commands

Commands to Remember

  • Tool results are data, often huge, and often hostile
  • Parse, validate, trim, then pack a short observation
  • Keep the raw result in a store keyed by call id
  • Never paste a fifty-page HTML response into the next prompt

Cheat Sheet

Quick recap

quick ref
  • Tool results
  • Budget
  • Don't dump

Common Mistakes

  • Skipping evaluation for Tool Result Management before production
  • No logging or tracing around tool result management steps
  • Ignoring cost and latency implications