Token导航 LogoToken导航

Agent Skill · 研究检索

circuit-breaker(断路器)

circuit-breaker 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

circuit-breaker 是研究检索类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为需要联网;许可证信息还不明确,第三方扫描已通过,按安装量在研究检索类的 73,675 个 Skill 里排第 46,747。

总安装 766周安装 31GitHub Stars 1下载 241核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
unknown

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:circuit-breaker(断路器)
来源仓库:https://github.com/pixel-process-ug/superkit-agents
仓库路径:skills/circuit-breaker
安装命令:
npx skills add https://github.com/pixel-process-ug/superkit-agents --skill circuit-breaker
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/pixel-process-ug/superkit-agents --skill circuit-breaker

这个 Skill 是做什么的

研究检索类 Skill 主要解决「找资料、核对事实、把来源整理清楚」的问题,通常会让助手先检索再总结。

circuit-breaker 用于查找、检索和筛选相关信息,适合快速定位候选结果。适用于需要根据关键词或任务场景从来源线索中筛选信息的场景。通过 npx skills add 命令从指定 GitHub 仓库安装并使用该技能。安装前需确认权限范围和维护状态,注意可能触发联网或文件读写操作。

适用宿主包括 Codex、Claude、Cursor、Gemini CLI,接入前应确认版本、权限和运行环境要求。

来源仓库内路径:skills/circuit-breaker

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/pixel-process-ug/superkit-agents --skill circu…;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要需要联网,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

circuit-breaker 怎么安装?

在终端执行 npx skills add https://github.com/pixel-process-ug/superkit-agents --skill circuit-breaker。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

circuit-breaker 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

circuit-breaker 需要什么权限?

权限级别是需要联网。该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

circuit-breaker 是免费的吗?

公开资料没有标注明确许可证,收费和商用限制都无法确认。正式使用前请到来源仓库核对授权说明。

circuit-breaker 用的人多吗?

公开数据是累计安装 766 次,近一周安装 31 次,下载 241 次,GitHub 1 星。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

circuit-breaker 安全吗?

第三方扫描结果为通过,但这只覆盖已知的静态检查项,不能替代自己读一遍源码和安装命令。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。
  • 第三方扫描已通过,常见的高风险行为没有命中。

先想清楚的地方

  • 许可证没有明确标注,能不能商用、能不能再分发都不确定。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理研究检索类任务、又不想每次都手写提示词的人。

不太适合

  • 需要明确授权才能用到公司项目里的场景。
  • 需要厂商级技术支持和 SLA 的生产系统。

研究检索类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
find-skills

寻找技能 · Codex、Claude

31,199,81316,486操作浏览器MIT有提醒
self-improving-agent

自我改进 Agent · OpenClaw

16,464,0023,396接触敏感数据MIT-0通过
soultrace

灵魂追踪 · Codex、Claude

7,588,94412需要联网未明确有提醒
self-improving

自我完善 · OpenClaw

6,829,2841,046需要联网MIT-0通过
microsoft-foundry

微软代工厂 · Codex、Claude

6,614,144764调用外部服务未明确有提醒
circuit-breaker

断路器 · 本页

7661需要联网未明确通过

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

Overview

The circuit-breaker skill is a safety mechanism that prevents infinite loops, resource exhaustion, and accidental destruction during autonomous development. It operates at the loop level (complementing resilient-execution which operates at the task level). Without circuit-breaker protection, autonomous loops can waste hours on stagnant problems, exhaust API limits, or accidentally destroy configuration files. This skill enforces hard boundaries that keep autonomous operations productive and safe.

Announce at start: "Circuit breaker is active — monitoring for stagnation, rate limits, and file protection."


Phase 1: Circuit State Check

Before each loop iteration, check the current circuit state:

+-----------+     threshold     +-----------+     cooldown     +------------+
|  CLOSED   |----exceeded----->|   OPEN    |----elapsed------>| HALF-OPEN  |
|  (normal) |                  |  (halted) |                  |  (probe)   |
+-----------+                  +-----------+                  +-----+------+
     ^                                                              |
     |                          success                             |
     +--------------------------------------------------------------+
     |                          failure                             |
     |                    +-----------+                              |
     +--------------------+   OPEN    |<----------------------------+
                          +-----------+
StateMeaningAction
CLOSEDNormal operationExecute iteration, monitor all thresholds
OPENHalted due to threshold breachReport status, wait for cooldown, or escalate
HALF-OPENProbing after cooldownAllow ONE iteration. If success: close. If failure: re-open.
STOP: Check circuit state BEFORE executing any loop iteration. Do NOT execute if circuit is OPEN.

