来自 UI 坐席的结构化输出
- Updated: 2026/04/29
为结构化输出向 UI Agents 进行提示的示例。
在目标中定义您的所需输出结构。
示例 1:让坐席自行确定输出结构。
Create a new invoice with the data: <data>. Return the Reference Number as a JSON.
注: 输出遵循特定格式。 例如,{"name": "str", "age": "int", "disability": "bool", "children": "list"}。
示例 2:在提示中指定架构,坐席将相应地格式化输出。
Open the product pricing page for “Pro Plan” in the web app. Extract pricing into the JSON schema below.
{
"plan_name": "",
"currency": "",
"price": {
"monthly": "",
"annual": ""
},
"included_limits": [
{"name": "", "value": ""}
]
}
示例 3:在运行操作中指定格式输出数据类型。
Goal: get current weather in San Francisco
Output format JSON: {"temperature": "int", "unit": "str", "rain": "bool"}
注: 输出格式 JSON 不支持嵌套的 JSON 结构。