chore: remove prompt lint and contract tests

This commit is contained in:
Codex
2026-06-11 11:54:35 +00:00
parent 4d68ad6ae3
commit 5e44545f07
98 changed files with 58 additions and 20917 deletions
+3 -8
View File
@@ -27,14 +27,11 @@ bun scripts/cli.ts commander contract
bun scripts/cli.ts commander plan --dry-run [--session-id primary]
bun scripts/cli.ts commander smoke --dry-run [--session-id primary]
bun scripts/cli.ts commander approval request --action <action> --dry-run [--reason text] [--task-id id]
bun scripts/cli.ts commander prompt-lint --kind gpt55-pr (--prompt-file <file>|--stdin)
```
`plan``smoke``approval request` 必须显式使用 `--dry-run`,缺失时返回 `error=dry-run-required`
`commander prompt-lint --kind gpt55-pr` 是指挥官派 GPT-5.5 PR/收口类任务前的本地辅助检查。它只读取 `--prompt-file``--stdin`,返回结构化 JSON 字段 `ok``missingClauses``riskLevel``suggestedPatchSnippet``promptShape.textEchoed=false``policy.advisoryOnly=true`;不会提交 Code Queue task、不会修改 scheduler、不会访问 live service,也不会回显完整 prompt。即使 lint 发现缺失条款,CLI envelope 仍保持成功退出,调用方应把 `data.ok=false` 当作派单前修补建议,而不是业务 PR 门禁或 `codex submit` admission 规则
`gpt55-pr` 当前检查的硬边界包括:普通 PR 创建/更新、自合并/关闭、rebase/update/冲突处理授权;repo-owned CI/CD、build/publish artifact、DEV image/artifact tag/digest/report 授权;DEV deploy apply、rollout 和 live health verification 默认由 host commander 统一执行;未显式包含 `ROLLOUT_OK` 时 runner 不得竞争 DEV CD lock、deploy apply、rollout 或 live verification;禁止 PROD mutation、密钥读取/打印、数据库手工写入和破坏性回滚。缺失时 `suggestedPatchSnippet` 只给可追加的边界片段,不包含原 prompt。
GPT-5.5 PR/收口类任务的边界由指挥官在 AgentRun 派单前直接审查,prompt 必须写清 PR 创建/更新、自合并/关闭、rebase/update/冲突处理、repo-owned CI/CD、artifact build/publish、DEV rollout、PROD/secret/DB/破坏性回滚禁止范围和 closeout 字段
## Operator-Run Stdio Loop
@@ -86,14 +83,12 @@ host commander 不直接编辑 HWLAB 业务代码,不以本地热修绕过 HWL
- approval draft preview:只运行 `commander approval request --dry-run``buildCommanderApprovalDraft`,确认 `requiresExplicitUserApproval=true``claudeqq.mutation=false``sendImplemented=false``dryRunNoClaudeQqSend=true``notificationDraft.message` 为 200 字以内中文纯文本、`notificationPath.error=notification-path-unavailable`,并返回 backend-core `microservice proxy claudeqq /api/push/text` 命令;禁止 POST ClaudeQQ。
- SSH bridge boundary:只检查 `commander plan --dry-run``bridge.mutation=false``startPlan.enabled=false``safetyBoundary.phaseOneMutationAllowed=false`;禁止打开 SSH、PTY 或 stdio bridge。
历史命名的 dry-run 脚本是:
默认 dry-run 验证入口是:
```bash
bun scripts/host-codex-commander-no-daemon-smoke-contract-test.ts
bun scripts/cli.ts commander smoke --dry-run
```
该脚本保留历史 `contract-test` 文件名,但只执行 CLI dry-run 和短命 source-level handler/helper,不启动长期进程,也不代表新增合同测试政策。
## HTTP
| Method | Path | 说明 |