@sentry/junior 0.112.0 → 0.114.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.
- package/dist/{agent-hooks-6MVTPKP4.js → agent-hooks-WNBUY4OB.js} +8 -8
- package/dist/api/conversations/cursor.d.ts +17 -0
- package/dist/api/conversations/detail.d.ts +40 -18
- package/dist/api/conversations/event-list.d.ts +115 -0
- package/dist/api/conversations/event-page.d.ts +18 -0
- package/dist/api/conversations/events.d.ts +6 -2
- package/dist/api/conversations/projection.d.ts +6 -1
- package/dist/api/schema/conversation.d.ts +228 -51
- package/dist/api/schema.d.ts +2 -2
- package/dist/api/schema.js +7 -1
- package/dist/api.js +461 -139
- package/dist/app.d.ts +2 -0
- package/dist/app.js +33 -24
- package/dist/{catalog-runtime-UEO25P2J.js → catalog-runtime-6O4M6JGA.js} +5 -5
- package/dist/chat/config.d.ts +1 -1
- package/dist/chat/conversations/history.d.ts +86 -0
- package/dist/chat/conversations/projection.d.ts +20 -1
- package/dist/chat/pi/transcript.d.ts +2 -0
- package/dist/chat/services/context-budget.d.ts +7 -2
- package/dist/chat/services/context-compaction.d.ts +28 -1
- package/dist/chat/services/conversation-memory.d.ts +1 -0
- package/dist/chat/services/provider-error.d.ts +40 -0
- package/dist/chat/services/provider-retry.d.ts +3 -6
- package/dist/chat/services/turn-router.d.ts +1 -0
- package/dist/chat/task-execution/state.d.ts +2 -2
- package/dist/chat/task-execution/store.d.ts +1 -1
- package/dist/chat/tools/sandbox/edit-file.d.ts +1 -1
- package/dist/chat/tools/sandbox/text-edits.d.ts +1 -0
- package/dist/{chunk-CSS7JHEM.js → chunk-4FUEG3QY.js} +1 -1
- package/dist/{chunk-AU2JVUDF.js → chunk-5CZ7RETL.js} +1 -1
- package/dist/{chunk-SKEMI4IF.js → chunk-6QWPVTMO.js} +200 -52
- package/dist/{chunk-AWNDKI5K.js → chunk-ABPSDO6M.js} +20 -15
- package/dist/{chunk-QIALGHRN.js → chunk-FIGAF6KL.js} +34 -2
- package/dist/{chunk-TZU3R5OC.js → chunk-K2W4CK7K.js} +1 -1
- package/dist/{chunk-2FJ6WEYV.js → chunk-O4GT7LYB.js} +1 -1
- package/dist/{chunk-ZHP4KNF7.js → chunk-OSKEC4XU.js} +1 -1
- package/dist/{chunk-IV2O4HQJ.js → chunk-PM3PX42K.js} +1 -1
- package/dist/{chunk-NDQL4ESR.js → chunk-RD7EJI7H.js} +2 -2
- package/dist/{chunk-JE23YR3X.js → chunk-S4QDH23A.js} +75 -43
- package/dist/{chunk-GJG67YFS.js → chunk-TLGM5X2M.js} +2 -2
- package/dist/{chunk-VBSVNOLA.js → chunk-VNNBSKCO.js} +5 -5
- package/dist/{chunk-4EJO4HIC.js → chunk-W6RDUAO3.js} +1 -1
- package/dist/{chunk-GR4IB6OQ.js → chunk-WV4UJBAS.js} +431 -96
- package/dist/{chunk-66IP6WED.js → chunk-XLFBQJUO.js} +4 -4
- package/dist/{chunk-X3SP5RDW.js → chunk-YU6PO42Q.js} +1 -1
- package/dist/{chunk-PK4ETCUQ.js → chunk-ZGXH3REA.js} +226 -215
- package/dist/cli/chat.js +19 -19
- package/dist/cli/check.js +6 -6
- package/dist/cli/plugins.js +11 -11
- package/dist/cli/snapshot-warmup.js +8 -8
- package/dist/cli/upgrade.js +5 -5
- package/dist/{db-P5H5RVQV.js → db-4VLP7KBF.js} +5 -5
- package/dist/instrumentation.js +2 -2
- package/dist/nitro.js +2 -2
- package/dist/{runner-B4ZDUO3R.js → runner-IPXLWQOF.js} +12 -13
- package/dist/{skills-GWTOZ3XV.js → skills-QCNZISNF.js} +6 -6
- package/dist/{validation-QFIC6XH6.js → validation-I2BW3UHD.js} +6 -6
- package/dist/version.js +1 -1
- package/package.json +6 -6
|
@@ -24,6 +24,13 @@ var conversationSurfaceSchema = z2.enum([
|
|
|
24
24
|
]);
|
|
25
25
|
var conversationUsageSchema = usageSchema;
|
|
26
26
|
var conversationParamsSchema = z2.object({ conversationId: z2.string().min(1) }).strict();
|
|
27
|
+
var conversationDetailQuerySchema = z2.object({
|
|
28
|
+
limit: z2.coerce.number().int().min(1).max(1e3).default(500)
|
|
29
|
+
}).strict();
|
|
30
|
+
var conversationEventsQuerySchema = z2.object({
|
|
31
|
+
before: z2.string().min(1),
|
|
32
|
+
limit: z2.coerce.number().int().min(1).max(1e3).default(500)
|
|
33
|
+
}).strict();
|
|
27
34
|
var conversationFeedQuerySchema = z2.object({
|
|
28
35
|
actorEmail: z2.string().trim().email().transform((value) => value.toLowerCase()).optional()
|
|
29
36
|
}).strict();
|
|
@@ -74,26 +81,26 @@ var conversationReportMessageHandledEventDataSchema = z2.object({
|
|
|
74
81
|
type: z2.literal("message_handled"),
|
|
75
82
|
messageId: z2.string().min(1)
|
|
76
83
|
}).strict();
|
|
77
|
-
var conversationReportToolStartedEventDataSchema = z2.object({
|
|
78
|
-
type: z2.literal("tool_started"),
|
|
79
|
-
toolCallId: z2.string().min(1),
|
|
80
|
-
name: z2.string().min(1)
|
|
81
|
-
}).strict();
|
|
82
84
|
var conversationReportToolCallSchema = z2.object({
|
|
83
85
|
toolCallId: z2.string().min(1),
|
|
84
86
|
name: z2.string().min(1),
|
|
85
|
-
|
|
86
|
-
|
|
87
|
+
status: z2.enum(["running", "completed", "error"]),
|
|
88
|
+
startedAt: z2.string().datetime().optional(),
|
|
89
|
+
startedSeq: z2.number().int().nonnegative().optional(),
|
|
90
|
+
input: z2.unknown().optional(),
|
|
91
|
+
output: z2.unknown().optional()
|
|
92
|
+
}).strict().superRefine((call, context) => {
|
|
93
|
+
if (call.startedAt === void 0 !== (call.startedSeq === void 0)) {
|
|
94
|
+
context.addIssue({
|
|
95
|
+
code: "custom",
|
|
96
|
+
message: "tool start sequence and timestamp must be provided together"
|
|
97
|
+
});
|
|
98
|
+
}
|
|
99
|
+
});
|
|
87
100
|
var conversationReportToolCallsEventDataSchema = z2.object({
|
|
88
101
|
type: z2.literal("tool_calls"),
|
|
89
102
|
calls: z2.array(conversationReportToolCallSchema).min(1)
|
|
90
103
|
}).strict();
|
|
91
|
-
var conversationReportToolResultEventDataSchema = z2.object({
|
|
92
|
-
type: z2.literal("tool_result"),
|
|
93
|
-
toolCallId: z2.string().min(1),
|
|
94
|
-
outcome: z2.enum(["completed", "error"]),
|
|
95
|
-
output: z2.unknown().optional()
|
|
96
|
-
}).strict();
|
|
97
104
|
var conversationReportTurnLifecycleEventDataSchema = z2.discriminatedUnion(
|
|
98
105
|
"state",
|
|
99
106
|
[
|
|
@@ -110,7 +117,30 @@ var conversationReportTurnLifecycleEventDataSchema = z2.discriminatedUnion(
|
|
|
110
117
|
}).strict()
|
|
111
118
|
]
|
|
112
119
|
);
|
|
113
|
-
var
|
|
120
|
+
var conversationReportTurnRoutedEventDataSchema = z2.object({
|
|
121
|
+
type: z2.literal("turn_routed"),
|
|
122
|
+
turnId: z2.string().min(1),
|
|
123
|
+
modelProfile: z2.string().min(1),
|
|
124
|
+
modelId: z2.string().min(1),
|
|
125
|
+
reasoningLevel: z2.string().min(1),
|
|
126
|
+
confidence: z2.number().min(0).max(1).optional(),
|
|
127
|
+
source: z2.enum(["configured", "inherited", "router"])
|
|
128
|
+
}).strict();
|
|
129
|
+
var conversationReportCompactionEventDataSchema = z2.object({
|
|
130
|
+
type: z2.literal("compaction"),
|
|
131
|
+
modelProfile: z2.string().min(1).optional(),
|
|
132
|
+
modelId: z2.string().min(1).optional(),
|
|
133
|
+
details: z2.object({
|
|
134
|
+
reason: z2.literal("capacity"),
|
|
135
|
+
estimatedInputTokens: z2.number().int().nonnegative(),
|
|
136
|
+
replacementInputTokens: z2.number().int().nonnegative().optional(),
|
|
137
|
+
triggerTokens: z2.number().int().nonnegative(),
|
|
138
|
+
inputLimitTokens: z2.number().int().positive(),
|
|
139
|
+
inputMessageCount: z2.number().int().nonnegative(),
|
|
140
|
+
retainedMessageCount: z2.number().int().nonnegative(),
|
|
141
|
+
summaryChars: z2.number().int().nonnegative()
|
|
142
|
+
}).strict().optional()
|
|
143
|
+
}).strict();
|
|
114
144
|
var conversationReportHandoffEventDataSchema = z2.object({
|
|
115
145
|
type: z2.literal("handoff"),
|
|
116
146
|
modelProfile: z2.string().min(1),
|
|
@@ -118,28 +148,24 @@ var conversationReportHandoffEventDataSchema = z2.object({
|
|
|
118
148
|
reasoningLevel: z2.string().min(1).optional(),
|
|
119
149
|
triggeringToolCallId: z2.string().min(1).optional()
|
|
120
150
|
}).strict();
|
|
121
|
-
var
|
|
122
|
-
type: z2.literal("
|
|
151
|
+
var conversationReportSubagentEventDataSchema = z2.object({
|
|
152
|
+
type: z2.literal("subagent"),
|
|
153
|
+
startedSeq: z2.number().int().nonnegative(),
|
|
154
|
+
startedAt: z2.string().datetime(),
|
|
123
155
|
childConversationId: z2.string().min(1),
|
|
124
156
|
subagentKind: z2.string().min(1),
|
|
125
|
-
parentToolCallId: z2.string().min(1).optional()
|
|
126
|
-
|
|
127
|
-
var conversationReportSubagentEndedEventDataSchema = z2.object({
|
|
128
|
-
type: z2.literal("subagent_ended"),
|
|
129
|
-
startedSeq: z2.number().int().nonnegative(),
|
|
130
|
-
outcome: z2.enum(["success", "error", "aborted"])
|
|
157
|
+
parentToolCallId: z2.string().min(1).optional(),
|
|
158
|
+
status: z2.enum(["running", "completed", "error", "aborted"])
|
|
131
159
|
}).strict();
|
|
132
160
|
var conversationReportEventDataSchema = z2.discriminatedUnion("type", [
|
|
133
161
|
conversationReportMessageEventDataSchema,
|
|
134
162
|
conversationReportMessageHandledEventDataSchema,
|
|
135
|
-
conversationReportToolStartedEventDataSchema,
|
|
136
163
|
conversationReportToolCallsEventDataSchema,
|
|
137
|
-
conversationReportToolResultEventDataSchema,
|
|
138
164
|
conversationReportTurnLifecycleEventDataSchema,
|
|
165
|
+
conversationReportTurnRoutedEventDataSchema,
|
|
139
166
|
conversationReportCompactionEventDataSchema,
|
|
140
167
|
conversationReportHandoffEventDataSchema,
|
|
141
|
-
|
|
142
|
-
conversationReportSubagentEndedEventDataSchema
|
|
168
|
+
conversationReportSubagentEventDataSchema
|
|
143
169
|
]);
|
|
144
170
|
var conversationReportEventSchema = z2.object({
|
|
145
171
|
seq: z2.number().int().nonnegative(),
|
|
@@ -161,13 +187,7 @@ var conversationModelUsageSchema = z2.object({
|
|
|
161
187
|
modelId: z2.string(),
|
|
162
188
|
usage: conversationUsageSchema
|
|
163
189
|
}).strict();
|
|
164
|
-
|
|
165
|
-
modelUsage: z2.array(conversationModelUsageSchema).optional(),
|
|
166
|
-
events: z2.array(conversationReportEventSchema),
|
|
167
|
-
eventHistory: conversationEventHistorySchema,
|
|
168
|
-
generatedAt: z2.string(),
|
|
169
|
-
sentryConversationUrl: z2.string().optional()
|
|
170
|
-
}).strict().superRefine((report, context) => {
|
|
190
|
+
function validateConversationEvents(report, context) {
|
|
171
191
|
if (report.eventHistory.status === "expired" && report.events.length > 0) {
|
|
172
192
|
context.addIssue({
|
|
173
193
|
code: "custom",
|
|
@@ -201,22 +221,31 @@ var conversationDetailReportSchema = conversationSummaryReportSchema.extend({
|
|
|
201
221
|
});
|
|
202
222
|
}
|
|
203
223
|
}
|
|
204
|
-
if (report.eventHistory.status === "redacted" && event.data.type === "tool_calls" && event.data.calls.some(
|
|
224
|
+
if (report.eventHistory.status === "redacted" && event.data.type === "tool_calls" && event.data.calls.some(
|
|
225
|
+
(call) => call.input !== void 0 || call.output !== void 0
|
|
226
|
+
)) {
|
|
205
227
|
context.addIssue({
|
|
206
228
|
code: "custom",
|
|
207
229
|
path: ["events", index, "data"],
|
|
208
|
-
message: "redacted event history must redact tool
|
|
209
|
-
});
|
|
210
|
-
}
|
|
211
|
-
if (report.eventHistory.status === "redacted" && event.data.type === "tool_result" && event.data.output !== void 0) {
|
|
212
|
-
context.addIssue({
|
|
213
|
-
code: "custom",
|
|
214
|
-
path: ["events", index, "data"],
|
|
215
|
-
message: "redacted event history must redact tool outputs"
|
|
230
|
+
message: "redacted event history must redact tool payloads"
|
|
216
231
|
});
|
|
217
232
|
}
|
|
218
233
|
}
|
|
219
|
-
}
|
|
234
|
+
}
|
|
235
|
+
var conversationDetailReportSchema = conversationSummaryReportSchema.extend({
|
|
236
|
+
modelUsage: z2.array(conversationModelUsageSchema).optional(),
|
|
237
|
+
events: z2.array(conversationReportEventSchema),
|
|
238
|
+
eventHistory: conversationEventHistorySchema,
|
|
239
|
+
previousCursor: z2.string().min(1).optional(),
|
|
240
|
+
generatedAt: z2.string(),
|
|
241
|
+
sentryConversationUrl: z2.string().optional()
|
|
242
|
+
}).strict().superRefine(validateConversationEvents);
|
|
243
|
+
var conversationEventPageSchema = z2.object({
|
|
244
|
+
events: z2.array(conversationReportEventSchema),
|
|
245
|
+
eventHistory: conversationEventHistorySchema,
|
|
246
|
+
previousCursor: z2.string().min(1).optional(),
|
|
247
|
+
generatedAt: z2.string()
|
|
248
|
+
}).strict().superRefine(validateConversationEvents);
|
|
220
249
|
var conversationFeedSchema = z2.object({
|
|
221
250
|
conversations: z2.array(conversationSummaryReportSchema),
|
|
222
251
|
source: z2.literal("conversation_index"),
|
|
@@ -378,6 +407,8 @@ var actorProfileReportSchema = z5.object({
|
|
|
378
407
|
export {
|
|
379
408
|
apiErrorSchema,
|
|
380
409
|
conversationParamsSchema,
|
|
410
|
+
conversationDetailQuerySchema,
|
|
411
|
+
conversationEventsQuerySchema,
|
|
381
412
|
conversationFeedQuerySchema,
|
|
382
413
|
archiveConversationBodySchema,
|
|
383
414
|
archiveConversationResponseSchema,
|
|
@@ -386,6 +417,7 @@ export {
|
|
|
386
417
|
conversationReportEventSchema,
|
|
387
418
|
conversationEventHistorySchema,
|
|
388
419
|
conversationDetailReportSchema,
|
|
420
|
+
conversationEventPageSchema,
|
|
389
421
|
conversationFeedSchema,
|
|
390
422
|
conversationStatsReportSchema,
|
|
391
423
|
dailyConversationActivitySchema,
|
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
import {
|
|
2
2
|
SANDBOX_WORKSPACE_ROOT,
|
|
3
3
|
getStateAdapter
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-YU6PO42Q.js";
|
|
5
5
|
import {
|
|
6
6
|
isConversationChannel,
|
|
7
7
|
isConversationScopedChannel,
|
|
8
8
|
isDmChannel,
|
|
9
9
|
normalizeSlackConversationId
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-RD7EJI7H.js";
|
|
11
11
|
import {
|
|
12
12
|
getDb
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-FIGAF6KL.js";
|
|
14
14
|
import {
|
|
15
15
|
botConfig,
|
|
16
16
|
completeObject,
|
|
17
17
|
embedTexts,
|
|
18
18
|
standardModelId
|
|
19
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-ZGXH3REA.js";
|
|
20
20
|
import {
|
|
21
21
|
isActorUserId,
|
|
22
22
|
parseActorUserId
|
|
@@ -25,7 +25,7 @@ import {
|
|
|
25
25
|
logException,
|
|
26
26
|
logInfo,
|
|
27
27
|
logWarn
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-4FUEG3QY.js";
|
|
29
29
|
import {
|
|
30
30
|
parseSlackChannelReferenceId,
|
|
31
31
|
parseSlackMessageTs,
|