Communityコーディング&開発github.com

MoonshotAI/consolidate

承認されたサブスキルのグループ化を適用し、ユーザー指定のスキルを親バンドルに移動します。移動のたびにタイムスタンプ付きのバックアップを作成します。

consolidate とは?

`sub-skill.consolidate` は、スキルの階層構造を整理・再編成するためのエージェントスキルです。ユーザーが `sub-skill.review` などで生成されたグループ化提案を承認した後、実際にスキルを親バンドル(子スキルを持てるディレクトリ)に移動し、サブスキル階層を構築します。このスキルは、ファイルの移動前に必ず元のスキルディレクトリ全体をタイムスタンプ付きでバックアップし、安全に変更を適用します。バックアップは上書きせず、常に新しいタイムスタンプで作成されます。また、移動時には親バンドルの `has-sub-skill: true` フロントマターの設定や、ドキュメントディレクトリ(references, assets, examples など)の整合性を保ち、相対リンクが壊れないようにします。Claude Code や Cursor、Codex などの AI エージェントプラットフォームで動作し、開発者が手動で行うとミスしやすいスキルディレクトリの再編成を自動化・安全化します。最終的には新しいディレクトリ構造の確認と変更レポートを出力します。

対応✓Claude Code~Codex CLI~Cursor
npx skills add https://github.com/MoonshotAI/kimi-code/tree/main/packages/agent-core-v2/src/app/skillCatalog/builtin/sub-skill/consolidate

Installed? Explore more コーディング&開発 skills: steipete/bluebubbles, steipete/eightctl, steipete/blucli · View all 6 →

お気に入りのAIに質問する

このエージェントスキルを事前に読み込んだ状態で新しいチャットを開きます。

ドキュメント

サブスキルの統合 (sub-skill.consolidate)

ユーザー指定のスキルを親バンドルに移動し、サブスキル階層を形成する再編成を実行します。

使用するタイミング

  • ユーザーがグループ化提案(通常は sub-skill.review からのもの)を承認し、それを適用したい場合。
  • スタンドアロンのスキルを新しい、または既存の親バンドルに移行する場合。

プロセス

  1. 計画を確認する。 どのスキルがどこに移動するかを再述し、ファイル変更を行う前にユーザーに確認を求めます。
  2. すべての元のスキルディレクトリをバックアップする。 移動を行う前に、変更される各スキルディレクトリのタイムスタンプ付きバックアップを作成します。
    • スキルが <root>/<skill-name>/SKILL.md にある場合、<skill-name> ディレクトリ全体をバックアップします。
      cp -r <skill-name> "<skill-name>.$(date +%Y%m%d-%H%M%S).bak"
      
    • すべてのバックアップを保持します。既存のバックアップファイルを上書きしないでください。
  3. 親バンドルを作成または更新する。
    • 親が存在しない場合、<parent-name>/SKILL.md を作成し、フロントマターに has-sub-skill: true を含めます。
    • 親が既に存在する場合、そのフロントマターに has-sub-skill: true が含まれていることを確認します。
  4. 子スキルを親に移動する。 各子スキルのディレクトリ全体を親バンドルの下に移動します。
    • 例: web-search/ → web-research/web-search/
  5. ドキュメントディレクトリの整合性を保つ。 ドキュメント、リファレンス、サンプル、アセット、またはその他のペイロードディレクトリを移動する際は、新しいスキルディレクトリのレイアウトに合わせます。
    • SKILL.md から references/、assets/、examples/、またはテンプレートなどのファイルへの相対リンクを維持します。
    • 子スキルが <root>/<child>/ から <root>/<parent>/<child>/ に移動する場合、承認された計画で別途指定がない限り、その子のドキュメントペイロードも一緒に移動する必要があります。
    • ドキュメントを古い場所に残したり、無関係なドキュメントディレクトリを一緒にマージしたりしないでください。
  6. 結果を確認する。 新しいディレクトリ構造を一覧表示し、移動した各スキルが引き続き有効な SKILL.md と必要なフロントマター(name および description)を持っていることを確認します。移動後のドキュメントディレクトリの整合性と相対リンクを確認します。
  7. 変更を報告する。 何が移動されたか、新しい構造、移動されたドキュメントディレクトリ、バックアップの場所をまとめます。

禁止事項

  • バックアップを取らずにスキルを移動しないでください。
  • 既存のバックアップを上書きしないでください — 常に新しいタイムスタンプのサフィックスを使用してください。
  • 移動中にフロントマターやペイロードファイルを削除しないでください。ディレクトリ全体を保持する必要があります。
  • ドキュメントディレクトリの整合性を壊さないでください — リファレンス、アセット、サンプル、テンプレートは、それらを使用するスキルディレクトリと整合性を保つ必要があります。
  • 深くネストされた階層(3レベル以上)を作成しないでください。ユーザーが明示的に要求した場合を除きます。

