微算力 · API 导航与自营网关
API 接入 EN
未登录登录
🛡️

失败时强制执行,尊严调试不摆烂

pua-debugging-pro · v1.0.0
效率 安全 A 级 作者 doraemon-claw 公开目录收录
1.2k 下载 1 安装 6.2k 收藏 11 浏览

简介

专业级代码调试协议,防止AI在失败时放弃、循环或甩锅,强制证据优先和结构化诊断,同时保持尊重沟通。

原始描述

Professional anti-giveup debugging protocol for coding tasks where the agent starts looping, deflecting to users, or trying to end early without evidence. Us...

通过你的 Agent 添加

点「快速安装」复制一段指令,粘给你正在用的 Agent(Claude Code、Codex、OpenClaw 等),它会自己完成安装。

或者手动安装

Claude Codeunzip -o skill.zip -d ~/.claude/skills/pua-debugging-pro/
其它 Agent解压到它自己的 skills 目录,目录名用 pua-debugging-pro

包里是 SKILL.md 加作者附带的文件,解压后目录名就是技能名。 技能申请的权限由作者决定,装之前请确认它能读什么、能执行什么。

中文使用说明 来自收录源

核心用法

PUA Debugging Pro 是一套用于提升 AI 代理在编码任务中失败时执行质量的调试协议,核心目标是防止"放弃行为"(giveup behavior)——包括无限循环、过早向用户求助、未验证即声明完成等低效能模式。

触发条件:同一目标失败 2 次以上、重复微调无新信息、未工具诊断即甩锅给用户、未经验证的环境归因、无测试即声称完成、表层修复后未做影响扫描。

三级升级阶梯:

  • L1(2次失败):切换实质性不同假设,记录失败、变更、观察信号
  • L2(3次失败):强制产出诊断包(完整错误文本、上下文代码、外部文档查询、假设反转测试)
  • L3(4次+失败):执行7点检查清单,产出结构化决策

7点检查清单:捕获精确错误、读取相关源码、验证运行时前提、尝试 materially different 方案、定义明确通过/失败标准、运行验证并记录结果、扫描相邻风险。

显著优点

  1. 系统性防放弃机制:通过强制升级阶梯和检查清单,阻断常见的"软放弃"路径
  2. 证据优先原则:工具先行,减少向用户的无效提问
  3. 尊严沟通:明确禁止羞辱性、威胁性语言,保持专业工程语境
  4. 结构化产出:Current hypothesis/Actions/Observed evidence/Next step 的标准格式确保可追溯性
  5. 明确停止条件:完成7点清单+无新诊断信号+依赖缺失外部要素时,可专业收尾而非无限纠缠

潜在缺点/局限性

  1. 认知开销:7点清单和三级阶梯对简单问题可能过度
  2. 上下文消耗:强制读取相关源码/配置在超长代码库中可能迅速耗尽token
  3. 外部依赖瓶颈:L3后若需外部secret/access,仍可能被迫停止
  4. 无自动工具绑定:协议本身不保证工具可用性,依赖执行环境
  5. "实质性不同"难以界定:L1的切换要求较主观

适合人群

  • AI代理开发者希望减少模型"躺平"行为
  • 复杂代码库调试场景(基础设施、遗留系统)
  • 需要可审计调试过程的企业环境
  • 对AI沟通语气有专业要求的场景

常规风险

  • 延迟响应:严格升级阶梯可能延长单次请求处理时间
  • 过度自信:结构化框架可能让AI忽视"此路不通"的直觉
  • 格式僵化:严格输出合同可能降低灵活性

技能正文


name: pua-debugging-pro description: Professional anti-giveup debugging protocol for coding tasks where the agent starts looping, deflecting to users, or trying to end early without evidence. Use when there are repeated failures, weak root-cause analysis, missing verification, vague environment blame, or low-agency behavior. Enforces evidence-first debugging, bounded escalation, structured stop conditions, and dignified communication without humiliation language.

PUA Debugging Pro (Dignified Edition)

Use this protocol to increase execution quality under failure, while preserving professional tone.

Non-negotiables

  1. No premature surrender

    • Do not conclude "cannot solve" before completing escalation checklist.
  2. Evidence before questions

    • Use available tools first.
    • If user input is still required, ask with concrete evidence and narrowed uncertainty.
  3. Verification before completion

    • No "done" claims without explicit validation output.
  4. Dignified communication

    • Never use humiliation or threatening rhetoric.
    • Use calm, direct, engineering language.

Trigger signals

Activate when one or more are present:

  • 2+ failed attempts on same objective
  • Repeated micro-tweaks with no new information
  • Deflection to user without prior tool-based diagnosis
  • Unverified environment blame (permissions/network/version)
  • Completion claim without tests/checks
  • Stopping at surface fix with no impact scan

Escalation ladder (bounded)

L1 (after 2 failed attempts)

  • Switch to a substantially different hypothesis.
  • Record: what failed, what changed, what signal to watch.

L2 (after 3 failed attempts)

  • Mandatory triage pack:
    • full error text
    • relevant context window (code/log around failure)
    • one external lookup or doc check
    • one assumption inversion test

L3 (after 4+ failed attempts)

  • Run full 7-point checklist (below).
  • Produce structured decision: continue / pivot / stop.

7-point checklist

  • Captured exact error/output
  • Read relevant source/config context
  • Verified runtime prerequisites (version/path/permission/dependency)
  • Tried a materially different approach
  • Defined clear pass/fail criteria for latest attempt
  • Ran validation (test/command/request) and recorded result
  • Scanned adjacent risk (same pattern in nearby code/config)

Output contract

When progressing:

  • Current hypothesis
  • Actions executed
  • Observed evidence
  • Next step

When blocked after L3:

  • Facts established
  • Options eliminated
  • Smallest unresolved uncertainty
  • Recommended next action with cost/risk

For reusable output format, read:

  • references/checklist-template.md

For one-page handoff/retrospective artifact, use:

  • assets/postmortem-onepager.md

Stop conditions (required)

If all conditions are true, stop trying and escalate to user:

  1. 7-point checklist completed
  2. Last attempt produced no new diagnostic signal
  3. Further attempts require missing external secret/access/business decision

Use this closing format:

  • "I completed bounded escalation and cannot safely proceed without X."
  • "Evidence gathered: ..."
  • "Recommended next action: ..."

Style rules

  • Prefer concise, factual updates over motivational talk.
  • Be direct; avoid apology loops.
  • Keep tone firm, respectful, and professional.

正文来自原始发布页, 版权归作者所有,许可未标注。 权利人认为有不妥,可申请下架。

标签

debuggingagent-behaviorcode-qualitysystematic-troubleshootingprofessional-protocol

同类 Skill