绕路成径
Use this skill when the user points to an agent trace, fallback, missing tool, missing dependency, missing preflight, or temporary workaround and asks whether that detour should be turned into a durable capability.
The goal is not to package every failure as a new skill. The goal is to decide whether a repeated or high-value detour reveals a capability gap, then choose the smallest durable fix.
Trigger Examples
Use this skill when the user says things like:
- "It wanted to use X, but X was missing, so it used Y."
- "Should we install/configure this so future runs are smoother?"
- "Does this deserve a new skill?"
- "Turn this fallback into a reusable capability."
- "Audit this Codex / agent trace for capability gaps."
- "Why did it write a temporary script instead of using an existing tool?"
Do not use this skill for ordinary debugging unless the user is asking about reusable capability design behind the failure.
Read Order
Load only the references needed for the current task:
references/fallback-review.md: read when reconstructing what happened in an agent trace.references/hardening-forms.md: read when choosing between install, preflight, runtime detection, runbook, new skill, or skip.references/validation-signals.md: read when designing verification after a capability improvement.examples/pdf-poppler-case.md: read when a concrete example would help calibrate the decision.
Workflow
- Reconstruct the detour:
- What path did the agent originally try to use?
- What layer was missing: system tool, library, credential, preflight, runtime route, or local data?
- What fallback did it use instead?
- What did the fallback cost: time, quality, reliability, repeatability, or trace clarity?
- Judge repeatability:
- Has this happened before?
- If it happened once, is it likely to recur in a high-value workflow?
- Can the input pattern be detected by file type, command absence, error message, or task type?
- Check existing coverage:
- Is there already a nearby skill, runbook, runtime module, or tool adapter?
- Would a preflight check solve most of the problem?
- Is this only a local setup issue?
- Choose the smallest durable form:
install_tool: install or configure a missing system tool.skill_preflight: update the nearest skill to check prerequisites before work starts.runtime_detection: add code that detects available tools and records the chosen path.runbook_or_solution_note: document a reusable command, boundary, and decision rule.new_skill_candidate: consider a new skill only when no existing skill/runtime is close and the workflow is independently repeated.skip: leave it alone when it is one-off, low-value, unstable, or already covered.
- Design verification:
- Check tool presence with commands such as
which <tool>or<tool> --version. - Run a minimal real sample.
- Confirm the next trace records the preferred path or clearly explains the fallback reason.
- If files changed, run the relevant lint, test, or check for the current repository.
- Check tool presence with commands such as
Output Contract
Return a short decision report:
md## Capability Gap Decision - Decision: improve / skip / need more evidence - Form: install_tool / skill_preflight / runtime_detection / runbook_or_solution_note / new_skill_candidate / skip - Landing place: <existing skill, runtime module, docs, or environment> ## Observed Detour | Evidence | Intended path | Gap | Fallback | Impact | |---|---|---|---|---| ## Recommended Improvement 1. ... ## Verification Signals - ... ## Out of Scope - ...
Boundaries
- Do not install system packages, edit shell profiles, write credentials, or change global environment unless the user explicitly asks.
- Do not create a new skill just because one tool is missing.
- Do not treat a temporary worktree setup issue as a durable main-environment fact.
- Do not hide fallbacks. If the preferred path is unavailable, say why and name the actual path used.
- Do not upgrade every failure into capability work. The detour must be repeated or likely to affect a high-value workflow.


