Skip to main content
Glama
Wilson520403

fgui-agent-bridge

by Wilson520403

fgui_upsert_transition

Create or fully replace a FairyGUI Transition declaratively. Supports atomic undo/redo and verifies changes against disk or after external reload.

Instructions

声明式创建或完整替换一个 Transition;一次调用可由 fgui_undo/redo 原子回退。

save=True 保存后默认比对磁盘 XML 中的 节点;external_reload=True(需 save=True)关闭并重新打开文档再比对,响应 strength 为 reload / disk / none。

Input Schema

NameRequiredDescriptionDefault
saveNo
verifyNo
transitionYes
external_reloadNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.8.6

TDQS

A3.7/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does so well: it discloses that a single call is atomically retractable via fgui_undo/redo, that save=True triggers a disk <transition> comparison, that external_reload closes/reopens the document, and it enumerates the possible response strength values (reload/disk/none). It omits error/failure behavior and whether an active document is required.

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-loads the core upsert semantics in the first clause, then packs the save/external_reload/strength details into one dense sentence. No filler, though the second sentence is heavy and would scan better if split.

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 a deep nested schema and no annotations, the description supplies the essential behavioral context (undo, save, reload, strength outcomes). An output schema exists so return-shape explanation is not required, and the description appropriately focuses on mutation semantics; only failure/permission preconditions are missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/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 explains save and external_reload (including the save=True dependency) and implies verify via the '默认比对' default behavior, but the central `transition` payload and the exact effect of verify are left to the schema's type structure. It partially compensates for a 4-parameter, zero-description 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?

States a specific operation (declare-and-create-or-fully-replace) on a specific resource (a Transition), which is more precise than a generic upsert and distinguishes it from the item-level siblings (fgui_add/update/remove_transition_item). It does not explicitly name the sibling it replaces or deprecates, so it stops short of a 5.

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?

Gives a useful conditional (external_reload requires save=True) and notes the atomic undo/redo affordance, but never states when to choose this tool over fgui_add_transition_item, fgui_update_transition_item, or fgui_get_transition, nor any preconditions like needing an open/active document.

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