feat: 补齐 HWLAB 手动调度能力
This commit is contained in:
+17
-12
@@ -2,7 +2,7 @@
|
||||
|
||||
`v0.1` CLI 的权威规格是 [spec-v01-cli.md](spec-v01-cli.md)。本文保留为 CLI 与服务 API 的辅助参考;如果命令、测试规格或实现状态与 `spec-v01-cli.md` 冲突,以 `spec-v01-cli.md` 为准。
|
||||
|
||||
AgentRun CLI 与服务 API 遵循 UniDesk `cli-spec` 原则。本文在 CLI 实现前先固化期望形态,避免实现漂移成长阻塞命令或隐藏状态。
|
||||
AgentRun CLI 与服务 API 遵循 UniDesk `cli-spec` 原则。本文只保留辅助索引,完整命令与测试规格见 [spec-v01-cli.md](spec-v01-cli.md)。
|
||||
|
||||
## CLI 形态
|
||||
|
||||
@@ -17,22 +17,27 @@ CLI 默认输出 JSON。空 stdout 是失败,不是成功。每个命令都必
|
||||
|
||||
长操作必须是 fire-and-forget 或短异步资源操作。CLI 调用应在 60 秒内返回。创建 run 或启动 runner 的命令返回创建出的资源和轮询命令,不等待模型 turn 完成。
|
||||
|
||||
## 规划命令
|
||||
## 常用命令
|
||||
|
||||
初始命令族:
|
||||
`v0.1` 常用命令族:
|
||||
|
||||
```bash
|
||||
bun scripts/agentrun-cli.ts runs create --json-file <run.json>
|
||||
bun scripts/agentrun-cli.ts runs show <runId>
|
||||
bun scripts/agentrun-cli.ts runs events <runId> --after-seq <n> --limit <n>
|
||||
bun scripts/agentrun-cli.ts commands create <runId> --type turn --json-file <payload.json>
|
||||
bun scripts/agentrun-cli.ts commands show <commandId>
|
||||
bun scripts/agentrun-cli.ts runner start --run-id <runId> --backend <backendProfile>
|
||||
bun scripts/agentrun-cli.ts backends list
|
||||
bun scripts/agentrun-cli.ts server start|status|stop|logs
|
||||
./scripts/agentrun runs create --json-file <run.json>
|
||||
./scripts/agentrun runs show <runId>
|
||||
./scripts/agentrun runs events <runId> --after-seq <n> --limit <n>
|
||||
./scripts/agentrun runs result <runId> [--command-id <commandId>]
|
||||
./scripts/agentrun runs cancel <runId> [--reason <text>]
|
||||
./scripts/agentrun commands create <runId> --type turn --json-file <payload.json>
|
||||
./scripts/agentrun commands show <commandId> --run-id <runId>
|
||||
./scripts/agentrun commands result <commandId> --run-id <runId>
|
||||
./scripts/agentrun commands cancel <commandId> [--reason <text>]
|
||||
./scripts/agentrun runner start --run-id <runId> --backend <backendProfile>
|
||||
./scripts/agentrun runner job --run-id <runId> --command-id <commandId> [--idempotency-key <key>]
|
||||
./scripts/agentrun backends list
|
||||
./scripts/agentrun server start|status
|
||||
```
|
||||
|
||||
具体命令名可以在实现时调整,但行为必须保持以下规则:
|
||||
行为必须保持以下规则:
|
||||
|
||||
- `runs create` 创建 durable facts 并立即返回。
|
||||
- `runner start` 启动本地进程或 Kubernetes Job,并返回 process/job identity、log path 和 poll commands。
|
||||
|
||||
Reference in New Issue
Block a user