Skip to main content
Glama

Resume a DSH session

dsh_resume_session

Resume a persisted inactive DSH session through ACP after validating its canonical cwd, ownership, and desktop release; continues the session without replaying prior transcript messages.

Instructions

Restore a persisted inactive DSH session via ACP session/resume, validating canonical cwd and session ownership first. Resume only restores a persisted inactive session and continues it; it does not replay prior transcript messages. WARNING: DSH ACP cannot see sessions held by another process (the desktop app), so session/list also lists sessions the desktop may still be running. Resuming is NOT read-only: it activates the session and writes to the same persisted log, which can conflict with the desktop. Requires acknowledge_released=true, and switching desktop tabs does not count as releasing.

Input Schema

NameRequiredDescriptionDefault
cwdYesAbsolute working directory; must match the session canonical cwd.
session_idYesExplicit persisted session id.
permission_policyNoValidated for compatibility but NOT inherited: pass permission_policy explicitly on each dsh_send_message.deny
acknowledge_releasedYesMust be true. Confirms the session is not in use by the desktop app (closed there, not merely a background tab).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.1/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=false, destructiveHint=false, idempotentHint=false and openWorldHint=false. The description adds genuine context the annotations cannot: resuming activates the session, writes to the same persisted log, and can conflict with the desktop process that DSH ACP cannot detect. That is real value beyond structured fields, though it doesn't say what error surfaces on a log conflict.

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 action, then the scope limit, then the warning, then the precondition — a logical escalation. The session/list aside about desktop-held sessions is somewhat tangential to invoking this tool and could be trimmed, but every sentence carries operational weight.

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 mutation tool with no output schema and four fully described parameters, the description covers the safety profile, the ownership precondition, and the concurrency hazard. It omits what a successful resume returns (session state, resumed cwd) and how a detected desktop conflict is reported, which an agent would want before acting.

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 baseline is 3; the description still adds meaning by explaining that acknowledge_released is a release confirmation and that 'switching desktop tabs does not count as releasing', which sharpen the schema's wording. It explains cwd validation and the permission_policy non-inheritance rule, but the latter is already spelled out fully in the schema.

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 ('Restore') plus resource ('persisted inactive DSH session') and the mechanism ('ACP session/resume'), then immediately bounds it: 'Resume only restores a persisted inactive session... it does not replay prior transcript messages.' That boundary cleanly separates it from dsh_create_session and dsh_send_message without needing to open their schemas.

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 explicit when-not conditions (does not replay transcript, cannot see sessions held by another process, do not resume while the desktop may still be running it) plus a hard precondition ('Requires acknowledge_released=true'). It stops short of naming the sibling to use instead when a session is not persisted or is currently held by the desktop, so the alternative routing is implied rather than stated.

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