simplify-existing-code
Skill4 starsChanged 2 months agoApache-2.0View on GitHub
Simplify a requested code path by deleting unnecessary work, reusing existing behavior, or reducing caller complexity. Use explicitly for cleanup; not permission to weaken contracts, checks, or requested features.
In this repository81 other files it gives its agents.
- agent-cli-designSkill
- agent-tool-boundariesSkill
- behavior-first-implementationSkill
- bounded-prototypeSkill
- bounded-pr-sliceSkill
- building-fdd-validationSkill
- context-efficiencySkill
- cross-language-contractsSkill
- cross-platform-agent-instructionsSkill
- design-interviewSkill
- diagnosis-loopSkill
- domain-languageSkill
- edge-cloud-syncSkill
- handoff-continuitySkill
- immutable-pr-reviewSkill
- memory-context-hygieneSkill
- module-designSkill
- orchestrateSkill
- owner-decision-gateSkill
- parallel-portfolioSkill
- pr-gate-loopSkill
- pyo3-async-lifecycleSkill
- pyo3-buffer-performanceSkill
- pyo3-free-threadingSkill
- pyo3-ownership-errorsSkill
- pyo3-wheel-releaseSkill
- python-api-typingSkill
- python-async-concurrencySkill
- python-ci-releaseSkill
- python-data-boundariesSkill
- python-packaging-environmentsSkill
- python-performanceSkill
- python-pytestSkill
- python-reviewSkill
- python-test-designSkill
- python-threading-workersSkill
- python-workflowSkill
- react-components-stateSkill
- react-performanceSkill
- repository-groundingSkill
- rust-api-designSkill
- rust-async-concurrencySkill
- rust-build-diagnosticsSkill
- rust-ci-releaseSkill
- rust-memory-layoutSkill
- rust-nextestSkill
- rust-numerics-simdSkill
- rust-performanceSkill
- rust-protocol-codecsSkill
- rust-python-bindingsSkill
- rust-reviewSkill
- rust-storage-durabilitySkill
- rust-test-designSkill
- rust-unsafe-ffiSkill
- rust-workflowSkill
- rust-workspace-dependenciesSkill
- shadcn-react-componentsSkill
- shadcn-svelte-componentsSkill
- source-verificationSkill
- svelte-components-runesSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
3 rules. About 0 are common, 3 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈3
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 19
Keep input validation, authentication, authorization, data-loss prevention, resource bounds, accessibility, and required error handling.
- Distinctive: line 21
Avoid incidental API redesign, broad formatting churn, clever compression, and permanent “simplification modes.” For a diagnosis-only …
- Distinctive: line 25
Use the existing test framework and meaningful behavioral checks.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Simplify Existing Code
Make the requested behavior easier to own without making it less correct. Simplicity is reduced coordination and maintenance cost—not the shortest line, smallest test count, or fewest files at any price.
Understand before removing
Read the actual path, callers, tests, and user goal. Identify what each layer or dependency does today, including failures and cleanup. Separate dead or speculative behavior from requirements that look inconvenient. A one-implementation abstraction may still enforce a useful boundary; judge its purpose, not its count.
First ask whether redundant work can disappear. Then consider an existing helper, language/runtime facility, native platform behavior, or installed dependency that meets the same contract. Adding a small correct local implementation can be simpler than forcing an ill-fitting package; using a mature existing dependency can be simpler than maintaining a risky reinvention. Explain only consequential tradeoffs.
Preserve the important costs and guarantees
Keep input validation, authentication, authorization, data-loss prevention, resource bounds, accessibility, and required error handling. Do not replace a cancellable or bounded operation with an unbounded convenience call. In protocols, storage, and bindings, preserve timing, durability, ownership, and error semantics.
Avoid incidental API redesign, broad formatting churn, clever compression, and permanent “simplification modes.” For a diagnosis-only request, propose the change without applying it. For authorized cleanup, make the smallest coherent change that removes a real source of complexity.
Prove the same behavior still works
Use the existing test framework and meaningful behavioral checks. Do not impose a one-test ceiling, delete fixtures for aesthetic reasons, or replace a suite with a self-check. Add a targeted regression for an uncovered contract when needed.
Compare public results and failure paths before and after. Measure performance only when it is part of the goal; fewer lines do not prove lower latency or less memory. Report removed responsibility, preserved behavior, actual checks, and any remaining tradeoff.
This is an explicit task, not an always-on hook or authority to challenge settled user requirements repeatedly.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

