Skip to main content
Glama

Reset terminal

terminal_reset
Destructive

Reset a terminal session by clearing its buffer and scrollback, or hard-reset to kill and respawn the shell while preserving env vars, cwd, and history by default.

Instructions

Wipe the terminal buffer and scrollback. By default the shell process keeps running (env vars, cwd, history all preserved). Pass hardReset: true to kill the current shell and spawn a brand-new one — anything mid-execution gets killed. When hardReset: true, you can also override cols, rows, shell, and cwd. In a session created with command, a hard reset runs that command again.

Input Schema

NameRequiredDescriptionDefault
cwdNohardReset only: working directory for the new shell.
colsNohardReset only: spawn at this width.
rowsNohardReset only: spawn at this height.
shellNohardReset only: shell command (default $SHELL).
hardResetNoKill + respawn the shell instead of just clearing the buffer. Default false.
sessionIdYesNumeric id of the session to target. Get one by calling terminal_create. Use terminal_list to enumerate currently-known ids.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

A4.5/5.0
Behavior5/5

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

Annotations already declare destructive=true and non-idempotent, but the description adds substantial context beyond them: what is preserved on a soft reset (env vars, cwd, history), what is lost on a hard reset (mid-execution processes), and the command-session re-run side effect. This is exactly the kind of consequence disclosure a destructive tool needs.

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

Conciseness5/5

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

Four tight sentences, front-loaded with the primary effect before the optional mode, and every sentence carries distinct information (default behavior, hard-reset behavior, overrides, command-session edge case). No filler.

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?

With no output schema and full annotation coverage, the description supplies everything needed to call this correctly: default vs hard mode, what each destroys, and the parameters that only take effect in hard mode. Nothing material is missing.

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%, and each parameter already documents 'hardReset only' plus defaults ($SHELL, false). The description restates the grouping of the hardReset-only overrides rather than adding new syntax or format detail, so the baseline 3 is appropriate.

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?

Opens with a specific verb+resource ('Wipe the terminal buffer and scrollback') and immediately distinguishes its two modes (soft clear vs hardReset kill/respawn), which separates it from siblings like terminal_resize or terminal_read. An agent can identify the operation without opening the schema.

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?

Clearly states the default behavior and the condition that selects the alternative ('Pass hardReset: true to kill...'), plus a non-obvious edge case (a session created with `command` re-runs it). It never names a sibling as the alternative or states when *not* to reset, so it falls short of a 5.

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