musubix3 0.1.3 → 0.1.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (35) hide show
  1. package/.github/plugin/marketplace.json +2 -2
  2. package/.github/skills/sdd-change/SKILL.md +10 -10
  3. package/.github/skills/sdd-implementation/SKILL.md +7 -2
  4. package/.github/skills/sdd-quality/SKILL.md +2 -2
  5. package/CHANGELOG.md +43 -0
  6. package/README-ja.md +87 -32
  7. package/README.md +74 -34
  8. package/dist/packages/analysis/src/adapters.js +12 -5
  9. package/dist/packages/analysis/src/adapters.js.map +1 -1
  10. package/dist/packages/analysis/src/config.d.ts +2 -0
  11. package/dist/packages/analysis/src/config.js +34 -7
  12. package/dist/packages/analysis/src/config.js.map +1 -1
  13. package/dist/packages/analysis/src/files.js +1 -1
  14. package/dist/packages/analysis/src/files.js.map +1 -1
  15. package/dist/packages/analysis/src/gate.js +82 -22
  16. package/dist/packages/analysis/src/gate.js.map +1 -1
  17. package/dist/packages/analysis/src/graph.js +6 -4
  18. package/dist/packages/analysis/src/graph.js.map +1 -1
  19. package/dist/packages/analysis/src/mutation.js +41 -11
  20. package/dist/packages/analysis/src/mutation.js.map +1 -1
  21. package/dist/packages/analysis/src/process.js +3 -2
  22. package/dist/packages/analysis/src/process.js.map +1 -1
  23. package/dist/packages/analysis/src/tdd.js +10 -4
  24. package/dist/packages/analysis/src/tdd.js.map +1 -1
  25. package/dist/packages/analysis/src/trace.js +13 -0
  26. package/dist/packages/analysis/src/trace.js.map +1 -1
  27. package/dist/packages/analysis/src/workflow.d.ts +13 -0
  28. package/dist/packages/analysis/src/workflow.js +219 -12
  29. package/dist/packages/analysis/src/workflow.js.map +1 -1
  30. package/dist/packages/cli/src/main.js +21 -3
  31. package/dist/packages/cli/src/main.js.map +1 -1
  32. package/dist/packages/domain/src/requirements.js +6 -6
  33. package/dist/packages/domain/src/requirements.js.map +1 -1
  34. package/package.json +1 -1
  35. package/plugin.json +1 -1
@@ -3,13 +3,13 @@
3
3
  "owner": { "name": "nahisaho" },
4
4
  "metadata": {
5
5
  "description": "GitHub Copilot CLI specification-driven development skills",
6
- "version": "0.1.3"
6
+ "version": "0.1.5"
7
7
  },
8
8
  "plugins": [
9
9
  {
10
10
  "name": "musubix3",
11
11
  "source": ".",
12
- "version": "0.1.3",
12
+ "version": "0.1.5",
13
13
  "description": "Evidence-driven SDD without duplicating native Copilot capabilities."
14
14
  }
15
15
  ]
@@ -3,16 +3,18 @@ name: sdd-change
3
3
  description: "Use for feature additions, behavior changes, bug fixes, refactoring with observable impact, or any request that must propagate through requirements, design, code, tests, traceability, and quality evidence. 機能追加・仕様変更・バグ修正を一貫して反映するときに使用。"
4
4
  ---
5
5
  # Integrated change workflow / 統合変更ワークフロー
6
-
7
- Follow the user's input language (日本語 / English). Use Copilot's native
8
- planning, editing, research, review, security review and subagents where useful.
6
+ Follow the user's input language. Use native Copilot planning, editing, research, review, security review and subagents.
9
7
  This skill coordinates SDD artifacts and checks; it is not another agent runtime.
10
8
  Record exactly one final invocation outcome with `npx musubix3 workflow-record
11
9
  sdd-change complete --status <status>`; `change-record` separately proves phases.
12
- Run `workflow-verify <copilot.jsonl>` to bind this declaration to one Skill call.
13
- For strict evidence, set an expected UUID or pass `--strict --session-id <uuid>`;
14
- this checks lifecycles; GitHub origin needs strict OIDC with key-bound claims.
10
+ Run `workflow-sanitize <copilot.jsonl> <safe.jsonl>` before review, then
11
+ `workflow-verify <safe.jsonl>`; it validates source-order lifecycles without
12
+ assuming globally monotonic clocks unless `maxEventSkewMs` is explicitly set.
13
+ For large logs, baseline-protect transcript total/line byte limits; never truncate or edit to bypass them.
14
+ For strict evidence, bind an expected UUID; GitHub origin needs strict OIDC.
15
15
  Never record multiple declarations per invocation; use only the configured CLI.
