self-regulation-brake-system
Brake system with pressure escalation — 1st-2nd failure triggers systematic-debugging, 3rd+ auto-stops on loops. Prevents token burning.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Brake system with pressure escalation — 1st-2nd failure triggers systematic-debugging, 3rd+ auto-stops on loops. Prevents token burning.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Social media account setup guide for AI/developer platforms. Agent prepares all content (bio, avatar, posts) for user to copy-paste, since automation is blocked by Cloudflare/CAPTCHA/React shadow DOM. Supports X/Twitter, Medium, Dev.to, Reddit, LinkedIn.
Fix missing .dylib libraries when brew upgrades break Node.js browser tooling — create symlinks from old version numbers to new.
Auto-detect environment and record terminal/GUI demos for GitHub repos. Supports VHS, asciinema+agg, svg-term, and cua-driver modes. Single-command orchestration layer.
Use when releasing a new open-source project or skill pack on GitHub. Follows the proven exposure playbook from Hermes Core Skills release — covering README, community health, topics, social media, and verification. Ensures every release meets a minimum exposure bar so the project is discoverable, trustworthy, and ready for adoption.
Multi-angle GitHub project discovery using browser + GitHub API + trending, with practical clone/install/absorption workflow
Use when installing any new tool/package from GitHub, Brew, or Cask — includes post-install verification script, automated health check cron, and deliverable report so the user can independently confirm the tool is in active daily use.
| name | self-regulation-brake-system |
| description | Brake system with pressure escalation — 1st-2nd failure triggers systematic-debugging, 3rd+ auto-stops on loops. Prevents token burning. |
| tags | ["self-regulation","brake","efficiency","feedback","timeout","pressure-escalation"] |
| triggers | ["brake","fail limit","stop retry","regulation"] |
Agent can burn thousands of tokens repeating the same failed action (GitHub login, OAuth, browser loops). The user only discovers this when they see the bill.
A lightweight shell script at ~/.hermes/scripts/brake.sh that:
Brake rules 已寫入 system instructions file,透過 config.yaml 嘅 prefill_messages_file 注入:
~/.hermes/system-instructions/self-regulation.mdAlready updated. Every new session shows brake status:
=== 🧠 SELF-REGULATION CONTEXT ===
⚠️ BRAKE SYSTEM IS ACTIVE
Injected as self-regulation rules. Ensures the agent knows about brakes even after context compaction.
Whenever the agent encounters a failing loop:
# Before retrying, check if brake is triggered
bash ~/.hermes/scripts/brake.sh check "github-login-by-browser"
# exit 0 = safe, count = N
# exit 2 = STOP, ask user
# After a failure
bash ~/.hermes/scripts/brake.sh record "github-login-by-browser"
# After success
bash ~/.hermes/scripts/brake.sh reset "github-login-by-browser"
| Condition | Action |
|---|---|
| 第 1 次失敗 | 正常 debug — 按 systematic-debugging skill 流程繼續 |
| 第 2 次失敗 | 🟡 壓力升級 L1 — 強制切換本質唔同嘅方案。用 brake.sh check 確認次數,然後用 brake.sh record 記錄。唔停,係轉方向! |
| 第 3 次失敗 | 🟠 壓力升級 L2 — 強制深度排查(搜 error、讀源碼、驗證假設)。完成前唔准向用戶問嘢 |
| 第 4 次失敗 | 🔴 壓力升級 L3 — 完成 7 項強制檢查清單 + 3 個全新假設。完成後先可以問用戶 |
| 第 5+ 次失敗 | ⚫ 壓力升級 L4 — 最後手段:最小 PoC + 隔離環境 + 完全唔同技術棧 |
| Same action fails ≥3 次但同一思路微調 | 唔係正常失敗 — 係「磨洋工」模式。第 2 次就強制切換,唔等到第 3 次 |
| 5 min of no progress | STOP → clarify user |
| Third-party auth (GitHub/Google/OAuth) | First failure → STOP, don't retry |
| Complex multi-step auth | Delegate to subagent first |
| 卡住咗唔出聲 | 違反 HARD RULE 2 — 失敗咗必須即刻報告,唔可以靜雞雞轉彎 |
做任何動作之前,先問「terminal 做唔做到」:
CUA 操作見到以下任何一個紅旗,即停 CUA,轉用 terminal/其他方法:
| 紅旗 | 原因 |
|---|---|
| 同一 CUA 操作失敗 2 次 | Pixel coord 唔準/AX tree 太複雜→唔會越試越準 |
| Accessibility tree > 500 elements | DevTools/Chrome/Electron 內部→AX tree 大得滯,無用 |
| Vision 座標 明顯唔合理 | 如話座標喺畫面範圍之外 |
| 畫面係 Canvas/WebGL 自繪 | CUA 睇唔到入面啲掣 |
CUA 只應該用喺以下場景:
❌ 失敗做法:
用 CUA pixel click 操作 DevTools 內部 UI(頁面路徑selector)
→ AX tree 971 elements,pixel coord 錯晒,失敗 5+ 次
→ 浪費大量 token,0 成果
✅ 正確做法:
改 code → terminal `bash boot.sh pre-commit` compile
→ 出錯直接改 code,唔使郁 DevTools 掣
因為 CUA 嘅 vision 同 AX tree 喺複雜 UI(DevTools、Electron app)入面非常唔可靠,而且每失敗一次就燒大量 token(screenshot + vision analysis + 再去試)。Terminal command 反而係 deterministic,成功失敗都 cheap 好多倍。
Session Start
├─ session-start.sh
│ └─ brake.sh status → context injection
│
Agent working
├─ action fails → brake.sh record
├─ before retry → brake.sh check
│ ├─ count < 3 → retry
│ └─ count ≥ 3 → BRAKE! → clarify user
│
Action succeeds → brake.sh reset
呢個 system 嘅關鍵唔係 script 本身,而係 注入層級:
點解 Agent 理論上可以「忽略」system instruction?
~/.hermes/scripts/brake.sh~/.hermes/state/brake/ (persists across sessions)~/.hermes/hooks/session-start.sh