智能体工具

终端终端

terminal({ action: "list" | "output" | "kill", id?, since? })

运行的终端启动或用户打开。 阅读它们是免费的; 杀死一个是命令—— 类别取决于动作 。

read, or exec on killsurvives the answernever on a phone
Using Python?

Switch any code block to Python: the choice applies to every page. Python SDK guide and resource reference.

actionstring必填

list · output · kill.

idstring

终点站 e.g. t_3需要 output 和 kill.

sinceinteger

output:从这一立场中读取。 0 保存的一切, 都归我所有。

一种工具中的两类

操作类别询问
list读为从未
output读为从未
killexec每种形体,只以足的、足的、

阅读服务器打印时不需要快速; 停止应该。 此类别是从参数中计算 。

工作循环

terminal({ action: "list" })                       // is it already running?
bash({ command: "npm run dev", background: true, port: 5173 })
terminal({ action: "output", id: "t_3" })          // what did it print since last time?
terminal({ action: "kill", id: "t_3" })            // stop it and everything it started
# The calls the model makes, in order:
#   terminal {"action": "list"}                                  is it already running?
#   terminal {"action": "create", "command": "npm run dev"}      start it
#   terminal {"action": "output", "id": "t_3"}                   what did it print since last time?
#   terminal {"action": "kill", "id": "t_3"}                     stop it and everything it started
开始之前的列表

代理商被要求检查一个服务器,该服务器可能已经运行,而不是在同一端口启动第二个服务器,因为这个服务器的故障方式看起来似乎代码已经破解。

他们生活在你的生活过程中

终端可以生存一个答案,而不是重新启用软件包。 值得在列出它们的接口中说。

无

只有在应用程序提供时, 才会在云工作空间上 终端终端电脑上,机器本身。