16
+ For broad work, use short stages: initialize, requirements, design, real Red,
17
+ Green, integration, trace/formal, quality. Report each result before the next prompt.
16
18
  For a staged change, run `change-record <CHANGE-ID> <phase> --requirement
17
19
  <REQ-ID...>` after each phase in this exact order: `impact`, `requirements`,
18
20
  `design`, `red`, `implementation`, `green`, `quality`.
@@ -60,10 +62,8 @@ Persisted monotonic order, not wall-clock time, proves these phase boundaries.
60
62
  `@verifies` annotations in the authoritative implementation and test files.
61
63
  Never create proxy or placeholder source files solely to satisfy trace coverage.
62
64
  Links are evidence locations, not proof by themselves.
63
- 5. Run focused tests during implementation, then the configured typecheck,
64
- build and complete test commands.
65
- Documentation, formatting and prototypes may omit TDD unless policy requires it;
66
- record the reason and never exempt observable behavior changes.
65
+ 5. Run focused tests, then configured typecheck, build and complete test commands.
66
+ Documentation/prototypes may omit TDD only when policy allows; record the reason.
67
67
  ## 4. Rebuild evidence and finish / 根拠更新と完了
68
68
  1. Run `trace build`, `trace check --strict`, `graph index`, and `graph gate`.
69
69
  2. Run `formal check` when changed requirements fit its documented abstraction;
@@ -29,6 +29,8 @@ After the work, run `npx musubix3 workflow-record sdd-implementation complete
29
29
  `npx musubix3 tdd red <TEST-ID> --requirement <REQ-ID> --command <name>`.
30
30
  3. Implement only enough code to pass, preserving the test unchanged, then run
31
31
  `tdd green`. Refactor only after Green and record `tdd refactor`.
32
+ Use `tdd validate` to inspect persisted order, fingerprints, durations and
33
+ hash-chain evidence before claiming the cycle is complete.
32
34
  4. Add one block comment per trace entity:
33
35
  ```ts
