usage and rules
Karen is a standalone compatibility guard. Everything the agent sees comes from one file, skills/karen/SKILL.md.
levels and commands
Starts off so it never hijacks a session. Toggle a level for the current session or save a default.
| command | what it does |
|---|---|
| /karen | Enable full (or show status if already active) |
| /karen mild | Build as asked; report bystander regressions in a note |
| /karen full | Check 1-2 highest-risk bystanders and fix verified breaks |
| /karen hoa | Inspect all direct callers up front; require executed checks |
| /karen off | Disable Karen and clear its prompt section |
| /karen-review | One-shot compatibility review of the current diff (no edits) |
| /karen default <mode> | Save default startup mode in ~/.config/karen/config.json |
| stop karen | Standalone user message that turns Karen off |
| env variable | effect |
|---|---|
| KAREN_DEFAULT_MODE | Override startup mode (mild, full, hoa, off) |
| KAREN_HIDE_STATUS | Set 1 to hide Pi status badge while rules stay active |
| KAREN_QUIET_STARTUP | Set 1 to suppress startup notifications |
# Claude Code / Codex / Agent Skills
# Point at skills/karen/SKILL.md
/karen <task> # guard while working
/karen # review diff, no edits standalone, or beside other skills
Karen needs no companion skill. If you also run another skill such as Ponytail, both keep separate prompt sections and merge into one closing footer.
---
name: karen
description: >
Compatibility guard for AI coding agents: preserve supported behavior outside
the requested change. Use when making risky changes, checking a diff for
collateral regressions, or when the user says "karen", "check bystanders",
"compatibility check", or "don't break callers". With a task, guards the
change as you work. Without a task (or on a diff), reviews without editing.
Levels: mild, full (default when active), hoa.
argument-hint: "[mild|full|hoa|off|review|status|<task>]"
license: MIT
---
# Karen
Preserve supported behavior outside the requested change.
The requested case now works. Which supported case that nobody asked to change got worse?
- **With a task:** apply these rules while completing the task.
- **Without a task (or when asked to review a diff):** review the uncommitted changes (or the last commit if the tree is clean) without editing files.
Active for the session until you run `/karen off` or send `stop karen`. Switch level with `/karen mild|full|hoa`.
## Rules
1. **Scope to the highest-risk bystanders.** Identify the intended behavior change and 1-2 highest-risk, directly reachable supported uses that must remain unchanged (defaults, valid inputs, state preservation, error semantics, callers). Expand inspection only when concrete evidence exposes another affected path or the user asks for broader scope. Do not run a repo-wide audit by default.
2. **Require a contract receipt.** Assert a compatibility regression only when you can name an affected user or caller, a material impact, and a receipt: a requirement, doc, type signature, test, or demonstrated supported use. Old behavior alone does not protect a known bug or exploit; exclude explicitly authorized behavior changes.
3. **Prove it or drop it.** Give every finding a concrete input and expected versus observed (or directly code-traced) behavior, backed by a test, reproduction, or direct trace. Distinguish executed checks from static reasoning and unrun tests. Never publish hypothetical complaint lists or claim an unrun check passed.
4. **Pick the smallest contract-preserving fix.** Choose the smallest change that satisfies both the requested behavior and supported retained behavior. Judge adapters, retries, casts, and fallbacks by whether they preserve the contract, not by their syntax; do not hide a contract failure at a call site.
5. **Ownership is not authorization.** Task-bounded fixes in the owning layer are allowed. Unrequested public-contract changes, migrations, and broad refactors require user approval. Ask about ambiguity only when it changes the safe implementation.
6. **Protect real safeguards.** Never weaken required security, safety, validation, or accessibility for compatibility. Report defects in those guarantees and unnecessary collateral damage; necessary friction is not a defect. Formatting taste is not a finding.
7. **Reuse checks.** Reuse the task's tests and verification. Add only the smallest missing coverage for risky requested and retained behavior. Do not duplicate test suites or build a harness solely for this skill. Review-only requests authorize no edits.
8. **Report cleanly and stop at zero.** Report only actionable, evidenced findings; zero findings is a valid outcome. End completed coding or review tasks with one line:
`Impact: <retained behavior checked + evidence>; unchecked/risk: <specific gap>.`
When another active skill already requires a closing summary line, merge into one footer instead of printing two.
## Levels
| Level | Behavior |
|-------|----------|
| **mild** | Report only. Build what was asked, then list receipt-backed bystander regressions in a short note and let the user decide whether to fix them. |
| **full** | The rules above. Default when active: check 1-2 highest-risk bystanders and fix verified regressions with the smallest contract-preserving patch. |
| **hoa** | Strict enforcement. Inspect all directly reachable callers and documented contracts before editing, push back if the request shifts avoidable friction onto unaffected users, require executed checks (test or repro) instead of static traces for retained behavior, and refuse to sign off on a contract violation without explicit user approval. |