phase29aj(p0): expose planner outcome facts for strict observability

This commit is contained in:
2025-12-29 12:17:57 +09:00
parent 2e1bb938b4
commit 5988374ecf
11 changed files with 187 additions and 48 deletions

View File

@ -17,7 +17,7 @@ Goal: promotion hint が付与されている事実を stable tag で固定し
## Implementation Steps
### Step 1: タグ出力を追加planner採用時のみ
### Step 1: タグ出力を追加planner outcome 参照
ファイル:
- `src/mir/builder/control_flow/plan/single_planner/rules.rs`
@ -25,10 +25,13 @@ Goal: promotion hint が付与されている事実を stable tag で固定し
実装位置:
- `try_build_domain_plan()``if let Some(domain_plan) = plan_opt { ... }` 直前付近
補足:
- planner outcome は `build_plan_with_facts()` の結果を使い、facts 直抽出はしない
ガード条件(全部満たすときだけ出す):
- `entry.kind``RuleKind::Pattern2`
- `crate::config::env::joinir_strict_enabled()` が true
- `Pattern2LoopBodyLocalFacts` が取れるplanner 由来の promotion か、facts 直抽出)
- `crate::config::env::joinir_dev::strict_enabled()` が true
- `build_plan_with_facts()` の outcome から `Pattern2LoopBodyLocalFacts` が取れる
出力するタグstderr 推奨、1行固定:
- TrimSeg: `[plan/pattern2/promotion_hint:TrimSeg]`
@ -36,6 +39,7 @@ Goal: promotion hint が付与されている事実を stable tag で固定し
注意:
- `trace::trace()``filter_noise()` で落ちるので `eprintln!` を使う
- facts 直抽出は禁止planner outcome だけを参照する)
### Step 2: integration smoke をタグ検証に昇格

View File

@ -95,7 +95,7 @@ Goal: pattern 名による分岐を外部APIから消し、Facts事実
- 指示書: `docs/development/current/main/phases/phase-29ai/P15-OBSERVE-PATTERN2-PROMOTION_HINT-INSTRUCTIONS.md`
- ねらい: strict/dev のときだけ promotion hint を安定タグで観測できるようにする(挙動不変)
- 完了: LoopBodyLocal facts が取れたときに `[plan/pattern2/promotion_hint:{TrimSeg|DigitPos}]` を出力し、2 本をタグ検証に昇格
- 完了: planner outcome から LoopBodyLocal facts を参照して `[plan/pattern2/promotion_hint:{TrimSeg|DigitPos}]` を出力し、2 本をタグ検証に昇格
- 検証: `cargo build --release` / `./tools/smokes/v2/run.sh --profile quick` / `./tools/smokes/v2/profiles/integration/joinir/phase29ae_regression_pack_vm.sh`
## Verification (SSOT)