Skip to content

実装: M6 ally/NPC/assist_player feature specをcurrent mainへreconcileしimplementation authorityを確立する #2704

Open

Description

@squne121

Machine-Readable Contract

contract_schema_version: v1
issue_kind: implementation
parent_issue: "#2702"
goal_ref: "M6 delivery-rollup parent #2702 の Desired Destination: unit-operations-and-npc-behavior.md の status/§6 Current Runtime Compatibility Matrix を current main の実装事実(AllyBehaviorSystem 等)と一致させる"
change_kind: docs

Parent Issue

#2702

Parent Goal Ref

  • Goal: docs/product/playable-roadmap.md M6 section と docs/product/game-thesis.md の HYP-001-ace-intervention を authority とし、pre-landed な ally/assist_player capability を roadmap・feature spec・milestone の SSOT に正しく反映し、HYP-001 を developer-self playtest で検証可能・検証済みの状態にする
  • Desired Destination: docs/product/features/unit-operations-and-npc-behavior.md の status が draft のままか accepted へ昇格するかが Human Product Review を経て確定し、§6 Current Runtime Compatibility Matrix の記述が current main の実装(src/state/GameState.ts の Faction/UnitRole/CommandIntent/NpcBehaviorState/TargetingPolicy/AllyState、src/systems/AllyBehaviorSystem.ts、src/systems/TargetingSystem.ts)と一致した状態になっていること

Current Validated Scope

Remaining Parent Gaps

  • status: draft → status: accepted への昇格判断自体(Human Product Review が必須。本 Issue の Out of Scope)
  • docs/product/playable-roadmap.md M6 section の github_milestone_number / mapping_status 更新(別 child issue の責務)
  • current main 上での HYP-001-ace-intervention causal baseline evidence 記録(別 child issue の責務)

Outcome

docs/product/features/unit-operations-and-npc-behavior.md の §6 Current Runtime Compatibility Matrix が current main の実装事実(src/state/GameState.ts / src/systems/AllyBehaviorSystem.ts / src/systems/TargetingSystem.ts)と一致するよう更新され、#981〜#987・#1173 の landing trace が同ファイルへ追記され、pnpm lint が通過している状態。
§6 に加えて、§7.1・§7.3・§14・§15 のうち current main の実装事実と矛盾する stale な記述も diff-first で訂正され、status frontmatter は draft のまま維持し、accepted 昇格の要否判断は別途 Human Product Review へ委ねる旨が Issue コメントまたは PR description に明記されている。

Runtime Verification Applicability

  • decision: not_applicable
  • reason: docs-only 変更であり、src/ のランタイム挙動を変更しないため動作検証は不要。静的な文字列一致確認(rg / grep)と pnpm lint のみで完結する。

In Scope

Human Product Review Decision Point

本 Issue は status frontmatter の値を単独で確定しない。ただし本 Issue の completion contract には、以下いずれかの disposition が Human Product Review を経て明示的に記録されることを含める:

