Skip to main content
Glama

set_widget_text

Rewrites an existing text fragment by locating it through page name, record index plus object ID, or container path, while optionally using the session chain for source and output.

Instructions

按页内名称、记录索引+对象 ID 或容器路径精确定位改写一个既有文本片段。具名调用省略宿主源/输出即使用会话链;原始 args 用 session:true 并省略这两个参数(多源工具保留导入源)。显式路径不推进链。 登记证据 gui-roundtrip,只适用 capabilities.md 的已验样本。CLI: node set-widget-text.mjs <source.rp> <output.rp>

Input Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.4.5

TDQS

A3.7/5.0
Behavior4/5

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

Annotations already declare non-read-only, non-destructive, closed-world behavior, and the description adds substantive context beyond them: it rewrites an existing fragment (not creating content), explains session-chain advancement semantics, and scopes applicability to verified capabilities.md samples. It does not describe what happens to existing rich formatting or styling during the rewrite, which would have made it a 5.

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

Conciseness3/5

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

The purpose is front-loaded in the first clause, but the text is dense and mixes several concerns in long clauses, including a 'registered evidence gui-roundtrip' note that is opaque without external context. The trailing CLI usage line largely restates the schema's required fields and adds length without adding selection guidance.

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

Completeness4/5

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

For a mutation tool with no output schema, the definition covers targeting strategies, source/output omission behavior, session-chain side effects, and applicability limits, which is enough for an agent to call it correctly. The main omissions are the effect on existing text formatting and any permission or overwrite preconditions.

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 schema only types the fields as strings, so the description's interpretation adds real meaning: page is an in-page name, widget can be a record index + object ID or a container path, and source/output may be omitted under session chaining while multi-source tools must keep the import source. This materially guides correct parameter construction beyond the structured schema.

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 uses a specific verb+resource: precisely locate and rewrite an existing text fragment, and it enumerates three targeting modes (in-page name, record index + object ID, container path). It does not explicitly distinguish itself from close siblings such as set_widget_richtext or edit_text, so an agent must infer the boundary.

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

Usage Guidelines3/5

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

Guidance is given for invocation modes – named call omitting source/output uses the session chain, raw args require session:true and omit those params, and explicit paths do not advance the chain – but this is parameter-mode guidance rather than when-to-use-this-tool-vs-alternatives guidance. The note that it applies only to verified samples in capabilities.md is a useful boundary but is not a usage rule for choosing among text-editing siblings.

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

Deploy Server

Other Tools