工具

終端機工具

用於編碼和營運操作的 Shell 與行程執行能力。

終端機工具

這是什麼

用於編碼和營運操作的 Shell 與行程執行能力。

白話解釋

這就像描述食譜可能做出什麼味道,和實際打開爐子品嚐成品之間的區別。終端機工具讓 Hermes 能夠實際執行命令——建構、測試套件、git 操作——並看到真實結果,而不是猜測可能的結果。

為什麼重要

Shell 和行程執行是編碼相關對話最常依賴的能力,因為執行建構、測試套件或 git 命令通常比抽象推理可能的結果更快。與瀏覽器或 computer-use 工具不同,它純粹在行程和檔案系統沙盒內運作,而不是驅動 GUI——這也是它擁有 4 個已註冊宣告的原因之一。沙盒邊界和核准規則在這裡最為明顯,因為在無人看管的 agent 上不受限制的 shell 存取正是那些防護措施要防止的情況。

How it works

The terminal toolset centers on two tools, terminal and process, which together can execute commands locally, inside a Docker container, or in a Modal cloud sandbox depending on configuration (tools/terminal_tool.py) — plus two desktop-only companions, read_terminal and close_terminal, that only register when the GUI is present. Long jobs can run in the background with notify_on_complete, which pings the agent exactly once when the process exits — the schema explicitly steers the model toward this for anything over a minute, like tests or deployments — while watch_patterns covers the rarer case of a long-lived process needing a mid-run signal, rate-limited to one notification per 15 seconds and switched over to notify_on_complete behavior after repeated drops. A pty flag enables pseudo-terminal mode for interactive CLI tools, and a once-per-process Docker orphan reaper cleans up abandoned containers.

A concrete example

A coding agent needs to run a slow test suite without stalling the conversation.

  1. It calls process with the test command and notify_on_complete=True.
  2. The test suite runs in the background while the agent continues handling other questions.
  3. When the tests finish, Hermes receives a single notification with the exit code and output, and can report the results without having blocked the conversation for the whole duration.