Skip to content

jnMetaCode/superpowers-zh / skills/writing-skills

writing-skills

Verified

当创建新技能、编辑现有技能或在部署前验证技能是否有效时使用

references/bulletproofing.md

View on GitHub
## 让技能经受住合理化的考验

执行纪律的技能(如 TDD)需要抵抗合理化。智能体很聪明,在压力下会找到漏洞。

**心理学说明:** 理解说服技巧为什么有效有助于你系统性地应用它们。参见 [persuasion-principles.md](../persuasion-principles.md) 了解研究基础(Cialdini, 2021; Meincke et al., 2025),涵盖权威、承诺、稀缺、社会认同和归属原则。

### 明确堵住每个漏洞

不要只是陈述规则——禁止具体的变通方法:

<Bad>
```markdown
先写代码再写测试?删掉它。
```
</Bad>

<Good>
```markdown
先写代码再写测试?删掉它。重新开始。

**无例外:**
- 不要保留作为"参考"
- 不要在写测试时"调整"它
- 不要看它
- 删除就是删除
```
</Good>

### 应对"精神 vs 字面"的辩论

在前面加入基础原则:

```markdown
**违反规则的字面意思就是违反规则的精神。**
```

这切断了整类"我遵循的是精神"的合理化借口。

### 构建合理化借口表

从基线测试中捕获合理化借口(参见下方测试章节)。智能体使用的每个借口都进入表中:

```markdown
| 借口 | 现实 |
|------|------|
| "太简单不值得测试" | 简单的代码也会出错。测试只需 30 秒。 |
| "我后面再测试" | 测试立即通过什么也证明不了。 |
| "后写测试效果一样" | 后写测试 = "这做了什么?" 先写测试 = "这应该做什么?" |
```

### 创建红线列表

让智能体容易自查是否在合理化:

```markdown
## 红线 - 停下来重新开始

- 先写代码再写测试
- "我已经手动测试过了"
- "后写测试效果一样"
- "重要的是精神不是仪式"
- "这个情况不同,因为……"

**以上所有都意味着:删除代码。用 TDD 重新开始。**
```

### 更新 SDO 以包含违规症状

在描述中添加:你即将违反规则时的症状:

```yaml
description: use when implementing any feature or bugfix, before writing implementation code
```

reverse-engineer-anythingmorluto/reaReverse engineer native, managed, Electron/JavaScript, packaged, firmware, and browser targets with REA, and build agent environments (AgentEnv bundles) of web applications from a live instance or a capture, and of Linux desktop apps with a task from a request. Use shipped-artifact or requested runtime evidence to explain features, compare versions, decompile code, or guide a reconstruction. Skip REA for ordinary source-repository architecture analysis.Stars: 472kUpdated Claude CodeCodexVerifiedInstall
diagnosing-superpowersobra/superpowersUse when a superpowers session went wrong and your human partner wants to know why — repeated work, ignored plans, stumbles, poor results, a skill that didn't fire, "it took too long", "why is it so expensive", "what is it doing" — or wants to build a bug report for the superpowers maintainers, for the current session or a past one identified by id or path, on any harness.Stars: 322kUpdated Claude CodeCodexVerifiedInstall
dispatching-parallel-agentsobra/superpowersUse when facing 2+ independent tasks that can be worked on without shared state or sequential dependenciesStars: 322kUpdated Claude CodeCodexVerifiedInstall
executing-plansobra/superpowersUse when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is availableStars: 322kUpdated Claude CodeCodexVerifiedInstall