Skip to main content
Glama
fgui-agent-bridge

fgui-agent-bridge

by Wilson520403

fgui_set_list_items

Batch replace items in an existing FairyGUI List with up to 1000 entries, setting url, title, icon, name, selectedTitle, and selectedIcon; omitted fields clear, and [] empties the list.

Instructions

整批替换已有 List 的条目(0.8.26+);数组顺序即条目顺序,[] 清空。

最多 1000 项,支持 url/title/icon/name/selectedTitle/selectedIcon;省略的字段清空。 省略 default_item 保留默认组件,空串清除它。条目的空/省略 url 继承最终默认组件。 先校验全部输入;限当前根组件下未锁定的 List,须退出时间轴与组内编辑。 不进 Agent 撤销栈;默认不保存,未保存可 discard,save 保存整个文档。 原生应用失败尝试恢复原条目并回报 rolledBack;保存/验证失败不自动回滚。 external_reload 要求 save=True 且 verify=True。

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "items": "<items>"
    },
    "name": "fgui_set_list_items"
  }
}

Input Schema

NameRequiredDescriptionDefault
saveNo
itemsYes
verifyNo
object_idNo
object_nameNo
object_pathNo
default_itemNo
external_reloadNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.8.25

TDQS

A4.5/5.0
Behavior5/5

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

With no annotations present, the description carries the full burden and does so: it discloses that all input is validated before any mutation, that the operation does not enter the Agent undo stack, that changes are unsaved by default, and that unsaved state can be discarded or committed with save (which saves the whole document). It even distinguishes rollback semantics — native-app failures attempt restore and report rolledBack, while save/verify failures do not auto-rollback.

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 core action, then semicolon-delimited clauses for limits, validation, rollback and persistence. Every clause carries information, but the telegraphic style and lack of visual grouping make the persistence/rollback section harder to parse than it needs to be.

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?

An output schema exists, so return values (including rolledBack) need not be spelled out, and the description covers the mutation, validation, persistence and failure paths that an agent must know before calling this destructive-feeling bulk write. The one real omission is how the target List is identified among object_id / object_name / object_path.

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?

Schema description coverage is 0%, so the description must compensate, and it covers the hard parts: items order equals item order, [] clears, max 1000 entries, supported fields url/title/icon/name/selectedTitle/selectedIcon, omitted fields are cleared, omitted default_item preserves the default component while an empty string clears it, and empty/omitted urls inherit the final default component. However, object_id / object_name / object_path (3 of 8 params) are given no explanation at all, so target resolution is left to inference.

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?

Opens with a specific verb+resource: batch-replace the items of an existing List, and notes the 0.8.26+ version gate. It is clearly distinguishable from the read-side siblings fgui_list_items / fgui_get_list_items and from fgui_set_list_layout, which handles layout rather than content.

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?

States explicit preconditions and exclusions: only unlocked Lists under the current root component, and the user must exit the timeline and group editing first. Also conditions external_reload on save=True plus verify=True. It never names an alternative tool (e.g. insert_list or get_list_items for inspection), so it stops short of a full when-to-use-this-vs-that rubric.

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