agent-health
Reads production/traces/agent-metrics.jsonl and displays a per-agent performance summary table for the current or a specified session. Highlights agents with…
Simplifies working code while preserving exact behavior. Use after tests pass, during review feedback, or when code is harder to read, maintain, or verify than it needs to be without changing product behavior.
$ npx -y skills add tranhieutt/software_development_department --skill code-simplification --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/code-simplificationContext preview
The summary Claude sees to decide when to auto-load this skill.
Simplifies working code while preserving exact behavior. Use after tests pass, during review feedback, or when code is harder to read, maintain, or verify than it needs to be without changing product behavior.
name: code-simplification type: workflow description: "Simplifies working code while preserving exact behavior. Use after tests pass, during review feedback, or when code is harder to read, maintain, or verify than it needs to be without changing product behavior." argument-hint: "[path-or-review-finding]" user-invocable: true allowed-tools: Read, Glob, Grep, Bash context: fork effort: 3 agent: lead-programmer when_to_use: "Use for behavior-preserving cleanup after implementation is green, when review flags readability or complexity, or when the user asks to simplify/refactor without changing behavior."
`code-simplification` reduces code complexity while preserving exact behavior. It is not a feature workflow, not a bug fix workflow, and not permission for drive-by refactors.
The goal is code that is easier to read, review, test, and maintain with the smallest safe diff.
Same behavior. Less cognitive load. Fresh verification evidence.
Prefer simplifications that deepen modules instead of flattening behavior across callers. A small interface hiding real complexity is valuable; a wrapper that only moves complexity around is not.
Use this workflow when:
abstraction.
changing behavior.
repeated conditionals that make future changes risky.
Do not use this workflow when:
or `spec-evolution`.
Preferred placement:
test-driven-development -> code-simplification -> verification-before-completion
Review feedback placement:
code-review -> receiving-code-review -> code-simplification -> verification-before-completion
Technical-debt placement:
tech-debt identifies issue -> user approves focused cleanup -> code-simplification
If a simplification requires changing externally visible behavior, API shape, data model, error behavior, timing, permissions, or user flow, stop and route to `spec-evolution`.
Before editing, all must be true:
State the gate before edits:
Pre-code gate: Fast satisfied for behavior-preserving simplification of <scope>; verification: <command/check>.
For cleanup attached to an approved task:
Pre-code gate: Plan satisfied by approved Task N; simplification scope: <scope>; verification: <command/check>.
Read the smallest necessary context and answer:
If you cannot answer, do not simplify yet. Gather context or ask.
Only act on specific signals:
| Signal | Typical simplification | | --- | --- | | Deep nesting | Guard clauses or named predicates | | Long function with mixed responsibilities | Extract focused helper(s) | | Nested ternaries | Readable conditional or lookup | | Boolean flag parameters | Options object or separate functions when warranted | | Repeated conditionals | Named predicate | | Generic names | Names that describe domain meaning | | Duplicate logic | Shared helper, if it reduces real duplication | | Unused wrapper | Inline only if the wrapper has no semantic value | | Comments explaining obvious "what" | Remove or replace with clearer code |
Use the deletion test on wrappers, helpers, and extracted modules:
behavior, it is probably earning its keep.
complexity, it is probably shallow.
Prefer deeper modules with clearer seams over helper sprawl.
Keep comments that explain why, tradeoffs, gotchas, or external constraints.
For each simplification:
1. Make the smallest behavior-preserving edit. 2. Run the relevant verification if cheap and available. 3. If verification fails, revert or diagnose before continuing. 4. Stop when further cleanup would broaden scope.
Do not batch unrelated simplifications. Do not modernize adjacent code just because it is nearby.
Use the strongest available proof:
Before claiming completion, use `verification-before-completion`.
## Code Simplification: [Scope] **Target:** [files/functions/review finding] **Behavior contract:** [what must remain unchanged] **Changes made:** [short list] **Verification:** [commands/checks and key result] **Verdict:** VERIFIED | PARTIAL | NOT VERIFIED | FAILED **Limits:** [anything not checked]
| Thought | Required correction | | --- | --- | | "Shorter means simpler." | Simpler means easier t
Repo: tranhieutt/software_development_department
Reads production/traces/agent-metrics.jsonl and displays a per-agent performance summary table for the current or a specified session. Highlights agents with…
Provides the vendored agent-style v0.3.5 prose rule pack as a portable Claude skill. Use when installing, syncing, applying, or auditing SDD Agent-Style…
Provides Angular best practices for components, modules, services, and reactive patterns. Use when working with Angular TypeScript files, component templates,…
Records unexpected API behaviors, undocumented caveats, version bugs, or non-obvious workarounds into .claude/memory/annotations.md. Use immediately when an…
Defines REST and GraphQL API contracts including endpoints, request/response schemas, auth flows, and versioning strategy. Use when designing a new API,…
Manages the ADR (Architecture Decision Record) registry. Use when recording tech-stack choices, design patterns, or infrastructure decisions with context,…