Skip to main content
Glama
w48930429

FairyGUI Agent Bridge

by w48930429

fgui_parse_component

Parses FairyGUI component XML into a structured description of its properties, controllers, display elements, gear/relation settings, and transitions, enabling developers to inspect and discuss UI component logic directly.

Instructions

解析组件并生成自然语言描述

将组件 XML 解析为易于理解的结构化描述,包含:

  • 基础属性(尺寸、扩展类型等)

  • 控制器定义

  • 显示列表元素

  • Gear 和 Relation 配置

  • Transition 动画

Args: package_name: 包名称 component_name: 组件名称

Returns: 组件的结构化描述

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
package_nameYes
component_nameYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.8.3

TDQS

C2.9/5.0
Behavior2/5

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

With no annotations, the description carries the full burden and only says the tool 'parses' XML, which implies read-only behavior but is never stated explicitly. It does not mention whether a document must be open, whether any state changes, or failure modes, so an agent cannot infer side-effect safety.

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?

The description opens with a one-line purpose, then uses bullet points to list included content, followed by Args and Returns. It is well-organized and modest in length, though the Args/Returns blocks mostly restate schema information.

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?

For a tool with no annotations and a 0%-described schema, the description omits usage context (prerequisites, when to prefer this over fgui_get_tree/search_component) and side-effect information. It gives the output categories but not enough for an agent to invoke it reliably in a workflow.

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?

The schema has 0% description coverage, and the description adds only 'package_name: package name' and 'component_name: component name', which are near-tautological translations of the parameter names. It does not define name formats, how to locate them, or any constraints, so it fails to compensate for the schema gap.

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 action ('parse component and generate natural language description') and enumerates the output categories (base attributes, controllers, display list, Gear/Relation, transitions), making the tool's role clear. It does not explicitly contrast with siblings like fgui_get_tree or fgui_search_component, so it misses the top score for sibling differentiation.

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?

There is no explicit when-to-use/when-not-to-use or alternative routing. The intended use is only implied by the purpose statement and the included sections; no prerequisites or exclusions are given.

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