↑ ↓ 移动 · Enter 打开 · Esc 关闭点按一个结果

架构
skill · orchestrator 类 · sonnet

new-feature-implement

实现一份已批准的规格:先做一次设置预检,再由执行器分三个串联的块组运行,最后打印 git-publish 命令。

skill · orchestratorsonnet不写任何文件随生成的项目导出
§ skill 的定义

new-feature-implement,逐节说明

skill 自己的 SKILL.md 的各个章节,节选。悬停或点击一个章节,查看它引用的项目规则、模板和 references/ 文件。章节也是标签:点击即可跳转。

nerviz/.claude/skills/new-feature-implement/SKILL.md

## Why this is Form 2 (manual skill)

Axis 2 (manual trigger) + axis 5 (procedural) + axis 8 (both). It was input row 3 of /new-feature until the two flows of the pipeline became two pieces: an implement run loaded the whole design procedure — about 10k tokens of steps 1–6 and consolidation it never runs — on every main-thread turn, and it ran on the opus the design needs. A subagent was rejected: the executor is already the isolated part, and this thread only chains it (@.claude/decisions/0135-new-feature-split-spec-and-implement.md).

Manual only. disable-model-invocation: true hides this skill from the model: the Skill tool can't call it, and trying is blocked. When a conversation reaches the point of running it, print the exact command for the user to type — don't attempt the call.

Pinned to sonnet: this thread runs a detection, chains three Agent calls and copies their findings — no design. The executor declares its own model (@.claude/decisions/0081-skill-model-required-per-class.md). A skill's model holds for the turn it runs in; a background executor's hand-back opens a new turn, which may run on the session's model — measured in the run's audit report, not assumed.

### 1 · Entry guardrail

Runs before any skill invocation, any delegation, and any question. Read @.claude/skills/new-feature/references/entry-guardrail.md and run its § 1 (survey and classify), then evaluate this table in order and stop at the first row that matches:

#InputResult
1empty✅ list the survey — each case with its status — and stop
2EXACT, FOLDER, status approved✅ implement: § 2 onwards. The argument is the request; nothing is asked before the pre-flight
3EXACT, FOLDER, status draft or (no spec)❌ <UC-NNN-slug> is <status> — design and approve it first — plus /new-feature <UC-NNN-slug>
4EXACT, FOLDER, status implemented or implemented-blocked❌ already implemented — describe the change as a new feature — plus /new-feature <description>
5no FOLDER, and the argument's UC-NNN resolves to exactly one folder on disk❌ <UC-NNN> is <real-slug>, status <status> — plus the exact command for that status: /new-feature-implement <real-slug> when approved, /new-feature <real-slug> when open
6EXACT, no FOLDER, number resolving to zero or several folders❌ use case not found
7UC_LIKE but not EXACT (slug plus context, malformed slug, two slugs, a path)❌ ambiguous argument
8free text❌ this skill implements an approved case; to design one, /new-feature <description>
—anything else❌ unrecognized argument

Every error follows the rule of the reference's § 1 — fixed shape, ends the run, no side effect:

❌ /new-feature-implement: <reason>.
Usage: /new-feature-implement UC-NNN-slug    → implement an approved case
       /new-feature-implement                → list
       /new-feature <feature description>    → design a new case

… 此处截断,其余见文件