Phase 2: Stagnation Detection

Monitor these thresholds continuously during autonomous operation:

ConditionThresholdDetection MethodAction
No progress3 consecutive loops with zero meaningful changesTrack files modified + tasks completed per loopOPEN circuit
Identical errors5 consecutive loops producing the same errorCompare error messages across iterationsOPEN circuit
Output decline70% decline in output volume across iterationsCompare output line count across last 3 iterationsOPEN circuit
Permission denials3 consecutive tool permission failuresTrack permission errorsOPEN circuit
Test fix loop>80% of effort spent on test fixes onlyTrack work type per iterationOPEN circuit, investigate root cause
Circular approachSame 2-3 approaches alternating without resolutionTrack approach historyOPEN circuit

Stagnation Scoring

Each iteration, compute a progress score:

IndicatorScore
New test passing that was previously failing+3
Task marked complete+5
File modified with meaningful changes+1
Build/lint error resolved+2
Same error as previous iteration-2
No files modified-3
Reverted previous changes-1

Threshold: If cumulative score across 3 iterations is negative, OPEN the circuit.

STOP: If any threshold is breached, OPEN the circuit immediately. Do NOT attempt "one more try."

Phase 3: Recovery Protocol

When the circuit opens, follow this recovery sequence:

Cooldown Period

  • Default: 30 minutes before retry
  • Purpose: Prevents rapid cycling through the same failing state
  • After cooldown: Circuit enters HALF-OPEN state

HALF-OPEN Behavior

  1. Allow exactly ONE iteration to execute
  2. If successful (positive progress score): Close circuit, resume normal operation
  3. If failed (same stagnation pattern): Re-open circuit, double the cooldown timer

Recovery Strategy Decision Table

Stagnation TypeStrategy 1Strategy 2Strategy 3Strategy 4
No progress (stuck on same task)Regenerate plan with fresh analysisBreak stuck task into 3+ subtasksSkip to next task, return laterEscalate to user
Identical errors (same error repeating)Change approach entirelyCheck if error is environmentalSearch for known issue/workaroundEscalate with error log
Test fix loop (tests keep breaking)Review test assumptionsCheck if implementation approach is flawedSimplify implementation scopeEscalate with test analysis
Circular approach (alternating same fixes)Step back and re-analyze root causeTry approach NOT yet attemptedReduce scope to minimal working versionEscalate with approach history
STOP: After recovery, monitor the next 3 iterations closely. If stagnation recurs, escalate immediately.

Phase 4: Rate Limiting

Track and enforce API usage limits:

ParameterDefaultPurpose
MAX_CALLS_PER_HOUR100Prevents API overuse
Reset windowHourly (rolling)Automatic counter reset
Countdown displayActiveShows remaining calls before limit

Rate Limit Behavior

  1. Track API calls per rolling hour
  2. At 80% of limit: display warning, prioritize remaining calls
  3. At 100% of limit: pause execution, display countdown to reset
  4. Never exceed limit — wait for reset window

Three-Layer Timeout Detection

For long-running operations (especially API calls with extended limits):

LayerDetectionFallback
1. Timeout guardExit code 124 or timeout signalCapture partial output, log what completed
2. JSON validationParse response structureAttempt text extraction from raw response
3. Text fallbackRaw output captureLog everything, report for human review

Phase 5: File Protection

Protected Paths

PathTypeWhy Protected
.ralph/DirectoryLoop state and configuration
.ralphrcFileRalph configuration
IMPLEMENTATION_PLAN.mdFileCurrent plan — source of truth for loop
AGENTS.mdFileAgent definitions
specs/DirectorySpecifications — source of truth for features
.claude/DirectoryClaude Code configuration
CLAUDE.mdFileAgent operating manual
memory/DirectoryPersisted learnings across sessions

Protection Mechanisms

MechanismHow It WorksWhen It Triggers
Allowlist enforcementOnly permitted tools can modify protected filesBefore any file write to protected path
Integrity validationCheck protected files exist after each iterationEnd of every loop iteration
Pre-operation checksVerify protected files before destructive operationsBefore rm, git clean, git checkout.
Restricted commandsBlock git clean, git rm on protected paths, rm -rf on config dirsWhen command targets protected path

Pre-Destructive Operation Checklist

Before any rm, git clean, or git checkout.:

  1. List all files that will be affected
  2. Check each against the protected paths list
  3. If ANY protected file would be affected: ABORT and report
  4. If safe: proceed with caution
  5. After operation: verify all protected files still exist
