Skip to content

v1.5.0: Introduce cross-cutting concepts for system-wide rules - #20

Open
kikaineko wants to merge 4 commits into
mainfrom
claude/cross-capability-business-rules-qad8p1
Open

v1.5.0: Introduce cross-cutting concepts for system-wide rules#20
kikaineko wants to merge 4 commits into
mainfrom
claude/cross-capability-business-rules-qad8p1

Conversation

@kikaineko

Copy link
Copy Markdown
Contributor

Summary

Introduces cross-cutting concepts (横断概念) as a first-class mechanism for managing business rules that affect multiple capabilities. This addresses the challenge of rules like "restricted users cannot post comments" that span multiple capabilities but are owned by a single capability.

The core insight: rules are unstable units (can be split/merged by rewording), but concepts are stable (the same concept regardless of phrasing). Therefore, obligations are attached to concepts (nouns), not rules (sentences).

Key Changes

Business Rules Guide

  • Added comprehensive "横断概念とは何か" section defining:
    • Judgment test (3 questions: otherness, universality, necessity) to identify cross-cutting concepts
    • Declaration format: 1 concept = 1 line with <!-- cross-concept --> marker in owner's BR
    • Conformance format: all capabilities must declare attitude (applicable/non-applicable with reason) toward all declared concepts
    • Responsibility split: owner declares concept + defines it; each capability specifies effects in their own rules + conformance section
    • Delayed migration for existing BR files (introduced when updating, not retroactively)

BR Structure

  • Added Section 4 "横断概念" with subsections "宣言" (Declaration) and "適合" (Conformance)
  • Updated documentation structure guidance to clarify that two-party dependencies belong in boundaries, not cross-cutting concepts
  • Updated example business_rules.md with ORD-05 (restricted user cannot post comments) as conformance example

Skill Updates

/miko.new-cap:

  • Step 6b: Added mandatory full-capability BR survey via Sonnet sub-agent (not just adjacent capabilities)
  • Step 6c: Added mandatory cross-cutting concept conformance judgment (grep declared concepts → confirm with user → record in conformance section)
  • Step 11: Conformance section now required in generated BR (with "特になし" if no concepts declared)
  • Step 12: Updated completion report to include conformance judgment counts and escalation candidates

/miko.propose:

  • Step 9: Changed other-capability impact survey from optional to mandatory (unless explicitly skipped by user)
  • Updated cross-capability impact guide to include cross-concept considerations:
    • Changes to declared concept definitions affect all conforming capabilities
    • New concept declarations require conformance from all capabilities
    • Escalation candidates (states meeting judgment test) reported separately

/miko.harae & /miko.new-harae:

  • Added mechanical verification step (not inference) for cross-concept coverage:
    • Detects missing conformance section
    • Detects missing conformance entries for declared concepts
    • Detects unresolved 要判定 entries
    • Detects broken rule ID references in conformance
  • Implemented in both棚卸 (inventory) and proposal verification modes

Delayed migration skills (/miko.quick-impl, /miko.catchup, /miko.quick-catchup, /miko.speckit.implement):

  • When updating business_rules.md, introduce cross-concept section if missing (only exception to "don't restructure existing BR" principle)
  • Follow migration procedure from guide

Documentation

  • Updated business_rules_driven_development.md with "解決済みの論点" section explaining:
    • Design decision rationale
    • Two-layer enforcement (mechanical grep + sub-agent discovery)
    • Rejected alternatives (glossary management, rule-level markers, central registry, discovery-only)
  • Updated harae_guide.md with mechanical verification procedure
  • Updated cross_capability_impact_guide.md with cross-concept impact patterns

Version

  • Bumped to v1.5.0 (2026-09-05)

Implementation Details

Concept List Derivation:

grep -n 'cross-concept' miko/*/business_rules.md

No central registry file maintained — list is derived on-demand to avoid sync drift between source and index.

Conformance Enforcement:

  • Layer 1 (Mechanical): `ha

https://claude.ai/code/session_019MrZz6XvUK3g1xUVTnGnRH

複数ケイパビリティに効果が及ぶルール(例: 規約違反ユーザーの発信制限)
を「横断概念」として管理する仕組みを追加する。

- 横断しているのはルール(文)ではなく概念(名詞)。オーナーの BR が
  「宣言」(1 行 + cross-concept マーカー)を持ち、全ケイパビリティが
  「適合」で態度を明示する(適用: ルール ID / 非適用: 理由)。
  無記載 = 検討漏れとして機械検出できる
- 一覧は grep で都度導出し、中央レジストリは持たない
- harae に網羅チェック(機械照合)を追加(new-harae / harae 両モード)
- new-cap に全ケイパビリティ BR 調査(必須)と適合判定ステップを追加
- propose の他ケイパビリティ影響調査を任意から必須に変更し、
  調査ガイドに横断概念の観点(影響先特定・昇格候補)を追加
- 既存 BR へは遅延マイグレーション: BR を更新するスキルが更新のついでに
  セクションを導入し、該当なしでも「特になし」を明示する

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MrZz6XvUK3g1xUVTnGnRH
- 「宣言」「適合」の見出しを「宣言(このケイパビリティがオーナーの横断概念)」
  「適合(他ケイパビリティの横断概念への態度)」に改名し、説明文なしで
  向きが読み取れるようにする。ガイドに provided / required の関係として
  分担の説明を追加
- example から機構の説明文(ガイドの内容)を削除。補足はサンプル用
  コメントに限定する
- example の宣言を「特になし」から実例(支払い不履行ユーザー、定義
  ルール PAY-03 を新設)に差し替え、オーナー側・消費側の両方を示す

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MrZz6XvUK3g1xUVTnGnRH
- 横断概念への依存は境界セクションに書かない(適合が唯一の置き場)ことを
  境界と適合の両方の指針に明記し、二重管理を封じる
- 適合エントリは判定(verdict)の機械可読レイヤーであり、ルール本文の
  言い直しではないことを明記(ルール本文は自由な日本語のため機械照合の
  分母にできない。実装マッピングと同じ位置づけで、参照切れは harae が照合)
- オーナーは消費者一覧を持たず、逆引きは適合セクションの grep で導出する
  ことを明記

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MrZz6XvUK3g1xUVTnGnRH
議論の結果、verdict 台帳(適合セクション)と事後監査による網羅チェックを
廃止し、最小の形に再設計する。

- 概念 ID を xc:{ケイパビリティディレクトリ名}/{短い英語スラッグ} 形式に
  する。ID がオーナー BR へのポインタを兼ね、採番は不要
- 宣言はオーナーの BR の「横断概念」セクションに 1 行(所有する場合のみ
  セクションを作る)。効果はルールの [xc:…] タグで表す。非適用は記録しない
- 網羅性は記録ではなくプロセスの門で構成的に保証する: 門 1 = propose の
  影響調査(必須)、門 2 = new-cap の横断概念判定ステップ。全ペアは
  遅い方の誕生イベントで必ず一度検討される
- harae の必須照合を廃止する。harae は完成したはずの体系を攻撃する事後の
  監査であり、必ず通るべき門を置く場所ではない(不完全性軸の攻撃観点と
  してのみ残す)
- 適合セクション廃止に伴い遅延マイグレーションも廃止し、BR 更新スキルの
  書き込み時 lint(orphan 参照・宣言重複・書式)に置き換える
- 却下した代替案(適合セクション・非適用の記録・グローバル連番 ID 等)を
  business_rules_driven_development.md に記録する

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MrZz6XvUK3g1xUVTnGnRH
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants