@inupedia/spotlight-vue 0.5.18 → 0.5.19

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.
@@ -1,44 +1,58 @@
1
- import { serializeSkillsForRemote as O } from "@inupedia/spotlight-client";
2
- import { useAgentSessionStore as P } from "../session/agentSession.js";
1
+ import { serializeSkillsForRemote as H } from "@inupedia/spotlight-client";
2
+ import { useAgentSessionStore as E } from "../session/agentSession.js";
3
3
  import { useSpotlightMemoryPreferenceStore as q } from "../store/memoryPreferenceStore.js";
4
4
  import { useSpotlightRuntimeStore as D } from "../store/runtimeStore.js";
5
5
  import { SPOTLIGHT_PIPELINE_STEP_IDS as r } from "../store/pipeline/constants.js";
6
6
  import { isLoopPlanningChunk as F, splitIntentStepContent as J } from "../store/pipeline/displayText.js";
7
- import { toolLaneStepId as E, resolveToolLane as j, toolLaneStepLabel as B } from "../store/pipeline/toolLane.js";
8
- import { getSpotlightConfig as k } from "../plugin.js";
7
+ import { toolLaneStepId as x, resolveToolLane as j, toolLaneStepLabel as B } from "../store/pipeline/toolLane.js";
8
+ import { getSpotlightConfig as N } from "../plugin.js";
9
9
  import { getSkillsPoolForRun as W } from "../skills/index.js";
10
- import { executeRemoteHostTool as z, ensureHostToolsManifest as x } from "./hostToolRunner.js";
11
- import { getSpotlightServerBase as _, buildSpotlightJsonHeaders as S, getSpotlightProjectId as G } from "./httpConfig.js";
10
+ import { executeRemoteHostTool as z, ensureHostToolsManifest as L } from "./hostToolRunner.js";
11
+ import { getSpotlightServerBase as w, buildSpotlightJsonHeaders as h, getSpotlightProjectId as G } from "./httpConfig.js";
12
12
  import { ensureSpotlightMeta as U } from "./meta.js";
13
- const I = /* @__PURE__ */ new WeakMap();
13
+ const C = /* @__PURE__ */ new WeakMap();
14
14
  function V(t) {
15
15
  return t.type !== "host_action_request" && t.type !== "run_completed" && t.type !== "run_error" && t.type !== "ping" && t.type !== "memory_decision";
16
16
  }
17
- function d(t, e, o) {
17
+ function d(t, e, n) {
18
18
  const s = t.getSteps().find((a) => a.id === e);
19
19
  if (s) return s;
20
- const n = { id: e, label: o, status: "pending" };
21
- return t.setSteps([...t.getSteps(), n]), n;
20
+ const o = { id: e, label: n, status: "pending" };
21
+ return t.setSteps([...t.getSteps(), o]), o;
22
22
  }
23
- function L() {
23
+ function $() {
24
24
  return new Promise((t) => {
25
25
  requestAnimationFrame(() => t());
26
26
  });
27
27
  }
28
28
  function Y(t) {
29
- const e = t.summary?.trim();
30
- if (e && e.length > 48 && !e.startsWith("{") && !e.startsWith("["))
31
- return e;
29
+ return Array.isArray(t) ? t.flatMap((n, s) => {
30
+ if (!n || typeof n != "object") return [];
31
+ const o = n, a = typeof o.content == "string" ? o.content.trim() : "";
32
+ if (!a) return [];
33
+ const i = typeof o.title == "string" && o.title.trim() || typeof o.url == "string" && o.url.trim() || `资料 ${s + 1}`, m = typeof o.url == "string" ? o.url.trim() : "";
34
+ return [[i, m && m !== i ? m : "", a].filter(Boolean).join(`
35
+ `)];
36
+ }).join(`
37
+
38
+ `) : "";
39
+ }
40
+ function K(t) {
41
+ const e = Y(t.output);
42
+ if (e) return e;
43
+ const n = t.summary?.trim();
44
+ if (n && n.length > 48 && !n.startsWith("{") && !n.startsWith("["))
45
+ return n;
32
46
  if (t.output != null && typeof t.output == "object")
33
47
  try {
34
- const o = JSON.stringify(t.output, null, 2);
35
- if (o && o !== "{}") return o;
48
+ const s = JSON.stringify(t.output, null, 2);
49
+ if (s && s !== "{}") return s;
36
50
  } catch {
37
51
  }
38
- return e || "";
52
+ return n || "";
39
53
  }
40
- function K(t) {
41
- const e = Y(t.result);
54
+ function Q(t) {
55
+ const e = K(t.result);
42
56
  return {
43
57
  id: t.result.call.id,
44
58
  name: t.result.call.name,
@@ -51,7 +65,7 @@ function K(t) {
51
65
  status: t.result.success ? "done" : "error"
52
66
  };
53
67
  }
54
- function Q(t) {
68
+ function X(t) {
55
69
  return {
56
70
  id: t.call.id,
57
71
  name: t.call.name,
@@ -60,40 +74,40 @@ function Q(t) {
60
74
  status: "running"
61
75
  };
62
76
  }
63
- function X(t, e) {
64
- const o = e.success ? "前端操作已执行。" : e.error || "前端操作执行失败。";
77
+ function Z(t, e) {
78
+ const n = e.success ? "前端操作已执行。" : e.error || "前端操作执行失败。";
65
79
  return {
66
80
  id: t.id,
67
81
  name: t.name,
68
82
  displayName: t.displayName,
69
83
  argsText: JSON.stringify(t.input ?? {}, null, 2),
70
- resultText: o,
71
- summary: o,
84
+ resultText: n,
85
+ summary: n,
72
86
  errorCode: e.errorCode,
73
87
  trace: e.trace,
74
88
  status: e.success ? "done" : "error"
75
89
  };
76
90
  }
77
- function Z(t, e) {
91
+ function v(t, e) {
78
92
  return j(t, e?.sideEffectByName?.get(t));
79
93
  }
80
- function c(t, e, o) {
81
- const s = t.getSteps().find((n) => n.id === e);
82
- !s || s.status === "done" || s.status === "error" || t.setStep(e, "done", s.content ?? o);
94
+ function c(t, e, n) {
95
+ const s = t.getSteps().find((o) => o.id === e);
96
+ !s || s.status === "done" || s.status === "error" || t.setStep(e, "done", s.content ?? n);
83
97
  }
84
- function C(t, e) {
98
+ function _(t, e) {
85
99
  c(t, r.understand);
86
- const o = E(e), s = B(e);
87
- d(t, o, s);
88
- const n = t.getSteps().find((a) => a.id === o);
89
- !n || n.status === "active" || n.status === "done" || t.setStep(o, "active", n.content);
100
+ const n = x(e), s = B(e);
101
+ d(t, n, s);
102
+ const o = t.getSteps().find((a) => a.id === n);
103
+ !o || o.status === "active" || o.status === "done" || t.setStep(n, "active", o.content);
90
104
  }
91
- function f(t, e, o) {
92
- const s = Z(e, o);
93
- return C(t, s), E(s);
105
+ function p(t, e, n) {
106
+ const s = v(e, n);
107
+ return _(t, s), x(s);
94
108
  }
95
- function v(t, e, o) {
96
- const s = f(t, e.name, o);
109
+ function tt(t, e, n) {
110
+ const s = p(t, e.name, n);
97
111
  t.appendToolCallsToStep(s, [
98
112
  {
99
113
  id: e.id,
@@ -104,52 +118,52 @@ function v(t, e, o) {
104
118
  }
105
119
  ]);
106
120
  }
107
- function tt(t, e, o, s) {
108
- const n = f(t, e.name, s);
109
- t.appendToolCallsToStep(n, [X(e, o)]);
121
+ function et(t, e, n, s) {
122
+ const o = p(t, e.name, s);
123
+ t.appendToolCallsToStep(o, [Z(e, n)]);
110
124
  }
111
- function N(t, e) {
125
+ function P(t, e) {
112
126
  return e || (t === r.gather ? "获取信息" : t === r.act ? "操作页面" : t === r.answer ? "回答" : t === r.understand ? "理解问题" : t === r.tool ? "获取信息" : t);
113
127
  }
114
- function m(t, e, o, s, n) {
115
- d(t, e, o), t.setStep(e, s, n);
128
+ function f(t, e, n, s, o) {
129
+ d(t, e, n), t.setStep(e, s, o);
116
130
  }
117
- function et(t, e) {
118
- const o = e.summary?.trim();
131
+ function st(t, e) {
132
+ const n = e.summary?.trim();
119
133
  switch (e.phase) {
120
134
  case "routing":
121
135
  case "analyzing":
122
- m(
136
+ f(
123
137
  t,
124
138
  r.understand,
125
139
  "理解问题",
126
140
  "active",
127
- o ?? "正在分析用户意图。"
141
+ n ?? "正在分析用户意图。"
128
142
  );
129
143
  return;
130
144
  case "router_done":
131
- m(
145
+ f(
132
146
  t,
133
147
  r.understand,
134
148
  "理解问题",
135
149
  "done",
136
- o ?? "意图分析已完成。"
150
+ n ?? "意图分析已完成。"
137
151
  );
138
152
  return;
139
153
  case "knowledge_agent_start":
140
- c(t, r.understand), m(
154
+ c(t, r.understand), f(
141
155
  t,
142
156
  r.gather,
143
157
  "获取信息",
144
158
  "active",
145
- o ?? "正在检索资料。"
159
+ n ?? "正在检索资料。"
146
160
  );
147
161
  return;
148
162
  case "knowledge_agent_done":
149
163
  c(
150
164
  t,
151
165
  r.gather,
152
- o ?? "资料已就绪。"
166
+ n ?? "资料已就绪。"
153
167
  );
154
168
  return;
155
169
  case "action_agent_start":
@@ -159,23 +173,23 @@ function et(t, e) {
159
173
  c(t, r.gather), c(
160
174
  t,
161
175
  r.act,
162
- o ?? "页面操作已完成。"
176
+ n ?? "页面操作已完成。"
163
177
  );
164
178
  return;
165
179
  case "memory_replay":
166
- m(
180
+ f(
167
181
  t,
168
182
  r.understand,
169
183
  "理解问题",
170
184
  "done",
171
- o ?? "已复用项目记忆,跳过本轮检索。"
185
+ n ?? "已复用项目记忆,跳过本轮检索。"
172
186
  );
173
187
  return;
174
188
  default:
175
189
  return;
176
190
  }
177
191
  }
178
- async function st(t, e, o) {
192
+ async function ot(t, e, n) {
179
193
  if (e.type !== "ping") {
180
194
  if (e.type === "step_sync")
181
195
  t.setSteps(
@@ -183,46 +197,46 @@ async function st(t, e, o) {
183
197
  id: s.id,
184
198
  label: s.label,
185
199
  status: s.status,
186
- content: t.getSteps().find((n) => n.id === s.id)?.content
200
+ content: t.getSteps().find((o) => o.id === s.id)?.content
187
201
  }))
188
202
  );
189
203
  else if (e.type === "step_status")
190
204
  d(t, e.stepId, e.label ?? e.stepId), t.setStep(e.stepId, e.status, e.content);
191
205
  else if (e.type === "step_content") {
192
- let s = e.stepId, n = e.content;
193
- if ((s === r.intent || s === r.understand) && F(n))
206
+ let s = e.stepId, o = e.content;
207
+ if ((s === r.intent || s === r.understand) && F(o))
194
208
  s = r.gather;
195
209
  else if ((s === r.intent || s === r.understand) && e.mode === "replace") {
196
- const { intent: a, misplacedPlanning: i } = J(n);
197
- n = a, i.trim() && (d(t, r.gather, "获取信息"), t.appendChunkToStep(
210
+ const { intent: a, misplacedPlanning: i } = J(o);
211
+ o = a, i.trim() && (d(t, r.gather, "获取信息"), t.appendChunkToStep(
198
212
  r.gather,
199
213
  i
200
214
  ));
201
215
  }
202
- if (d(t, s, N(s, e.label)), e.mode === "replace")
216
+ if (d(t, s, P(s, e.label)), e.mode === "replace")
203
217
  t.setStep(
204
218
  s,
205
219
  t.getSteps().find((a) => a.id === s)?.status ?? "active",
206
- n
220
+ o
207
221
  );
208
222
  else {
209
223
  if (s === r.tool || s === r.gather || s === r.act) {
210
224
  const a = s === r.act ? "act" : "gather";
211
- C(t, a);
225
+ _(t, a);
212
226
  }
213
- t.appendChunkToStep(s, n), await L();
227
+ t.appendChunkToStep(s, o), await $();
214
228
  }
215
229
  } else if (e.type === "step_artifact") {
216
230
  const s = e.stepId === r.tool ? r.gather : e.stepId;
217
- d(t, s, N(s, e.label)), (s === r.gather || s === r.act) && C(
231
+ d(t, s, P(s, e.label)), (s === r.gather || s === r.act) && _(
218
232
  t,
219
233
  s === r.act ? "act" : "gather"
220
234
  ), e.artifact === "tool_calls" && e.toolCalls?.length ? t.appendToolCallsToStep(s, e.toolCalls) : e.artifact === "attachments" && e.attachments?.length ? t.appendAttachmentsToStep(s, e.attachments) : e.artifact === "files" && e.files?.length ? t.appendFilesToStep(s, e.files) : e.artifact === "artifacts" && e.artifacts?.length ? t.appendArtifactsToStep(s, e.artifacts) : e.artifact === "chat_items" && e.chatItems?.length && t.appendChatItemsToStep(s, e.chatItems);
221
235
  } else if (e.type === "tool_start") {
222
- const s = f(t, e.call.name, o);
223
- t.appendToolCallsToStep(s, [Q(e)]);
236
+ const s = p(t, e.call.name, n);
237
+ t.appendToolCallsToStep(s, [X(e)]);
224
238
  } else if (e.type === "tool_progress") {
225
- const s = f(t, e.call.name, o);
239
+ const s = p(t, e.call.name, n);
226
240
  t.appendToolCallsToStep(s, [
227
241
  {
228
242
  id: e.call.id,
@@ -234,8 +248,8 @@ async function st(t, e, o) {
234
248
  }
235
249
  ]);
236
250
  } else if (e.type === "tool_result") {
237
- const s = f(t, e.result.call.name, o);
238
- t.appendToolCallsToStep(s, [K(e)]), e.result.attachments?.length && t.appendAttachmentsToStep(s, e.result.attachments), e.result.files?.length && t.appendFilesToStep(s, e.result.files), e.result.toolCalls?.length && t.appendToolCallsToStep(s, e.result.toolCalls);
251
+ const s = p(t, e.result.call.name, n);
252
+ t.appendToolCallsToStep(s, [Q(e)]), e.result.attachments?.length && t.appendAttachmentsToStep(s, e.result.attachments), e.result.files?.length && t.appendFilesToStep(s, e.result.files), e.result.toolCalls?.length && t.appendToolCallsToStep(s, e.result.toolCalls);
239
253
  } else if (e.type === "skill_permission_request") {
240
254
  const { useSpotlightStore: s } = await import("../store/spotlightStore.js");
241
255
  s().setPendingSkillPermission({
@@ -254,15 +268,15 @@ async function st(t, e, o) {
254
268
  `
255
269
  );
256
270
  } else if (e.type === "turn_transition")
257
- et(t, e);
271
+ st(t, e);
258
272
  else if (e.type === "memory_decision") {
259
273
  const s = {
260
274
  reuse: "已复用项目记忆",
261
275
  augment: "正在结合历史项目结论",
262
276
  refresh: "资料可能变化,正在重新验证",
263
277
  ignore: "未发现可直接使用的项目记忆"
264
- }, n = t.getSteps().find((i) => i.id === r.understand), a = e.decision.action === "reuse" || n?.status === "done" ? "done" : "active";
265
- m(
278
+ }, o = t.getSteps().find((i) => i.id === r.understand), a = e.decision.action === "reuse" || o?.status === "done" ? "done" : "active";
279
+ f(
266
280
  t,
267
281
  r.understand,
268
282
  "理解问题",
@@ -277,12 +291,12 @@ async function st(t, e, o) {
277
291
  V(e) && t.appendExecutionEvent?.(e);
278
292
  }
279
293
  }
280
- async function ot(t) {
294
+ async function nt(t) {
281
295
  await fetch(
282
- `${_()}/v1/runs/${encodeURIComponent(t.runId)}/host-results`,
296
+ `${w()}/v1/runs/${encodeURIComponent(t.runId)}/host-results`,
283
297
  {
284
298
  method: "POST",
285
- headers: S(),
299
+ headers: h(),
286
300
  body: JSON.stringify({
287
301
  correlationId: t.correlationId,
288
302
  success: t.result.success,
@@ -295,35 +309,35 @@ async function ot(t) {
295
309
  }
296
310
  );
297
311
  }
298
- function nt(t) {
299
- const e = t.split(/\n\n/u), o = e.pop() ?? "";
300
- return { events: e.flatMap((n) => {
301
- const a = n.split(/\n/u).find((i) => i.startsWith("data: "));
312
+ function rt(t) {
313
+ const e = t.split(/\n\n/u), n = e.pop() ?? "";
314
+ return { events: e.flatMap((o) => {
315
+ const a = o.split(/\n/u).find((i) => i.startsWith("data: "));
302
316
  if (!a) return [];
303
317
  try {
304
318
  return [JSON.parse(a.slice(6))];
305
319
  } catch {
306
320
  return [];
307
321
  }
308
- }), rest: o };
322
+ }), rest: n };
309
323
  }
310
- async function ht(t) {
324
+ async function Tt(t) {
311
325
  await Promise.allSettled([
312
- x(),
326
+ L(),
313
327
  U(t)
314
328
  ]);
315
329
  }
316
- async function rt(t, e, o) {
317
- const s = P(), n = D(), a = q(), i = await x();
330
+ async function at(t, e, n) {
331
+ const s = E(), o = D(), a = q(), i = await L();
318
332
  return {
319
333
  hostManifest: i,
320
334
  payload: {
321
335
  projectId: G(),
322
336
  sessionId: s.sessionId,
323
- memorySubjectId: k().getMemorySubjectId?.() ?? void 0,
337
+ memorySubjectId: N().getMemorySubjectId?.() ?? void 0,
324
338
  userQuestion: t,
325
- memoryRefreshRequested: o?.forceMemoryRefresh === !0,
326
- uiContext: k().getUiContext?.() ?? {},
339
+ memoryRefreshRequested: n?.forceMemoryRefresh === !0,
340
+ uiContext: N().getUiContext?.() ?? {},
327
341
  sessionState: {
328
342
  sessionId: s.sessionId,
329
343
  activeTaskId: s.activeTaskId,
@@ -340,86 +354,86 @@ async function rt(t, e, o) {
340
354
  memoryWriteEnabled: !0
341
355
  },
342
356
  runtimeState: {
343
- activeDomain: n.activeDomain,
344
- activeTarget: n.activeTarget,
345
- activeAction: n.activeAction,
346
- resumableAction: n.resumableAction,
347
- lastResolvedTarget: n.lastResolvedTarget
357
+ activeDomain: o.activeDomain,
358
+ activeTarget: o.activeTarget,
359
+ activeAction: o.activeAction,
360
+ resumableAction: o.resumableAction,
361
+ lastResolvedTarget: o.lastResolvedTarget
348
362
  },
349
363
  clientToolsManifestVersion: i.manifestDigest,
350
364
  clientToolManifest: i,
351
- skills: O(W()),
365
+ skills: H(W()),
352
366
  frontendBuildId: i.frontendBuildId,
353
367
  manifestDigest: i.manifestDigest
354
368
  }
355
369
  };
356
370
  }
357
- async function Tt(t, e, o) {
358
- const s = _(), n = e.getSignal(), { payload: a, hostManifest: i } = await rt(
371
+ async function It(t, e, n) {
372
+ const s = w(), o = e.getSignal(), { payload: a, hostManifest: i } = await at(
359
373
  t,
360
- n,
361
- o
362
- ), A = new Set(i.tools.map((u) => u.name)), h = {
374
+ o,
375
+ n
376
+ ), m = new Set(i.tools.map((u) => u.name)), T = {
363
377
  sideEffectByName: new Map(
364
378
  i.tools.map((u) => [u.name, u.sideEffect])
365
379
  )
366
- }, p = await fetch(`${s}/v1/runs`, {
380
+ }, g = await fetch(`${s}/v1/runs`, {
367
381
  method: "POST",
368
- headers: S(),
382
+ headers: h(),
369
383
  body: JSON.stringify(a),
370
- signal: n
384
+ signal: o
371
385
  });
372
- if (!p.ok) {
373
- const u = await p.text().catch(() => "");
386
+ if (!g.ok) {
387
+ const u = await g.text().catch(() => "");
374
388
  throw new Error(
375
- `Spotlight 后端创建 run 失败:${p.status} ${u}`
389
+ `Spotlight 后端创建 run 失败:${g.status} ${u}`
376
390
  );
377
391
  }
378
- const { runId: g } = await p.json();
379
- n && (I.set(n, g), n.addEventListener(
392
+ const { runId: y } = await g.json();
393
+ o && (C.set(o, y), o.addEventListener(
380
394
  "abort",
381
395
  () => {
382
- $(g);
396
+ A(y);
383
397
  },
384
398
  { once: !0 }
385
399
  ));
386
- const y = await fetch(
387
- `${s}/v1/runs/${encodeURIComponent(g)}/events`,
400
+ const S = await fetch(
401
+ `${s}/v1/runs/${encodeURIComponent(y)}/events`,
388
402
  {
389
- headers: S(),
390
- signal: n
403
+ headers: h(),
404
+ signal: o
391
405
  }
392
406
  );
393
- if (!y.ok || !y.body)
394
- throw new Error(`Spotlight 后端事件流连接失败:${y.status}`);
395
- const w = y.body.getReader(), H = new TextDecoder();
396
- let T = "";
407
+ if (!S.ok || !S.body)
408
+ throw new Error(`Spotlight 后端事件流连接失败:${S.status}`);
409
+ const R = S.body.getReader(), M = new TextDecoder();
410
+ let I = "";
397
411
  try {
398
412
  for (; ; ) {
399
- const { done: u, value: M } = await w.read();
413
+ const { done: u, value: O } = await R.read();
400
414
  if (u) break;
401
- T += H.decode(M, { stream: !0 });
402
- const R = nt(T);
403
- T = R.rest;
404
- for (const l of R.events) {
415
+ I += M.decode(O, { stream: !0 });
416
+ const b = rt(I);
417
+ I = b.rest;
418
+ for (const l of b.events) {
405
419
  if (l.type === "host_action_request") {
406
- v(e, l.request.call, h);
407
- const b = await z(l.request.call, e, {
408
- allowedHostNames: A,
420
+ tt(e, l.request.call, T);
421
+ const k = await z(l.request.call, e, {
422
+ allowedHostNames: m,
409
423
  hostEffect: l.request.hostEffect
410
424
  });
411
- tt(e, l.request.call, b, h), await ot({
412
- runId: g,
425
+ et(e, l.request.call, k, T), await nt({
426
+ runId: y,
413
427
  correlationId: l.request.correlationId,
414
- result: b,
415
- signal: n
428
+ result: k,
429
+ signal: o
416
430
  });
417
431
  continue;
418
432
  }
419
433
  if (l.type === "run_error")
420
434
  throw new Error(l.error);
421
- if (await st(e, l, h), await L(), l.type === "run_completed")
422
- return l.sessionPatch && P().applySessionPatch(l.sessionPatch), {
435
+ if (await ot(e, l, T), await $(), l.type === "run_completed")
436
+ return l.sessionPatch && E().applySessionPatch(l.sessionPatch), {
423
437
  command: null,
424
438
  memoryReplay: l.memoryReplay ?? null,
425
439
  memoryDecision: l.memoryDecision ?? null,
@@ -428,33 +442,33 @@ async function Tt(t, e, o) {
428
442
  }
429
443
  }
430
444
  } finally {
431
- w.releaseLock();
445
+ R.releaseLock();
432
446
  }
433
447
  return {
434
448
  command: null
435
449
  };
436
450
  }
437
- async function $(t) {
451
+ async function A(t) {
438
452
  await fetch(
439
- `${_()}/v1/runs/${encodeURIComponent(t)}`,
453
+ `${w()}/v1/runs/${encodeURIComponent(t)}`,
440
454
  {
441
455
  method: "DELETE",
442
- headers: S()
456
+ headers: h()
443
457
  }
444
458
  );
445
459
  }
446
- function It(t) {
460
+ function Ct(t) {
447
461
  if (!t) return;
448
- const e = I.get(t);
449
- e && (I.delete(t), $(e));
462
+ const e = C.get(t);
463
+ e && (C.delete(t), A(e));
450
464
  }
451
465
  export {
452
- et as applyLangGraphTransition,
453
- st as applyRemoteEvent,
454
- v as beginHostToolCall,
455
- $ as cancelRemoteSpotlightRun,
456
- It as cancelRemoteSpotlightRunForSignal,
457
- Tt as runRemoteSpotlightPipeline,
458
- tt as settleHostToolCall,
459
- ht as warmupSpotlightRemoteContext
466
+ st as applyLangGraphTransition,
467
+ ot as applyRemoteEvent,
468
+ tt as beginHostToolCall,
469
+ A as cancelRemoteSpotlightRun,
470
+ Ct as cancelRemoteSpotlightRunForSignal,
471
+ It as runRemoteSpotlightPipeline,
472
+ et as settleHostToolCall,
473
+ Tt as warmupSpotlightRemoteContext
460
474
  };
@@ -14,6 +14,11 @@ export declare function composeToolStepContent(planning: string, answer: string)
14
14
  * 最终回答和流式回答都必须经过这里,避免中途把内部材料渲染给用户。
15
15
  */
16
16
  export declare function sanitizeToolStepAnswerText(content: string): string;
17
+ /**
18
+ * Strip vendor evidence labels from displayed text.
19
+ * Never wipe the whole answer just because a label appears inside it.
20
+ */
21
+ export declare function stripInternalEvidenceAnswer(text: string): string;
17
22
  export interface GatherProcessDisplay {
18
23
  headline: string;
19
24
  items: string[];
@@ -1 +1 @@
1
- {"version":3,"file":"displayText.d.ts","sourceRoot":"","sources":["../../../src/store/pipeline/displayText.ts"],"names":[],"mappings":"AAeA,kEAAkE;AAClE,eAAO,MAAM,0BAA0B,qCAAqC,CAAC;AAE7E,8CAA8C;AAC9C,wBAAgB,4BAA4B,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAOpE;AAoCD,yCAAyC;AACzC,wBAAgB,oBAAoB,CAAC,OAAO,EAAE,MAAM,GAAG;IACrD,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,CAAC;CAChB,CAeA;AAED,wBAAgB,sBAAsB,CACpC,QAAQ,EAAE,MAAM,EAChB,MAAM,EAAE,MAAM,GACb,MAAM,CAOR;AAED;;;;GAIG;AACH,wBAAgB,0BAA0B,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAelE;AAED,MAAM,WAAW,oBAAoB;IACn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