AR

architecture-refactor

Provides a structured, incremental approach to refactoring large codebases and aligning internal documentation and rules.

Install

mkdir -p .claude/skills/architecture-refactor && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/16253" && unzip -o skill.zip -d .claude/skills/architecture-refactor && rm skill.zip

Installs to .claude/skills/architecture-refactor

Activation

This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.

用于执行 Sourcelin 跨端架构重构、目录整理、页面拆分、模块边界治理、规则和文档同步。
47 chars · catalog descriptionno explicit “when” trigger
Advanced

Key capabilities

  • Execute progressive refactoring based on rules
  • Split large pages, components, or composables
  • Organize backend module boundaries
  • Synchronize project rules and documentation
  • Validate changes with automated checks at each step

How it works

The skill reads existing rules and documentation, confirms a clear boundary for refactoring, and establishes automated validation. It then performs refactoring in small, verifiable steps, updating related documentation and running validation commands after each sub-module completion.

Inputs & outputs

You give it
List of files to refactor, current rules/skills/directory structure, validation commands, completed/remaining tasks
You get back
Small, verifiable refactoring changes, updated rules/skills/SQL documentation, validation results, remaining risks

When to use architecture-refactor

  • Splitting large components or modules
  • Decoupling backend services
  • Synchronizing architectural rules with code

About this skill

架构重构技能

使用场景

  • 按规则执行渐进式重构。

  • 拆分大页面、大组件或大 composable。

  • 整理后端模块边界、公共能力、规则体系和文档。

  • 对齐 rules/skills/AGENTS.md

输入

  • 待重构文件清单或阶段任务。

  • 当前规则、技能、目录结构和验证命令。

  • 已完成项与剩余项。

输出

  • 小步可验证的重构改动。

  • 同步更新的规则、技能或 SQL 文档。

  • 每步验证结果和剩余风险。

执行步骤

  1. 读取 AGENTS.mdrules/README.md 和全部相关领域规则。

  2. 确认本轮只处理一个明确边界,避免跨模块大范围改动。

  3. 先建立或确认自动验证,再修改代码或文档。

  4. 对前台重构,按页面、组件、composable、API 分层拆分。

  5. 对后台重构,按查询、表格、分页、弹窗、操作列协议拆分。

  6. 对后端重构,按 Controller、Service、Mapper、domain、common 边界拆分。

  7. 对规则体系重构,同步更新 rules/skills/AGENTS.md

  8. 数据库初始化变化更新 docs/sql/**,架构说明变化更新 docs/architecture/**

  9. 每个子模块完成后运行对应验证命令,失败先修复再进入下一模块。

依赖 rules

  • rules/api-contract.md

  • rules/backend.md

  • rules/frontend-platform.md

  • rules/frontend-uniapp.md

  • rules/frontend-admin.md

  • rules/coding-conventions.md

  • rules/testing-and-validation.md

禁止行为

  • 禁止一次性跨多个无关模块大改。

  • 禁止改变视觉表现、交互行为或权限逻辑,除非任务明确要求。

  • 禁止为了通过检查删除核心功能或降低测试标准。

  • 禁止保留规则、技能、入口文件之间的旧引用。

  • 禁止只输出方案不落地验证。

When not to use it

  • When performing large-scale changes across multiple unrelated modules at once
  • When the user needs to change visual presentation or interaction behavior without explicit task requirements
  • When the user needs to remove core functionality to pass checks

Limitations

  • The skill processes one clear boundary at a time.
  • The skill prohibits changing visual presentation, interaction behavior, or permission logic unless explicitly required.
  • The skill requires establishing automated validation before modifying code or documentation.

How it compares

This skill enforces a step-by-step, rule-driven refactoring process with integrated validation and documentation synchronization, which is more controlled and less error-prone than ad-hoc refactoring.

Compared to similar skills

architecture-refactor side by side with the closest alternatives in the catalog.

SkillInstallsUpdatedSafetyDifficulty
architecture-refactor (this skill)02moNo flagsAdvanced
deepwiki-rs259moReviewIntermediate
agui-dotnet-feature-workflow01moReviewAdvanced
audit-spec06moNo flagsIntermediate

Try saying

Example prompts that trigger this skill in your AI assistant.

Search skills

Search the agent skills registry