Community寫作與編輯github.com

MoonshotAI/agent-core-review

僅用於 `packages/agent-core-v2`(DI × Scope 代理引擎)的程式碼審查與測試編寫/審查指引。不適用於舊版 `packages/agent-core` 或其他套件——對於那些情況,請勿載入此技能。

agent-core-review 是什麼?

MoonshotAI/agent-core-review 是一個專門針對 `packages/agent-core-v2` 套件(DI × Scope 代理引擎)設計的技能組合,包含 `slop` 與 `test` 兩個子技能。`slop` 子技能專注於單層抽象與分層錯誤處理的程式碼結構審查,但僅在使用者明確要求時才應觸發,不能隨意應用於一般的審查或重構任務。`test` 子技能則遵循「測試合約/責任,而非實作細節」的原則,支援兩種模式:編寫模式用於撰寫符合 CCCR(清晰、隔離、可重構)標準的測試,審查模式則用於稽核既有測試並回報問題(含行號)。此技能支援 Claude Code、Cursor、Codex 等平台,能有效提升 agent-core-v2 的程式碼品質與測試一致性。

相容平台~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/MoonshotAI/kimi-code/tree/main/.agents/skills/agent-core-review

Installed? Explore more 寫作與編輯 skills: steipete/notion, langchain-ai/langchain, bytedance/podcast-generation · View all 6 →

在你喜歡的 AI 中提問

開啟一個已預先載入此 Agent Skill 的新對話。

說明文件

kc-review

範圍:僅限 packages/agent-core-v2。 這些透鏡是針對 v2 引擎(DI × Scope)校準的。請勿將它們應用於舊版 packages/agent-core 或其他套件。

用於審查或測試 packages/agent-core-v2 時的一組透鏡。每個子技能都是自包含的;請根據任務調用對應的子技能。

子技能

  • slop/ — 單層抽象與分層錯誤處理。這是一個審查維度:函式應像其自身層級的直線描述,錯誤應在上層或下層處理。代理報告檢測結果和度量,而非嚴重性等級。僅在使用者明確要求此透鏡時才調用——請勿在一般審查或重構時未經提示就應用它。
  • test/ — 遵循「測試合約/責任,而非實作細節」的每項測試規則,支援兩種模式。編寫模式: 撰寫測試——每個 it 一個行為,透過公開表面驅動,僅模擬真正的外部邊界,透過文件化的旋鈕控制時間/配置,保持測試清晰、隔離且可重構(CCCR)。審查模式: 根據相同規則稽核既有測試,並以 file:line 格式回報發現。在編寫、修改或審查測試,或被問及如何撰寫良好的單一測試時使用。

路由

  • 審查程式碼結構/抽象層/錯誤處理歸屬 → slop(僅在明確要求時)。
  • 編寫或修改測試、審查測試品質、或針對單一測試提供建議 → test。

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/consolidate

Apply an approved sub-skill grouping by moving user-specified skills into a parent bundle, with timestamped backups of every modified directory.

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).

相關技能