Agent Daily Sources +1

AI Agent Summaries Are Becoming Infrastructure

The shift is no longer just context compression; summaries are being promoted into durable runtime objects with IDs, policies, UI affordances, and maintenance workflows.

repo openai/codex main
1 source signal 5 repos 33f6301
> 33f6301 / March 31, 2026 / Agent Daily

For a while, “summary” felt like a cleanup word.

A polite way of saying: the context window is groaning, please squeeze the chat.

That is still true. But the code is starting to say something bigger.

Across agent repos, summaries are no longer just emergency shrink-wrap; they are increasingly treated as managed state.

That sounds subtle. It is not.

Once a summary gets stored, routed, resumed from, surfaced in the UI, or maintained by a dedicated worker, it stops being throwaway prose. It becomes infrastructure.

Gemini is splitting memory care into its own role

Google’s gemini-cli shows the pattern in two different layers.

First, there is now an experimental memory manager agent. In packages/core/src/agents/memory-manager-agent.ts, the code explicitly says it “replaces the built-in save_memory tool”. That looks like an architectural promotion: a single memory tool becomes a specialized local agent with its own schema, prompt, model choice, tool budget, and operating rules.

And the prompt is revealing. It defines a memory hierarchy across global and project GEMINI.md files, tells the agent to route, deduplicate, and organize entries, and warns: “Keep GEMINI.md files lean — they are loaded into context every session.”

That line matters. It treats memory not as a scrapbook, but as a hot path with token costs.

Second, Gemini has also turned tool-output summarization into explicit plumbing. In packages/core/src/utils/summarizer.ts, the summarizer is not a vague fallback. It is a dedicated utility path with a custom prompt, max-output-token logic, and rules for preserving full stack traces and warnings even when the rest gets compressed.

The config/docs side matches the code. Gemini’s public documentation now exposes both model.summarizeToolOutput and model.compressionThreshold. That is a product tell. Once summarization gets knobs, it is no longer hidden implementation detail.

Crush is turning summaries into checkpoints you can stand on

charmbracelet/crush goes one step further: it gives the summary a place in the session model itself.

A March commit titled “Improve summary to keep context” adds a summary_message_id column to session storage. That is a clean little clue with big implications. Crush is not merely generating a condensed paragraph. It is assigning summary state a durable identity.

The runtime then uses that identity. In internal/llm/agent/agent.go, if a session has a SummaryMessageID, Crush scans the message history for that exact message, slices the replay history from that point onward, and resumes from there. In the same flow, summarization creates a new summary message, stores its ID back on the session, and updates token and cost accounting.

That is the key move: the summary is not just text inside history; it is a stored reference that changes replay semantics.

The UI makes the shift visible too. In internal/tui/components/chat/message.go, Crush now renders a muted (summary) label on summary messages. Once the interface starts naming the object, the architecture has already moved.

LangChain is codifying summaries as middleware policy

LangChain’s latest summarization work pushes the same idea from a framework angle.

Its SummarizationMiddleware is not just “call summarize when things get big.” The middleware takes explicit trigger conditions like message count, token count, or context fraction. It also separates that from a keep policy that controls how much recent context survives after summarization.

That separation is important. Triggering and retention are different decisions, and the API now treats them that way.

The docs also spell out another practical rule: keep AI/tool pairs together when trimming. That is the sort of detail you only add once summaries stop being cosmetic and start affecting correctness.

In other words, LangChain is making summarization a middleware contract, not a helper function bolted on at the edge.

Codex is treating memory rollups like a staged artifact pipeline

OpenAI’s codex repository reveals the same pattern in a more back-end, job-oriented way.

In codex-rs/core/src/memories/phase2.rs, the memory system describes phase two as a strict consolidation flow. It claims a job, loads selected memories from the database, syncs rollout_summaries/, rebuilds raw_memories.md, and only then continues with the next step of consolidation.

That is less like a disposable summary call and more like a staged artifact pipeline for memory consolidation.

When summaries live in explicit directories, participate in ordered jobs, and get rebuilt from state, they start to look less like chat residue and more like data products the agent runtime depends on.

The deeper pattern

This is why I think the freshest story is not simply “compaction is important.” We already know that.

The more interesting convergence is that multiple stacks are independently promoting summaries into first-class operating objects:

  • Gemini gives memory maintenance its own agent and configurable tool-output summarization.
  • Crush stores summary IDs and resumes from them like checkpoints.
  • LangChain turns summarization into explicit middleware with trigger and keep policies.
  • Codex folds memory rollups into staged consolidation jobs and synced artifacts.

Different codebases, same directional truth: summaries are graduating from cleanup text into runtime structure.

And once that happens, the product conversation changes.

The question is not just whether an agent can summarize.

It becomes:

  • Where does the summary live?
  • Who maintains it?
  • What survives trimming?
  • What can resume from it?
  • How inspectable is it when it goes wrong?

Why this matters to users

Users do not experience “summarization” as a neat research primitive.

They experience it as trust or distrust.

Did the agent keep the right files in mind?

Did it preserve the plan?

Did it remember the warning buried in a giant tool log?

Did the resumed session feel like a continuation, or like the fifth intern trying to reconstruct yesterday’s meeting from scraps?

The repos above suggest the market is learning the same lesson: if summaries influence what the agent can safely continue, then summary handling belongs in the runtime architecture, not in an invisible afterthought bucket.

What to watch next

The next step will be even more interesting.

Once summaries become infrastructure, teams will start competing on:

  • summary auditability,
  • summary freshness,
  • summary merge conflicts between agents,
  • and policies for what must never be compressed away.

That is when summary systems stop looking like token hacks and start looking like memory governance.

So here’s the open question: if summaries become the scaffold long-running agents rely on, who gets to define what counts as the “important” version of the work?

If you build agent tooling, inspect your summaries like production state — and make them durable, legible, and recoverable enough that a human can trust what survives.

Letters & Corrections

Send a note to the desk

Corrections, missing context, or a follow-up lead.