본문으로 건너뛰기
Skillpedia
배포 및 클라우드 (DevOps)48k · #4938

improve-codebase-architecture

하는 일

이 도구는 코드를 분석해 구조의 개선 영역을 찾고, 더 견고하게 만드는 방법을 제안합니다. 제안을 시각적 보고서로 보여 주며, 각 제안을 자세히 살펴볼 수 있게 합니다.

사용하는 경우

  • ✓코드의 어느 부분을 개선할 수 있는지 알고 싶을 때.
  • ✓이해하거나 테스트하기 어려운 코드 부분을 찾을 때.
  • ✓단순한 코드 부분을 더 정교하고 잘 정의된 구조로 바꾸는 경우.

스킬 링크

https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/improve-codebase-architecture/SKILL.md

복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.

사용 방법

가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.

바로 붙여넣을 수 있는 메시지

Use this skill to help me: https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/improve-codebase-architecture/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
AI가 이런 스킬을 알아서 찾아 쓰길 원하시나요?무료 Skillpedia MCP를 설치하세요. 한 줄이면 작업마다 스킬 15,000+개 중에서 검색합니다.1분 만에 설치 →

AI에게 요청하는 예시

“제 프로젝트 아키텍처를 분석하고, 개선할 수 있는 곳을 보여 주세요.”

매주 새 스킬 5개. 읽는 데 1분.

작동 방식

도구는 코드를 읽고, 더 주의가 필요한 부분을 찾아 제안이 담긴 시각 보고서를 만듭니다. 그다음 제안 하나를 골라 세부 내용을 논의할 수 있습니다.

기술 내용 (원본 SKILL.md)

작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.

Improve Codebase Architecture

When to Use

Use when this workflow matches the user request: Scan a codebase for deepening opportunities, present them as a visual HTML report, then grill through whichever one you pick.

Source: mattpocock/skills (MIT).

Surface architectural friction and propose deepening opportunities — refactors that turn shallow modules into deep ones. The aim is testability and AI-navigability.

This command is informed by the project's domain model and built on a shared design vocabulary:

  • Run the /codebase-design skill for the architecture vocabulary (module, interface, depth, seam, adapter, leverage, locality) and its principles (the deletion test, "the interface is the test surface", "one adapter = hypothetical seam, two = real"). Use these terms exactly in every suggestion — don't drift into "component," "service," "API," or "boundary."
  • The domain language in CONTEXT.md gives names to good seams; ADRs in docs/adr/ record decisions this command should not re-litigate.

Process

1. Explore

Read the project's domain glossary (CONTEXT.md) and any ADRs in the area you're touching first.

Then use the Agent tool with subagent_type=Explore to walk the codebase. Don't follow rigid heuristics — explore organically and note where you experience friction:

  • Where does understanding one concept require bouncing between many small modules?
  • Where are modules shallow — interface nearly as complex as the implementation?
  • Where have pure functions been extracted just for testability, but the real bugs hide in how they're called (no locality)?
  • Where do tightly-coupled modules leak across their seams?
  • Which parts of the codebase are untested, or hard to test through their current interface?

Apply the deletion test to anything you suspect is shallow: would deleting it concentrate complexity, or just move it? A "yes, concentrates" is the signal you want.

2. Present candidates as an HTML report

Write a self-contained HTML file to the OS temp directory so nothing lands in the repo. Resolve the temp dir from $TMPDIR, falling back to /tmp (or %TEMP% on Windows), and write to <tmpdir>/architecture-review-<timestamp>.html so each run gets a fresh file. Open it for the user — xdg-open <path> on Linux, open <path> on macOS, start <path> on Windows — and tell them the absolute path.

The report uses Tailwind via CDN for layout and styling, and Mermaid via CDN for diagrams where a graph/flow/sequence reliably communicates the structure. Mix Mermaid with hand-crafted CSS/SVG visuals — use Mermaid when relationships are graph-shaped (call graphs, dependencies, sequences), and hand-built divs/SVG when you want something more editorial (mass diagrams, cross-sections, collapse animations). Each candidate gets a before/after visualisation. Be visual.

For each candidate, render a card with:

  • Files — which files/modules are involved
  • Problem — why the current architecture is causing friction
  • Solution — plain English description of what would change
  • Benefits — explained in terms of locality and leverage, and how tests would improve
  • Before / After diagram — side-by-side, custom-drawn, illustrating the shallowness and the deepening
  • Recommendation strength — one of Strong, Worth exploring, Speculative, rendered as a badge

End the report with a Top recommendation section: which candidate you'd tackle first and why.

Use CONTEXT.md vocabulary for the domain, and the /codebase-design vocabulary for the architecture. If CONTEXT.md defines "Order," talk about "the Order intake module" — not "the FooBarHandler," and not "the Order service."

ADR conflicts: if a candidate contradicts an existing ADR, only surface it when the friction is real enough to warrant revisiting the ADR. Mark it clearly in the card (e.g. a warning callout: "contradicts ADR-0007 — but worth reopening because…"). Don't list every theoretical refactor an ADR forbids.

See HTML-REPORT.md for the full HTML scaffold, diagram patterns, and styling guidance.

Do NOT propose interfaces yet. After the file is written, ask the user: "Which of these would you like to explore?"

3. Grilling loop

…

자주 묻는 질문

'심화 기회(deepening opportunities)'란 무엇인가요?

코드 부분을 더 견고하고, 테스트하기 쉽고, 이해하기 쉽게 만들기 위한 리팩터링 제안입니다. 단순한 모듈을 더 정교하고 잘 정의된 모듈로 바꿉니다.

'아키텍처 마찰(architectural friction)'이란 무엇인가요?

코드 구조 때문에 이해하거나 유지보수하거나 새 기능을 추가하기 어려운 상태입니다. 예를 들어 하나를 이해하려고 여러 곳을 살펴봐야 하는 경우입니다.

보고서가 왜 HTML인가요?

쉽게 보고 공유할 수 있도록 하기 위해서입니다. 명확한 도표와 설명이 들어 있으며, 코드를 직접 바꾸지 않습니다.

상세 정보

작성자의 원본 설명

Scan a codebase for deepening opportunities, present them as a visual HTML report, then grill through whichever one you pick.

repo: sickn33/agentic-awesome-skills

인기도

GitHub 스타
48k
순위
#4938
라이선스
MIT
업데이트
2026. 10. 15.

이 스킬이 유용한가요?

0

로그인 투표하려면 로그인하세요.

댓글

  • …

이 저장소의 다른 스킬

비슷한 스킬