STOP: If a protected file is missing after any operation, halt immediately and restore it.

Phase 6: Monitoring and Metrics

Track these metrics across loop iterations:

MetricPurposeAlert Threshold
Loop countTotal iterations executed>20 for a single task
Tasks completedProgress measurement0 for 3+ iterations
Files modifiedChange velocity0 for 3+ iterations
Test pass rateQuality trendDeclining for 3+ iterations
Error frequencyStagnation early warningIncreasing for 3+ iterations
Output volumeProductivity trend70% decline
API calls remainingRate limit proximity<20% remaining
Progress scoreOverall healthNegative for 3 iterations

Per-Iteration Status Log

## Iteration [N] — [timestamp]
- Circuit state: CLOSED / HALF-OPEN
- Tasks completed: [N]
- Files modified: [list]
- Tests: [X passed, Y failed, Z skipped]
- Errors encountered: [list]
- Progress score: [+/- N]
- API calls remaining: [N]
- Stagnation risk: LOW / MEDIUM / HIGH

Anti-Patterns / Common Mistakes

What NOT to DoWhy It FailsWhat to Do Instead
Ignore stagnation signalsWastes hours on unsolvable problemsOpen circuit at threshold breach
Manually override open circuitBypasses safety mechanismFollow recovery protocol properly
Skip file protection checksConfig deletion derails entire projectAlways verify protected files after operations
Set cooldown to zeroRapid cycling through same failureRespect 30-minute minimum cooldown
Count test-fix-only iterations as progressMasks the real problem (flawed approach)Flag >80% test-fix effort as stagnation
Delete and recreate protected filesLoses configuration stateNever delete protected files, only update
Ignore rate limit warningsHits hard limit mid-operationPrioritize when at 80% of limit
Run destructive commands without pre-checksMay delete protected filesAlways check affected files first

Anti-Rationalization Guards

ThoughtReality
"One more try will fix it"That is what you said 3 iterations ago. Open the circuit.
"The error is almost fixed""Almost" for 5 iterations means the approach is wrong.
"I cannot stop now, I am so close"Sunk cost fallacy. Open circuit, reassess.
"The cooldown is too long"The cooldown prevents wasting more time on the same failure.
"These config files are not important"They are protected for a reason. Do not delete them.
"The rate limit will not be hit"Track it. Do not guess.
"This is a different error"Check if it is truly different or the same root cause manifesting differently.
Do NOT override an open circuit. Follow the recovery protocol.

Integration Points

SkillRelationship
resilient-executionTask-level retries (3 attempts). Circuit-breaker activates AFTER resilient-execution exhausts retries within individual tasks.
autonomous-loopCircuit-breaker monitors the loop. Opens circuit when loop-level stagnation detected.
ralph-statusStatus block provides metrics for stagnation detection.
verification-before-completionCircuit-breaker ensures verification passes before closing a loop.
self-learningStagnation patterns are persisted to memory for future avoidance.
auto-improvementCircuit-breaker events feed into improvement metrics.

Scope Clarification

ScopeSkillBehavior
Task-levelresilient-executionTry 3 approaches for a single failing task
Loop-levelcircuit-breakerHalt the entire loop when patterns indicate systemic failure

The circuit breaker activates AFTER resilient-execution has exhausted its retries within individual tasks. If tasks keep failing despite 3 retries each, the circuit breaker detects the pattern.


Process Summary

  1. Before each loop iteration: Check circuit state (CLOSED/HALF-OPEN/OPEN)
  2. If OPEN: Report status, wait for cooldown, or escalate
  3. If HALF-OPEN: Allow one probe iteration, evaluate result
  4. If CLOSED: Execute normally, monitor all thresholds
  5. After each iteration: Update metrics, compute progress score, evaluate thresholds
  6. If threshold exceeded: Open circuit, report reason, begin cooldown
  7. After cooldown: Enter HALF-OPEN, allow one probe
  8. After probe: Close if successful, re-open with doubled cooldown if failed

Skill Type

RIGID — Thresholds and protection rules must be followed exactly. Do not relax circuit breaker conditions. Do not override open circuits. Do not skip file protection checks. Do not ignore stagnation signals.

平台分布

Codex

34.11%
按下载量换算82

Claude

30.33%
按下载量换算73

Cursor

17.62%
按下载量换算42

Gemini CLI

8.1%
按下载量换算20

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

需要联网

该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills