@sentry/junior 0.284.0 → 0.286.0

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.
Files changed (84) hide show
  1. package/dist/{adapter-CW5UW7vL.js → adapter-JQZaJ-B_.js} +37 -3
  2. package/dist/{admin-DUWN8zZX.js → admin-Dm2bimJ-.js} +1 -1
  3. package/dist/{agent-runner-Cqr21pOU.js → agent-runner-DGCwOEyL.js} +2180 -2735
  4. package/dist/api/schema.d.ts +2 -2
  5. package/dist/api/schema.js +8 -7
  6. package/dist/api.d.ts +1 -1
  7. package/dist/api.js +166 -90
  8. package/dist/{app-CvGalMxi.d.ts → app-BKq0JzWx.d.ts} +2 -3
  9. package/dist/app.d.ts +1 -1
  10. package/dist/app.js +225 -188
  11. package/dist/{assistant-reply-CFE-OZMS.js → assistant-reply-CAPafcUY.js} +1 -1
  12. package/dist/{automation-Zvx_I9Z5.js → automation-B-jJN_gM.js} +1 -1
  13. package/dist/{background-compaction-queue-CHFzrQbS.js → background-compaction-queue-Btu2oab_.js} +137 -3
  14. package/dist/{briefs-Cx7mkfSk.js → briefs-UMeYehUe.js} +5 -5
  15. package/dist/{catalog-runtime-dKOVbR7l.js → catalog-runtime-Bym8GVdh.js} +1 -1
  16. package/dist/cli/chat.js +19 -16
  17. package/dist/cli/check.js +3 -3
  18. package/dist/cli/init.js +3 -0
  19. package/dist/cli/main.js +3 -3
  20. package/dist/cli/plugins.js +4 -4
  21. package/dist/cli/snapshot-create.js +5 -6
  22. package/dist/cli/upgrade.d.ts +1 -1
  23. package/dist/cli/upgrade.js +12 -17
  24. package/dist/{client-CMyH5rDz.js → client-B0aAs7wC.js} +2 -2
  25. package/dist/{config-Dt3CpG17.js → config-B9f9Lqo5.js} +1 -1
  26. package/dist/{connections-CCHPybZP.js → connections-CQ7p0aNJ.js} +16 -50
  27. package/dist/{conversation-DdT7SNar.js → conversation-BusI2uzj.js} +68 -7
  28. package/dist/{conversation-pending-messages-Dct5pheX.js → conversation-pending-messages-DwehU0Fd.js} +1 -1
  29. package/dist/{conversation-privacy-BpHHhEVp.js → conversation-privacy-Cd_nZZBM.js} +1 -1
  30. package/dist/{credential-sync-BBPw8dam.js → credential-sync-DmiJi_At.js} +13 -13
  31. package/dist/{db-D7CCwAo8.d.ts → db-C5zi4ecs.d.ts} +18 -2
  32. package/dist/{executor-CyIwHz9r.js → executor-Dipi2Ixl.js} +19 -17
  33. package/dist/instrumentation.js +2 -2
  34. package/dist/{logging-Qo-7xGp1.js → logging-CMFhLLj4.js} +1 -1
  35. package/dist/{media-Bu9C6lz0.js → media-B-BpXo41.js} +14 -2
  36. package/dist/{message-DFbtOWqv.js → message-D1xLljUF.js} +13 -23
  37. package/dist/nitro.d.ts +1 -1
  38. package/dist/nitro.js +2 -3
  39. package/dist/{oauth-callback-server-BB1gixWo.js → oauth-callback-server-DCAFIUQr.js} +2 -2
  40. package/dist/{projection-0UcUeuzn.js → projection-CoeMNxJ4.js} +545 -262
  41. package/dist/{prompt-CCtaGgbI.js → prompt-C9OQEfan.js} +8 -6
  42. package/dist/{registry-DOnPkI8g.js → registry-u-sFYtx_.js} +1 -1
  43. package/dist/{reporting-window-B-QP9zX1.js → reporting-window-B4TwyuJo.js} +14 -14
  44. package/dist/{resolve-Di3omymY.js → resolve-DYqgL3Eo.js} +3 -3
  45. package/dist/result-CescSwAw.js +299 -0
  46. package/dist/result-event-type-DD6BAgT7.js +11 -0
  47. package/dist/{runner-CnX_dTKw.js → runner-Cr67a8TB.js} +16 -12
  48. package/dist/{sandbox-egress-signals-CtxLJmmg.js → sandbox-egress-signals-DLOazy5W.js} +1 -1
  49. package/dist/{schema-Bn3miEd_.js → schema-BUSi3sgv.js} +63 -5
  50. package/dist/{schema-B017enNE.d.ts → schema-Ih60j59-.d.ts} +194 -220
  51. package/dist/{service-account-KhZIqXRi.js → service-account-CGEqz9wG.js} +3 -3
  52. package/dist/{service-account-ewDAx4Mx.js → service-account-CsKxktLk.js} +3 -3
  53. package/dist/session-stop-CGz5DByb.js +2926 -0
  54. package/dist/{skills-CKyotM4g.js → skills-COCqf61f.js} +2 -2
  55. package/dist/{spawn-D5D2MQdz.js → spawn-C8F_iXWO.js} +13 -2
  56. package/dist/{stop-BSKRTaRS.js → stop-GyFZkHuQ.js} +7730 -7818
  57. package/dist/{store-ymkEUWe4.js → store-D0-8plWp.js} +30 -5
  58. package/dist/{turn-session-routing-D_GXfcAG.js → task-runner-xPuQmEot.js} +1440 -994
  59. package/dist/{store-G3S0kWSD.js → turn-failure-response-BOviBdT-.js} +404 -311
  60. package/dist/{validation-DJG_wrg2.js → validation-DZDKorGz.js} +1 -1
  61. package/dist/{version-i1An1eTS.js → version-BTIz7fGi.js} +1 -1
  62. package/dist/version.js +1 -1
  63. package/dist/{viewer-BlpnzZZa.js → viewer-CH-ASQzh.js} +208 -68
  64. package/dist/{work-BgCW3FDC.js → work-C75_IM5e.js} +311 -100
  65. package/dist/{worker-BJz1mwYt.js → worker-Dl47I729.js} +6 -6
  66. package/migrations/0083_conversation_kind.sql +11 -0
  67. package/migrations/0084_read_position_backfill.sql +25 -0
  68. package/migrations/0085_child_archived_at.sql +1 -0
  69. package/migrations/0086_shared_archive.sql +31 -0
  70. package/migrations/0087_child_location.sql +64 -0
  71. package/migrations/meta/0083_snapshot.json +4388 -0
  72. package/migrations/meta/0084_snapshot.json +4388 -0
  73. package/migrations/meta/0085_snapshot.json +4394 -0
  74. package/migrations/meta/0086_snapshot.json +4366 -0
  75. package/migrations/meta/0087_snapshot.json +4366 -0
  76. package/migrations/meta/_journal.json +35 -0
  77. package/package.json +5 -4
  78. package/dist/result-NvndYzCb.js +0 -483
  79. package/dist/session-stop-D_1SysjC.js +0 -1438
  80. package/dist/task-queue-BcOHzXxe.js +0 -139
  81. package/dist/task-runner-B65cDumh.js +0 -290
  82. package/dist/thread-state-D6rNGQu9.js +0 -173
  83. package/dist/turn-failure-response-BlO4nuDJ.js +0 -224
  84. package/dist/turn-lifecycle-BQ8ETk63.js +0 -58
