Improve Codebase Architectureのロゴ

Improve Codebase Architecture

コミュニティ
domengabrovsek
improve-codebase-architecture

Finds deepening opportunities in a codebase, informed by the domain language in CONTEXT.md and the decisions in docs/adr/. Use when the user wants to improve architecture, find refactoring opportunities, consolidate tightly-coupled modules, or make a codebase more testable and AI-navigable.

概要

公開者domengabrovsek
リポジトリagent-config
スキル名improve-codebase-architecture
スター
22
フォーク
4
同梱ファイル
3
リンク
  • Markdown形式の指示

    モデルが必要に応じて読み込むSKILL.mdファイルです。関連するリクエストがあったときだけトークンを消費します。

  • どのLLMでも利用可能

    AIスキルはプロバイダー固有のコードではなく、通常のMarkdownなので、GPT、Claude、Gemini、Grok、ローカルモデルで利用できます。

  • 3個の同梱ファイル

    モデルが作業中に読み取れるスクリプト、テンプレート、参考資料です。ファイルは読み取り専用で、実行されることはありません。

  • オープンソース

    domengabrovsekがGitHubで公開しています。インストールする前にソースを確認してください。

インストール

AIスキルImprove Codebase ArchitectureをTypingMindにインストールすれば、どのLLMでも利用できます。SKILL.mdを読み取れる別のAIエージェントに追加することもできます。

1

TypingMindにインストール

TypingMindはGitHubフォルダから直接スキルをインストールします。SKILL.mdを読み取り、リソースファイルをまとめてローカルに保存します。

  1. アプリを開き、「プラグイン」→「スキル」に移動します。
  2. 「GitHubからインストール」を選択します。
  3. 以下のスキルフォルダのURLを貼り付けて確定します。
    https://github.com/domengabrovsek/agent-config/tree/main/skills/improve-codebase-architecture
  4. スキルを利用したいチャットごとに、そのスキルを有効にしてください。
「プラグイン」→「スキル」→「スキルを追加」→「GitHubのURLから」を選択し、フォルダのURLを貼り付けて「続行」を押します。
2

別のAIエージェントにインストール

Agent Skills形式を読み取れるAIエージェントなら、このスキルを利用できます。フォルダをそのAIエージェントのスキルディレクトリにコピーしてください。

Claude Code — .claude/skills
git clone --depth 1 https://github.com/domengabrovsek/agent-config.git /tmp/agent-config
mkdir -p .claude/skills
cp -r /tmp/agent-config/skills/improve-codebase-architecture .claude/skills/improve-codebase-architecture
コピー後、新しいスキルを読み込むためにClaude Codeを再起動してください。

TypingMindで使用

TypingMindのチャットでImprove Codebase Architectureを有効にするだけで、あとはモデルが対応します。名前と説明がシステムプロンプトに含まれ、関連するリクエストがあると、モデルが指示の全文を自動で読み込みます。手動で呼び出す必要はなく、実際に使用されるまでトークンを消費しません。

関連するリクエストがあると、モデルが自動的にImprove Codebase Architectureを読み込みます。

どのAIモデルでも利用可能

AIスキルはプロバイダー固有のコードではなく、通常のMarkdownで書かれた指示です。そのため、Improve Codebase Architectureは作成時に想定されたモデルに縛られません。TypingMindに一度インストールすれば、ご自身のAPIキーを使って、GPT-5、Claude、Gemini、Grok、DeepSeek、Mistral、Llama、またはご自身で実行するローカルモデルで利用できます。

  • 必要なときだけ読み込み

    システムプロンプトには名前と説明だけが含まれます。関連するリクエストが初めてあったときに指示を取得するため、未使用のスキルにはコストがかかりません。

  • チャットの途中でモデルを切り替え

    スキルはコードではなく指示なので、モデルを切り替えてもそのまま使えます。次のモデルも同じSKILL.mdを読み込みます。

スキルの指示

モデルが読み込むSKILL.mdの内容です。スキルはモデルが従う指示なので、インストールする前に確認してください。

Source: mattpocock/skills - engineering/improve-codebase-architecture

Improve Codebase Architecture

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

Glossary

why-no-hook: skill workflow guidance; each step requires understanding the surrounding context (repo, task shape, prior state).

Use these terms exactly in every suggestion. Consistent language is the point - don't drift into "component," "service," "API," or "boundary." Full definitions in LANGUAGE.md.

  • Module - anything with an interface and an implementation (function, class, package, slice). (review-time: see section note)
  • Interface - everything a caller must know to use the module: types, invariants, error modes, ordering, config. Not just the type signature. (review-time: see section note)
  • Implementation - the code inside. (review-time: see section note)
  • Depth - leverage at the interface: a lot of behaviour behind a small interface. Deep = high leverage. Shallow = interface nearly as complex as the implementation. (review-time: see section note)
  • Seam - where an interface lives; a place behaviour can be altered without editing in place. (Use this, not "boundary.") (review-time: see section note)
  • Adapter - a concrete thing satisfying an interface at a seam. (review-time: see section note)
  • Leverage - what callers get from depth. (review-time: see section note)
  • Locality - what maintainers get from depth: change, bugs, knowledge concentrated in one place. (review-time: see section note)

Key principles (see LANGUAGE.md for the full list):

  • Deletion test: imagine deleting the module. If complexity vanishes, it was a pass-through. If complexity reappears across N callers, it was earning its keep. (review-time: see section note)
  • The interface is the test surface. (review-time: see section note)
  • One adapter = hypothetical seam. Two adapters = real seam. (review-time: see section note)

