refactor

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Refactor

重构

When this skill activates, IMMEDIATELY invoke the script. The script IS the workflow.
当此技能激活时,立即调用脚本。脚本即为工作流。

Invocation

调用方式

<invoke working-dir=".claude/skills/scripts" cmd="python3 -m skills.refactor.refactor --step 1 --n 10" />
ArgumentRequiredDescription
--step
YesCurrent step (starts at 1)
--n
NoNumber of categories to explore (default: 10)
Do NOT explore or analyze first. Run the script and follow its output.
<invoke working-dir=".claude/skills/scripts" cmd="python3 -m skills.refactor.refactor --step 1 --n 10" />
参数是否必填说明
--step
当前步骤(从1开始)
--n
要探索的类别数量(默认值:10)
请勿先进行探索或分析。运行脚本并遵循其输出结果。

Determining N (category count)

确定N(类别数量)

Default: N = 10
Adjust based on user request scope:
  • SMALL (single file, specific concern, "quick look"): N = 5
  • MEDIUM (directory, module, standard analysis): N = 10
  • LARGE (entire codebase, "thorough", "comprehensive"): N = 25
The script randomly selects N categories from the 38 available code quality categories defined in conventions/code-quality/.
默认值:N = 10
根据用户请求的范围进行调整:
  • 小型(单个文件、特定问题、“快速查看”):N = 5
  • 中型(目录、模块、标准分析):N = 10
  • 大型(整个代码库、“全面”、“详尽”):N = 25
脚本会从conventions/code-quality/中定义的38个可用代码质量类别中随机选择N个类别。