modular-decomposition
Fungsinya
Skill ini menjalankan urutan pemeriksaan tetap pada basis kode yang besar: inventaris, logika duplikat, masalah folder, keterikatan, dan pengelompokan domain. Skill ini ditujukan untuk tim yang bersiap memecah aplikasi besar dan ingin bukti terlebih dahulu.
Kapan dipakai
- ✓Saat Anda ingin tahu cara memecah aplikasi besar menjadi bagian yang lebih kecil.
- ✓Ketika Anda perlu mengukur dan mendaftar bagian sistem sebelum ekstraksi apa pun.
- ✓Ketika Anda ingin analisis gabungan tentang duplikasi, keterikatan, dan pengelompokan bisnis.
Link skill
https://github.com/tech-leads-club/agent-skills/blob/main/packages/skills-catalog/skills/(architecture)/modular-decomposition/SKILL.mdSalin lalu tempelkan ke AI Anda (Claude, ChatGPT, atau Cursor) dan minta AI mengikuti instruksinya.
Cara pakai
Cara paling mudah: salin pesan ini dan tempelkan ke AI Anda. AI akan membaca skill dan mengikuti instruksinya.
Pesan siap tempel
Untuk Claude Code, Codex, atau Cursor: jalankan di folder proyek, lalu skill langsung terpasang.
Unduh SKILL.md lalu taruh di folder skill agen Anda.
Contoh permintaan ke AI
“Jalankan analisis lengkap terhadap monolit kami agar kami tahu bagian mana yang harus dipecah dan bagaimana bagian-bagian itu dikelompokkan.”
5 skill baru setiap minggu. 1 menit baca.
Cara kerjanya
AI menjalankan lima langkah analisis secara berurutan, memuat instruksi untuk setiap langkah, dan menggabungkan hasilnya menjadi tampilan kandidat kelompok.
Konten teknis (SKILL.md asli)
Teks asli dari pembuat, dalam bahasa Inggris, langsung dari GitHub.
Modular Decomposition
This skill runs the Patterns 1–5 analysis pipeline before service extraction. Each pattern is plain markdown under references/; load the file for that step and execute it against the user’s codebase.
How to Use
Quick start (what users can say)
- Full pipeline: “Run modular decomposition Patterns 1 through 5 on this repo,” “Analyze this monolith for splitting—inventory, coupling, and domain grouping.”
- Single early step: “Identify and size components here,” “Find duplicated domain logic across modules,” “Analyze coupling between our packages.”
- With DDD lens: “Group components into domains and check bounded contexts,” “Use DDD strategic design on this codebase before we group services.”
If the user only wants extraction order, phases, or migration roadmap after analysis exists, use decomposition-planning-roadmap instead. If they need a full legacy migration plan (strangler fig, research, multi-stack), use legacy-migration-planner as well or instead of this skill when that is the primary ask.
How the agent should run it
- Scope: Confirm the task is structural analysis (inventory → coupling → grouping), not roadmap authoring. If unclear, ask once whether they want the full ordered pipeline or a subset.
- Order: Run patterns 1 → 2 → 3 → 4 → 5 in that order. Do not skip a step unless the user explicitly limits scope; if they do, state which patterns were skipped and how that limits later conclusions.
- Load references: For each pattern, open the matching
references/pattern-NN-*.mdfile and follow its instructions. Use the optional*-quick-reference.mdfor the same number when a short checklist is enough. - Carry context forward: Reuse outputs from earlier patterns in later ones (e.g. component inventory from Pattern 1 informs coupling in 4 and grouping in 5). Reference concrete paths, modules, or tables from previous steps.
- Domain language (Pattern 5): If subdomains or bounded contexts need grounding beyond structure, read
references/domain-analysis.mdbefore or alongside Pattern 5. Optionally openreferences/domain-analysis-quick-reference.mdorreferences/domain-analysis-examples.mdfor condensed rules or illustrations. - Deliver: Produce clear, actionable findings per pattern or one consolidated report—always tied to evidence from the repository (files, dependencies, metrics), not generic advice.
Usage examples
Example 1 — Full pipeline
User: "We're going to split this monolith—run the full decomposition analysis (Patterns 1–5)."
Agent: Execute patterns 1→5 in order, loading each references/pattern-NN-*.md, preserving outputs between steps, then summarize cross-cutting recommendations.
Example 2 — Coupling after inventory
User: "We already have a rough module list—focus on coupling (Pattern 4) and then domain grouping (Pattern 5)."
Agent: If no prior inventory exists in the thread, either run Pattern 1 briefly or derive an explicit module list from the repo before 4 and 5. State any assumptions.
Example 3 — DDD before grouping
User: "Map bounded contexts and language, then group components into domains."
Agent: Read references/domain-analysis.md (and optional quick reference/examples) in parallel with or immediately before Pattern 5; align Pattern 5 groupings with linguistic boundaries where evidence supports it.
Prerequisites
- Complete Pattern N before starting Pattern N+1 unless the user explicitly narrows scope. Later patterns depend on earlier results (for example, inventory and structure inform coupling and grouping).
- If business vocabulary, subdomains, or bounded contexts are uncertain, use
references/domain-analysis.mdbefore or alongside Pattern 5 (see Bounded contexts below).
Ordered workflow (Patterns 1–5)
| Step | Pattern | Primary reference |
|---|---|---|
| 1 | Identify and size components | references/pattern-01-identify-and-size.md (optional: pattern-01-identify-and-size-quick-reference.md) |
| 2 | Common domain detection | references/pattern-02-common-domain.md (optional: pattern-02-common-domain-quick-reference.md) |
Pertanyaan umum
Apakah skill ini menghasilkan peta jalan migrasi?
Tidak. Urutan ekstraksi dan fase ditangani oleh skill peta jalan yang terpisah.
Bisakah saya menjalankan satu langkah saja?
Bisa. Anda bisa meminta satu analisis saja, seperti mengukur komponen atau memeriksa keterikatan.
Apakah skill ini mencakup analisis domain?
Bisa menambahkan sudut pandang domain bisnis jika Anda memintanya.
Detail
Deskripsi asli dari pembuat
Runs a sequenced monolith-to-modular pipeline that sizes and inventories components, finds shared domain duplication, addresses flattening and hierarchy issues, analyzes coupling, then groups components into candidate domain-aligned units, with optional embedded DDD strategic analysis for bounded contexts. Use when asking how to split a monolith, size components before extraction, find duplicated domain logic, clean up module hierarchy, measure coupling between modules, or group components into services. Do NOT use for phased extraction roadmaps or prioritization without the prior analysis ste
Popularitas
- Bintang GitHub
- 7.1k
- Peringkat
- #13509
- Lisensi
- —
- Diperbarui
- 2/11/2026
Komentar
- …
Skill lain dari repositori ini
component-common-domain-detection
7.1kMembantu agent Anda menemukan logika bisnis yang berulang di beberapa bagian basis kode dan menyarankan cara menggabungkannya.
component-flattening-analysis
7.1kMembantu agent Anda menemukan kode yang salah tempat dan meratakan struktur folder komponen yang berantakan, agar setiap bagian berada di tempat yang seharusnya.
component-identification-sizing
7.1kMembantu agent Anda memetakan bagian-bagian basis kode dan mengukur ukurannya, untuk menemukan modul mana yang sebaiknya dipecah lebih dulu.
coupling-analysis
7.1kMembantu agent Anda memeriksa seberapa erat bagian-bagian basis kode saling bergantung, dan koneksi mana yang sebaiknya dilonggarkan lebih dulu.
Skill serupa
diffs
394kMemungkinkan agent Anda menghasilkan diff perubahan yang nyata dan dapat dibagikan sebagai tautan viewer atau file gambar, bukan ringkasan yang ditulis manual.
coding-agent
394kMembantu agent Anda menyerahkan pekerjaan pemrograman besar ke Codex, Claude Code, atau OpenCode di latar belakang, lalu memeriksa kemajuannya.
gh-issues
394kMembantu agent Anda menemukan issue GitHub, memilih yang dikerjakan, dan membuka pull request perbaikan, termasuk tindak lanjut komentar tinjauan.