Архитектура: закрыть phase17 clarification-resume и обновить readiness-статус перед расширением доменов
This commit is contained in:
@@ -419,7 +419,10 @@ export function createAssistantTransitionPolicy(deps) {
|
||||
const hasOrganizationClarificationContinuation = Boolean(
|
||||
lastOrganizationClarificationDebug && organizationClarificationSelection
|
||||
);
|
||||
const followupOffer = previousAddressDebug ? deps.buildAddressFollowupOffer(previousAddressDebug) : null;
|
||||
const carryoverSourceDebug =
|
||||
previousAddressDebug ??
|
||||
(hasOrganizationClarificationContinuation ? lastOrganizationClarificationDebug : null);
|
||||
const followupOffer = carryoverSourceDebug ? deps.buildAddressFollowupOffer(carryoverSourceDebug) : null;
|
||||
const hasImplicitContinuationSignal =
|
||||
Boolean(previousAddressDebug) &&
|
||||
Boolean(followupOffer?.enabled) &&
|
||||
@@ -427,7 +430,7 @@ export function createAssistantTransitionPolicy(deps) {
|
||||
(deps.toNonEmptyString(alternateMessage)
|
||||
? deps.isImplicitAddressContinuationByLlm(alternateMessage, llmPreDecomposeMeta)
|
||||
: false));
|
||||
const sourceIntentHint = deps.toNonEmptyString(previousAddressDebug?.detected_intent);
|
||||
const sourceIntentHint = deps.toNonEmptyString(carryoverSourceDebug?.detected_intent);
|
||||
const navigationFocusObjectHint =
|
||||
addressNavigationState &&
|
||||
typeof addressNavigationState === "object" &&
|
||||
@@ -560,10 +563,10 @@ export function createAssistantTransitionPolicy(deps) {
|
||||
) {
|
||||
return null;
|
||||
}
|
||||
if (!previousAddressDebug) {
|
||||
if (!carryoverSourceDebug) {
|
||||
return null;
|
||||
}
|
||||
const sourceIntent = deps.toNonEmptyString(previousAddressDebug.detected_intent);
|
||||
const sourceIntent = deps.toNonEmptyString(carryoverSourceDebug.detected_intent);
|
||||
const llmExplicitIntent = deps.toNonEmptyString(llmPreDecomposeMeta?.predecomposeContract?.intent);
|
||||
const llmSelectedObjectScopeDetected =
|
||||
llmPreDecomposeMeta?.predecomposeContract?.semantics?.selected_object_scope_detected === true;
|
||||
@@ -637,7 +640,7 @@ export function createAssistantTransitionPolicy(deps) {
|
||||
followupSelectionMode = "switch_to_suggested_intent";
|
||||
}
|
||||
}
|
||||
const previousAnchorContext = resolveAddressDebugAnchorContext(previousAddressDebug, deps.toNonEmptyString);
|
||||
const previousAnchorContext = resolveAddressDebugAnchorContext(carryoverSourceDebug, deps.toNonEmptyString);
|
||||
let previousAnchorType = previousAnchorContext.anchorType;
|
||||
let previousAnchor = previousAnchorContext.anchorValue;
|
||||
const navigationSessionContext =
|
||||
@@ -723,7 +726,7 @@ export function createAssistantTransitionPolicy(deps) {
|
||||
);
|
||||
let resolvedCounterpartyFromDisplay = false;
|
||||
let displayedEntityTargetIntent = null;
|
||||
let previousFilters = resolveAddressDebugCarryoverFilters(previousAddressDebug, deps.toNonEmptyString);
|
||||
let previousFilters = resolveAddressDebugCarryoverFilters(carryoverSourceDebug, deps.toNonEmptyString);
|
||||
const shouldBackfillHistoricalPartyAnchors =
|
||||
sourceIntentHint === "list_contracts_by_counterparty" ||
|
||||
sourceIntentHint === "list_documents_by_counterparty" ||
|
||||
@@ -754,12 +757,12 @@ export function createAssistantTransitionPolicy(deps) {
|
||||
if (inventoryPurchaseDateVatBridge) {
|
||||
const purchaseBridgeItem =
|
||||
previousAddressItem &&
|
||||
deps.toNonEmptyString(previousAddressDebug?.detected_intent) === "inventory_purchase_provenance_for_item"
|
||||
deps.toNonEmptyString(carryoverSourceDebug?.detected_intent) === "inventory_purchase_provenance_for_item"
|
||||
? previousAddressItem
|
||||
: findRecentInventoryPurchaseProvenanceItem(
|
||||
items,
|
||||
deps.toNonEmptyString(navigationFocusObjectLabel) ??
|
||||
readAddressDebugItem(previousAddressDebug, deps.toNonEmptyString) ??
|
||||
readAddressDebugItem(carryoverSourceDebug, deps.toNonEmptyString) ??
|
||||
deps.toNonEmptyString(previousFilters.item)
|
||||
) ?? previousAddressItem;
|
||||
const purchaseBridgeWindow = extractPurchaseDateBridgeWindow(purchaseBridgeItem, addressNavigationState);
|
||||
|
||||
Reference in New Issue
Block a user