feat(cli): add real-time streaming support to run command with tool execution visibility

- Added message.part.updated event handling for incremental text streaming
- Added tool.execute event to display tool calls with input previews
- Added tool.result event to show truncated tool result outputs
- Enhanced EventState with lastPartText and currentTool tracking
- Defined MessagePartUpdatedProps, ToolExecuteProps, ToolResultProps types
- Updated event tests to cover new state fields

This enables the CLI run command to display real-time agent output similar to the native opencode run command, improving user experience with immediate feedback on tool execution.

🤖 Generated with assistance of OhMyOpenCode (https://github.com/code-yeongyu/oh-my-opencode)
This commit is contained in:
YeonGyu-Kim
2025-12-25 19:05:00 +09:00
parent c804da43cf
commit 695f9e03fc
7 changed files with 137 additions and 20 deletions

View File

@@ -717,8 +717,8 @@ Agent 爽了,你自然也爽。但我还想直接让你爽。
默认开启。Sisyphus 提供一个强力的编排器,带可选的专门 Agent
- **Sisyphus**:主编排 AgentClaude Opus 4.5
- **Builder-Sisyphus**OhMyOpenCode 增强版构建 Agent默认禁用
- **Planner-Sisyphus**OhMyOpenCode 增强版计划 Agent默认启用
- **Builder-Sisyphus**OpenCode 默认构建 Agent因 SDK 限制仅改名,默认禁用)
- **Planner-Sisyphus**OpenCode 默认计划 Agent因 SDK 限制仅改名,默认启用)
**配置选项:**
@@ -779,8 +779,8 @@ Sisyphus Agent 也能自定义:
| 选项 | 默认值 | 说明 |
| ------------------- | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
| `disabled` | `false` | 设为 `true` 就禁用所有 Sisyphus 编排,恢复原来的 build/plan。 |
| `builder_enabled` | `false` | 设为 `true` 就启用 Builder-Sisyphus AgentOhMyOpenCode 增强构建模式)。为了保留默认 OpenCode 构建体验,默认禁用。 |
| `planner_enabled` | `true` | 设为 `true` 就启用 Planner-Sisyphus AgentOhMyOpenCode 增强计划模式)。默认启用。 |
| `builder_enabled` | `false` | 设为 `true` 就启用 Builder-Sisyphus AgentOpenCode build 相同,因 SDK 限制仅改名)。默认禁用。 |
| `planner_enabled` | `true` | 设为 `true` 就启用 Planner-Sisyphus AgentOpenCode plan 相同,因 SDK 限制仅改名)。默认启用。 |
| `replace_build` | `true` | 设为 `true` 就把默认构建 Agent 降级为子 Agent 模式。设为 `false` 可以同时保留 Builder-Sisyphus 和默认构建。 |
| `replace_plan` | `true` | 设为 `true` 就把默认计划 Agent 降级为子 Agent 模式。设为 `false` 可以同时保留 Planner-Sisyphus 和默认计划。 |