@@ -1,4 +1,4 @@
1
- import { H as conversationBriefSchema, U as parseBriefInput, V as briefOutcomeStatusSchema } from "./conversation-DdT7SNar.js";
1
+ import { G as conversationBriefSchema, K as parseBriefInput, U as briefOutcomeStatusSchema } from "./conversation-BusI2uzj.js";
2
2
  import * as z from "zod";
3
3
  // src/chat/briefs/generate.ts
4
4
  const MAX_INPUT_CHARS = 6e4;
@@ -317,9 +317,9 @@ function hasMergedEvidence(input) {
317
317
  return input.codeChanges.some((change) => change.state === "merged") || input.resources.some((resource) => resource.status?.trim().toLowerCase() === "merged");
318
318
  }
319
319
  /** Build the text indexed for a Brief without adding transcript content. */
320
- function buildBriefSearchText(brief, title) {
321
- return [
322
- title,
320
+ function buildBriefSearchText(brief, input) {
321
+ const values = [
322
+ input.title,
323
323
  brief.summary,
324
324
  brief.intent,
325
325
  brief.outcome.text,
@@ -327,9 +327,11 @@ function buildBriefSearchText(brief, title) {
327
327
  ...brief.facts,
328
328
  ...brief.keywords,
329
329
  ...brief.links.map((link) => link.label),
330
+ ...deterministicLinks(input).map((link) => link.label),
330
331
  ...brief.record.participants.map((participant) => participant.name),
331
332
  ...brief.record.codeChanges.map((change) => `${change.repository}#${change.number} ${change.state}`)
332
- ].filter((value) => Boolean(value?.trim())).join("\n");
333
+ ].filter((value) => Boolean(value?.trim()));
334
+ return [...new Set(values)].join("\n");
333
335
  }
334
336
  /** Generate one bounded Brief and attach only deterministic evidence links. */
335
337
  async function generateBrief(args) {
@@ -382,7 +384,7 @@ async function generateBrief(args) {
382
384
  mergedClaimWithoutEvidence: mergedClaim && hasLinkedEvidence && !hasMergedEvidence(input),
383
385
  resourceCount: input.resources.length
384
386
  },
385
- searchText: buildBriefSearchText(normalized.brief, input.title),
387
+ searchText: buildBriefSearchText(normalized.brief, input),
386
388
  throughIndex: args.throughIndex
387
389
  };
388
390
  }
@@ -1,4 +1,4 @@
1
- import { b as setSpanAttributes, h as logWarn, m as logInfo } from "./logging-Qo-7xGp1.js";
1
+ import { b as setSpanAttributes, h as logWarn, m as logInfo } from "./logging-CMFhLLj4.js";
2
2
  import { o as isUserActor, s as parseActorUserId } from "./actor-6jsm_v96.js";
3
3
  import { n as normalizePluginPackageNames, o as pluginRoots, t as discoverInstalledPluginPackageContent } from "./package-discovery-DJhGdS4c.js";
4
4
  import path from "node:path";
@@ -32,15 +32,6 @@ const AGENT_INVOCATION_PARENT_MAILBOX_STATUSES = [
32
32
  "skipped",
33
33
  "steered"
34
34
  ];
35
- // src/chat/conversations/web-message-id.ts
36
- /**
37
- * Build the retry-stable Message id shared by web ingress and browser sends.
38
- * Keep the existing hash and prefix so retries still address stored Messages.
39
- */
40
- async function webMessageId(args) {
41
- const digest = await crypto.subtle.digest("SHA-256", new TextEncoder().encode(`${args.conversationId}\u0000${args.idempotencyKey}`));
42
- return `api-msg:${Array.from(new Uint8Array(digest), (byte) => byte.toString(16).padStart(2, "0")).join("").slice(0, 24)}`;
43
- }
44
35
  // src/chat/tools/runtime/user-input-request.ts
45
36
  const USER_INPUT_LIMITS = {
46
37
  maxButtonOptions: 5,
@@ -154,13 +145,13 @@ function answerLine(text) {
154
145
  return text.split("\n").map((line) => line.trim()).filter(Boolean).join("\n");
155
146
  }
156
147
  /**
157
- * Write an answer as the text of the person's message. Slack and the web
158
- * dashboard both send this text, so the model reads one format. The first
159
- * line names the request, and each field starts its own line.
148
+ * Write the fields of an answer, one `Label (field_id): value` line each.
149
+ * Slack, the web dashboard, and the prompt all use this text, so the model
150
+ * reads one format.
160
151
  */
161
152
  function formatUserInputAnswer(request, answer) {
162
153
  const normalized = normalizeUserInputAnswer(request, answer);
163
- const lines = [`Answer to request ${normalized.requestId}:`];
154
+ const lines = [];
164
155
  for (const field of request.fields) {
165
156
  const values = normalized.values[field.id];
166
157
  const value = values?.length ? values.join(", ") : "(no answer)";
@@ -169,6 +160,15 @@ function formatUserInputAnswer(request, answer) {
169
160
  if (normalized.other) lines.push(answerLine(`Other: ${normalized.other}`));
170
161
  return lines.join("\n");
171
162
  }
163
+ // src/chat/conversations/web-message-id.ts
164
+ /**
165
+ * Build the retry-stable Message id shared by web ingress and browser sends.
166
+ * Keep the existing hash and prefix so retries still address stored Messages.
167
+ */
168
+ async function webMessageId(args) {
169
+ const digest = await crypto.subtle.digest("SHA-256", new TextEncoder().encode(`${args.conversationId}\u0000${args.idempotencyKey}`));
170
+ return `api-msg:${Array.from(new Uint8Array(digest), (byte) => byte.toString(16).padStart(2, "0")).join("").slice(0, 24)}`;
171
+ }
172
172
  // src/api/reporting-window.ts
173
173
  /** Shared UTC day/hour/six-hour windows for dashboard activity series. */
174
174
  const HOUR_MS = 36e5;
@@ -292,4 +292,4 @@ function sumUtcHoursIntoSixHours(args) {
292
292
  rows: bySix
293
293
  });
294
294
  }
295
- export { AGENT_INVOCATION_STATUSES as C, userCustomizationTextSchema as E, AGENT_INVOCATION_PARENT_MAILBOX_STATUSES as S, userCustomizationSchema as T, isEmptyUserInputAnswer as _, fillUtcSixHours as a, webMessageId as b, trailingUtcDayWindow as c, utcDayKey as d, utcHourKey as f, formatUserInputAnswer as g, buttonUserInputField as h, fillUtcHours as i, trailingUtcHourWindow as l, USER_INPUT_NOTE as m, HOUR_MS as n, startOfUtcHour as o, USER_INPUT_LIMITS as p, fillUtcDays as r, sumUtcHoursIntoSixHours as s, DAY_MS as t, trailingUtcSixHourWindow as u, normalizeUserInputAnswer as v, USER_CUSTOMIZATION_MAX_CHARS as w, AGENT_INVOCATION_MAILBOX_STATUSES as x, userInputRequestSchema as y };
295
+ export { AGENT_INVOCATION_STATUSES as C, userCustomizationTextSchema as E, AGENT_INVOCATION_PARENT_MAILBOX_STATUSES as S, userCustomizationSchema as T, formatUserInputAnswer as _, fillUtcSixHours as a, userInputRequestSchema as b, trailingUtcDayWindow as c, utcDayKey as d, utcHourKey as f, buttonUserInputField as g, USER_INPUT_NOTE as h, fillUtcHours as i, trailingUtcHourWindow as l, USER_INPUT_LIMITS as m, HOUR_MS as n, startOfUtcHour as o, webMessageId as p, fillUtcDays as r, sumUtcHoursIntoSixHours as s, DAY_MS as t, trailingUtcSixHourWindow as u, isEmptyUserInputAnswer as v, USER_CUSTOMIZATION_MAX_CHARS as w, AGENT_INVOCATION_MAILBOX_STATUSES as x, normalizeUserInputAnswer as y };
@@ -1,6 +1,6 @@
1
- import { Ea as SANDBOX_COMMAND_PATH, La as runNonInteractiveCommand, ba as sleep, gi as isStale, ja as SANDBOX_WORKSPACE_ROOT, mi as create, vi as getSandboxProvider } from "./projection-0UcUeuzn.js";
2
- import { E as withSpan, b as setSpanAttributes } from "./logging-Qo-7xGp1.js";
3
- import { r as getStateAdapter } from "./adapter-CW5UW7vL.js";
1
+ import { Di as create, Na as sleep, Ua as SANDBOX_WORKSPACE_ROOT, Ya as runNonInteractiveCommand, ji as getSandboxProvider, ki as isStale, za as SANDBOX_COMMAND_PATH } from "./projection-CoeMNxJ4.js";
2
+ import { E as withSpan, b as setSpanAttributes } from "./logging-CMFhLLj4.js";
3
+ import { r as getStateAdapter } from "./adapter-JQZaJ-B_.js";
4
4
  import * as z from "zod";
5
5
  // src/chat/sandbox/resources.ts
6
6
  let configuredResources;
@@ -0,0 +1,299 @@
1
+ import { v as __exportAll } from "./sentry-BRTJqumy.js";
2
+ import { yn as renderUntrustedTag } from "./projection-CoeMNxJ4.js";
3
+ import { V as SYSTEM_IDENTITY_ID } from "./viewer-CH-ASQzh.js";
4
+ import { f as credentialContextForActor } from "./registry-u-sFYtx_.js";
5
+ import { Vt as listUnreportedSiblingAgents } from "./agent-runner-DGCwOEyL.js";
6
+ import { C as isTerminalAgentInvocation, G as getAgentInvocationIdForMessage, J as getAgentInvocationResultMessageId, K as getAgentInvocationIdForResult, W as getAgentInvocationIdForEvents, k as markAgentInvocationParentMailboxAppended, x as getLatestAgentInvocationForConversation, y as getAgentInvocation } from "./turn-failure-response-BOviBdT-.js";
7
+ import { D as timerWatchCredentialSubject, E as renderEventBatchInputs, S as EVENT_WAIT_MS, T as isEventMailboxMetadata, f as getEventBatchDelayMs, m as parseEventMessages, n as isWatchEvent, s as eventReviewItemInputs } from "./session-stop-CGz5DByb.js";
8
+ import { r as appendAndEnqueueInboundMessage } from "./store-D0-8plWp.js";
9
+ import { a as enqueueAgentInvocation, l as createAgentInvocationFromLatest, o as resolveAgentInvocationId, t as createAgentInvocationWorker } from "./work-C75_IM5e.js";
10
+ import { n as isAgentInvocationResultEventType, t as agentInvocationResultEventType } from "./result-event-type-DD6BAgT7.js";
11
+ // src/chat/agent-invocations/result.ts
12
+ var result_exports = /* @__PURE__ */ __exportAll({
13
+ createChildConversationWorker: () => createChildConversationWorker,
14
+ enqueueAgentInvocationResult: () => enqueueAgentInvocationResult,
15
+ enqueueAgentMessageToParent: () => enqueueAgentMessageToParent,
16
+ withAgentInvocationResultActors: () => withAgentInvocationResultActors
17
+ });
18
+ const AGENT_INVOCATION_EVENT_NAMESPACE = "junior";
19
+ const AGENT_INVOCATION_RESULT_MAX_LENGTH = 12e3;
20
+ /** Event type of a message that a child agent sends to its parent. */
21
+ const AGENT_MESSAGE_EVENT_TYPE = "agent.message";
22
+ /**
23
+ * Return the Inbound message author id for results sent by one Actor.
24
+ * `selectContiguousTurnBatch` in `task-execution/worker.ts` puts messages in
25
+ * one attempt only when their author ids and sources match. Mid-Turn drains
26
+ * take only `interrupt` messages, and results are `defer`. So results never
27
+ * share a Turn and its credentials with another Actor or with watch Events.
28
+ * Keep this id unique per Actor if either rule changes.
29
+ */
30
+ function resultAuthorId(actor) {
31
+ switch (actor.platform) {
32
+ case "system": return `agent-invocation:system:${actor.name}`;
33
+ case "slack": return `agent-invocation:slack:${actor.teamId}:${actor.userId}`;
34
+ default: return `agent-invocation:${actor.platform}:${actor.userId}`;
35
+ }
36
+ }
37
+ /**
38
+ * Error messages can contain text from tools or providers, so the trusted
39
+ * summary in the mailbox metadata has only the status.
40
+ */
41
+ function trustedSummary(invocation, agent) {
42
+ switch (invocation.status) {
43
+ case "completed": return `${agent} finished its task.`;
44
+ case "blocked": return `${agent} is blocked.`;
45
+ case "failed": return `${agent} failed.`;
46
+ case "stopped": return `${agent} was stopped.`;
47
+ }
48
+ }
49
+ /**
50
+ * Render the parent agent input for one terminal agent invocation as one
51
+ * `<agent-result>`. A child agent wrote the output, so it is escaped data.
52
+ * `status` and `waiting_on` are runtime facts. The system prompt says what to
53
+ * do for each status, so the input repeats no guidance.
54
+ */
55
+ function renderResultInput(invocation, openSiblings) {
56
+ const output = (invocation.status === "completed" ? invocation.result : invocation.errorMessage).trim().slice(0, AGENT_INVOCATION_RESULT_MAX_LENGTH);
57
+ return renderUntrustedTag("agent-result", {
58
+ conversation_id: invocation.childConversationId,
59
+ name: invocation.agentName,
60
+ source: "child_agent",
61
+ status: invocation.status,
62
+ title: invocation.title,
63
+ waiting_on: openSiblings.length ? openSiblings.map(siblingLabel).join(", ") : void 0
64
+ }, "A child agent that you started", output || "(empty)");
65
+ }
66
+ function siblingLabel(sibling) {
67
+ return sibling.agentName ?? sibling.title ?? sibling.childConversationId;
68
+ }
69
+ /** Build the parent Inbound message for one terminal agent invocation. */
70
+ function buildResultInboundMessage(invocation, nowMs, openSiblings) {
71
+ const summary = trustedSummary(invocation, childAgentLabel(invocation));
72
+ const metadata = {
73
+ kind: "event",
74
+ event: {
75
+ eventKey: invocation.invocationId,
76
+ eventType: agentInvocationResultEventType(invocation.status),
77
+ identifier: invocation.invocationId,
78
+ namespace: AGENT_INVOCATION_EVENT_NAMESPACE,
79
+ trustedSummary: summary
80
+ }
81
+ };
82
+ return {
83
+ conversationId: invocation.parentConversationId,
84
+ createdAtMs: invocation.terminalAtMs,
85
+ delivery: "defer",
86
+ inboundMessageId: getAgentInvocationResultMessageId(invocation.invocationId),
87
+ input: {
88
+ authorId: resultAuthorId(invocation.actor),
89
+ authorIdentityId: SYSTEM_IDENTITY_ID,
90
+ metadata,
91
+ text: renderResultInput(invocation, openSiblings)
92
+ },
93
+ receivedAtMs: nowMs,
94
+ source: "event"
95
+ };
96
+ }
97
+ /**
98
+ * Append one terminal agent invocation result to the parent mailbox and wake
99
+ * the parent. Repeat calls are safe.
100
+ *
101
+ * Results do not go through `admitAutomatedTurn`, so the automated-turn limit
102
+ * never drops them. Result Turns still count toward that limit.
103
+ * TODO(dcramer): Add a per-parent total invocation limit as the loop guard
104
+ * for spawn -> result -> spawn chains (#881).
105
+ */
106
+ async function enqueueAgentInvocationResult(invocation, options) {
107
+ if (invocation.parentMailboxStatus !== "pending") return;
108
+ const nowMs = options.nowMs ?? Date.now();
109
+ const openSiblings = await listUnreportedSiblingAgents(invocation.parentConversationId, invocation.childConversationId);
110
+ await appendAndEnqueueInboundMessage({
111
+ message: buildResultInboundMessage(invocation, nowMs, openSiblings),
112
+ queue: options.queue,
113
+ queueDelayMs: EVENT_WAIT_MS,
114
+ state: options.state
115
+ });
116
+ await markAgentInvocationParentMailboxAppended(invocation.invocationId, nowMs);
117
+ }
118
+ function childAgentLabel(invocation) {
119
+ return invocation.agentName ? `Child agent "${invocation.agentName}"` : "Child agent";
120
+ }
121
+ function renderMessageInput(sender, text) {
122
+ return renderUntrustedTag("agent-message", {
123
+ conversation_id: sender.childConversationId,
124
+ name: sender.agentName,
125
+ source: "child_agent",
126
+ title: sender.title
127
+ }, "A child agent that you started", text.trim());
128
+ }
129
+ /**
130
+ * Append one message from a child agent to its parent mailbox and wake the
131
+ * parent. `sender` is the open agent invocation of the child. The parent
132
+ * handles the message like a result: a root parent runs an Event Turn, and a
133
+ * child parent starts a new agent invocation. Repeat calls with the same
134
+ * `messageKey` are safe.
135
+ */
136
+ async function enqueueAgentMessageToParent(args) {
137
+ const nowMs = args.nowMs ?? Date.now();
138
+ const inboundMessageId = `agent-invocation:${args.sender.invocationId}:message:${args.messageKey}`;
139
+ const summary = `${childAgentLabel(args.sender)} sent a message.`;
140
+ const metadata = {
141
+ kind: "event",
142
+ event: {
143
+ eventKey: inboundMessageId,
144
+ eventType: AGENT_MESSAGE_EVENT_TYPE,
145
+ identifier: args.sender.invocationId,
146
+ namespace: AGENT_INVOCATION_EVENT_NAMESPACE,
147
+ trustedSummary: summary
148
+ }
149
+ };
150
+ await appendAndEnqueueInboundMessage({
151
+ message: {
152
+ conversationId: args.sender.parentConversationId,
153
+ createdAtMs: nowMs,
154
+ delivery: "defer",
155
+ inboundMessageId,
156
+ input: {
157
+ authorId: resultAuthorId(args.sender.actor),
158
+ authorIdentityId: SYSTEM_IDENTITY_ID,
159
+ metadata,
160
+ text: renderMessageInput(args.sender, args.text)
161
+ },
162
+ receivedAtMs: nowMs,
163
+ source: "event"
164
+ },
165
+ queue: args.queue,
166
+ queueDelayMs: EVENT_WAIT_MS,
167
+ state: args.state
168
+ });
169
+ }
170
+ /**
171
+ * Read the agent invocation that one result or message Event refers to: the
172
+ * finished child work for a result, or the open sender work for a message.
173
+ */
174
+ function childAgentInput(message) {
175
+ const metadata = message.input.metadata;
176
+ if (!isEventMailboxMetadata(metadata) || metadata.event.namespace !== AGENT_INVOCATION_EVENT_NAMESPACE) return;
177
+ if (metadata.event.eventType === AGENT_MESSAGE_EVENT_TYPE) return {
178
+ invocationId: metadata.event.identifier,
179
+ kind: "message"
180
+ };
181
+ return isAgentInvocationResultEventType(metadata.event.eventType) ? {
182
+ invocationId: metadata.event.identifier,
183
+ kind: "result"
184
+ } : void 0;
185
+ }
186
+ /**
187
+ * Return whether a stop after this result was sent skipped it, so it starts no
188
+ * work. A message that a child sent before its stop is still delivered.
189
+ */
190
+ function isSkippedAgentResult(input, invocation) {
191
+ return input.kind === "result" && isTerminalAgentInvocation(invocation) && invocation.parentMailboxStatus === "skipped";
192
+ }
193
+ /**
194
+ * Read the agent invocation of one result or message and check that it
195
+ * belongs to a child of the Conversation that received it.
196
+ */
197
+ async function getChildAgentInputInvocation(message, input) {
198
+ const invocation = await getAgentInvocation(input.invocationId);
199
+ if (!invocation || input.kind === "result" && !isTerminalAgentInvocation(invocation) || invocation.parentConversationId !== message.conversationId) throw new Error(`Agent invocation ${input.kind} ${input.invocationId} does not belong to ${message.conversationId}`);
200
+ return invocation;
201
+ }
202
+ /**
203
+ * Give mailbox input that reaches a child Conversation to that child: results
204
+ * and messages from its own child agents, and its own watch events. A child
205
+ * Conversation has no Location, so it cannot run an Event Turn. Each input
206
+ * starts a new agent invocation on the child instead, and that invocation
207
+ * reports to the child's parent. Returns undefined for work that is not
208
+ * mailbox input for a child Conversation.
209
+ */
210
+ async function startAgentInvocationsForChildInput(context, options) {
211
+ const messages = context.attempt.messages;
212
+ const inputs = messages.map(childAgentInput);
213
+ const isAgentInput = inputs.every((input) => input !== void 0);
214
+ const events = isAgentInput ? [] : parseEventMessages(messages);
215
+ if (messages.length === 0 || !isAgentInput && events.length === 0) return;
216
+ const latest = await getLatestAgentInvocationForConversation(context.conversationId);
217
+ if (!latest) return;
218
+ if ((latest.status === "stopped" || isTerminalAgentInvocation(latest) && latest.parentMailboxStatus === "skipped") && (isAgentInput || !messages.every(isWatchEvent))) {
219
+ await context.attempt.ack();
220
+ return { status: "completed" };
221
+ }
222
+ if (!isAgentInput) {
223
+ const delayMs = getEventBatchDelayMs(messages);
224
+ if (delayMs > 0) return {
225
+ status: "deferred",
226
+ delayMs
227
+ };
228
+ const { actor, source } = events[0];
229
+ const invocation = await createAgentInvocationFromLatest({
230
+ input: renderEventBatchInputs(messages, await eventReviewItemInputs(messages)).join("\n\n"),
231
+ invocationId: getAgentInvocationIdForEvents(messages[0].inboundMessageId),
232
+ latest,
233
+ runAs: {
234
+ actor,
235
+ credentialContext: credentialContextForActor(actor, timerWatchCredentialSubject(context.conversationId, messages)),
236
+ source
237
+ }
238
+ });
239
+ await enqueueAgentInvocation(invocation, options);
240
+ await context.attempt.ack();
241
+ return { status: "completed" };
242
+ }
243
+ for (const [index, message] of messages.entries()) {
244
+ const input = inputs[index];
245
+ const source = await getChildAgentInputInvocation(message, input);
246
+ if (isSkippedAgentResult(input, source)) continue;
247
+ const invocation = await createAgentInvocationFromLatest({
248
+ input: message.input.text.trim(),
249
+ invocationId: input.kind === "result" ? getAgentInvocationIdForResult(source.invocationId) : getAgentInvocationIdForMessage(message.inboundMessageId),
250
+ latest
251
+ });
252
+ await enqueueAgentInvocation(invocation, options);
253
+ }
254
+ await context.attempt.ack();
255
+ return { status: "completed" };
256
+ }
257
+ /**
258
+ * Build the worker for all work of a child Conversation. The caller selects
259
+ * it from the stored parent of the Conversation, never from a Turn Source. It
260
+ * starts agent invocations for child input, then runs the agent invocation
261
+ * that owns the work. Work that no agent invocation owns is an error.
262
+ */
263
+ function createChildConversationWorker(agentRunner, options) {
264
+ const invocationWorker = createAgentInvocationWorker(agentRunner, options);
265
+ return async (context) => {
266
+ const started = await startAgentInvocationsForChildInput(context, options);
267
+ if (started) return started;
268
+ const invocationId = await resolveAgentInvocationId(context);
269
+ if (!invocationId) throw new Error(`Child conversation ${context.conversationId} has no agent invocation for this work`);
270
+ return await invocationWorker(context, invocationId);
271
+ };
272
+ }
273
+ /**
274
+ * Run each agent invocation result or message as the Actor that triggered the
275
+ * child, user or system. This is on purpose: the result continues that
276
+ * Actor's work. The Actor comes from SQL, not from mailbox metadata, so the
277
+ * parent Turn has the same authority it had at spawn time. A result that a
278
+ * stop skipped is dropped. Returns undefined when no input is left.
279
+ *
280
+ * TODO(dcramer): Pass the delegated credential subject of a system Actor, such
281
+ * as a timer watch Turn, when system Turns can spawn children that need it.
282
+ */
283
+ async function withAgentInvocationResultActors(work) {
284
+ if (work.kind !== "mailbox") return work;
285
+ const kept = (await Promise.all(work.batch.map(async (entry) => {
286
+ const input = childAgentInput(entry.message);
287
+ if (!input) return entry;
288
+ const invocation = await getChildAgentInputInvocation(entry.message, input);
289
+ return isSkippedAgentResult(input, invocation) ? void 0 : {
290
+ ...entry,
291
+ actor: invocation.actor
292
+ };
293
+ }))).filter((entry) => entry !== void 0);
294
+ return kept.length > 0 ? {
295
+ kind: "mailbox",
296
+ batch: kept
297
+ } : void 0;
298
+ }
299
+ export { withAgentInvocationResultActors as a, result_exports as i, enqueueAgentInvocationResult as n, enqueueAgentMessageToParent as r, createChildConversationWorker as t };
@@ -0,0 +1,11 @@
1
+ // src/chat/agent-invocations/result-event-type.ts
2
+ const AGENT_INVOCATION_RESULT_EVENT_TYPE_PREFIX = "agent_invocation.";
3
+ /** Build the Event type of the parent message for one agent invocation result. */
4
+ function agentInvocationResultEventType(status) {
5
+ return `${AGENT_INVOCATION_RESULT_EVENT_TYPE_PREFIX}${status}`;
6
+ }
7
+ /** True when an Event type names an agent invocation result. */
8
+ function isAgentInvocationResultEventType(eventType) {
9
+ return eventType.startsWith(AGENT_INVOCATION_RESULT_EVENT_TYPE_PREFIX);
10
+ }
11
+ export { isAgentInvocationResultEventType as n, agentInvocationResultEventType as t };
@@ -1,14 +1,11 @@
1
- import { B as authorizationId, D as buildConversationContext, I as upsertConversationMessage, M as markConversationMessage, N as normalizeConversationText, P as recordDeliveredAssistantMessage, Ut as persistWithRetry, Z as saveTurnCheckpoint, a as loadProjection, d as recordAuthorizationCompleted, t as commitAcceptedReply, v as hydrateConversationMessages, y as persistConversationMessages } from "./projection-0UcUeuzn.js";
2
- import { S as setTags, T as withLogContext, p as logException } from "./logging-Qo-7xGp1.js";
3
- import { F as SYSTEM_IDENTITY_ID, x as getConversationStore, y as getConversationEventStore } from "./viewer-BlpnzZZa.js";
4
- import { f as credentialContextForActor } from "./registry-DOnPkI8g.js";
5
- import { j as messageCardText } from "./conversation-DdT7SNar.js";
6
- import { $ as markTurnFailed, et as startActiveTurn } from "./store-G3S0kWSD.js";
7
- import { n as getAssistantReplyText } from "./assistant-reply-CFE-OZMS.js";
8
- import { t as ConversationTurnLifecycleService } from "./turn-lifecycle-BQ8ETk63.js";
9
- import { a as persistThreadStateById, n as getPersistedSandboxState, o as coerceThreadConversationState, r as getPersistedThreadState } from "./thread-state-D6rNGQu9.js";
10
- import { n as scheduleSessionCompletedPluginTasks, t as processPluginTask } from "./task-runner-B65cDumh.js";
11
- import { i as completeAuthPauseTurn, l as buildDeliveredTurnStatePatch, t as finalizeFailedTurnReplyWithEvent, u as loadPendingMessageCards } from "./turn-failure-response-BlO4nuDJ.js";
1
+ import { L as upsertConversationMessage, M as markConversationMessage, N as normalizeConversationText, P as recordDeliveredAssistantMessage, V as authorizationId, Yt as persistWithRetry, a as loadProjection, b as persistConversationMessages, d as recordAuthorizationCompleted, et as saveTurnCheckpoint, j as latestConversationMessageSeq, t as commitAcceptedReply, v as hydrateConversationMessages } from "./projection-CoeMNxJ4.js";
2
+ import { S as setTags, T as withLogContext, p as logException } from "./logging-CMFhLLj4.js";
3
+ import { V as SYSTEM_IDENTITY_ID, x as getConversationStore, y as getConversationEventStore } from "./viewer-CH-ASQzh.js";
4
+ import { f as credentialContextForActor } from "./registry-u-sFYtx_.js";
5
+ import { N as messageCardText } from "./conversation-BusI2uzj.js";
6
+ import { dt as startActiveTurn, f as ConversationTurnLifecycleService, i as completeAuthPauseTurn, l as buildDeliveredTurnStatePatch, m as loadPendingMessageCards, t as finalizeFailedTurnReplyWithEvent, u as buildTurnThreadContext, ut as markTurnFailed } from "./turn-failure-response-BOviBdT-.js";
7
+ import { n as getAssistantReplyText } from "./assistant-reply-CAPafcUY.js";
8
+ import { _t as getPersistedThreadState, bt as coerceThreadConversationState, gt as getPersistedSandboxState, n as scheduleSessionCompletedPluginTasks, t as processPluginTask, yt as persistThreadStateById } from "./task-runner-xPuQmEot.js";
12
9
  import { randomUUID } from "node:crypto";
13
10
  import { createLocalSource, localDestinationSchema } from "@sentry/junior-plugin-api";
14
11
  // src/chat/local/runner.ts
@@ -115,6 +112,7 @@ async function runLocalAgentTurnInContext(input, deps) {
115
112
  createdAtMs: Date.now(),
116
113
  inputMessageIds: [userMessageId],
117
114
  surface: "internal",
115
+ threadContextThroughSeq: latestConversationMessageSeq(conversation),
118
116
  turnId
119
117
  });
120
118
  startActiveTurn({
@@ -184,7 +182,13 @@ async function runLocalAgentTurnInContext(input, deps) {
184
182
  runId: currentRunId,
185
183
  instruction: {
186
184
  text,
187
- context: buildConversationContext(conversation, { excludeMessageIds: [userMessageId] })
185
+ context: await buildTurnThreadContext({
186
+ conversation,
187
+ conversationId: input.conversationId,
188
+ excludeMessageIds: [userMessageId],
189
+ hasHistory: Boolean(messages?.length),
190
+ turnId
191
+ })
188
192
  },
189
193
  history: messages,
190
194
  actor: localActor,
@@ -1,4 +1,4 @@
1
- import { ha as sandboxEgressSignalsResponseSchema } from "./projection-0UcUeuzn.js";
1
+ import { Oa as sandboxEgressSignalsResponseSchema } from "./projection-CoeMNxJ4.js";
2
2
  // src/chat/local/sandbox-egress-signals.ts
3
3
  const SANDBOX_EGRESS_SIGNALS_PATH = "/api/internal/sandbox-egress/signals";
4
4
  const LOCAL_DEV_SERVER_TIMEOUT_MS = 1e3;
@@ -1,8 +1,8 @@
1
1
  import { r as notificationScheduleSchema } from "./schedule-BTp__wrw.js";
2
- import { E as conversationChildAgentTotalsSchema, o as conversationAuxiliaryCostsSchema, r as actorIdentitySchema, x as conversationUsageSchema, y as conversationSummaryReportSchema } from "./conversation-DdT7SNar.js";
3
- import { C as AGENT_INVOCATION_STATUSES, i as fillUtcHours, r as fillUtcDays, s as sumUtcHoursIntoSixHours, y as userInputRequestSchema } from "./reporting-window-B-QP9zX1.js";
4
- import "./automation-Zvx_I9Z5.js";
5
- import "./conversation-pending-messages-Dct5pheX.js";
2
+ import { D as conversationChildAgentTotalsSchema, S as conversationUsageSchema, b as conversationSummaryReportSchema, i as actorIdentitySchema, s as conversationAuxiliaryCostsSchema } from "./conversation-BusI2uzj.js";
3
+ import { C as AGENT_INVOCATION_STATUSES, b as userInputRequestSchema, i as fillUtcHours, r as fillUtcDays, s as sumUtcHoursIntoSixHours } from "./reporting-window-B4TwyuJo.js";
4
+ import "./automation-B-jJN_gM.js";
5
+ import "./conversation-pending-messages-DwehU0Fd.js";
6
6
  import { t as isPushServiceEndpoint } from "./push-endpoint-CO-nomUd.js";
7
7
  import * as z from "zod";
8
8
  import { codeChangeStateSchema, eventMatchSchema } from "@sentry/junior-plugin-api";
@@ -33,8 +33,23 @@ const pinConversationResponseSchema = z.object({ pinnedAt: z.string().datetime()
33
33
  const reorderPinnedConversationsBodySchema = z.object({ conversationIds: z.array(z.string().min(1)).min(1).max(500).refine((ids) => new Set(ids).size === ids.length, { message: "Each Conversation can appear once." }) }).strict();
34
34
  /** The pinned Conversations that got a new place, in order. */
35
35
  const reorderPinnedConversationsResponseSchema = z.object({ conversationIds: z.array(z.string()) }).strict();
36
+ // src/api/schema/conversation-unread.ts
37
+ /** Mark one Conversation read or unread for the signed-in viewer. */
38
+ const markConversationUnreadBodySchema = z.object({ unread: z.boolean() }).strict();
39
+ /**
40
+ * Whether Junior's latest visible reply is after the viewer's read position
41
+ * once the change is stored.
42
+ */
43
+ const conversationUnreadSchema = z.object({ unreadReply: z.boolean() }).strict();
36
44
  // src/api/schema/conversation-archive.ts
45
+ /**
46
+ * Archive or restore one conversation. `applyToChildren` applies to a child
47
+ * only: archive refuses while a descendant is unarchived unless it is true,
48
+ * and restore also restores the descendants archived with the child when it
49
+ * is true. A root archive is per viewer and writes no child rows.
50
+ */
37
51
  const archiveConversationBodySchema = z.object({
52
+ applyToChildren: z.boolean().optional(),
38
53
  archived: z.boolean(),
39
54
  lastSeenAt: z.string().datetime()
40
55
  }).strict();
@@ -43,6 +58,13 @@ const archiveConversationResponseSchema = z.object({ archivedAt: z.string().date
43
58
  const conversationAutoArchiveSchema = z.object({ autoArchive: z.boolean() }).strict();
44
59
  /** Result of archiving all of the viewer's done conversations once. */
45
60
  const archiveDoneConversationsResponseSchema = z.object({ archived: z.number().int().nonnegative() }).strict();
61
+ // src/api/schema/conversation-title.ts
62
+ /** Longest Conversation title that a rename can save. */
63
+ const CONVERSATION_TITLE_MAX_LENGTH = 200;
64
+ /** A participant's new title for one Conversation. Every viewer sees it. */
65
+ const renameConversationBodySchema = z.object({ title: z.string().trim().min(1).max(200) }).strict();
66
+ /** The stored title after the rename. */
67
+ const renameConversationResponseSchema = z.object({ title: z.string().min(1) }).strict();
46
68
  // src/api/schema/conversation-stats.ts
47
69
  const conversationStatsItemSchema = z.object({
48
70
  active: z.number(),
@@ -123,6 +145,15 @@ const stopConversationTurnResponseSchema = z.object({
123
145
  stoppedInboundMessageIds: z.array(z.string().min(1)),
124
146
  stoppedMessages: z.array(stoppedConversationMessageSchema)
125
147
  }).strict();
148
+ // src/api/schema/conversation-continue-in-slack.ts
149
+ /** Public Slack channel Location that a dashboard Conversation moves to. */
150
+ const continueConversationInSlackBodySchema = z.object({ locationId: z.string().min(1) }).strict();
151
+ /** The Slack thread where the Conversation now continues. */
152
+ const continueConversationInSlackResponseSchema = z.object({
153
+ conversationId: z.string().min(1),
154
+ channelName: z.string().min(1).optional(),
155
+ locationUrl: z.string().url().optional()
156
+ }).strict();
126
157
  // src/api/schema/child-agent.ts
127
158
  /**
128
159
  * One direct child agent of a Conversation, from agent invocation records.
@@ -130,14 +161,18 @@ const stopConversationTurnResponseSchema = z.object({
130
161
  * Viewers who cannot see private content get the status, time, and usage, but
131
162
  * not the name, task, title, or error. Usage covers the child Conversation and
132
163
  * all its own child agents, like the detail of that child Conversation.
164
+ * Archived children stay in the report.
133
165
  */
134
166
  const conversationChildAgentSchema = z.object({
135
167
  auxiliaryCosts: conversationAuxiliaryCostsSchema.optional(),
168
+ /** When the child was archived for everyone, or null. */
169
+ archivedAt: z.string().datetime().nullable(),
136
170
  childAgentTotals: conversationChildAgentTotalsSchema.optional(),
137
171
  conversationId: z.string().min(1),
138
172
  cumulativeDurationMs: z.number(),
139
173
  cumulativeUsage: conversationUsageSchema.optional(),
140
174
  error: z.string().min(1).optional(),
175
+ kind: z.enum(["thread", "task"]),
141
176
  name: z.string().min(1).optional(),
142
177
  redacted: z.literal(true).optional(),
143
178
  status: z.enum(AGENT_INVOCATION_STATUSES),
@@ -710,4 +745,27 @@ const statsReportSchema = z.object({
710
745
  windowEnd: z.string(),
711
746
  windowStart: z.string()
712
747
  }).strict();
713
- export { codeOverviewReportSchema as $, avatarParamsSchema as A, dailyConversationActivitySchema as B, createdPersonalTokenSchema as C, revokePersonalTokenResponseSchema as D, personalTokenParamsSchema as E, locationDirectoryReportSchema as F, connectionListSchema as G, pushSubscriptionBodySchema as H, locationParamsSchema as I, disconnectConnectionResponseSchema as J, connectionParamsSchema as K, activityDays as L, personalSpendReportSchema as M, locationActivityDayReportSchema as N, actorDirectoryReportSchema as O, locationDetailReportSchema as P, codeChangeSummarySchema as Q, activityHours as R, createPersonalTokenBodySchema as S, personalTokenMetadataSchema as T, pushSubscriptionDeleteBodySchema as U, notificationSettingsSchema as V, testNotificationResponseSchema as W, codeActivityDaySchema as X, startConnectionResponseSchema as Y, codeChangeSummaryReportSchema as Z, disconnectServiceAccountResponseSchema as _, reorderPinnedConversationsResponseSchema as _t, workspaceBodySchema as a, conversationWatchesReportSchema as at, serviceAccountSchema as b, workspaceRepoSchema as c, stopConversationTurnResponseSchema as ct, reviewItemCountSchema as d, archiveConversationResponseSchema as dt, codePersonReportSchema as et, reviewItemListQuerySchema as f, archiveDoneConversationsResponseSchema as ft, reviewItemWaitingConversationsSchema as g, reorderPinnedConversationsBodySchema as gt, reviewItemSchema as h, pinConversationResponseSchema as ht, deleteWorkspaceResponseSchema as i, conversationWatchSchema as it, personParamsSchema as j, actorProfileReportSchema as k, workspaceSchema as l, conversationStatsReportSchema as lt, reviewItemParamsSchema as m, pinConversationBodySchema as mt, statsReportSchema as n, codeRepositoryReportSchema as nt, workspaceListSchema as o, conversationChildAgentSchema as ot, reviewItemListSchema as p, conversationAutoArchiveSchema as pt, connectionSchema as q, baselineSnapshotSchema as r, codeRepositorySummarySchema as rt, workspaceParamsSchema as s, conversationChildAgentsReportSchema as st, statSchema as t, codeRepositoryParamsSchema as tt, reviewItemActionSchema as u, archiveConversationBodySchema as ut, serviceAccountListSchema as v, conversationCatchUpBodySchema as vt, personalTokenListSchema as w, startServiceAccountSignInResponseSchema as x, serviceAccountParamsSchema as y, conversationCatchUpSchema as yt, activitySixHours as z };
748
+ // src/api/schema/versions.ts
749
+ const versionsQuerySchema = z.object({
750
+ /** The open Conversation, whose token comes back as `conversation`. */
751
+ conversationId: z.string().min(1).optional() }).strict();
752
+ /**
753
+ * Opaque change tokens for the dashboard reads that refresh by themselves.
754
+ * A token changes when the read it covers can change. Compare a token only
755
+ * with an earlier token of the same field.
756
+ */
757
+ const versionsSchema = z.object({
758
+ /**
759
+ * Tree token of the requested Conversation, the same value as the
760
+ * detail report's `CONVERSATION_VERSION_HEADER`. Missing when it does
761
+ * not exist.
762
+ */
763
+ conversation: z.string().min(1).optional(),
764
+ /** The viewer's Conversation feed. */
765
+ conversations: z.string().min(1),
766
+ /** Open Review items that need the viewer. */
767
+ reviewItems: z.string().min(1),
768
+ /** The viewer's rolling model spend. */
769
+ spend: z.string().min(1)
770
+ }).strict();
771
+ export { codeChangeSummaryReportSchema as $, actorDirectoryReportSchema as A, activityHours as B, startServiceAccountSignInResponseSchema as C, pinConversationBodySchema as Ct, personalTokenMetadataSchema as D, conversationCatchUpBodySchema as Dt, personalTokenListSchema as E, reorderPinnedConversationsResponseSchema as Et, locationActivityDayReportSchema as F, pushSubscriptionDeleteBodySchema as G, dailyConversationActivitySchema as H, locationDetailReportSchema as I, connectionParamsSchema as J, testNotificationResponseSchema as K, locationDirectoryReportSchema as L, avatarParamsSchema as M, personParamsSchema as N, personalTokenParamsSchema as O, conversationCatchUpSchema as Ot, personalSpendReportSchema as P, codeActivityDaySchema as Q, locationParamsSchema as R, serviceAccountSchema as S, markConversationUnreadBodySchema as St, createdPersonalTokenSchema as T, reorderPinnedConversationsBodySchema as Tt, notificationSettingsSchema as U, activitySixHours as V, pushSubscriptionBodySchema as W, disconnectConnectionResponseSchema as X, connectionSchema as Y, startConnectionResponseSchema as Z, reviewItemSchema as _, archiveConversationBodySchema as _t, baselineSnapshotSchema as a, codeRepositorySummarySchema as at, serviceAccountListSchema as b, conversationAutoArchiveSchema as bt, workspaceListSchema as c, conversationChildAgentSchema as ct, workspaceSchema as d, continueConversationInSlackResponseSchema as dt, codeChangeSummarySchema as et, reviewItemActionSchema as f, stopConversationTurnResponseSchema as ft, reviewItemParamsSchema as g, renameConversationResponseSchema as gt, reviewItemListSchema as h, renameConversationBodySchema as ht, statsReportSchema as i, codeRepositoryReportSchema as it, actorProfileReportSchema as j, revokePersonalTokenResponseSchema as k, workspaceParamsSchema as l, conversationChildAgentsReportSchema as lt, reviewItemListQuerySchema as m, CONVERSATION_TITLE_MAX_LENGTH as mt, versionsSchema as n, codePersonReportSchema as nt, deleteWorkspaceResponseSchema as o, conversationWatchSchema as ot, reviewItemCountSchema as p, conversationStatsReportSchema as pt, connectionListSchema as q, statSchema as r, codeRepositoryParamsSchema as rt, workspaceBodySchema as s, conversationWatchesReportSchema as st, versionsQuerySchema as t, codeOverviewReportSchema as tt, workspaceRepoSchema as u, continueConversationInSlackBodySchema as ut, reviewItemWaitingConversationsSchema as v, archiveConversationResponseSchema as vt, createPersonalTokenBodySchema as w, pinConversationResponseSchema as wt, serviceAccountParamsSchema as x, conversationUnreadSchema as xt, disconnectServiceAccountResponseSchema as y, archiveDoneConversationsResponseSchema as yt, activityDays as z };