This skill is informed by the project's domain model. The domain language gives names to good seams; ADRs record decisions the skill should not re-litigate.

Process

1. Explore

Read the project's domain glossary 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? (review-time: see section note)
  • Where are modules shallow - interface nearly as complex as the implementation? (review-time: see section note)
  • Where have pure functions been extracted just for testability, but the real bugs hide in how they're called (no locality)? (review-time: see section note)
  • Where do tightly-coupled modules leak across their seams? (review-time: see section note)
  • Which parts of the codebase are untested, or hard to test through their current interface? (review-time: see section note)

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

Present a numbered list of deepening opportunities. For each candidate:

  • Files - which files/modules are involved (review-time: see section note)
  • Problem - why the current architecture is causing friction (review-time: see section note)
  • Solution - plain English description of what would change (review-time: see section note)
  • Benefits - explained in terms of locality and leverage, and also in how tests would improve (review-time: see section note)

Use CONTEXT.md vocabulary for the domain, and LANGUAGE.md 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 (e.g. "contradicts ADR-0007 - but worth reopening because…"). Don't list every theoretical refactor an ADR forbids.

Do NOT propose interfaces yet. Ask the user: "Which of these would you like to explore?"

3. Grilling loop

Once the user picks a candidate, drop into a grilling conversation. Walk the design tree with them - constraints, dependencies, the shape of the deepened module, what sits behind the seam, what tests survive.

Side effects happen inline as decisions are made:

  • Naming a deepened module after a concept not in CONTEXT.md? Add the term to CONTEXT.md - same discipline as /grill-with-docs (see CONTEXT-FORMAT.md). Create the file lazily if it doesn't exist. (review-time: see section note)
  • Sharpening a fuzzy term during the conversation? Update CONTEXT.md right there. (review-time: see section note)
  • User rejects the candidate with a load-bearing reason? Record the reason in the review output so a future run does not re-suggest it. Do not propose an ADR; the user creates one via /document adr when they want the rejection on record. (review-time: see section note)
  • Want to explore alternative interfaces for the deepened module? See INTERFACE-DESIGN.md. (review-time: see section note)

同梱ファイル

スキルが読み込まれている間、モデルは必要に応じてこれらを読み取ります。読み取り可能なファイルとして提供され、実行されることはありません。

よくある質問

AIスキル「Improve Codebase Architecture」では何ができますか?

Finds deepening opportunities in a codebase, informed by the domain language in CONTEXT.md and the decisions in docs/adr/. Use when the user wants to improve architecture, find refactoring opportunities, consolidate tightly-coupled modules, or make a codebase more testable and AI-navigable.

TypingMindでImprove Codebase Architectureを使うメリットは何ですか?

一度インストールすれば、どのモデルでも使えるからです。Improve Codebase Architectureはプロバイダー固有のコードではなく、通常のMarkdownで記述されているため、同じスキルをGPT-5、Claude、Gemini、Grok、ローカルモデルで利用できます。チャットの途中でモデルを切り替えても、そのまま使い続けられます。TypingMindは自分のAPIキーで動作するため、シート単位のサブスクリプションではなく、プロバイダーに直接料金を支払います。スキルとチャットは自分のストレージに保持されます。

TypingMindにImprove Codebase Architectureをインストールするにはどうすればよいですか?

TypingMindで「プラグイン」→「スキル」→「GitHubからインストール」を開き、https://github.com/domengabrovsek/agent-config/tree/main/skills/improve-codebase-architectureを貼り付けてください。TypingMindがSKILL.mdを読み込み、関連ファイルをまとめて、チャットごとに有効にできるスキルとしてインストールします。

Improve Codebase Architectureを使えるAIモデルはどれですか?

TypingMindに接続したどのモデルでも利用できます。AIスキルはプロバイダー固有のコードではなく、通常のMarkdownで書かれた指示です。そのため、GPT、Claude、Gemini、Grok、ローカルモデルのいずれも、リクエストが合致したときにこのスキルを読み込めます。

Improve Codebase Architectureは何個のAIモデルで使えますか?

数に制限はありません。スキルに対応したモデルであれば、GPT、Claude、Gemini、Grok、DeepSeek、Mistral、Llamaなど、どのモデルでもImprove Codebase Architectureを利用できます。すべてTypingMind上で、自分のAPIキーを使って利用できます。

AIスキル「Improve Codebase Architecture」は無料ですか?

domengabrovsekがGitHubで公開しています。ライセンス条件はリポジトリでご確認ください。支払いが必要なのは、利用したトークンに対する、ご自身が契約するAIプロバイダーへの料金だけです。

AIスキルとは何ですか?

AIスキルは、特定のタスクの実行方法をAIモデルに教える、再利用可能な指示のセットです。オープンなAgent Skills形式に従い、名前と説明を含むSKILL.mdファイルに加え、モデルが必要とするスクリプト、テンプレート、参照ファイルで構成されます。モデルはリクエストがスキルに合致したときだけ指示を読み込むため、インストール済みのスキルも、使うまでは費用がかかりません。

AIスキルは、プラグインやMCPサーバーとどう違いますか?

プラグインやMCPサーバーは、モデルが呼び出せる新しいツールを提供します。ツールとは、どこかで実行され、結果を返すコードです。一方、AIスキルは、タスクへの取り組み方、従うべき手順、望ましい出力の例といった知識や進め方をモデルに伝えます。スキルは通常のMarkdownで記述されているため、サーバー、APIキー、実行環境は不要で、どのモデルでも利用できます。

すべて見る

今すぐ自分専用のAIワークスペースを作成

ニュースレターに登録すると、新機能や今後のプレゼント企画のお知らせが届きます👇