Skip to main content
Glama
xuanmingguo

DOT DeepSeek Harness MCP

by xuanmingguo

Close one idle run owner’s persistent terminals

close_run_terminals
DestructiveIdempotent

Close a run's terminal sessions and reconcile its permission lease after recovery, discarding that agent's PTY snapshot while preserving other owners and activity.

Instructions

Explicit permission recovery for a terminal run, or needs_attention with permission_restore_failed. Reject active native Agents. Discard this exact Agent session’s published PTY snapshot, including shells retained from prior runs; Agent idle cannot prove commands inside those shells are idle. Preserve other owners and unpublished/new terminal activity. Reconcile the original permission lease only after confirmed quiescence and return the updated original run. Never clears Inbox/history.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
runIdYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.18-dsh021a2.14

TDQS

B3.4/5.0
Behavior5/5

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

Annotations already declare destructiveHint=true, idempotentHint=true and readOnlyHint=false, yet the description still adds substantial value: exactly what is destroyed (the published PTY snapshot, including shells retained from prior runs), what is preserved (other owners, unpublished/new terminal activity), the ordering constraint (reconcile the lease only after confirmed quiescence), the return value (updated original run), and the boundary 'Never clears Inbox/history.' That is well beyond what the annotations convey.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

It is information-dense with little filler, but it is a run-on sequence of jargon fragments rather than front-loaded prose, and it leads with a conditional usage clause instead of the action. Structure impedes comprehension even though few words are wasted.

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?

For a destructive, idempotent mutation with no output schema and one parameter, the description covers the essential behavioral facts: destruction scope, preservation scope, sequencing, and return value. The main gap is the runId parameter's semantics, which neither schema nor description explains.

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?

With schema description coverage at 0% and one required parameter, the description must carry the load. 'This exact Agent session' and 'return the updated original run' weakly imply runId names a run, but nothing states where the id comes from, its format, or that it must be an idle/non-native-agent run. The single parameter is effectively undocumented.

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 core action is inferable from the title ('Close one idle run owner's persistent terminals') and the phrase 'Discard this exact Agent session's published PTY snapshot,' so a verb+resource does exist. However the description itself opens with a usage condition ('Explicit permission recovery...') rather than a plain statement of what the tool does, and the jargon-heavy phrasing makes the purpose hard to extract. It also fails to distinguish itself from the sibling reconcile_permissions, which the 'permission recovery' wording overlaps with.

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?

It gives real conditions for use ('Explicit permission recovery for a terminal run, or needs_attention with permission_restore_failed') and one exclusion ('Reject active native Agents'). But it never names an alternative sibling (reconcile_permissions, cancel_run) or explains how to choose between them, so the routing guidance is only implied.

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