### 2 · Implement

  1. One-time setup pre-flight, before delegating. The executor is about to write the

    … 此处截断,其余见文件

    ### 3 · Long-running background work

    Implementing a complete feature takes dozens of minutes. An executor launched in the background doesn't survive the machine sleeping: the watchdog cuts the stream and execution dies where it was. This happened three times in a row on the first real feature, with not a single file written, because all three died still in the reading phase.

    Before delegating the first group in the background, warn once and offer both options: keep the machine awake for the whole chain (caffeinate -i on macOS), or implement on the main thread, which is resumable. The executor writes by checkpoint precisely so that an interruption leaves reusable progress — but no checkpoint helps if execution dies before the first Write. A chain cut between groups resumes at the first group with open steps (§ Procedure, step 2).

    ### 4 · Final report

    Last message of the run, and the only report: the spec path and its status:, the groups that ran and how each ended, every ## Infrastructure row of the spec, with what this run did to it — added or failed by the installer, already present, external with its address, or pending with the /docker-architect command (or "none") — every approved use case this run left unreachable end to end, with the backlog row that restores it named by its BL-NN (or "none"), every item deferred, with its owner (or "none"), every guarantee delegated to a consumer outside this project whose idempotency is assumed or unknown (or "none"), and every personal-data field that crosses a boundary in clear, with its receiver (or "none") — the findings come from the tests group's report, which carries every group's lines — and the next commands, in this order:

    /clear
    /git-publish feat(UC-NNN-<slug>): <one-line summary>[ — pre-existing: <paths>]
    /new-feature <next feature description>

    /clear comes first: the commit then runs on a clean context, and SessionEnd has closed this run, so its report and history.jsonl line are on disk and enter the same commit instead of staying staged behind it. — pre-existing: is present only when the guardrail's worktree step listed changes from before the run, with the list itself (directories past 20 paths). /git-publish is the person's call and may be skipped or typed later. A clean context per use case keeps cost measurable per case. A failed group's report instead names the group, its failure, and /new-feature-implement UC-NNN-<slug> to resume there — no /git-publish.

    ## References

    • @.claude/decisions/0130-executor-split-by-block-group-implement-in-clean-session.md — the
    • @.claude/decisions/0135-new-feature-split-spec-and-implement.md — why this flow is a
    • @.claude/decisions/0067-implement-entry-row.md — the single door to the implement half,
    • @.claude/decisions/0116-tests-defers-while-a-writer-subagent-runs.md — why the next
    • @.claude/agents/commons-logging-installer.md — one-time logging/masking setup,
    • @.claude/agents/mapstruct-installer.md — records the project's mapper mechanism once;
    • @.claude/agents/compose-service-installer.md — adds the spec's materialize services
    • @.claude/decisions/0182-git-publish-printed-not-chained-by-the-feature-flows.md — why the
    • @.claude/decisions/0137-pending-compose-service-decided-at-design-materialized-at-implement.md

    ## Entry into generated projects

    Step 6.6 writes the skills into the project, this one included — the user runs /new-feature-implement UC-NNN-<slug> after /new-feature approves a spec.

    在 GitHub 上打开完整文件 →
    § 行为

    它读什么、写什么、拒绝什么

    skill 自己的契约,取自 SKILL.md,保留原文。

    Class

    orchestrator — skill_classes.orchestrator in @.claude/schemas/extensions.json, with overrides.new-feature-implement.write_allow: []: this thread writes nothing. Every write of a run is a subagent's, judged by its own agent_classes entry — the executor's and the installers' — never by this phase (@.claude/decisions/0059-agent-classes-territory-schema.md). The class keeps design_phase: true, so ArchHook.java guard refuses a Skill call to a build-class skill while the run is open.

    Ownership

    Feature spec→code orchestrator. Owns the pre-flight, the group chain, the hand-off between groups, and the /git-publish line an implemented case ends with. Does not own the spec — /new-feature writes it and its status: up to approved; java-spring-boot-developer writes implemented or implemented-blocked (@.claude/skills/new-feature/SKILL.md § Spec lifecycle).

    Reads

    - @.claude/skills/new-feature/references/entry-guardrail.md — survey, classification, error rule, worktree, project, disk; shared with /new-feature, owned there - docs/use-cases/UC-*/ — folder existence and each spec's status: line, by command - docs/use-cases/UC-NNN-<slug>/UC-NNN-spec.md — the checklist, to find where the chain starts, and ## Infrastructure, for the services the run adds and reports - @.claude/skills/docker-architect/references/compose-service-decision.md — what each ## Infrastructure decision means, and who acts on it - src/test/, the commons package, the root CLAUDE.md's Mappers: paragraph — by command, for the pre-flight

    Writes (indirectly)

    - src/**, pom.xml and the spec's checklist and status: — via java-spring-boot-developer - the ArchUnit tests and coverage gate — via test-architect setup mode → archunit-installer - the logging/masking classes — via commons-logging-installer, from this skill's templates/commons/*.example - the project's mapper mechanism — the **Mappers: paragraph, and for MapStruct the build wiring and every converted mapper — via mapstruct-installer, from this skill's templates/mapstruct/*.example - docker-compose.yml and what a service needs next to it — via compose-service-installer, which runs docker-architect for every materialize row of the spec

    Writes (directly): none

    Never runs `git add`, `git commit`, or `git push`, and never invokes `git-publish`

    Git happens only through git-publish, which the person types after /clear, behind its two confirmations; the final report prints the command (@.claude/decisions/0182-git-publish-printed-not-chained-by-the-feature-flows.md). No end of this flow is left without an explicit git instruction.

    Integrates with

    1. test-architect (setup mode), commons-logging-installer and mapstruct-installer — pre-flight, each only when its gap is found; the first two when the user answers Install now, the third with whichever mechanism the user picks 2. java-spring-boot-developer — three chained delegations, one per block group 3. compose-service-installer — on success, only when the spec has a materialize row

    来源:SKILL.md § Contract(nerviz e4cae27)。

    § guard 与 hook

    guard 如何处理它

    orchestrator 是这个 skill 的类别,左侧的列表就是它的领地。skill 在自己的提示上运行时阶段打开,ArchHook 对照这份列表判断每一次写入。右侧的文字是 hook 自己输出的。

    new-feature-implement 的 write_allow

    • 任何文件:领地为空

    拒绝以退出码 2 结束,消息回到模型。

    > /new-feature-implement …
    UserPromptSubmit
      guard prompt                     exit 0
    # phase opened: new-feature-implement (class orchestrator)
    # write_allow: [] — this class writes no file