docs: 更新协议文档和设计文档
This commit is contained in:
@@ -185,7 +185,7 @@ interface Context {
|
||||
|
||||
---
|
||||
|
||||
## forwardedProps.client_time Schema
|
||||
## forwardedProps Schema(当前仅支持 client_time)
|
||||
|
||||
`RunAgentInput.forwardedProps` 支持透传客户端时间上下文。日历相关能力必须使用以下结构:
|
||||
|
||||
@@ -213,6 +213,7 @@ interface ForwardedProps {
|
||||
- `device_timezone` 必须是有效 IANA 时区。
|
||||
- `client_now_iso` 必须是 RFC3339 且包含时区偏移。
|
||||
- `client_epoch_ms` 必须是整数毫秒时间戳。
|
||||
- `forwardedProps` 当前仅允许 `client_time`,额外字段会触发 `422 invalid RunAgentInput.forwardedProps`。
|
||||
- 业务代码不得使用服务器本地时区作为事件语义时区。
|
||||
|
||||
### 说明
|
||||
@@ -434,7 +435,7 @@ interface HistoryMessageAssistant {
|
||||
seq: number;
|
||||
role: "assistant";
|
||||
content: string;
|
||||
ui_schema: UiSchemaRenderer | null; // 由 worker_agent_output.ui_hints 编译
|
||||
ui_schema: UiSchemaRenderer | null; // 由 agent_output.ui_hints 编译
|
||||
timestamp: string;
|
||||
}
|
||||
|
||||
@@ -519,4 +520,5 @@ interface UiSchemaRenderer {
|
||||
- `tools` 是前端工具通道字段;当前后端运行时不基于该字段构造后端工具 prompt
|
||||
- `RunAgentInput` 同时接受 camelCase 与 snake_case 别名输入(推荐统一使用 camelCase)
|
||||
- 日历能力依赖 `forwardedProps.client_time` 透传设备时间上下文;缺失时回退用户 profile 时区
|
||||
- `forwardedProps` 不支持业务私有控制字段(例如 `system_agent_mode`)
|
||||
- tool 消息在存储层用于运行时上下文续接,不在 `/history` 对外返回
|
||||
|
||||
Reference in New Issue
Block a user