Skip to main content
Glama

sweep_stale_agents

Retire abandoned agents in a project using conservative inactivity rules while protecting the caller and active file reservations.

Instructions

Retire abandoned agents in the caller's project using the server's conservative inactivity heuristic. The caller is never retired, the threshold has a 60-second floor, and active file reservations block retirement by default.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
agent_nameYes
project_keyYes
threshold_secondsNo
registration_tokenNo
require_no_active_reservationsNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.4

TDQS

B3.4/5.0
Behavior4/5

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

With zero annotations the description carries the full behavioral burden and does so well: it discloses that the caller is never retired, that the threshold has a 60-second floor, and that active reservations block retirement by default. It omits whether retirement is reversible (unretire_agent exists as a sibling) and what authorization registration_token implies.

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 dense sentence, front-loaded with the action and packed with behavioral constraints and no filler. It earns nearly every clause, though the run-on structure slightly reduces scannability.

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

Completeness3/5

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

An output schema exists, so return shape need not be described, and the behavioral constraints are covered. However, for a destructive batch operation with no annotations and 0% schema coverage, leaving three parameters (notably registration_token) and the reversibility question unanswered is a meaningful gap.

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 coverage is 0% and the description only partially compensates: it clarifies threshold_seconds (60-second floor) and require_no_active_reservations (default blocking), but agent_name, project_key, and especially registration_token are left unexplained. Three of five parameters carry no semantics anywhere.

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 states a specific verb (retire), resource (abandoned agents), scope (caller's project), and mechanism (conservative inactivity heuristic), which clearly sets it apart from single-target siblings like retire_agent or deregister_agent. It never explicitly names an alternative, but the batch/heuristic framing is unambiguous.

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?

Conditions are given (60-second threshold floor, reservations blocking retirement, caller exempt), which implies when the tool applies, but there is no explicit when-to-use vs an alternative such as retire_agent for a single agent. The agent must infer that this is the bulk-sweep option.

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