Skip to main content
Glama

desktop_focus_window

Focus a specified window by its handle, restoring it first if minimized so AI agents can interact with the correct application.

Instructions

把指定句柄的窗口切到前台(最小化时会先还原)。句柄来自 desktop_list_windows / desktop_perceive。

Input Schema

NameRequiredDescriptionDefault
handleYes窗口句柄
verifyNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.2

TDQS

A3.5/5.0
Behavior3/5

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

No annotations are provided, so the description carries the full behavioral burden. It usefully discloses the non-obvious trait that a minimized window is restored before focusing, but says nothing about what happens with a stale/invalid handle, whether the call can block, or what is returned on success/failure.

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?

Two short sentences, zero filler, with the core action front-loaded and the handle provenance trailing as supporting detail. Every clause earns its place.

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

Completeness3/5

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

For a two-parameter mutation-style GUI action with no annotations and no output schema, the description covers the main behavior and input source but leaves the 'verify' parameter and the return/failure semantics entirely unexplained.

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?

Schema coverage is only 50%: 'handle' is minimally described in-schema (the description adds the useful detail of which tools produce it), but the optional 'verify' parameter is never mentioned anywhere. With half the parameters undocumented, the description does not compensate for the coverage gap.

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

Purpose4/5

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

A specific verb+resource pair ('bring the window with the given handle to the foreground') that an agent can distinguish from siblings like desktop_screenshot or desktop_click. It does not differentiate itself from other activation-adjacent tools (there are none obvious), but the action is unambiguous.

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?

The second sentence tells the agent exactly where the handle must come from (desktop_list_windows / desktop_perceive), which is a concrete prerequisite and effectively routes the agent to call discovery first. No explicit exclusions or failure conditions are stated.

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