AI(本 Issue の実行者)が単独で accepted を確定させることはない。両disposition とも、Human の明示的な確認(Issue コメントでの承認、または明確な承認シグナル)を伴わない限り、本 Issue は disposition 未確定として close しない。draft_continue が選ばれた場合、親 Issue(#2702)の「spec authority 確立」という close condition の一部は満たされていない状態として扱い、AI がこれを false-green で「確立済み」と記録することはない。

Out of Scope

  • docs/product/features/unit-operations-and-npc-behavior.md の status: draft → status: accepted へのフロントマター変更(Human Product Review が必須のため、このIssueでは実行しない)
  • ally/assist_player runtime のコード変更(src/ 配下は Allowed Paths に含めない)
  • docs/product/mvp-scope.md / docs/product/playtest-protocol.md 自体の内容変更
  • docs/product/playable-roadmap.md M6 section の milestone number / mapping_status 更新(別 child issue)

Acceptance Criteria

  • AC1: §6 Current Runtime Compatibility Matrix 内の allies | absent という記述が除去され、Faction.ally / UnitRole.ally_basic / AllyState の実装済み状況を反映した記述に更新されている
  • AC2: §6 内の command intent | absent(\InputCommand` = move/aim/fire のみ) という記述が除去され、CommandIntent.assist_player` の実装済み状況を反映した記述に更新されている
  • AC3: §6 内の targeting policy | absent(chaser のみ) という記述が除去され、TargetingPolicy の実装済み状況を反映した記述に更新されている
  • AC4: 同ファイル内に #981〜#987 のいずれかの Issue 番号を用いた landing trace 記述が新規追加されている
  • AC5: frontmatter の status フィールドが draft のまま変更されていない
  • AC6: pnpm lint が成功する
  • AC7: §7.1 内の「現行には command intent の sampling 段も、NPC target acquisition の snapshot boundary も存在しない」という記述、または §7.3 の「current」列における stale な記述(command sampling なし等)が、current main の実装事実(command sampling・ally behavior step の存在)を反映するよう訂正されている。
  • AC8: §15 の Bounded Current Context 内「ally / CommandIntent / TargetingPolicy 不在」「現在フェーズは M3」という記述が、current main の実装事実(ally/CommandIntent/TargetingPolicy 実装済み、現在の milestone フェーズ)を反映するよう訂正されている。
  • AC9: accepted または draft_continue のいずれかの disposition が Human Product Review を経て Issue コメントまたは PR description に明記されている。AI が単独で accepted を確定させていないことが確認できる。

Verification Commands

# AC1
$ rg -c "allies.{1,3}absent" docs/product/features/unit-operations-and-npc-behavior.md
# AC2
$ rg -c "command intent.{1,3}absent" docs/product/features/unit-operations-and-npc-behavior.md
# AC3
$ rg -c "targeting policy.{1,3}absent" docs/product/features/unit-operations-and-npc-behavior.md
# AC4
$ rg -c "#98[1-7]" docs/product/features/unit-operations-and-npc-behavior.md
# AC5
$ rg -n "^status: draft$" docs/product/features/unit-operations-and-npc-behavior.md
# AC6
$ pnpm lint
# AC7
$ rg -c "command intent.{1,5}sampling.{1,10}段も.{1,10}存在しない" docs/product/features/unit-operations-and-npc-behavior.md
# AC8
$ rg -c "ally.{0,3}/.{0,3}CommandIntent.{0,3}/.{0,3}TargetingPolicy.{0,3}不在" docs/product/features/unit-operations-and-npc-behavior.md
# AC9
$ true
  • AC1: 出力が 0 であること(該当行が除去されたことを確認)
  • AC2: 出力が 0 であること(該当行が除去されたことを確認)
  • AC3: 出力が 0 であること(該当行が除去されたことを確認)
  • AC4: 出力が 0 より大きいこと(landing trace が追記されたことを確認)
  • AC5: マッチすること(frontmatter status が draft のまま維持されていることを確認)
  • AC6: exit code 0 であること
  • AC7: 出力が 0 であること(stale な command sampling 不在記述が訂正されたことを確認)
  • AC8: 出力が 0 であること(stale な ally/CommandIntent/TargetingPolicy 不在記述が訂正されたことを確認)
  • AC9: 上記 true コマンドは VC セクション形式上のプレースホルダであり、AC9 自体は shell コマンドでは充足しない。Issue コメントまたは PR description における Human Product Review の human confirmation readback(承認シグナルの明記)で確認する。

Allowed Paths

  • docs/product/features/unit-operations-and-npc-behavior.md

Stop Conditions

  • Allowed Paths 外の変更が必要と判明した場合(特に src/ 配下のコード変更が必要と感じた場合は直ちに停止する)
  • In Scope の固定契約(キー集合・スキーマ・型定義)の変更が必要になった場合
  • 新規 Issue の起票が必要と判断した場合(スコープ分割が発生する場合)
  • 後続 Phase / 別スコープへの波及が判明した場合
  • nested SubAgent delegation が必要になった場合
  • 外部サービス利用・権限昇格・既存テスト大規模改変が必要になった場合、または status: draft → accepted への昇格を単独で確定させたくなった場合は必ず停止し人間判断を仰ぐ

Required Skills

なし

Required Design References

  • docs/dev/product-spec-lifecycle.md#Update Rules
  • docs/product/playable-roadmap.md
  • docs/product/game-thesis.md

Scope Delta(任意)

N/A

Notes for Reviewer

Overlap preflight(check_issue_overlap.py)で decision: overlap_requires_comment(policy_class C1)を検出。ただし候補 #1185(docs/product/features/movement-projectile.md の status 移行判断、対象ファイルは別ファイル)と #435(tokenization 設計判断)はいずれも docs/product/features(ディレクトリ全体)を Allowed Paths とする broad-path match であり、本 Issue の narrow bare path(docs/product/features/unit-operations-and-npc-behavior.md)との実質的な作業内容の重複はない(non_conflict_reason: 対象ファイルおよび作業内容が異なる)。#1860 Owner Decision に従い、advisory として記録した上で起票を継続する。

Metadata

Metadata

Assignees

No one assigned

    Labels

    agent/implementerenhancementphase/implementation

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions