@tutti-os/agent-gui 0.0.193 → 0.0.194

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.
@@ -2,7 +2,7 @@ import * as react from 'react';
2
2
  import { ReactNode, Ref, JSX } from 'react';
3
3
  import { c as AgentConversationVM, g as WorkspaceLinkAction, f as WorkspaceAgentSessionDetailViewModel } from '../workspaceLinkActions-BmVLZszV.js';
4
4
  export { B as BuildWorkspaceAgentSessionDetailInput, W as WorkspaceAgentActivityCard, e as WorkspaceAgentActivityTimelineItem, h as buildWorkspaceAgentSessionDetailViewModel } from '../workspaceLinkActions-BmVLZszV.js';
5
- import { d as AgentGUIProviderSkillOption, h as AgentMessageMarkdownWorkspaceAppIcon } from '../agentGuiNodeTypes-B23ubO8n.js';
5
+ import { d as AgentGUIProviderSkillOption, h as AgentMessageMarkdownWorkspaceAppIcon } from '../agentGuiNodeTypes-CAdPKW7W.js';
6
6
  import { AgentActivityMessage } from '@tutti-os/agent-activity-core';
7
7
  import '@tutti-os/workspace-issue-manager/core';
8
8
  import '../types-CWKbqBmi.js';
@@ -3,7 +3,7 @@ import { ReactNode } from 'react';
3
3
  import { I18nRuntime } from '@tutti-os/ui-i18n-runtime';
4
4
  import { AgentActivityGoalControlInput, AgentActivityGoalControlResult, AgentActivityCreateSessionInput, AgentActivitySession, AgentActivityDeleteSessionInput, AgentActivityDeleteSessionResult, AgentActivitySendInput, AgentActivitySessionSettings, AgentActivityActivateSessionResult, AgentActivityUpdateTuttiModeActivationInput, AgentActivityUpdateTuttiModeActivationResult, AgentActivitySnapshot, AgentSessionEngine, AgentActivityMessageOrder, AgentActivityMessagePage, AgentActivitySendInputResult, AgentActivityRenameSessionInput, AgentActivitySetCollaborationAdoptionInput, AgentActivityCollaborationRun, AgentActivitySubmitInteractiveInput, AgentActivitySubmitInteractiveResult, AgentActivitySnapshotListener, AgentActivitySubmitSettingsPatch } from '@tutti-os/agent-activity-core';
5
5
  import { k as AgentHostAgentSessionComposerSettings, o as AgentHostUnactivateAgentSessionResult, b as AgentGUIAgentTarget, f as AgentGUIProvider, p as AgentPromptContentBlock, e as AgentGUINodeData, P as Point, g as AgentGUIProviderRailAllPresentation, h as AgentGUIProviderRailMode, i as AgentGUIProviderReadinessGate, d as AgentGUIHomeSuggestionId, N as NodeFrame, a as AgentGUIAgentDirectorySnapshot, c as AgentGUIAllAgentsPresentation } from './types-CWKbqBmi.js';
6
- import { A as AgentComposerDraft, i as AgentSessionCommand, d as AgentGUIProviderSkillOption, b as AgentGUIComposerSettingsVM, e as AgentGUIQueueStatus, f as AgentGUIQueuedPromptVM, h as AgentMessageMarkdownWorkspaceAppIcon, j as AgentSlashCommandCapability, c as AgentGUINodeViewModel, a as AgentComposerDraftFile, k as AgentUsageQuota, g as AgentHostInputApi } from './agentGuiNodeTypes-B23ubO8n.js';
6
+ import { A as AgentComposerDraft, i as AgentSessionCommand, d as AgentGUIProviderSkillOption, b as AgentGUIComposerSettingsVM, e as AgentGUIQueueStatus, f as AgentGUIQueuedPromptVM, h as AgentMessageMarkdownWorkspaceAppIcon, j as AgentSlashCommandCapability, c as AgentGUINodeViewModel, a as AgentComposerDraftFile, k as AgentUsageQuota, g as AgentHostInputApi } from './agentGuiNodeTypes-CAdPKW7W.js';
7
7
  import { WorkspaceFileReference, ReferenceLocateTarget, WorkspaceFileReferenceAdapter, ReferenceProvenanceCatalog } from '@tutti-os/workspace-file-reference/contracts';
