Problem Description / 问题描述
English:
Currently in DSH Desktop, when an agent executes a bash/terminal command tool (e.g., running long-running scripts, building projects, installing dependencies, or running tests), the process output (stdout/stderr) is not streamed to the UI in real-time. DSH Desktop buffers the output and only displays everything all at once after the execution has finished.
For long-running tasks, this results in a degraded user experience:
- Lack of visibility: Users cannot track progress or see log output while the script is running.
- Perceived freeze: With no streaming feedback, users cannot easily tell whether the task is actively progressing or has hung/frozen.
- Troubleshooting difficulty: If a process hangs or gets stuck in an unexpected state, the user cannot see where it stopped without waiting for a timeout or killing the process.
中文:
目前在 DSH Desktop 中,当 Agent 调用 bash/终端命令工具(例如执行耗时脚本、编译构建或运行测试)时,进程输出(stdout/stderr)无法实时流式(stream)回显到界面中。DSH Desktop 目前是在整个命令执行完成后,才一次性展示全部 output。
对于执行时间较长的任务,这会导致用户体验较差:
- 缺乏实时进度反馈: 脚本运行过程中打印到控制台的进度信息无法即时看到。
- 容易误判卡死: 在长时间无输出反馈的情况下,用户无法直观确认进程是在正常执行还是已经卡死/无响应。
- 排查困难: 如果进程卡在某一步或陷入死循环,无法通过实时日志及时发现问题。
Suggested Solution / 期望行为
- Support real-time streaming of
stdout and stderr to the UI while the command/bash tool is actively running.
- Provide an auto-scrolling log/terminal block for running tool calls so users can monitor progress in real-time.
- Finalize the tool output block with execution status, exit code, and elapsed time once finished.
Problem Description / 问题描述
English:
Currently in DSH Desktop, when an agent executes a bash/terminal command tool (e.g., running long-running scripts, building projects, installing dependencies, or running tests), the process output (
stdout/stderr) is not streamed to the UI in real-time. DSH Desktop buffers the output and only displays everything all at once after the execution has finished.For long-running tasks, this results in a degraded user experience:
中文:
目前在 DSH Desktop 中,当 Agent 调用 bash/终端命令工具(例如执行耗时脚本、编译构建或运行测试)时,进程输出(
stdout/stderr)无法实时流式(stream)回显到界面中。DSH Desktop 目前是在整个命令执行完成后,才一次性展示全部 output。对于执行时间较长的任务,这会导致用户体验较差:
Suggested Solution / 期望行为
stdoutandstderrto the UI while the command/bash tool is actively running.