Skip to main content
Glama

原地压缩话题上下文

app_compress_session

Compress a conversation topic into a summary, reset the underlying long thread, and mount that summary at the top so the session can continue with less context.

Instructions

UI 专用:将指定话题压缩为摘要、重置底层长线程并将摘要挂载到当前话题顶部继续。

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": {
      "sessionId": "<sessionId>"
    },
    "name": "app_compress_session"
  }
}

Input Schema

NameRequiredDescriptionDefault
sessionIdYes
summarizerPersonaIdNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.1/5.0
Behavior3/5

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

No annotations are supplied, so the description must disclose behavior itself. It does reveal the critical trait that the underlying long thread is reset and a summary is mounted in its place, which signals a mutating, hard-to-reverse operation. However, it does not say whether original messages are destroyed or recoverable, what permissions are needed, or what happens on failure.

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?

A single front-loaded sentence with the UI-only caveat first and the three effects of the call in sequence. It is dense with no filler, though the packed clause chain slightly reduces readability.

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

Completeness2/5

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

This is a destructive reset-and-replace operation with no annotations, no output schema, and zero schema coverage for two parameters, one of which is entirely unexplained. The description should say whether the compression is reversible, what happens to discarded messages, and what summarizerPersonaId does. Those omissions leave it inadequate for the tool's complexity.

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

Parameters2/5

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

Schema description coverage is 0% and neither parameter is documented in the schema. The description's reference to "指定话题" loosely maps to sessionId, but summarizerPersonaId is never mentioned, so the agent cannot infer what it controls or whether it is optional. Little meaning is added beyond the raw parameter names.

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?

The description names a specific verb and resource: it compresses a topic into a summary, resets the underlying long thread, and re-mounts the summary at the top of the topic. That behavior is distinct from siblings like app_clear_session or app_delete_session, which do not summarize. It does not name a sibling explicitly, so a 4 rather than a 5.

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

Usage Guidelines3/5

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

"UI 专用" (UI-only) tells the agent this tool is meant for the interface rather than programmatic use, which is a real usage constraint. Beyond that, nothing says when to prefer this over clearing or deleting a session, or what preconditions must hold. Usage is implied by the compression scenario rather than stated.

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