34
36
  /** @id CODE-FEATURE-001
@@ -44,7 +46,8 @@ After the work, run `npx musubix3 workflow-record sdd-implementation complete
44
46
  ```
45
47
  IDs are globally unique. Multiple targets are comma/space-separated.
46
48
  Put annotations in the authoritative source and test files, including
47
- supported non-JS/TS files; never add a proxy file just to increase coverage.
49
+ supported non-JS/TS files. In Python, use consecutive `#` comment lines;
50
+ annotations inside docstrings are ignored and diagnosed. Never add a proxy file just to increase coverage.
48
51
  An annotation establishes a link, not proof that code or tests are correct.
49
52
  5. Before recording Red, run every configured `tdd.redPreflightCommands`
50
53
  formatter/check and let musubix3 enforce that preflight. Then run the
@@ -54,7 +57,9 @@ After the work, run `npx musubix3 workflow-record sdd-implementation complete
54
57
  test linkage, source/test SHA-256, operator/location, and killed status.
55
58
  Never fabricate results or add a large mutation dependency. Use
56
59
  `npx musubix3 mutation doctor --json` to inspect locally available engines
57
- and configuration recommendations.
60
+ and configuration recommendations. Before Python mutation runs, remove
61
+ existing `__pycache__` directories, then use `-B` for mutation and test
62
+ commands so stale bytecode is absent and no new `.pyc` files are created.
58
63
  6. Regenerate `npx musubix3 trace build`, check `trace check --strict`, then
59
64
  `npx musubix3 gate --changed`. Configure real command/argument arrays first.
60
65
  7. Use Copilot's native review and security-review capabilities when appropriate.
@@ -3,7 +3,6 @@ name: sdd-quality
3
3
  description: "Use when deciding release readiness from actual checks, measurable policy, architecture and trace evidence, including incremental change checks. 品質ゲート・リリース判定時に使用。"
4
4
  ---
5
5
  # Quality / 品質
6
-
7
6
  Follow the user's input language (日本語 / English). Use native Copilot review and
8
7
  security review for their specialist reasoning; this skill does not replace them.
9
8
  After the work, run `npx musubix3 workflow-record sdd-quality complete --status
@@ -40,6 +39,7 @@ completed` exactly once.
40
39
  fingerprints. Inspect `formal.json` and `workflow.json` when configured.
41
40
  Treat workflow records as declarations until `workflow-verify` binds each
42
41
  completed declaration to one distinct completed Copilot Skill tool call.
42
+ Use `workflow-sanitize` before review; it validates before filtering.
43
43
  In strict mode require one final successful result, matching session UUID,
44
44
  causal transcript order, policy-bounded concurrent-event clock skew, bounded
45
45
  freshness, complete tool lifecycles and canonical transcript hash. Ensure the
@@ -61,7 +61,7 @@ completed` exactly once.
61
61
  identities bound to must functional requirements, current source/test
62
62
  fingerprints, operator/location, authoritative tests, and killed results.
63
63
  Reject survived, skipped, duplicate, conflicting, stale, or unlinked mutants.
64
- Run `mutation doctor` for language-aware local probes and remediation;
64
+ Treat zero executed or non-passing tests as incomplete evidence after exit zero; run `mutation doctor`;
65
65
  musubix3 validates evidence and does not bundle a mutation engine.
66
66
  Missing required tools, commands, artifacts or evidence block readiness.
67
67
  5. Use native review/security-review as needed, recording their findings
package/CHANGELOG.md CHANGED
@@ -2,6 +2,49 @@
2
2
 
3
3
  ## Unreleased
4
4
 
5
+ - Parse Surefire/Failsafe `<testcase>` elements correctly when a self-closing
6
+ entry precedes one with `<system-out>`/`<system-err>` children, so JUnit
7
+ identities are no longer dropped or given a neighbouring test's status.
8
+ - Stop counting Java, Kotlin and Scala annotations as calls in Code Graph.
9
+ - Report the offending field and mutant index for invalid schema-v1 mutation
10
+ reports instead of a single opaque message.
11
+ - Explain that superseded TDD cycles are still validated and must be archived
12
+ and regenerated rather than replaced by a newer recording.
13
+ - Label `status` artifact counts as requirement and design files, and document
14
+ the `musubix3/analysis` entry point for `mutationIdentity` plus the
15
+ `.musubix/evidence/native/` location for command-generated reports.
16
+ - Name the configuration key that raises a rejected workflow transcript total or
17
+ line size limit instead of only reporting the exceeded bound.
18
+
19
+ ## 0.1.5 - 2026-09-08
20
+
21
+ - Accept causally ordered concurrent workflow events whose clocks are not
22
+ monotonic by default, while preserving optional policy-bound timestamp skew.
23
+ - Add policy-protected `workflow.maxTranscriptBytes` and
24
+ `workflow.maxTranscriptLineBytes` so streaming sanitization and verification
25
+ can process large real Copilot transcripts without removing resource bounds.
26
+ - Fail structured required test commands that report zero executed tests or
27
+ skipped tests even when the process exits successfully.
28
+ - Diagnose Python trace annotations hidden in docstrings and recommend
29
+ bytecode-free Python mutation/test execution to prevent stale `.pyc` results.
30
+ - Guide broad SDD changes through short reviewable stages rather than requiring
31
+ a single all-inclusive prompt.
32
+
33
+ ## 0.1.4 - 2026-09-08
34
+
35
+ - Measure subprocess durations with a monotonic clock and reject negative or
36
+ non-integer TDD execution durations with `TDD_DURATION_INVALID`.
37
+ - Add `tdd validate` for direct persisted-evidence diagnostics and provide
38
+ safer regeneration guidance for invalid legacy order or duration records.
39
+ - Add `workflow-sanitize` to reduce Copilot JSONL logs to privacy-minimized
40
+ Skill lifecycle and terminal events before strict verification.
41
+ - Accept explicit Japanese EARS subjects such as API/service names plus common
42
+ `時` and `中` control markers, and report bilingual corrective examples.
43
+ - Explain pytest TEST ID naming/project-runner recovery and make policy baseline
44
+ approval diagnostics actionable for new repositories.
45
+ - Document the natural-language-only TypeScript/Python/PostgreSQL experiment
46
+ and its fail-closed repair workflow.
47
+
5
48
  ## 0.1.3 - 2026-09-08
6
49
 
7
50
  - Add a built-in `dotnet` test adapter with xUnit `DisplayName` targeting and
package/README-ja.md CHANGED
@@ -1,14 +1,14 @@
1
1
  # musubix3
2
2
 
3
- **最新リリース v0.1.3 · GitHub Copilot CLI 専用 · Node.js ≥20 · TypeScript · MIT**
3
+ **最新リリース v0.1.4 · GitHub Copilot CLI 専用 · Node.js ≥20 · TypeScript · MIT**
4
4
 
5
5
  [English](README.md)
6
6
 
7
- [musubix2 から musubix3 で変わったこと](MUSUBIX2-TO-MUSUBIX3.md)
7
+ [musubix2 から musubix3 で変わったこと](docs/MUSUBIX2-TO-MUSUBIX3.md)
8
8
 
9
9
  GitHub Copilotは、計画、コード生成、編集、テスト、レビューを実行できます。
10
- musubix3は、その作業を本当に完了と判断するためのrepository-localな仕様と
11
- 決定的な証拠を追加します。
10
+ musubix3は、repository-localな仕様と、設定した品質プロファイルが要求する
11
+ 根拠を決定的かつfail-closedに検査する仕組みを追加します。
12
12
  要求 → 憲章 → 設計・ADR → 実装 → 追跡可能性 → 品質根拠を、
13
13
  8つのSkillsと検証CLIで接続します。
14
14
 
@@ -45,29 +45,32 @@ Copilotは実装を担うエンジンです。要求を理解し、repositoryを
45
45
 
46
46
  musubix3はCopilotを置き換えず、別のcoding agentも追加しません。
47
47
  SATだから実装が正しいとも主張しません。開発はCopilotが実行し、
48
- musubix3は仕様を残し、証拠を検査し、古い・不完全な完了宣言を拒否して、
49
- 「なぜこの変更をreadyと判断できるのか」をreview可能な形でrepositoryへ残します。
48
+ musubix3は仕様を残し、必須証拠を検査し、古い・不完全な必須証拠を拒否して、
49
+ 「なぜ設定したpolicyがこの変更をreadyと判断したのか」をreview可能な形で
50
+ repositoryへ残します。
50
51
 
51
52
  ## クイックスタート
52
53
 
53
- 対象プロジェクトで、公開済みパッケージを実行します。
54
+ 再現可能なproject-local環境として、exact versionを導入します。
54
55
 
55
56
  ```sh
56
- npx musubix3@0.1.3 --version
57
- npx musubix3@0.1.3 init --dry-run
58
- npx musubix3@0.1.3 init
57
+ npm install --save-dev --save-exact musubix3@latest
58
+ npx --no-install musubix3 --version
59
+ npx --no-install musubix3 init --dry-run
60
+ npx --no-install musubix3 init
59
61
  copilot
60
62
  ```
61
63
 
62
- バージョンを固定してプロジェクトへインストールする場合は、次を実行します。
64
+ 継続利用するSkill内CLIのversionを固定しない、単発評価だけなら次を使えます。
63
65
 
64
66
  ```sh
65
- npm install --save-dev --save-exact musubix3@0.1.3
66
- npx --no-install musubix3 --version
67
- npx --no-install musubix3 init --dry-run
68
- npx --no-install musubix3 init
67
+ npx musubix3@latest --version
68
+ npx musubix3@latest init --dry-run
69
69
  ```
70
70
 
71
+ 生成されたSkillsを継続開発で使う前にexact local dependencyを導入してください。
72
+ Skillsのコマンドはrepository-localな`npx --no-install musubix3`を使用します。
73
+
71
74
  リポジトリ自体をビルドする場合は、次を実行します。
72
75
 
73
76
  ```sh
@@ -78,7 +81,8 @@ npm run build
78
81
  node dist/packages/cli/src/main.js --help
79
82
  ```
80
83
 
81
- Copilot に「sdd-requirements でこの機能の要求を定義し、設計を計画して」と依頼します。
84
+ Copilot に「sdd-changeを使ってこの機能を追加し、仕様、実装、追跡可能性、
85
+ 品質ゲートまで一貫して反映して」と依頼します。
82
86
  すべての Skills は入力言語(日本語・英語)に合わせてガイダンスを生成します。
83
87
 
84
88
  `init`(別名 `install`)は Skills と雛形を配置し、既存ファイルを保持します。
@@ -107,7 +111,8 @@ copilot plugin install nahisaho/musubix3
107
111
 
108
112
  `npx musubix3 plugin-install` は `copilot plugin install <package-root>` を実行する
109
113
  だけで、Copilot 内部を編集しません。永続的なローカルパスには
110
- `npm install --save-dev musubix3` と `npx --no-install musubix3 plugin-install` を推奨します。
114
+ `npm install --save-dev --save-exact musubix3@latest` と
115
+ `npx --no-install musubix3 plugin-install` を推奨します。
111
116
  一時的な npx キャッシュのパスに依存しないでください。
112
117
 
113
118
  ### ネイティブマーケットプレイス
@@ -125,7 +130,8 @@ copilot plugin marketplace add ./musubix3
125
130
 
126
131
  ### リポジトリ内 Skills / npm インストーラー
127
132
 
128
- 対象リポジトリで `npx musubix3 init` を実行するか、
133
+ exact local dependencyの導入後に対象リポジトリで
134
+ `npx --no-install musubix3 init`を実行するか、
129
135
  `.github/skills/sdd-*` をコピーし、その信頼済みプロジェクトで Copilot を起動します。
130
136
  `--root <dir>` で対象を指定でき、`--feature <slug>` は雛形のディレクトリ名と
131
137
  ID 接頭辞を変えます。別機能の追加でも既存設定はリセットしません。
@@ -215,8 +221,10 @@ npx musubix3 status --json
215
221
  | `model-correspondence validate` | Formal JSON→生成trace→正本passing testの証拠を再検証 |
216
222
  | `evidence refresh [--changed]` | 同じfail-closed gate pipelineで派生証拠を再生成 |
217
223
  | `mutation validate` | 要求scopeのschema-v1 killed-mutant証拠を再検証 |
224
+ | `tdd validate` | 保存済みRed/Green/Refactorの順序、指紋、実行時間、hash-chainを検証 |
218
225
  | `tdd red\|green\|refactor <TEST-ID> --requirement <REQ-ID> --command <name>` | 検証可能なTDDフェーズを実行・記録 |
219
226
  | `workflow-record <skill> <phase> --status <status>` | 自己申告のworkflow宣言を記録 |
227
+ | `workflow-sanitize <copilot.jsonl> <output-file> [--session-id <uuid>]` | reviewやstrict検証前にmessageとSkill以外のtool dataを除去 |
220
228
  | `workflow-verify <copilot.jsonl> [--strict] [--session-id <uuid>]` | Skillイベントを照合し、任意で完全な成功session transcriptを要求 |
221
229
  | `attestation oidc-audience --key-id <id> [--public-key-file <pem>]` | 署名鍵を許可するGitHub custom audienceを導出 |
222
230
  | `attestation payload --provider <name> --run-id <id> --key-id <id> [--public-key-file <pem>] [--github-oidc-token-file <jwt>]` | 外部署名用の正規化CI payloadを出力 |
@@ -251,7 +259,7 @@ workflow証拠があれば`workflow`、TDD証拠があれば`tdd`が自動的に
251
259
  changes.json # 変更checkpoint
252
260
  order.json # TDD/change共通の単調chronology ledger
253
261
  performance.json # 決定的operation budget観測
254
- model-correspondence.json # Formal model→trace→fresh passing test証明
262
+ model-correspondence.json # Formal model→trace→fresh passing testの対応証拠
255
263
  mutation.json # freshな要求scope mutation実行証拠
256
264
  attestation.json # 任意の外部署名済みCI provenance
257
265
  cache/ # Git除外。索引とsolver入力
@@ -318,6 +326,8 @@ JS/TSはparser-awareなcomment位置を使い、Haskellは`--`と`{- ... -}`、
318
326
  Luaは`--`と`--[[ ... ]]`、Visual Basicは`'''` XML documentを含む
319
327
  apostrophe commentを扱います。これらは文字列中の記載をリンクとして扱いません。
320
328
  その他の言語では対応する行commentまたはblock commentを使用します。
329
+ Pythonは連続した`#` commentを使用してください。docstring内のannotationは無視され、
330
+ `TRACE_ANNOTATION_IN_PYTHON_DOCSTRING`で配置変更を案内します。
321
331
  網羅率だけを満たす代理JS/TSファイルは作成しません。
322
332
 
323
333
  ```ts
@@ -385,7 +395,9 @@ version: 1.0.0
385
395
  "mode": "compatible",
386
396
  "maxAgeSeconds": 3600,
387
397
  "maxFutureSkewSeconds": 60,
388
- "maxEventSkewMs": 1000
398
+ "maxEventSkewMs": 1000,
399
+ "maxTranscriptBytes": 250000000,
400
+ "maxTranscriptLineBytes": 2000000
389
401
  },
390
402
  "attestation": {
391
403
  "mode": "local",
@@ -412,8 +424,9 @@ glob は `*` / `**` / `?` に対応し、外部依存は `npm:` 接頭辞で表
412
424
  含む完全なrelease checkを要求します。不足設定や弱い設定を証拠で補ったことにはしません。
413
425
  `tdd.redPreflightCommands`にはformatter等のplain command名を指定でき、
414
426
  Redのtest fingerprintを取得する前に成功が必須です。
415
- 通常ファイルの`pyvenv.cfg`を含む`.venv`と`venv`はsnapshotと
416
- Code Graphから除外されます。Gradle `.gradle/`、Dart `.dart_tool/`、
427
+ 通常ファイルの`pyvenv.cfg`を含む`.venv`と`venv`に加え、生成された
428
+ `__pycache__/` directoryはsnapshotとCode Graphから除外されます。
429
+ sourceなしで実行可能な`.pyc`/`.pyo`単体fileは追跡対象のままです。Gradle `.gradle/`、Dart `.dart_tool/`、
417
430
  SwiftPM `.build/`、Zig `.zig-cache/`/`zig-out/`、.NET `.dotnet/`は、
418
431
  親directoryに対応manifestがある場合だけ除外されます。同名の任意source
419
432
  directoryは追跡対象のままです。
@@ -446,7 +459,9 @@ strict OIDC identity/key binding、必須コマンド名の最低条件です。
446
459
  介さず、時間と出力サイズを制限して実コマンドを動かします。個別の必須コマンドは
447
460
  集約 `commands` の設定に関係なく失敗・未実行で準備不可になります。
448
461
  任意コマンドの失敗は非阻止ですが、憲章が失敗件数を制限していれば不合格です。
449
- コマンド未設定は skipped です。
462
+ コマンド未設定は skipped です。構造化test commandはprocessがexit 0でも、
463
+ 実行testが0件、またはskipped・failed・error testを1件でも報告した場合は
464
+ 失敗します。integration suiteが依存service不在のまま暗黙に通ることを防ぎます。
450
465
 
451
466
  TDD用コマンドには明示的な`tddArgs`と`tddReport`、または組込みの
452
467
  `vitest`、`jest`、`pytest`、`go-test`、`cargo`、`junit`、`dotnet` adapterが必要です。
@@ -455,6 +470,8 @@ Vitest/Jestの無関係なskipped結果は対象TDDから除外します。pytes
455
470
  `test_TEST_APP_001`形式、Goには`TEST-*`名のsubtest、Cargoには`test_app_001`形式、
456
471
  JUnitには正確な`@Tag("TEST-APP-001")`と、IDを含むmethod名または`@DisplayName`を推奨します。
457
472
  正規化処理はtestcase属性とJUnit Platformのdisplay-name出力の両方を読み取り、
473
+ Surefire/Failsafeのtestcase要素は自己終了形でも`<system-out>`/`<system-err>`を
474
+ 含む形でも解析するため、Spring Bootのbanner等のlog出力で合格IDが欠落しません。
458
475
  xUnitには`[Fact(DisplayName = "TEST-APP-001 ...")]`が必要です。
459
476
  それぞれXMLまたはTRX report directoryを読み取ります。各フェーズ前に旧レポートを削除し、
460
477
  必要なreport親directoryを作成して、対象テストだけを含むfreshな `musubix-json` を要求します。Redは `failed`、
@@ -504,6 +521,9 @@ freshなschema-v1 mutantは、決定的`MUT-<hash>` identity、must functional r
504
521
  設定driftを拒否します。既定の`compatible`は証拠なしを許容し、releaseでは`strict`と
505
522
  mutation commandをpolicy baselineで保護します。大規模mutation engineは同梱しません。
506
523
  mutation/model-correspondenceのsemantic headはattestationに含まれ、元のprovenanceも再検査されます。
524
+ Pythonではstaleな`.pyc`によるfalse survivorを防ぐため、`mutation doctor`は
525
+ 各run前の`__pycache__`削除と、その後の`python -B -m mutmut`および
526
+ `python -B -m pytest`を推奨します。
507
527
 
508
528
  品質根拠は状態、必須フラグ、終了コード・出力、実測値、日時、入力の指紋を保存します。
509
529
  変更ゲートのパス、HEAD、影響範囲は後続の通常ゲートでも保持します。
@@ -511,6 +531,8 @@ mutation/model-correspondenceのsemantic headはattestationに含まれ、元の
511
531
  `workflow-verify` はCopilot JSONLからSkill発火メタデータだけを取り込み、完了宣言ごとに
512
532
  異なる成功完了tool callを順序付きで1対1対応させます。未完了、失敗、再利用、順序違反、
513
533
  後からの宣言変更は失敗です。
534
+ 元transcriptにmessage、Skill以外のtool引数、outputが含まれる場合は、
535
+ review evidenceへ入れる前に`workflow-sanitize`で必要最小限へ変換します。
514
536
  したがって各Skill発火は最終workflow outcomeを1件だけ記録し、複数phaseのchronologyは
515
537
  重複workflow eventではなく`change-record`に記録します。
516
538
  `"workflow":{"mode":"strict"}`または`--strict`では、全非空行のJSON、
@@ -520,12 +542,20 @@ event数、terminal時刻、raw source hash、canonical transcript hashを保存
520
542
  `workflow.expectedSessionId`または`--session-id`でcaller申告sessionの置換を拒否します。
521
543
  strict検証は`workflow.maxAgeSeconds`と`workflow.maxFutureSkewSeconds`で
522
544
  terminal transcriptの古さと未来方向clock skewも制限します。
523
- 並行eventはtimestamp順で出力されない場合があるため、全体sortではなくtool/resultの
524
- 因果順序を検査します。
545
+ 並行eventや異なる実行clockのtimestampは単調にならない場合があるため、JSONLの
546
+ source順でtool/resultの因果関係を検査し、timestamp sortは行いません。
547
+ pair/terminalのclock skewは`maxEventSkewMs`を明示した場合だけ制限し、
548
+ terminalの古さ・未来skew policyは独立して検査します。検証はstreamingかつresource-boundで、
549
+ 既定上限は100,000,000 bytesです。大きな実transcriptには`workflow.maxTranscriptBytes`を
550
+ 最大1,000,000,000 bytesまで明示設定できます。1 JSONL行は既定1,000,000 bytesで、
551
+ `workflow.maxTranscriptLineBytes`により最大10,000,000 bytesまで設定できます。
552
+ 選択した両上限はpolicy baselineで保護できます。
525
553
  gate実行中に入力が変わった場合、`input-stability`は追加・変更・削除された各pathと
526
554
  前後のSHA-256を報告します。Cargo/Mavenの標準`target/`、manifest直下の
527
555
  .NET `bin/`と`obj/`、project-local `.nuget/packages/`は除外しますが、
528
- source相当の生成入力はfail-closedのままです。組込みadapterは対象test選択とreport引数を
556
+ source相当の生成入力はfail-closedのままです。コマンドが生成するreportは
557
+ 追跡対象のsource treeではなく`.musubix/evidence/native/`配下へ出力してください。
558
+ gate中に自身のreportを書き込むとinput stabilityが失敗します。組込みadapterは対象test選択とreport引数を
529
559
  所有します。Cargo/Goの既存設定にある先頭`test`は安全に統合し、
530
560
  `--json-report`など競合するreport引数は早期拒否します。
531
561
  実行中の入力変更は失敗、その後の変更は `status` で stale になります。
@@ -568,10 +598,13 @@ skipped/unsigned-localではなくfailed/missingとして報告します。
568
598
  }
569
599
  ```
570
600
 
571
- Ed25519鍵はmusubix3外で生成し、公開PEMだけを`attestation oidc-audience`へ渡します。
601
+ 通常のCLI利用ではEd25519鍵をmusubix3外で生成し、公開PEMだけを
602
+ `attestation oidc-audience`へ渡します。
572
603
  その完全一致audienceでGitHub Actions OIDC tokenを要求し、公開PEMとJWT fileを
573
- `attestation payload`へ渡して、出力payloadを外部で署名します。musubix3は秘密鍵を
574
- 読み取りも保存もしません。短命JWTは署名済みattestationに含まれ、現在時刻で期限を
604
+ `attestation payload`へ渡して、出力payloadを外部で署名します。`musubix3` CLIは
605
+ 秘密鍵を受け取らず、読み取りも保存もしません。このrepositoryのrelease専用automationは
606
+ 別途ephemeral private keyを無視対象の`.test-work`内に生成して署名へ使用し、
607
+ CLI検証を呼び出す前に削除します。短命JWTは署名済みattestationに含まれ、現在時刻で期限を
575
608
  検査するため、有効期間内に検証する必要があります。これはGitHub OIDC identityが
576
609
  署名鍵と記載claimを認可したことを示しますが、runnerの任意動作やworkflowの意味的正しさ
577
610
  までは証明しません。workflow evidence headは別途transcript/sessionを署名へ束縛します。
@@ -622,8 +655,10 @@ Ed25519鍵はmusubix3外で生成し、公開PEMだけを`attestation oidc-audie
622
655
  日本語は文字 bigram。Git 根拠は最大100コミット・各30ファイルで、共変更は相関、
623
656
  著者別ディレクトリ件数は貢献の記録であって因果や専門性ではありません。
624
657
  履歴がない場合は明示的に skipped。外部サービスへは送信しません。
625
- - Node 20 と Node 24(現行LTS)をCI対象とし、Linuxで検証します。
626
- Windowsの実行ラッパー・プロセスツリー停止はRC保証対象外です。
658
+ - Core CIはNode 22をLinux、Windows、macOSで実行し、LinuxではNode 20と
659
+ Node 24の互換性も追加確認します。native adapterとformal solverの統合は、
660
+ 固定toolchainを使ってLinuxで実行します。
661
+ Windowsの実行ラッパーとprocess tree停止にはplatform固有の差があります。
627
662
  ESLintは追加せず、strict TypeScript と既存テストで検証します。
628
663
 
629
664
  ## 開発・リリース検査
@@ -641,9 +676,29 @@ npm run pack:smoke
641
676
  `packages/domain` は純粋な検証、`packages/analysis` は根拠・コンパイラ・
642
677
  ファイルシステム、`packages/cli` はコマンドと配置を担当します。
643
678
  ビルド出力は `dist/packages/**`。npm パッケージには隠しSkills、プラグイン定義、
644
- CLI、モジュール、雛形が明示的に含まれます。CI は Node 20/24 を検証します。
679
+ CLI、モジュール、雛形が明示的に含まれます。Core CIはNode 22をLinux、Windows、
680
+ macOSで実行し、LinuxではNode 20/24の互換性も検証します。native adapterと
681
+ formal solverは固定toolchainを使ってLinuxで統合検証します。
645
682
  `pack:smoke` は実際のtarballを `.test-work/` 内の独立した利用側プロジェクトへ
646
683
  導入し、実行ファイル・ESM export・配置を確認してから削除します。
647
684
  attestation APIは`musubix3/analysis`と専用`musubix3/attestation` exportの
648
685
  両方から利用できます。
686
+
687
+ `v*` tagは`.github/workflows/release.yml`を起動します。workflowはtagと
688
+ package/plugin versionの一致を検証し、Linux上のnative/formal suiteを実行して、
689
+ npm tarball、CycloneDX SBOM、SHA256SUMS、GitHub Releaseを生成します。
690
+ `npm publish --provenance --access public`は保護された`npm-publish` environmentで
691
+ 別途承認されます。npm Trusted Publishingを優先し、任意の`NPM_TOKEN` environment
692
+ secretも利用できます。npm publishがpendingまたは失敗してもGitHub Release作成結果を
693
+ 成功に見せかけず、各jobの状態を独立して確認できます。手動実行ではrelease tagを
694
+ workflow refとして選び、同じ値を`release_tag`へ指定します。tagがOIDCに束縛された
695
+ `GITHUB_SHA`を指していなければworkflowは拒否します。
696
+
697
+ release attestationは、ephemeral Ed25519公開鍵をcustom audienceへ束縛した
698
+ GitHub Actions OIDC tokenを使用します。署名対象にはrepository、Git commit、
699
+ run ID、workflow/ref identity、workspace snapshot、存在するmusubix evidence headが
700
+ 含まれます。release automationは`.test-work`内のprivate keyで署名した後、
701
+ CLI検証前に削除し、署名済みattestationだけをuploadします。署名だけでtest semanticsが
702
+ 正しいとは主張せず、testとsolverは先行するrelease validation jobで検査します。
703
+
649
704
  [CONTRIBUTING.md](CONTRIBUTING.md) と [CHANGELOG.md](CHANGELOG.md) も参照してください。