refactoring
Team standard for improving existing code without changing behaviour. Use when refactoring code.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Team standard for improving existing code without changing behaviour. Use when refactoring code.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
Team quality gate as executable instruction. Use when reviewing completed work before merge, or when processing PR review comments received from other reviewers.
Generate well-formed user stories from technical context. Use when generating or improving story descriptions for an issue tracker.
Type-safe validated configuration properties from application.yml. Use when adding any externalisable value.
Consistent error handling with named exceptions and global handler. Use when implementing any method that can fail with a business reason.
Consistent, safe log statements with correct levels and no PII. Use when adding or reviewing log statements.
Team threat model as executable instruction. Use when checking code for security issues before merge.
| name | refactoring |
| description | Team standard for improving existing code without changing behaviour. Use when refactoring code. |
When to load it: When improving existing code without changing observable behaviour.
Applies the team's refactoring philosophy to a specific piece of code. Proposes improvements that reduce complexity, remove duplication, and align with project conventions — without changing the public interface or adding unrequested behaviour. Output is a proposed change with explanation of what each transformation does and why.
Opening prompt structure:
I need to refactor [ComponentName / method / file].
Problem: [what is wrong — duplication / complexity / convention violation / other]
Constraints:
- Do not change the public interface
- Do not change observable behaviour
- Follow [specific convention from Layer 1 or Layer 2]
Current code:
[paste the code]
Propose the refactored version. Explain each transformation.
Do not change anything not related to the stated problem.
Response structure the skill produces:
Problem identified: [one sentence]
Transformations:
1. [transformation name] — [what changed and why]
2. [transformation name] — [what changed and why]
Refactored code:
[code]
Public interface unchanged: [confirm or flag deviations]
Tests required: [list any new tests needed to verify the transformation]