Skip to main content
Glama

workbench_analyze

Run structured source analysis—AST queries, linting, Git history, crash symbolization, and log parsing—to investigate bugs and collect evidence with provenance.

Instructions

Structured analysis: Tree-sitter AST/query including Swift and syntactic call edges; Ruff/clang-tidy/golangci-lint/ESLint/SwiftLint; Git diff/blame/log; addr2line/LLVM symbolizer; local Semgrep rules; compiler/test/stack parsing. Missing tools or malformed output never imply a clean scan. ESLint requires execution authorization.

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": {
      "case_id": "<case_id>",
      "target_file_filter": "<target_file_filter>",
      "analysis": "<analysis>"
    },
    "name": "workbench_analyze"
  }
}

Input Schema

NameRequiredDescriptionDefault
case_idYes
analysisYes
max_linesNo
timeout_msNo
target_file_filterYesExact files relative to source_root. Directories and whole-repository globs are refused.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

B3.4/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=false, destructiveHint=false, and openWorldHint=true. The description adds two genuinely useful behavioral facts beyond that: missing tools or malformed output never imply a clean scan (an important false-negative warning), and ESLint needs execution authorization. It does not cover what the call returns, whether results are persisted to the case, or how failures other than missing tools surface.

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?

It is a single dense sentence followed by two short caveats, with no filler or restatement of the title. The trade-off is that the capability list is a comma-spliced run-on that is harder to scan than separate mode bullets would be.

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

Completeness5/5

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

For a read-and-run analysis tool whose annotations carry the safety profile and which has no output schema, the description states the mode surface and the key false-negative and authorization caveats. It leaves the best-documented parameter to the schema's own text, which is reasonable at this level of detail.

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 coverage is only 20%, so the description has to carry weight, and it partially does by naming the mode discriminators (AST/lint/semgrep/git/symbolize/logs), the lint engines, git operations, symbolizer engines, and log formats. It says nothing about case_id, target_file_filter, max_lines, timeout_ms, or fields like query, base, staged, addresses, and load_bias, so most of the discriminated union remains unexplained.

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 concrete resource (structured source/code analysis) and enumerates the specific capabilities behind it: Tree-sitter AST queries, a fixed set of linters, Git diff/blame/log, symbolizers, Semgrep, and log parsing. That is enough for an agent to know precisely which operations live here, though it never contrasts itself with siblings such as workbench_run_check or workbench_inspect_source.

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?

There is no when-to-use or when-not-to-use guidance at all: nothing says which sibling to prefer for running checks or inspecting source, or which of the six analysis kinds fits which investigation. The only selection-adjacent statement is 'ESLint requires execution authorization', which is a gate rather than routing guidance.

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