Skip to main content
Glama

magpie_swarm_state

Refresh, archive, or clear swarm state and safely cancel running tasks for front-end MCP apps, with project-scoped control over active members and background work.

Instructions

供前端 MCP App 内部调用的 Swarm 状态刷新、成员归档与清空工具(不对模型暴露)。

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": "magpie_swarm_state"
  }
}

Input Schema

NameRequiredDescriptionDefault
allNo当 action 为 cancel_task 时设为 true 可一键暂停当前项目全部运行中任务。
cwdNo可选项目工作目录路径,与 project_key 作用相同。
actionNorefresh 读取最新快照;clear 清空任务与流水但保留项目激活态;clear_all 连同项目激活态一并清空;archive_member 归档指定成员;archive_errors 一键收敛历史异常成员;cancel_task 安全暂停指定或全部运行中任务并终止后台进程。
reasonNo当 action 为 cancel_task 时可选的暂停原因说明。
task_idNo当 action 为 cancel_task 时可选指定的后台 task_id。
member_idNo当 action 为 archive_member 或 cancel_task 时指定的目标成员 ID。
role_nameNo当 action 为 cancel_task 时可选指定的成员职能名。
project_keyNo可选项目分仓键,用于在多项目并行时指定读取或操作的项目分仓。

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.0.1

TDQS

C2.6/5.0
Behavior2/5

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

With no annotations, the description carries the full behavioral burden, yet it only gestures at destructiveness through the word '清空' and discloses nothing about irreversibility, permissions, or side effects like terminating background processes. The genuinely important behavioral detail — that clear keeps project activation while clear_all wipes it, and that cancel_task terminates processes — lives only in the schema, not the description.

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 zero filler. It is tight, though the brevity is partly what leaves the gaps elsewhere; structurally sound and easy to parse.

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?

For an 8-parameter, 6-action tool with destructive clear operations, no annotations, and no output schema, a one-sentence description is thin. An agent would have to reconstruct all usage and safety semantics from the enum alone, and the omitted cancel_task surface is a meaningful completeness gap.

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

Parameters3/5

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

Schema description coverage is 100%, so the schema already documents every parameter, including the conditional relevance of all, reason, task_id, member_id, and role_name per action. The description adds no additional parameter meaning beyond what the schema provides, so the baseline of 3 is appropriate.

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

Purpose3/5

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

The description names a specific resource and three operations (state refresh, member archiving, clearing), so it is more than a restatement of the name. However, it omits half of the actual action surface — cancel_task, archive_errors, and clear vs. clear_all distinctions — which the schema reveals, and it never differentiates itself from siblings like magpie_swarm_board or magpie_swarm_plan.

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

Usage Guidelines2/5

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

It states who calls it (internal frontend MCP App, not exposed to the model) which is a caller note rather than when-to-use guidance. There is no guidance on which action to pick for a given situation and no reference to alternative tools for the same goal, leaving selection entirely to inference from the enum.

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