Phase 3 Testing: Agent 可观测性 — prompt 注入 + CLI 展示 (#194) #197

Closed
opened 2026-05-12 01:33:04 +00:00 by xiaoju · 0 comments
Owner

验证目标

子 workflow agent 能感知父上下文;CLI thread show 展示调用栈链接。

测试步骤

  • Step 1: buildAgentPrompt 包含父上下文提示
    当 start node 有 parentState 时,prompt 中应提示 agent 可通过 cas get 遍历父上下文。

    bun test packages/workflow-util-agent
    

    预期: 新增测试用例验证 parentState 场景下 prompt 包含父上下文信息

  • Step 2: CLI thread show 显示链接

    uncaged-workflow thread show <thread-id>
    

    预期: 输出中包含 parentState 和/或 childThread 字段(非 null 时显示 hash)

  • Step 3: 端到端验证
    solve-issue workflow 跑一个实际任务,确认:

    • 子 thread 的 planner agent 能通过 DAG 获取父 preparer 的 repoPath
    • thread show 父子 thread 都能看到对方的链接
    uncaged-workflow thread show <parent-thread-id>
    uncaged-workflow thread show <child-thread-id>
    

    预期: 父 developer step 显示 childThread hash;子 start 显示 parentState hash

验证完成标准

所有 checkbox 打勾
Agent 能通过 DAG 遍历获取父上下文
CLI 展示调用栈关系

Ref: #194

## 验证目标 子 workflow agent 能感知父上下文;CLI thread show 展示调用栈链接。 ## 测试步骤 - [ ] **Step 1: buildAgentPrompt 包含父上下文提示** 当 start node 有 parentState 时,prompt 中应提示 agent 可通过 `cas get` 遍历父上下文。 ```bash bun test packages/workflow-util-agent ``` **预期:** 新增测试用例验证 parentState 场景下 prompt 包含父上下文信息 - [ ] **Step 2: CLI thread show 显示链接** ```bash uncaged-workflow thread show <thread-id> ``` **预期:** 输出中包含 `parentState` 和/或 `childThread` 字段(非 null 时显示 hash) - [ ] **Step 3: 端到端验证** 用 `solve-issue` workflow 跑一个实际任务,确认: - 子 thread 的 planner agent 能通过 DAG 获取父 preparer 的 repoPath - `thread show` 父子 thread 都能看到对方的链接 ```bash uncaged-workflow thread show <parent-thread-id> uncaged-workflow thread show <child-thread-id> ``` **预期:** 父 developer step 显示 childThread hash;子 start 显示 parentState hash ## 验证完成标准 ✅ 所有 checkbox 打勾 ✅ Agent 能通过 DAG 遍历获取父上下文 ✅ CLI 展示调用栈关系 Ref: #194
Sign in to join this conversation.
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: uncaged/workflow#197