Files
val-blog/org/ops/sentinel_audit_contract.v1.md
T

28 lines
946 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# Sentinel 审计输入强制规则(v1
目的:避免 Sentinel 因缺少方案正文而“空跑审计”。
## 强制字段
每次调用 Sentinel 前,必须包含:
- `task_id`
- `audit_scope`safety/logic/cost/full
- `audit_payload`(三选一或组合)
- `inline_text`(内嵌正文)
- `file_paths`(可读文件路径)
- `artifact_refs`(可定位产物引用)
- `source_type`inline/workspace_file/mixed
- `requested_output_schema`
## 拦截规则
- 缺少 `audit_payload`:直接拒绝派发 Sentinel
- `file_paths` 不可读:直接拒绝派发 Sentinel
- 正文长度不足(<500字):返回输入不完整错误
## 返回错误码
`SENTINEL_INPUT_CONTRACT_MISSING`
## 最佳实践
- 优先使用 `mixed`:正文摘要 + 文件路径双保险
- 高风险任务必须提供可复核文件路径
- 审计后将结论与问题清单落盘到 Atlas 的 `decision_log/``failure_patterns/`