- AGENTS.md: 新增 §20 工具脚本复用 / §21 分析结论复用 / §22 Flaky 门禁,更新文档配置表
- .pi/: 新增 settings.json、rules/guardrails.md、prompts/{debug,review,ship}-gym-manage.md
- .agents/: 新增 Hook 配置与 4 个 Hook 脚本(session-start/pre-agent-check/check-completeness/stop-check)
及 protocols/systematic-debugging.md(check-completeness 含接口链缺口检测)
- scripts/flaky-scan.sh: vitest shuffle 稳定性扫描(gym-manage-web)
- .gitignore: 追踪 AGENTS.md 与 .pi 配置,忽略运行时缓存(todos/taskflows-runs/tokenomy/sessions)
52 lines
1.2 KiB
JSON
52 lines
1.2 KiB
JSON
{
|
|
"_comment": "Generic agent hook configuration. Environment variable AGENT_PROJECT_DIR should be set by the host agent to the project root. If unavailable, hooks fall back to pwd.",
|
|
"hooks": {
|
|
"SessionStart": [
|
|
{
|
|
"hooks": [
|
|
{
|
|
"type": "command",
|
|
"command": "bash \"${AGENT_PROJECT_DIR}/.agents/hooks/session-start.sh\"",
|
|
"timeout": 10000
|
|
}
|
|
]
|
|
}
|
|
],
|
|
"PreToolUse": [
|
|
{
|
|
"matcher": "Write|Edit",
|
|
"hooks": [
|
|
{
|
|
"type": "command",
|
|
"command": "bash \"${AGENT_PROJECT_DIR}/.agents/hooks/pre-agent-check.sh\"",
|
|
"timeout": 3000
|
|
}
|
|
]
|
|
}
|
|
],
|
|
"PostToolUse": [
|
|
{
|
|
"matcher": "Write|Edit",
|
|
"hooks": [
|
|
{
|
|
"type": "command",
|
|
"command": "bash \"${AGENT_PROJECT_DIR}/.agents/hooks/check-completeness.sh\"",
|
|
"timeout": 5000
|
|
}
|
|
]
|
|
}
|
|
],
|
|
"Stop": [
|
|
{
|
|
"hooks": [
|
|
{
|
|
"type": "command",
|
|
"command": "bash \"${AGENT_PROJECT_DIR}/.agents/hooks/stop-check.sh\"",
|
|
"timeout": 30000
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}
|
|
}
|