Skip to main content
Glama
DustinTrap

kvm-pilot

by DustinTrap

calibrate_mouse

Idempotent

Measure and store this host's mouse movement correction so clicks land where intended; run it on a static screen with a visible cursor, then calibrated percent coordinates apply transparently.

Instructions

Measure and store this host's mouse commanded→observed correction (#128).

Fixes "clicks where the button should be and misses". Pointer moves only — no clicks, no keystrokes — but it visibly moves the live cursor ~10-30s, so it is gated like HID input (KVM_PILOT_MCP_ALLOW_HID; one approval covers the whole run). Preconditions: live video signal, a static screen, and a visible cursor. Afterwards mouse percent coords apply it transparently (calibrated: true); stored per (host, capture resolution) — a resolution change makes it stale, never applied. Mechanism details: the MCP server README.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
confirmNoPer-invocation approval when the client cannot prompt a human: set true to approve this exact call under the operator's standing policy. Leave false when the client supports elicitation (a human is asked). Never pre-set it speculatively; a denial returns outcome=not_confirmed.
profileNoProfile name from ~/.config/kvm-pilot/config.toml selecting which KVM/BMC (and its managed host) this call targets. Omit to use the server's default (KVM_PILOT_PROFILE).
toleranceNoMax held-out verification error, as a fraction of the screen, for the fit to be stored.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changedv1.0.0
    • addedInput schema / properties / confirm / description
      Added value: +"Per-invocation approval when the client cannot prompt a human: set true to approve this exact call under the operator's standing policy. Leave false when the client supports elicitation (a human is asked). Never pre-set it speculatively; a denial returns outcome=not_confirmed."
    • addedInput schema / properties / profile / description
      Added value: +"Profile name from ~/.config/kvm-pilot/config.toml selecting which KVM/BMC (and its managed host) this call targets. Omit to use the server's default (KVM_PILOT_PROFILE)."
    • addedInput schema / properties / tolerance / description
      Added value: +"Max held-out verification error, as a fraction of the screen, for the fit to be stored."
    • addedInput schema / properties / tolerance / exclusiveMinimum
      Added value: +0
  2. First observedv0.1.0

TDQS

A4.6/5.0
Behavior5/5

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

Goes well beyond the annotations: discloses that the live cursor visibly moves for ~10-30s, that it is gated by KVM_PILOT_MCP_ALLOW_HID with one approval covering the run, that results are stored per (host, capture resolution), and that a resolution change makes the calibration stale and it is never applied. This is exactly the extra behavioral context annotations cannot carry.

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 gating, then preconditions, then persistence semantics — a sensible ordering. It is dense with parentheticals and an issue reference (#128) that costs a little space, but nearly every sentence carries decision-relevant information.

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, the description still covers what an agent needs: preconditions, duration, approval/gating, side effects on the live cursor, and post-run state. The one failure mode it mentions (outcome=not_confirmed) is handled in the schema description, so 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 coverage is 100%, so `confirm`, `profile`, and `tolerance` are already fully documented in the schema. The description only indirectly touches parameters ('stored per (host, capture resolution)') without adding syntax or semantics beyond the schema, so the baseline 3 applies.

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+resource ('Measure and store this host's mouse commanded→observed correction') with the effect spelled out (fixes 'clicks where the button should be and misses'). It is clearly distinguishable from the sibling `mouse` tool, which the description explicitly says consumes this calibration afterwards.

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

Usage Guidelines5/5

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

Gives explicit preconditions (live video signal, static screen, visible cursor), scope boundaries ('pointer moves only — no clicks, no keystrokes'), the approval model, and the relationship to the `mouse` tool. An agent can decide when to call this versus `mouse` or `type_text` without inference.

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