051-design-two-steps-methods
Skill452 starsChanged 3 months agoApache-2.0View on GitHub
Use when a complex or risky code change should be split into Kent Beck's two-step method by first making the change easy through behavior-preserving preparatory refactoring, then making the intended behavior change once the design supports it. This should trigger for requests such as Apply two-step change; Make this risky change safer; Refactor before changing behavior; Separate preparation from behavior change. Part of Plinth Toolkit
We split this skill into the rules it gives an agent
6 rules. About 0 are common, 5 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈5
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 28
MUST: Keep Step 1 behavior-preserving.
- Distinctive: line 29
MUST: Verify existing behavior after Step 1 using the project-appropriate tests, build, characterization tests, or manual checks
- Distinctive: line 31
MUST: Verify the intended behavior after Step 2 with focused tests and relevant build checks
- Very specific: line 46
Read references/051-design-two-steps-methods.md, inspect the relevant code and tests, and state the exact behavior or capability that must …
- Distinctive: line 58
Run the relevant existing tests, build checks, characterization tests, or manual verification.
- Distinctive: line 66
Verify the intended behavior with targeted tests and relevant project validation.
≈ “Common” is an estimate: at least 1 in 5 of the 308,232 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
Two-Step Change Method
Guide Java developers through complex or risky changes by keeping design preparation separate from behavior modification. This is an interactive SKILL.
What is covered in this Skill?
- Clarifying the intended behavior change before editing
- Identifying design obstacles that make the change difficult or risky
- Step 1: behavior-preserving preparatory refactoring that makes the change easy
- Validation that Step 1 preserves existing behavior
- Step 2: the smallest intended behavior change after the design supports it
- Verification that Step 2 delivers the intended behavior
- Handoff to focused Java, framework, persistence, messaging, API, or testing skills while preserving the two-step sequence
Constraints
Separate behavior-preserving preparation from behavior-changing work, and validate after each step.
- MUST: State the intended behavior change before proposing preparatory refactoring
- MUST: Keep Step 1 behavior-preserving; do not mix broad refactoring with the intended behavior change
- MUST: Verify existing behavior after Step 1 using the project-appropriate tests, build, characterization tests, or manual checks
- MUST: Make Step 2 only after the design has been prepared and validated
- MUST: Verify the intended behavior after Step 2 with focused tests and relevant build checks
- MUST: Record assumptions and risks when preparation cannot be fully separated from behavior change
When to use this skill
- Apply two-step change
- Make this risky change safer
- Refactor before changing behavior
- Separate preparation from behavior change
- Make the change easy, then make the easy change
Workflow
- Define the intended change
Read references/051-design-two-steps-methods.md, inspect the relevant code and tests, and state the exact behavior or capability that must change. Identify why the current design makes the change complex, risky, or hard to verify.
- Plan preparatory refactoring
Choose the smallest behavior-preserving refactoring that reduces the obstacle: extract method or class, clarify names, isolate dependencies, add seams for testing, move responsibilities, improve types, or add characterization tests before touching behavior.
- Make the change easy
Apply Step 1 as focused preparatory refactoring only. Keep commits, notes, or task boundaries clear enough that reviewers can see no intended behavior change is included.
- Validate preserved behavior
Run the relevant existing tests, build checks, characterization tests, or manual verification. If behavior changes unexpectedly, fix or revert the preparation before proceeding.
- Make the easy behavior change
Apply the smallest intended behavior change now that the design supports it. Use focused Java, framework, persistence, messaging, API, or testing skills when detailed implementation guidance is needed.
- Verify and report the outcome
Verify the intended behavior with targeted tests and relevant project validation. Report what was preparation, what changed behavior, what was verified after each step, and any remaining risks.
Reference
For detailed guidance, examples, and constraints, see references/051-design-two-steps-methods.md.
Other versions1 project uses a version of this.
Word for word · 1
- jabrena/plinth★ 448100% same
Edited · 0
None found.
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository124 other files it gives its agents.
- AGENTS.mdAGENTS.md
- 001-commands-inventorySkill
- 002-agents-inventorySkill
- 003-skills-inventorySkill
- 004-commands-installationSkill
- 005-agents-installationSkill
- 012-agile-epicSkill
- 013-agile-featureSkill
- 014-agile-user-storySkill
- 021-problem-framingSkill
- 022-root-cause-analysisSkill
- 023-assumption-analysisSkill
- 024-context-mappingSkill
- 025-quality-attribute-discoverySkill
- 030-architecture-adr-generalSkill
- 033-architecture-diagramsSkill
- 041-planning-plan-modeSkill
- 042-planning-openspecSkill
- 043-planning-github-issuesSkill
- 044-planning-jiraSkill
- 045-planning-azure-devopsSkill
- 052-design-hamburger-methodSkill
- 053-design-simple-rulesSkill
- 054-design-tddSkill
- 055-design-parallel-changeSkill
- 056-design-avoid-breaking-changesSkill
- 057-design-feature-togglesSkill
- 058-design-bddSkill
- 059-design-atddSkill
- 110-java-maven-best-practicesSkill
- 111-java-maven-dependenciesSkill
- 112-java-maven-pluginsSkill
- 113-java-maven-documentationSkill
- 114-java-maven-searchSkill
- 121-java-object-oriented-designSkill
- 122-java-type-designSkill
- 123-java-design-patternsSkill
- 124-java-secure-codingSkill
- 125-java-concurrencySkill
- 126-java-exception-handlingSkill
- 128-java-genericsSkill
- 130-java-testing-strategiesSkill
- 131-java-testing-unit-testingSkill
- 132-java-testing-integration-testingSkill
- 133-java-testing-acceptance-testsSkill
- 141-java-refactoring-with-modern-featuresSkill
- 142-java-functional-programmingSkill
- 143-java-functional-exception-handlingSkill
- 144-java-data-oriented-programmingSkill
- 145-java-refactoring-high-performanceSkill
- 151-java-performance-jmeterSkill
- 152-java-performance-gatlingSkill
- 161-java-profiling-detectSkill
- 162-java-profiling-analyzeSkill
- 163-java-profiling-refactorSkill
- 164-java-profiling-verifySkill
- 170-java-documentationSkill
- 181-java-observability-loggingSkill
- 182-java-observability-metrics-micrometerSkill
- 183-java-observability-tracing-opentelemetrySkill
- The first 60 shown.
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.

