[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill-9b2cf3ff-f805-48e2-bf2d-ee143d04ef8d":3,"$f1ktIJWzXzP4P41WWbRid1Wqj7ttueNW5Un8ghwojuw4":43},{"id":4,"title":5,"description":6,"categoryId":7,"moduleId":8,"tags":9,"prompt":10,"icon":11,"source":12,"sourceUrl":13,"authorId":14,"authorName":15,"isPublic":16,"stars":17,"runs":18,"createdAt":19,"updatedAt":19,"module":20,"category":27,"packages":34},"9b2cf3ff-f805-48e2-bf2d-ee143d04ef8d","orchestrate-batch-refactor","规划和执行大型重构，使用依赖感知的工作包和并行分析。","cat_prod_automation","mod_productivity","sickn33,productivity","---\nname: \"orchestrate-batch-refactor\"\ndescription: \"Plan and execute large refactors with dependency-aware work packets and parallel analysis.\"\nrisk: safe\nsource: \"Dimillian\u002FSkills (MIT)\"\ndate_added: \"2026-03-25\"\n---\n\n# Orchestrate Batch Refactor\n\n## Overview\n\nUse this skill to run high-throughput refactors safely.\nAnalyze scope in parallel, synthesize a single plan, then execute independent work packets with sub-agents.\n\n## When to Use\n- When a refactor spans many files or subsystems and needs clear work partitioning.\n- When you need dependency-aware planning before parallel implementation.\n\n## Inputs\n\n- Repo path and target scope (paths, modules, or feature area)\n- Goal type: refactor, rewrite, or hybrid\n- Constraints: behavior parity, API stability, deadlines, test requirements\n\n## When to Use Parallelization\n\n- Use this skill for medium\u002Flarge scope touching many files or subsystems.\n- Skip multi-agent execution for tiny edits or highly coupled single-file work.\n\n## Core Workflow\n\n1. Define scope and success criteria.\n   - List target paths\u002Fmodules and non-goals.\n   - State behavior constraints (for example: preserve external behavior).\n2. Run parallel analysis first.\n   - Split target scope into analysis lanes.\n   - Spawn `explorer` sub-agents in parallel to analyze each lane.\n   - Ask each agent for: intent map, coupling risks, candidate work packets, required validations.\n3. Build one dependency-aware plan.\n   - Merge explorer output into a single work graph.\n   - Create work packets with clear file ownership and validation commands.\n   - Sequence packets by dependency level; run only independent packets in parallel.\n4. Execute with worker agents.\n   - Spawn one `worker` per independent packet.\n   - Assign explicit ownership (files\u002Fresponsibility).\n   - Instruct every worker that they are not alone in the codebase and must ignore unrelated edits.\n5. Integrate and verify.\n   - Review packet outputs, resolve overlaps, and run validation gates.\n   - Run targeted tests per packet, then broader suite for integrated scope.\n6. Report and close.\n   - Summarize packet outcomes, key refactors, conflicts resolved, and residual risks.\n\n## Work Packet Rules\n\n- One owner per file per execution wave.\n- No parallel edits on overlapping file sets.\n- Keep packet goals narrow and measurable.\n- Include explicit done criteria and required checks.\n- Prefer behavior-preserving refactors unless user explicitly requests behavior change.\n\n## Planning Contract\n\nEvery packet must include:\n\n1. Packet ID and objective.\n2. Owned files.\n3. Dependencies (none or packet IDs).\n4. Risks and invariants to preserve.\n5. Required checks.\n6. Integration notes for main thread.\n\nUse [`references\u002Fwork-packet-template.md`](references\u002Fwork-packet-template.md) for the exact shape.\n\n## Agent Prompting Contract\n\n- Use the prompt templates in [`references\u002Fagent-prompt-templates.md`](references\u002Fagent-prompt-templates.md).\n- Explorer prompts focus on analysis and decomposition.\n- Worker prompts focus on implementation and validation with strict ownership boundaries.\n\n## Safety Guardrails\n\n- Do not start worker execution before plan synthesis is complete.\n- Do not parallelize across unresolved dependencies.\n- Do not claim completion if any required packet check fails.\n- Stop and re-plan when packet boundaries cause repeated merge conflicts.\n\n## Validation Strategy\n\nRun in this order:\n\n1. Packet-level checks (fast and scoped).\n2. Cross-packet integration checks.\n3. Full project safety checks when scope is broad.\n\nPrefer fast feedback loops, but never skip required behavior checks.\n\n## Limitations\n- Use this skill only when the task clearly matches the scope described above.\n- Do not treat the output as a substitute for environment-specific validation, testing, or expert review.\n- Stop and ask for clarification if required inputs, permissions, safety boundaries, or success criteria are missing.\n","","imported","https:\u002F\u002Fgithub.com\u002Fsickn33\u002Fantigravity-awesome-skills","user_system_seed","SkillOPIC",true,116,1039,"2026-05-16 13:33:02",{"id":8,"name":21,"slug":22,"icon":23,"description":24,"sort":25,"createdAt":26},"效率工具","productivity","mdi-lightning-bolt-outline","文档处理、数据分析、自动化工作流",4,"2026-05-16 12:53:40",{"id":7,"name":28,"slug":29,"icon":30,"description":31,"moduleId":8,"sort":32,"skillCount":33,"createdAt":26},"自动化","automation","mdi-robot-outline","工作流自动化、批处理",3,101,[35],{"id":36,"skillId":4,"version":37,"fileName":38,"fileSize":39,"filePath":40,"fileHash":41,"manifest":42,"createdAt":19},"41f22e0c-a958-48d8-bf60-28d8a138b91f","1.0.0","orchestrate-batch-refactor.zip",3618,"uploads\u002Fskills\u002F9b2cf3ff-f805-48e2-bf2d-ee143d04ef8d\u002Forchestrate-batch-refactor.zip","4d4b44d81a99685bdd0affcb027566eb2808a213e73e4b867712a43ff24b10f6","[{\"path\":\"SKILL.md\",\"isDirectory\":false,\"size\":3920},{\"path\":\"agents\u002Fopenai.yaml\",\"isDirectory\":false,\"size\":271},{\"path\":\"references\u002Fagent-prompt-templates.md\",\"isDirectory\":false,\"size\":1360},{\"path\":\"references\u002Fwork-packet-template.md\",\"isDirectory\":false,\"size\":997}]",{"code":44,"message":45,"data":46},200,"success",{"items":47,"stats":48,"page":51},[],{"averageRating":49,"totalRatings":49,"ratingCounts":50},0,[49,49,49,49,49],{"limit":52,"offset":49,"hasMore":53,"nextOffset":52,"ratedOnly":16},15,false]