Individual skills in this repo

This repo contains 13 individual skills — each has its own dedicated page.

MoonshotAI/agent-core-dev

Use when developing in packages/agent-core-v2 (the DI × Scope agent engine) — adding or modifying a domain Service, choosing a LifecycleScope, wiring DI dependencies, splitting a domain across scopes, owning or migrating a config section, gating behavior behind an experimental flag, raising coded errors, working on the permission system, writing DI/Scope tests, porting business logic from agent-core (v1) to v2, triaging a main-branch commit against v2, or exposing a v2 domain over server-v2 while keeping the /api/v1 wire contract compatible with released clients. Self-contained guide organized by development stage (orient → design → implement → test → verify) plus align workflows for v1→v2 migration, main-branch commit triage, and server-v2 wire exposure; each file carries the rules, examples, and red lines for its step.

MoonshotAI/agent-core-review

Use ONLY for code review and test write/review guidance in `packages/agent-core-v2` (the DI × Scope agent engine). Does NOT apply to the legacy `packages/agent-core` or to any other package — for those, do not load this skill. Groups the review and testing lenses used for agent-core-v2 — `slop` (single-level-of-abstraction / layered error-handling review, invoked only on explicit request) and `test` (contract-driven per-test rules for both authoring and reviewing tests). Apply the sub-skill that matches the task; do not apply `slop` unprompted.

MoonshotAI/gen-changesets

Use when generating changesets in the kimi-code repository, including package bump selection, internal package and CLI bundle handling, bump levels, major confirmation, and English changelog wording.

MoonshotAI/gen-docs

Update Kimi Code CLI user documentation after meaningful code changes that affect product behavior or user experience.

MoonshotAI/kimi-datasource

Universal data-source assistant. Use this skill when the user wants external structured data such as stocks, financial reports, technical indicators, A-share/HK/US markets, global macroeconomics, Chinese enterprise registry information, arXiv papers, Google Scholar results, or Chinese laws/regulations and judicial cases. This plugin exposes tools via MCP server `plugin-kimi-datasource_data`; call them in the flow `mcp__plugin-kimi-datasource_data__get_data_source_desc` → `mcp__plugin-kimi-datasource_data__call_data_source_tool`.

MoonshotAI/pre-changelog

Use before merging a kimi-code release PR to preview the user-facing CLI changelog in Chinese. Reads the changelog that changesets pre-generated in the release PR, then reuses sync-changelog's strip / classify / translate logic to render a Chinese preview. Writes no files.

MoonshotAI/review

Analyze the available skill set and recommend candidate groups that could be consolidated into sub-skill bundles. Read-only — proposes a plan, does not move files.

MoonshotAI/slop

Invoke only when the user explicitly asks to review code through the "single level of abstraction / layered error handling" lens — a function does only its own layer's business logic while errors are handled above or below. The agent reports detections, raw-count measurements, and move directions. Apply only when the user explicitly requests this lens.

MoonshotAI/sub-skill

Discover and reorganize the skill inventory into hierarchical sub-skill bundles. Use when the user asks to review, group, or consolidate skills into a parent bundle.

MoonshotAI/sync-changelog

Use after a release succeeds, when maintainers need to sync apps/kimi-code/CHANGELOG.md into docs/en/release-notes/changelog.md and docs/zh/release-notes/changelog.md, then open a PR on a dedicated branch.

MoonshotAI/test

Use when writing or reviewing tests, or when asked how to write a good single test. Encodes the per-test rules behind the "test the contract / responsibility, not the implementation" principle — name and structure one behavior per `it`, drive through the public surface, stub only true external boundaries, control time and config via documented knobs, and keep tests clear, isolated, and refactor-resilient. The same rules drive both authoring (write mode) and auditing existing tests (review mode).

MoonshotAI/translate-docs

Translate and sync bilingual user documentation between docs/zh/ and docs/en/ following the source-of-truth rules in docs/AGENTS.md.

MoonshotAI/write-tui

Use when writing or modifying the kimi-code terminal UI in apps/kimi-code/src/tui — components, dialogs/selectors, slash commands, themes, streaming render, or the KimiTUI controllers. Covers the architecture, where new features go, test placement, the theme system mechanics, and the dialog interaction/visual spec (DESIGN.md).

関連スキル