АРЧ АП11 - Архитектура после регресса: Архитектура: сохранить свежую дату при inventory root restore и очистить data-scope ответы от грязных лейблов

This commit is contained in:
2026-04-18 09:12:39 +03:00
parent a5ea9adf53
commit 0431595542
24 changed files with 1030 additions and 58 deletions
@@ -145,6 +145,39 @@ Still open after this pass:
- mixed continuity is now strong enough for the current phase7 gate, but it still needs broader saved-session proof before domain expansion can be treated as low-risk;
- the next architecture pass should move from one repaired mixed replay to a wider saved-session set and multi-domain acceptance pack;
- remaining work should focus on keeping the unified continuity authority stable under new real user paths, not on wording-only polish or isolated route greens.
- company authority is still not proactive enough at root inventory entry in multi-company sessions without an already grounded active organization;
- the next stabilization slice should prefer system-level company authority handling over repeated local clarification templates when the session has enough business context.
Completed in the current follow-up pass:
- direct company activity-age wording like `а по Альтернативе Плюс сколько лет активности в базе 1С?` is now protected by a unicode-safe exact signal instead of depending on mojibake-sensitive legacy lifecycle phrases;
- capability meta answers now explain supported business groups through human examples instead of leaking internal operation ids like `vat_period_snapshot`, `inventory_on_hand_as_of_date`, `explain_boundary`, or `suggest_safe_next_step`;
- the next proof target after unit/build checks is the live phase5 replay, because it exercises both the restored activity-age path and the capability-meta interrupt in one shared session.
Latest live replay evidence after that proof run:
- the capability meta interrupt is now business-first and no longer leaks internal operation ids in the top block;
- the same replay exposed a stricter continuity defect that the top-level review initially missed: organization identity can drift in session state as a damaged live label like `ООО \\Альтернати"а Плюс\\`;
- when that happens, the runtime keeps both `organization` and a stale `counterparty` anchor, does not emit `counterparty_cleared_for_selected_organization_activity`, and falls into `counterparty_anchor_not_matched_in_materialized_rows`;
- this is a system-level organization-identity robustness gap between data-scope probing, continuity memory, and exact-route truth gating, not a wording-only prompt defect;
- the current stabilization slice therefore includes hardening organization identity matching itself and rerunning the same live pack until step-level human answers and review verdicts align.
Latest phase8 runtime authority evidence after the manual mixed replay hardening:
- live replay `address_truth_harness_phase8_manual_runtime_authority_mix_live_20260417_rerun1` proved that the activity-age route was restored, but also exposed a hidden false-green: `step_11_inventory_same_date_after_receivables` silently reused stale inventory-root date `2021-03-31` instead of the freshest receivables date `2020-03-31`;
- the first fix in `assistantService` was not sufficient on its own, because `decomposeStage` still rebuilt `inventory_root` follow-up context by overwriting `previous_filters` from `root_filters` wholesale;
- the architectural correction was to preserve `root` authority for organization / warehouse while preserving the freshest temporal scope (`as_of_date`, `period_from`, `period_to`) from the immediately previous grounded step;
- this was locked by direct regressions in `assistantTransitionPolicy.test.ts` and `addressInventoryRootFrameRegression.test.ts`, plus a live rerun against the same manual replay spec;
- live replay `address_truth_harness_phase8_manual_runtime_authority_mix_live_20260417_rerun4` is now accepted end-to-end with `14/14` steps green, including:
- `step_07_capability_meta` with business-first human wording;
- `step_11_inventory_same_date_after_receivables` on the correct date `31.03.2020`;
- `step_14_company_activity_age` with restored factual lifecycle answer;
- cleaned user-facing company labels in the data-scope meta reply (`ООО Альтернатива Плюс`, `ООО Лайсвуд`, `РАЙМ`) instead of damaged raw probe labels.
Still open after the accepted phase8 replay:
- proactive organization authority at the very beginning of a new multi-company bookkeeping session is still weaker than the target product feel; the current system now clarifies honestly and cleanly, but it does not yet always pre-offer company selection early in the conversational flow;
- some user-facing inventory/counterparty labels inside business answers still deserve final presentation cleanup, but these are now post-stabilization quality refinements rather than continuity-authority blockers.
## Ready Signal