Skip to main content
Glama
computer
by zznabil

Focused element

ax_focused
Read-onlyIdempotent

Retrieves the UI element that currently holds keyboard focus, or null when no element is focused. Use it to detect and act on the active control.

Instructions

The element holding keyboard focus, or null.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "ax_focused"
  }
}

Input Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

B3.4/5.0
Behavior3/5

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

Annotations already declare readOnlyHint, idempotentHint, destructiveHint=false and openWorldHint=false, so the safety profile is covered. The description adds one real behavioral fact beyond them — the null result when nothing is focused — but discloses nothing about staleness, focus scoping (session/window/application), or how quickly the state can change between calls.

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?

A single front-loaded phrase that states the resource and the edge-case return with zero redundant wording. Nothing could be removed without losing information.

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 trivial zero-parameter getter the description is close to sufficient, but with no output schema present it leaves the shape of the returned element undefined — an agent cannot tell whether it receives a handle, an id, or a serialized node, nor what to do with the null case.

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?

The tool takes no parameters, so there is nothing for the description to disambiguate and the baseline for zero-param tools applies. The schema is closed (additionalProperties: false), consistent with the parameterless signature.

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?

The description names a concrete resource — the element that currently holds keyboard focus — and states the return (or null), so an agent knows exactly what it retrieves. It does not differentiate from similarly named siblings such as element_focus (a likely action tool) or ax_element, so a small amount of ambiguity remains about query vs. action.

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

Usage Guidelines2/5

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

No when-to-use or when-not-to-use guidance is given, and no alternative sibling is named. Usage is only implicitly inferable from the fact that the tool takes zero parameters and reads a single piece of state.

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