compress_context
Replace buffered messages with a compressed summary to free space for new messages. Ideal for archiving old conversations after retrieving context.
Instructions
Compress all buffered messages for a target into a single summary, freeing buffer space.
This is destructive: raw messages are replaced by a compressed summary. Once compressed, individual messages cannot be recovered from the buffer. Use this after get_recent_context when you want to archive old conversations and make room for new messages.
The compression uses the client LLM (via MCP sampling) to generate a concise summary. Falls back to rule-based compression if LLM is unavailable.
Destructive: permanently replaces raw messages with a summary.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"target": "<target>"
},
"name": "compress_context"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| target | Yes | ||
| target_type | No | group |