Skip to main content
Glama

compact_thread

Summarizes an assistant thread's history in place so it can continue as the same thread indefinitely instead of being replaced; call it once and report the result.

Instructions

Compact the assistant thread: summarise its history in place so it can keep being the same thread forever instead of being replaced. Call it exactly once and report what it returns. It is a no-op if the thread was already compacted today. Takes up to a few minutes on a long thread.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "compact_thread"
  }
}

Input Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden and does well: it discloses that this is an in-place mutation, that it is idempotent per day (no-op if already compacted), and that it can take minutes on long threads. It stops short of saying whether the summarisation is lossy/irreversible or what permissions are needed.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Four short sentences, front-loaded with the action and effect, then the call protocol, then idempotency, then latency. Every sentence conveys something actionable, though 'forever' and the 'call it exactly once' phrasing are slightly conversational.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a zero-parameter tool this covers purpose, mutation semantics, idempotency, and runtime cost. The one gap is that there is no output schema and the description only says to 'report what it returns' without describing the shape of that return.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The tool takes zero parameters, so there is nothing for the description to disambiguate; the baseline for a parameterless schema applies. No misleading parameter hints are introduced.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource — 'Compact the assistant thread: summarise its history in place' — and explains the outcome (the thread persists rather than being replaced). It does not name any sibling, so the contrast with tools like purge_sessions or tidy_sessions is left implicit.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives concrete operational guidance: call it exactly once, report the result, and expect a no-op if the thread was already compacted today. The implicit trigger ('a long thread') is signalled by the duration note, though no explicit when-not-to-use or alternative tool is named.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.