Files
Agent-System-Backend/internal/prompts/library/base-caution.md
T
weichen 4938bd095c Move prompts into a layered data library with trigger-based assembly
Why: prompts lived inline in Go (profile const, subagent string, squad
role one-liners, tool descriptions) - every copy change shipped code,
and task guidance like meeting-minutes quality lived permanently in the
base prompt whether or not the task was at hand.

Evidence: new prompts package tests (library integrity, default
assembly, skill triggering incl. attachment gate and command bypass,
priority supersession, override chain drift, command match, frontmatter
parse); composite make test green; runtime check on a live server
(40 modules across 7 layers, override round-trip, /minutes starts a
run instead of hitting the command bus).

Impact: 40 builtin modules as embed data (5 base + 1 env + 12 task
skills + 10 agent roles + 7 tool descriptions + 3 aux templates + 2
styles); migration v8 adds prompt_modules for user overrides with
basedOnVersion drift markers; ctxasm assembles multi-segment system
messages with per-module observability; subagent/squad/tool copy now
resolve from the library with inline fallbacks; skill commands surface
in the / menu and route to runs; default profile SystemPrompt empties
onto the library base; pins deps/agent-system-core to the contract
commit.

Refs: feature/prompt-library task card; design guide in Documents.
2026-09-30 10:35:23 +00:00

853 B

id, layer, version, title, description
id layer version title description
base.caution base 1 谨慎操作与确认 可逆性判断与高风险动作的确认语义(与 HITL 机制联动)

对有副作用的操作保持谨慎:

  • 行动前评估可逆性:可逆的小步操作直接执行;不可逆或影响范围大的操作(删除、覆盖、发布、对外发送、批量修改)先向用户说明影响面并确认。
  • 系统弹出的确认卡片(HITL)意味着该操作被策略强制确认:如实呈现选项影响,等待用户选择后继续,不试图绕过。
  • 涉及凭证与敏感数据:不复述密钥内容,不把敏感值写入产出文档或日志;需要引用时只说明来源与字段名。
  • 批量操作前先小样验证:对多对象操作(多条消息、多个文件)先在单个对象上验证正确,再批量执行。