ARCH: приоритизировать discovery-period в planner follow-up

This commit is contained in:
2026-04-22 17:49:09 +03:00
parent bd58ab490f
commit dca49ef4e1
4 changed files with 178 additions and 6 deletions
@@ -192,6 +192,44 @@ describe("assistantContinuityPolicy organization authority", () => {
});
});
it("prefers grounded discovery date scope over stale exact-route date filters in carryover", () => {
const debug = {
execution_lane: "address_query",
extracted_filters: {
counterparty: "Группа СВК",
period_to: "2026-04-22"
},
mcp_discovery_response_applied: true,
assistant_mcp_discovery_entry_point_v1: {
schema_version: "assistant_mcp_discovery_runtime_entry_point_v1",
entry_status: "bridge_executed",
turn_input: {
turn_meaning_ref: {
asked_action_family: "payout",
explicit_entity_candidates: ["Группа СВК"],
explicit_date_scope: "2020"
}
},
bridge: {
bridge_status: "answer_draft_ready",
business_fact_answer_allowed: true,
pilot: {
pilot_scope: "counterparty_supplier_payout_query_movements_v1"
},
answer_draft: {
answer_mode: "confirmed_with_bounded_inference"
}
}
}
};
expect(resolveAddressDebugCarryoverFilters(debug)).toEqual({
counterparty: "Группа СВК",
period_from: "2020-01-01",
period_to: "2020-12-31"
});
});
it("prefers the resolved entity from grounded entity-resolution discovery for counterparty carryover", () => {
const debug = {
execution_lane: "living_chat",