Skip to main content
Glama

Assert On

assert_on

Verifies the specified app ID is in the foreground on a device, failing if not.

Instructions

Fail unless app_id is in the foreground.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
app_idYes
deviceNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

C2.9/5.0
Behavior3/5

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

With no annotations, the description carries the full behavioral burden, but it does disclose the single most important trait: the tool raises/returns a failure rather than a boolean, which is non-obvious for an assertion helper. It is silent on timing (is it instantaneous?), retry behavior, timeout, and the actual error shape.

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?

One short sentence, front-loaded with the failure condition and no filler. It is terse rather than wasted, though the terseness shades into under-specification.

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

Completeness2/5

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

An output schema exists, so return values need no prose, but for a mutation-free assertion tool with no annotations and 0% parameter coverage the description should still cover synchronization semantics and the device parameter. As written it is too thin for an automation precondition check.

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 description coverage is 0%, so the description must compensate. It conveys what app_id means (the package/identifier expected in the foreground) but says nothing about the second parameter, device, leaving half the parameters undocumented in both schema and description.

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 states a specific outcome: it fails unless the given app_id occupies the foreground. That is more precise than a restatement of the name 'assert_on', and an agent can infer it is a precondition check rather than a query. It does not, however, name the neighboring concepts it should not be confused with (current_app_id, wait_for_app, validate_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?

There is no statement of when to prefer this over current_app_id (which reads the foreground app), wait_for_app (which waits for an app to appear), or validate_action. The agent must infer the usage context entirely from the word 'fail'.

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