agentic-abstention
Skill2 starsChanged 11 days agoMITView on GitHub
Encode CONVOLVE-style stopping rules: decide when to stop acting instead of continuing tool calls on an infeasible task. Use this skill whenever an agent must determine if further execution is warranted. Not for general task planning (use goap-agent).
In this repository63 other files it gives its agents.
- AGENTS.mdAGENTS.md
- .agents/skills/avoid-ai-writing/AGENTS.mdAGENTS.md
- .agents/skills/do-web-doc-resolver/AGENTS.mdAGENTS.md
- .agents/skills/skill-evaluator/AGENTS.mdAGENTS.md
- scripts/AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- llms-full.txtllms.txt
- llms.txtllms.txt
- accessibility-auditorSkill
- agent-browserSkill
- agents-mdSkill
- api-design-firstSkill
- architecture-diagramSkill
- avoid-ai-writingSkill
- cicd-pipelineSkill
- cloudflare-worker-apiSkill
- codacySkill
- codeberg-apiSkill
- code-review-assistantSkill
- css-render-performanceSkill
- database-devopsSkill
- debuggerSkill
- delegateSkill
- dependency-upgradesSkill
- dist-channel-selectionSkill
- docs-hookSkill
- document-rendering-and-locatorsSkill
- dogfoodSkill
- dora-reportSkill
- do-web-doc-resolverSkill
- durable-objectsSkill
- eu-ai-act-complianceSkill
- git-github-workflowSkill
- goap-agentSkill
- implementerSkill
- intent-classifierSkill
- iterative-refinementSkill
- jules-delegatorSkill
- learnSkill
- lifecycle-managementSkill
- local-context-sanitizationSkill
- memory-contextSkill
- migration-refactoringSkill
- nested-build-isolationSkill
- privacy-firstSkill
- progressive-deliverySkill
- pwa-offline-syncSkill
- reader-ui-uxSkill
- readme-best-practicesSkill
- secrets-managementSkill
- secure-invite-and-accessSkill
- security-code-auditorSkill
- shell-script-qualitySkill
- skill-creatorSkill
- skill-evaluatorSkill
- static-analysisSkill
- testing-strategySkill
- test-runnerSkill
- triz-solverSkill
- turso-dbSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
8 rules. About 0 are common, 6 are distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈6
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 66
When any rule fires, emit the following and halt:
- Distinctive: line 81
Halt: Do NOT retry the failed action
- Distinctive: line 85
Do not retry after a rule fires — the rule indicates futility
- Distinctive: line 86
Do not bypass rules by rephrasing the same tool call
- Distinctive: line 87
Do not ignore timeout because "almost done" — budget is absolute
- Distinctive: line 88
Do not treat a single empty result as Rule 1 — requires 2+ repetitions
- Very specific: line 101
Call 1: glob("missing.txt") → empty (no abstain)
- Very specific: line 102
Call 2: glob("missing.txt") → empty (Rule 1 fires: 2+ empty results)
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Agentic Abstention
Decide when to stop acting instead of continuing tool calls on an infeasible task.
When to Use This Skill
- Agent has made repeated tool calls with no progress
- Task appears blocked by environment constraints
- Resource errors indicate the goal is unreachable
- Agent must decide between retrying and emitting ABSTAIN
Core Stopping Rules (CONVOLVE-derived)
Any single rule triggers mandatory abstention. All thresholds reference
AGENTS.md named constants.
Rule 1: Empty-Result Repetition
Agent returns 2+ consecutive tool calls that yield identical empty or null results. A single empty result does NOT trigger abstention.
Check: result[N] == result[N-1] == empty (N ≥ 2)
Rule 2: Resource Unavailable
Target resource returns HTTP 404, connection refused, DNS resolution failure, or equivalent "does not exist" signal from the environment.
Check: Error code ∈ {404, 502, 503, ECONNREFUSED, ENOENT}
Rule 3: No-Progress Step Budget
Agent has taken ≥ DEFAULT_MAX_RETRIES (3) steps without measurable progress
toward the goal. Progress is measured by state change in the task output.
Check: steps_since_last_progress ≥ DEFAULT_MAX_RETRIES
Rule 4: Infeasibility Signal
External system, user, or tool explicitly states the task cannot be completed (e.g., "not supported", "does not exist", "permission denied", "cannot be done").
Check: Output contains explicit infeasibility keyword
Rule 5: Timeout Budget Exceeded
Elapsed wall-clock time since task start exceeds DEFAULT_TIMEOUT_SECONDS
(1800s). Agent must track start time at task initiation.
Check: now - task_start_time > DEFAULT_TIMEOUT_SECONDS
ABSTAIN Protocol
When any rule fires, emit the following and halt:
- Log: Record which rule triggered and relevant context
Emit: Return structured ABSTAIN response:
{ "action": "ABSTAIN", "rule": "<rule-name>", "reason": "<brief explanation>", "steps_taken": <int>, "elapsed_seconds": <int> }- Halt: Do NOT retry the failed action
What NOT to Do
- Do not retry after a rule fires — the rule indicates futility
- Do not bypass rules by rephrasing the same tool call
- Do not ignore timeout because "almost done" — budget is absolute
- Do not treat a single empty result as Rule 1 — requires 2+ repetitions
Integration with Existing AGENTS.md Constants
| Constant | Value | Applies to Rule |
DEFAULT_MAX_RETRIES | 3 | Rule 3 (No-Progress Step Budget) |
DEFAULT_TIMEOUT_SECONDS | 1800 | Rule 5 (Timeout Budget Exceeded) |
Example Usage
Scenario: Agent searches for a file 3 times, each returning empty.
- Call 1:
glob("missing.txt")→ empty (no abstain) - Call 2:
glob("missing.txt")→ empty (Rule 1 fires: 2+ empty results) - Action: Emit ABSTAIN with
rule: "empty-result-repetition"
Scenario: Agent calls API, receives 404.
- Call 1:
GET /api/v1/resource/999→ 404 - Action: Emit ABSTAIN with
rule: "resource-unavailable"
Rationalizations
| Rationalization | Reality |
| "One more try might work" | If a stopping rule fired, the evidence says it will not. Retrying wastes tokens. |
| "The timeout hasn't hit yet" | Rules are independent — timeout is one of five triggers, not the only one. |
| "I'll rephrase and try again" | Rephrasing the same infeasible request still wastes resources. Halt and report. |
Red Flags
- Continuing execution after any stopping rule fires
- Treating first empty result as a stopping condition (Rule 1 requires 2+)
- Ignoring explicit "cannot be completed" messages
- Skipping ABSTAIN emission and silently failing
References
- CONVOLVE stopping rules — origin of the 5-rule framework
AGENTS.mdnamed constants —DEFAULT_MAX_RETRIES,DEFAULT_TIMEOUT_SECONDS
See Also
goap-agent— Task decomposition and planningiterative-refinement— When to continue refining (opposite of abstention)
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

