Skip to main content
Glama

get_wait_chain

Read-onlyIdempotent

Diagnose why a process is unresponsive by tracing its threads' wait chain across processes, including locks, COM/ALPC calls, and deadlocks, before forcing thread access.

Instructions

What a process' threads wait for, across processes (Wait Chain Traversal): locks, other threads, other processes, COM and ALPC calls, deadlocks first. The answer to "why is it not responding". OPENS THE PROCESS' THREADS: the first call is refused with the risks; call again with force=true only if the user agreed. Can take seconds.

Input Schema

NameRequiredDescriptionDefault
pidYesThe process ID.
forceNoTrue only after the user agreed to the risk this tool described.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.5/5.0
Behavior5/5

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

Adds substantial behavior beyond the annotations: the tool opens the target process' threads, the first invocation is deliberately refused with a risk explanation, the retry requires force=true with user consent, and the call can take seconds. These access, consent, and latency traits are exactly what annotations cannot convey (readOnlyHint=true alone would hide the thread-opening risk).

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?

Front-loaded with the purpose, then the risk protocol, then the latency caveat — a sensible order with no filler sentences. The opening sentence is dense with a long enumerated list, but every clause earns its place by narrowing scope.

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

Completeness4/5

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

Given no output schema, the description still tells the agent what comes back conceptually (wait chain across processes, deadlocks first) and what to expect on the first call. The only gap is that the return structure of a wait chain is not sketched, though the self-refusal protocol is well explained.

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

Parameters4/5

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

Schema coverage is 100%, so both parameters are already documented, and the schema for force is nearly identical to the prose. The description still adds the operational meaning of force — it is the second-call escape hatch after a deliberate refusal and requires user consent — which is more actionable than the schema's wording.

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

Purpose5/5

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

States a specific verb and resource (what a process' threads wait for) and enumerates the scope precisely: locks, threads, processes, COM/ALPC calls, with deadlocks surfaced first. It also frames the diagnostic question it answers ("why is it not responding"), which distinguishes it cleanly from siblings like get_thread_stacks and why_process_will_not_end.

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

Usage Guidelines4/5

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

Gives clear context for when to reach for it (a non-responding process) and a mandatory two-step protocol: the first call is refused, force=true only after user agreement. What it does not do is name an alternative sibling (e.g. why_process_will_not_end) or state when the cheaper tools should be tried first.

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