8
8
  export { ReferenceProvenanceCatalog as AgentGUIReferenceProvenanceFilterCatalog } from '@tutti-os/workspace-file-reference/contracts';
9
9
  import { A as AgentContextMentionItem } from './agentFileMentionContracts-B0yQizXB.js';
package/dist/agent-gui.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  AgentGUI
3
- } from "./chunk-CUIJXYHG.js";
3
+ } from "./chunk-U3ZWUTTQ.js";
4
4
  import "./chunk-LB4AGT7B.js";
5
5
  import "./chunk-A4WCTHWS.js";
6
6
  import "./chunk-L3YCXXMA.js";
@@ -709,6 +709,7 @@ interface AgentGUIQueuedPromptVM {
709
709
  }
710
710
  type AgentGUIQueueStatus = "active" | "paused_by_user";
711
711
  interface AgentGUIShellViewModel {
712
+ nodeId?: string | null;
712
713
  workspaceId: string;
713
714
  workspacePath?: string | null;
714
715
  currentUserId?: string | null;
@@ -10459,6 +10459,7 @@ function useAgentGUIViewModel(candidate) {
10459
10459
  [
10460
10460
  candidate.shell.currentUserId,
10461
10461
  candidate.shell.data,
10462
+ candidate.shell.nodeId,
10462
10463
  candidate.shell.workspaceId,
10463
10464
  candidate.shell.workspacePath
10464
10465
  ]
@@ -12438,6 +12439,7 @@ function useAgentGUIViewAssembly(input) {
12438
12439
  });
12439
12440
  const viewModel = useAgentGUIViewModel({
12440
12441
  shell: {
12442
+ nodeId: input.nodeId?.trim() || null,
12441
12443
  workspaceId: input.workspaceId,
12442
12444
  workspacePath: input.workspacePath,
12443
12445
  currentUserId: input.currentUserId,
@@ -14023,6 +14025,7 @@ function useAgentGUINodeController({
14023
14025
  isLoadingConversations,
14024
14026
  isLoadingMessages,
14025
14027
  normalizedComingSoonProviders,
14028
+ nodeId,
14026
14029
  operationActions,
14027
14030
  persistActiveConversation,
14028
14031
  planImplementationTurnIdRef,
@@ -34881,27 +34884,63 @@ import { useEffect as useEffect31, useMemo as useMemo40, useRef as useRef48 } fr
34881
34884
  // agent-gui/agentGuiNode/controller/agentGuiConversationRailDiagnostics.ts
34882
34885
  var CONVERSATION_RAIL_SLOW_DIAGNOSTIC_THRESHOLD_MS = 250;
34883
34886
  var ConversationRailProviderSwitchDiagnosticTracker = class {
34884
- constructor(diagnosticLogger, now, workspaceId) {
34887
+ constructor(diagnosticLogger, now, context, slowThresholdMs) {
34885
34888
  this.diagnosticLogger = diagnosticLogger;
34886
34889
  this.now = now;
34887
- this.workspaceId = workspaceId;
34890
+ this.context = context;
34891
+ this.slowThresholdMs = slowThresholdMs;
34888
34892
  }
34889
34893
  diagnosticLogger;
34890
34894
  now;
34891
- workspaceId;
34895
+ context;
34896
+ slowThresholdMs;
34892
34897
  pending = null;
34893
34898
  configure(input) {
34894
34899
  if (input.nextScopeKey !== input.previousScopeKey && this.pending?.scopeKey !== input.nextScopeKey) {
34900
+ if (this.pending) {
34901
+ emitConversationRailScopeChangeDiagnostic({
34902
+ ...this.pending,
34903
+ ...this.context,
34904
+ controllerApplyMs: 0,
34905
+ diagnosticLogger: this.diagnosticLogger,
34906
+ durationMs: Math.max(0, this.now() - this.pending.startedAtMs),
34907
+ requestId: null,
34908
+ requestMs: 0,
34909
+ returnedSessionCount: 0,
34910
+ returnedSessionIds: [],
34911
+ sectionCount: 0,
34912
+ status: "superseded"
34913
+ });
34914
+ }
34895
34915
  this.pending = null;
34896
34916
  }
34897
- if (input.attached && input.nextScopeKey !== input.previousScopeKey && input.previousScopeKey !== null && input.previousAgentTargetId !== input.nextAgentTargetId) {
34917
+ if (input.attached && input.nextScopeKey !== input.previousScopeKey && input.previousScopeKey !== null) {
34898
34918
  this.pending = {
34899
- cacheStatus: "miss",
34919
+ activeConversationId: input.activeConversationId,
34920
+ cacheStatus: "unknown",
34900
34921
  fromAgentTargetId: input.previousAgentTargetId || null,
34922
+ fromFilterKind: input.previousFilterKind,
34923
+ preservedSectionCount: input.preservedSectionCount,
34924
+ preservedSessionIds: input.preservedSessionIds,
34925
+ retainedPreviousSections: input.retainedPreviousSections,
34901
34926
  scopeKey: input.nextScopeKey,
34902
34927
  startedAtMs: this.now(),
34903
- toAgentTargetId: input.nextAgentTargetId || null
34928
+ toAgentTargetId: input.nextAgentTargetId || null,
34929
+ toFilterKind: input.nextFilterKind
34904
34930
  };
34931
+ emitConversationRailScopeChangeDiagnostic({
34932
+ ...this.pending,
34933
+ ...this.context,
34934
+ controllerApplyMs: 0,
34935
+ diagnosticLogger: this.diagnosticLogger,
34936
+ durationMs: 0,
34937
+ requestId: null,
34938
+ requestMs: 0,
34939
+ returnedSessionCount: 0,
34940
+ returnedSessionIds: [],
34941
+ sectionCount: 0,
34942
+ status: "pending"
34943
+ });
34905
34944
  }
34906
34945
  }
34907
34946
  hasPending(scopeKey) {
@@ -34916,16 +34955,140 @@ var ConversationRailProviderSwitchDiagnosticTracker = class {
34916
34955
  const pending = this.pending;
34917
34956
  if (!pending || pending.scopeKey !== scopeKey) return;
34918
34957
  this.pending = null;
34919
- emitConversationRailProviderSwitchDiagnostic({
34958
+ emitConversationRailScopeChangeDiagnostic({
34959
+ ...pending,
34920
34960
  ...result,
34961
+ ...this.context,
34921
34962
  diagnosticLogger: this.diagnosticLogger,
34922
34963
  durationMs: Math.max(0, this.now() - pending.startedAtMs),
34923
- fromAgentTargetId: pending.fromAgentTargetId,
34924
- toAgentTargetId: pending.toAgentTargetId,
34925
- workspaceId: this.workspaceId
34964
+ status: result.status
34965
+ });
34966
+ if (pending.fromAgentTargetId !== pending.toAgentTargetId) {
34967
+ emitConversationRailProviderSwitchDiagnostic({
34968
+ ...result,
34969
+ ...this.context,
34970
+ diagnosticLogger: this.diagnosticLogger,
34971
+ durationMs: Math.max(0, this.now() - pending.startedAtMs),
34972
+ fromAgentTargetId: pending.fromAgentTargetId,
34973
+ toAgentTargetId: pending.toAgentTargetId
34974
+ });
34975
+ }
34976
+ }
34977
+ completeFirstPages(scopeKey, input) {
34978
+ const controllerApplyMs = Math.max(
34979
+ 0,
34980
+ input.completedAt - input.requestResolvedAt
34981
+ );
34982
+ const requestMs = Math.max(
34983
+ 0,
34984
+ input.requestResolvedAt - input.requestStartedAt
34985
+ );
34986
+ const returnedSessionIds = conversationRailQuerySessionIds(
34987
+ input.query.queryState
34988
+ );
34989
+ this.complete(scopeKey, {
34990
+ cacheStatus: input.cacheStatus,
34991
+ controllerApplyMs,
34992
+ requestId: input.requestId,
34993
+ requestMs,
34994
+ returnedSessionIds,
34995
+ returnedSessionCount: input.query.returnedSessionCount,
34996
+ sectionCount: input.query.sectionCount,
34997
+ status: "ready"
34998
+ });
34999
+ emitConversationRailFirstPagesDiagnostic({
35000
+ agentTargetId: input.agentTargetId,
35001
+ controllerApplyMs,
35002
+ diagnosticLogger: this.diagnosticLogger,
35003
+ diagnosticSlowThresholdMs: this.slowThresholdMs,
35004
+ durationMs: Math.max(0, input.completedAt - input.requestStartedAt),
35005
+ requestId: input.requestId,
35006
+ requestMs,
35007
+ refreshReason: input.refreshReason,
35008
+ returnedSessionIds,
35009
+ returnedSessionCount: input.query.returnedSessionCount,
35010
+ ...this.context,
35011
+ sectionCount: input.query.sectionCount,
35012
+ status: "ready"
35013
+ });
35014
+ }
35015
+ completeCachedFirstPages(scopeKey, input) {
35016
+ this.complete(scopeKey, {
35017
+ cacheStatus: "fresh",
35018
+ controllerApplyMs: input.controllerApplyMs,
35019
+ requestId: null,
35020
+ requestMs: 0,
35021
+ returnedSessionIds: conversationRailQuerySessionIds(
35022
+ input.query.queryState
35023
+ ),
35024
+ returnedSessionCount: input.query.returnedSessionCount,
35025
+ sectionCount: input.query.sectionCount,
35026
+ status: "ready"
35027
+ });
35028
+ }
35029
+ failFirstPages(scopeKey, input) {
35030
+ const requestMs = Math.max(0, input.failedAt - input.requestStartedAt);
35031
+ this.complete(scopeKey, {
35032
+ cacheStatus: input.cacheStatus,
35033
+ controllerApplyMs: 0,
35034
+ error: input.error,
35035
+ requestId: input.requestId,
35036
+ requestMs,
35037
+ returnedSessionIds: [],
35038
+ returnedSessionCount: 0,
35039
+ sectionCount: 0,
35040
+ status: "error"
35041
+ });
35042
+ emitConversationRailFirstPagesDiagnostic({
35043
+ agentTargetId: input.agentTargetId,
35044
+ controllerApplyMs: 0,
35045
+ diagnosticLogger: this.diagnosticLogger,
35046
+ diagnosticSlowThresholdMs: this.slowThresholdMs,
35047
+ durationMs: requestMs,
35048
+ error: input.error,
35049
+ requestId: input.requestId,
35050
+ requestMs,
35051
+ refreshReason: input.refreshReason,
35052
+ returnedSessionIds: [],
35053
+ returnedSessionCount: 0,
35054
+ ...this.context,
35055
+ sectionCount: 0,
35056
+ status: "error"
34926
35057
  });
34927
35058
  }
34928
35059
  };
35060
+ function emitConversationRailScopeChangeDiagnostic(input) {
35061
+ const event = input.status === "pending" ? "agent_gui.conversation_rail.scope_change.started" : input.status === "error" ? "agent_gui.conversation_rail.scope_change.failed" : input.status === "superseded" ? "agent_gui.conversation_rail.scope_change.superseded" : "agent_gui.conversation_rail.scope_change.completed";
35062
+ const payload = {
35063
+ activeConversationId: input.activeConversationId,
35064
+ cacheStatus: input.cacheStatus,
35065
+ controllerApplyMs: input.controllerApplyMs,
35066
+ durationMs: input.durationMs,
35067
+ ...input.status === "error" ? { errorKind: conversationRailErrorKind(input.error) } : {},
35068
+ event,
35069
+ fromAgentTargetId: input.fromAgentTargetId,
35070
+ fromFilterKind: input.fromFilterKind,
35071
+ nodeId: input.nodeId,
35072
+ preservedSectionCount: input.preservedSectionCount,
35073
+ preservedSessionIds: input.preservedSessionIds,
35074
+ requestId: input.requestId,
35075
+ requestMs: input.requestMs,
35076
+ retainedPreviousSections: input.retainedPreviousSections,
35077
+ returnedSessionIds: input.returnedSessionIds,
35078
+ returnedSessionCount: input.returnedSessionCount,
35079
+ runtimeOrigin: input.runtimeOrigin,
35080
+ sectionCount: input.sectionCount,
35081
+ status: input.status,
35082
+ toAgentTargetId: input.toAgentTargetId,
35083
+ toFilterKind: input.toFilterKind,
35084
+ workspaceId: input.workspaceId
35085
+ };
35086
+ try {
35087
+ input.diagnosticLogger(payload);
35088
+ } catch (error) {
35089
+ ignoreConversationRailDiagnosticFailure(error);
35090
+ }
35091
+ }
34929
35092
  function emitConversationRailProviderSwitchDiagnostic(input) {
34930
35093
  const payload = {
34931
35094
  cacheStatus: input.cacheStatus,
@@ -34934,8 +35097,12 @@ function emitConversationRailProviderSwitchDiagnostic(input) {
34934
35097
  ...input.status === "error" ? { errorKind: conversationRailErrorKind(input.error) } : {},
34935
35098
  event: input.status === "error" ? "agent_gui.provider_switch.failed" : "agent_gui.provider_switch.completed",
34936
35099
  fromAgentTargetId: input.fromAgentTargetId,
35100
+ nodeId: input.nodeId,
35101
+ requestId: input.requestId,
34937
35102
  requestMs: input.requestMs,
35103
+ returnedSessionIds: input.returnedSessionIds,
34938
35104
  returnedSessionCount: input.returnedSessionCount,
35105
+ runtimeOrigin: input.runtimeOrigin,
34939
35106
  sectionCount: input.sectionCount,
34940
35107
  status: input.status,
34941
35108
  toAgentTargetId: input.toAgentTargetId,
@@ -34960,7 +35127,10 @@ function emitConversationRailFirstPagesDiagnostic(input) {
34960
35127
  requestId: input.requestId,
34961
35128
  requestMs: input.requestMs,
34962
35129
  refreshReason: input.refreshReason,
35130
+ returnedSessionIds: input.returnedSessionIds,
34963
35131
  returnedSessionCount: input.returnedSessionCount,
35132
+ nodeId: input.nodeId,
35133
+ runtimeOrigin: input.runtimeOrigin,
34964
35134
  sectionCount: input.sectionCount,
34965
35135
  status: input.status,
34966
35136
  workspaceId: input.workspaceId
@@ -35002,6 +35172,13 @@ function conversationRailErrorKind(error) {
35002
35172
  }
35003
35173
  return error === null ? "null" : typeof error;
35004
35174
  }
35175
+ function conversationRailQuerySessionIds(queryState) {
35176
+ return [
35177
+ ...new Set(
35178
+ (queryState.sections ?? []).flatMap((section) => section.sessionIds)
35179
+ )
35180
+ ];
35181
+ }
35005
35182
 
35006
35183
  // agent-gui/agentGuiNode/model/agentGuiConversationRailMembershipRecords.ts
35007
35184
  import {
@@ -35383,6 +35560,7 @@ var AgentGUIConversationRailQueryController = class {
35383
35560
  diagnosticNow;
35384
35561
  diagnosticSlowThresholdMs;
35385
35562
  getActiveConversationId;
35563
+ nodeId;
35386
35564
  listeners = /* @__PURE__ */ new Set();
35387
35565
  runtime;
35388
35566
  scheduler;
@@ -35418,11 +35596,17 @@ var AgentGUIConversationRailQueryController = class {
35418
35596
  this.diagnosticSlowThresholdMs = input.diagnosticSlowThresholdMs ?? CONVERSATION_RAIL_SLOW_DIAGNOSTIC_THRESHOLD_MS;
35419
35597
  this.engine = input.engine;
35420
35598
  this.getActiveConversationId = input.getActiveConversationId;
35599
+ this.nodeId = input.nodeId?.trim() || null;
35421
35600
  this.runtime = input.runtime;
35422
35601
  this.providerSwitchDiagnostics = new ConversationRailProviderSwitchDiagnosticTracker(
35423
35602
  this.diagnosticLogger,
35424
35603
  this.diagnosticNow,
35425
- input.workspaceId
35604
+ {
35605
+ nodeId: this.nodeId,
35606
+ runtimeOrigin: input.engine.identity.origin,
35607
+ workspaceId: input.workspaceId
35608
+ },
35609
+ this.diagnosticSlowThresholdMs
35426
35610
  );
35427
35611
  this.sessionSectionsQueryCache = input.sessionSectionsQueryCache ?? input.runtime.getSessionSectionsQueryCache?.(input.workspaceId) ?? createWorkspaceQueryCache();
35428
35612
  this.scheduler = input.scheduler ?? agentGuiScheduler;
@@ -35471,14 +35655,24 @@ var AgentGUIConversationRailQueryController = class {
35471
35655
  configure(scope) {
35472
35656
  const previousScopeKey = this.railSectionQueryKey;
35473
35657
  const previousAgentTargetId = this.sectionAgentTargetId;
35658
+ const previousFilterKind = this.scope?.conversationFilter.kind ?? null;
35659
+ const preservedSessionIds = conversationRailQuerySessionIds(
35660
+ this.queryState
35661
+ );
35474
35662
  const { agentTargetId: sectionAgentTargetId, scopeKey: nextScopeKey } = resolveConversationRailQueryScope(this.workspaceId, scope);
35475
35663
  const scopeChanged = nextScopeKey !== this.railSectionQueryKey;
35476
35664
  this.providerSwitchDiagnostics.configure({
35665
+ activeConversationId: this.getActiveConversationId(),
35477
35666
  attached: this.attached,
35667
+ nextFilterKind: scope.conversationFilter.kind,
35478
35668
  nextAgentTargetId: sectionAgentTargetId,
35479
35669
  nextScopeKey,
35670
+ preservedSectionCount: this.queryState.sections?.length ?? 0,
35671
+ preservedSessionIds,
35672
+ previousFilterKind,
35480
35673
  previousAgentTargetId,
35481
- previousScopeKey
35674
+ previousScopeKey,
35675
+ retainedPreviousSections: this.queryState.sections !== null && this.queryState.resolvedScopeKey === previousScopeKey
35482
35676
  });
35483
35677
  this.scope = scope;
35484
35678
  this.sectionAgentTargetId = sectionAgentTargetId;
@@ -35680,13 +35874,9 @@ var AgentGUIConversationRailQueryController = class {
35680
35874
  this.publishIfReady(void 0, true);
35681
35875
  }
35682
35876
  if (cached && !cached.stale && this.cacheNow() - cached.resolvedAtUnixMs <= this.cacheFreshMs) {
35683
- this.providerSwitchDiagnostics.complete(scopeKey, {
35684
- cacheStatus: "fresh",
35877
+ this.providerSwitchDiagnostics.completeCachedFirstPages(scopeKey, {
35685
35878
  controllerApplyMs: cacheApplyStartedAt === null ? 0 : Math.max(0, this.diagnosticNow() - cacheApplyStartedAt),
35686
- requestMs: 0,
35687
- returnedSessionCount: cached.value.returnedSessionCount,
35688
- sectionCount: cached.value.sectionCount,
35689
- status: "ready"
35879
+ query: cached.value
35690
35880
  });
35691
35881
  this.sectionPublicationState = "idle";
35692
35882
  this.publishIfReady(void 0, true);
@@ -35724,56 +35914,29 @@ var AgentGUIConversationRailQueryController = class {
35724
35914
  this.sectionPublicationState = "idle";
35725
35915
  this.publishIfReady(void 0, true);
35726
35916
  const completedAt = this.diagnosticNow();
35727
- this.providerSwitchDiagnostics.complete(scopeKey, {
35728
- cacheStatus,
35729
- controllerApplyMs: Math.max(0, completedAt - requestResolvedAt),
35730
- requestMs: Math.max(0, requestResolvedAt - requestStartedAt),
35731
- returnedSessionCount: entry.value.returnedSessionCount,
35732
- sectionCount: entry.value.sectionCount,
35733
- status: "ready"
35734
- });
35735
- emitConversationRailFirstPagesDiagnostic({
35917
+ this.providerSwitchDiagnostics.completeFirstPages(scopeKey, {
35736
35918
  agentTargetId: this.sectionAgentTargetId || null,
35737
- controllerApplyMs: Math.max(0, completedAt - requestResolvedAt),
35738
- diagnosticLogger: this.diagnosticLogger,
35739
- diagnosticSlowThresholdMs: this.diagnosticSlowThresholdMs,
35740
- durationMs: Math.max(0, completedAt - requestStartedAt),
35741
- requestId: requestSequence,
35742
- requestMs: Math.max(0, requestResolvedAt - requestStartedAt),
35919
+ cacheStatus,
35920
+ completedAt,
35921
+ query: entry.value,
35743
35922
  refreshReason,
35744
- returnedSessionCount: entry.value.returnedSessionCount,
35745
- sectionCount: entry.value.sectionCount,
35746
- status: "ready",
35747
- workspaceId: this.workspaceId
35923
+ requestId: requestSequence,
35924
+ requestResolvedAt,
35925
+ requestStartedAt
35748
35926
  });
35749
35927
  }).catch((error) => {
35750
35928
  if (requestSequence !== this.pagingRequestSequence || scopeKey !== this.railSectionQueryKey) {
35751
35929
  return;
35752
35930
  }
35753
35931
  const failedAt = this.diagnosticNow();
35754
- this.providerSwitchDiagnostics.complete(scopeKey, {
35755
- cacheStatus,
35756
- controllerApplyMs: 0,
35757
- error,
35758
- requestMs: Math.max(0, failedAt - requestStartedAt),
35759
- returnedSessionCount: 0,
35760
- sectionCount: 0,
35761
- status: "error"
35762
- });
35763
- emitConversationRailFirstPagesDiagnostic({
35932
+ this.providerSwitchDiagnostics.failFirstPages(scopeKey, {
35764
35933
  agentTargetId: this.sectionAgentTargetId || null,
35765
- controllerApplyMs: 0,
35766
- diagnosticLogger: this.diagnosticLogger,
35767
- diagnosticSlowThresholdMs: this.diagnosticSlowThresholdMs,
35768
- durationMs: Math.max(0, failedAt - requestStartedAt),
35934
+ cacheStatus,
35769
35935
  error,
35770
- requestId: requestSequence,
35771
- requestMs: Math.max(0, failedAt - requestStartedAt),
35936
+ failedAt,
35772
35937
  refreshReason,
35773
- returnedSessionCount: 0,
35774
- sectionCount: 0,
35775
- status: "error",
35776
- workspaceId: this.workspaceId
35938
+ requestId: requestSequence,
35939
+ requestStartedAt
35777
35940
  });
35778
35941
  this.queryState = wasResolvedForScope ? {
35779
35942
  ...this.queryState,
@@ -35986,6 +36149,7 @@ function useAgentGUIConversationRailQuery({
35986
36149
  activeConversationId,
35987
36150
  conversationFilter,
35988
36151
  conversationQuery,
36152
+ nodeId,
35989
36153
  previewMode,
35990
36154
  registerInteractionLockProbe,
35991
36155
  sectionAgentTargetFallbackId,
@@ -36007,10 +36171,11 @@ function useAgentGUIConversationRailQuery({
36007
36171
  () => new AgentGUIConversationRailQueryController({
36008
36172
  engine,
36009
36173
  getActiveConversationId: () => activeConversationIdRef.current,
36174
+ nodeId,
36010
36175
  runtime,
36011
36176
  workspaceId
36012
36177
  }),
36013
- [engine, runtime, workspaceId]
36178
+ [engine, nodeId, runtime, workspaceId]
36014
36179
  );
36015
36180
  useEffect31(() => {
36016
36181
  if (batchDeletionCapability.partial) {
@@ -36105,6 +36270,7 @@ var AgentGUIConversationRailController = memo9(
36105
36270
  activeConversationId: props.activeConversationId,
36106
36271
  conversationFilter: props.conversationFilter,
36107
36272
  conversationQuery,
36273
+ nodeId: props.nodeId,
36108
36274
  previewMode: props.previewMode,
36109
36275
  registerInteractionLockProbe: props.registerInteractionLockProbe,
36110
36276
  sectionAgentTargetFallbackId: props.sectionAgentTargetFallbackId,
@@ -41918,6 +42084,7 @@ function AgentGUINodeView({
41918
42084
  {
41919
42085
  ...conversationRailStoreState,
41920
42086
  conversations: viewModel.rail.conversations,
42087
+ nodeId: viewModel.shell.nodeId,
41921
42088
  registerInteractionLockProbe: registerRailInteractionLockProbe,
41922
42089
  userProjects: viewModel.rail.userProjects,
41923
42090
  workspaceId: viewModel.shell.workspaceId,
@@ -44036,4 +44203,4 @@ export {
44036
44203
  AgentHandoffMenu,
44037
44204
  AgentGUI
44038
44205
  };
44039
- //# sourceMappingURL=chunk-CUIJXYHG.js.map
44206
+ //# sourceMappingURL=chunk-U3ZWUTTQ.js.map