@burdenoff/microfe-botmanor 2026.1120.11 → 2026.1120.13
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/botlit/hooks/index.d.ts +2 -2
- package/dist/botlit/hooks/index.js +2 -2
- package/dist/botlit/hooks/useExecutions.d.ts +30 -18
- package/dist/botlit/hooks/useExecutions.js +42 -49
- package/dist/botlit/hooks/useExecutions.js.map +1 -1
- package/dist/botlit/pages/ChannelsPage.js +4 -3
- package/dist/botlit/pages/ChannelsPage.js.map +1 -1
- package/dist/botlit/pages/ExecutionDetailPage.js +263 -199
- package/dist/botlit/pages/ExecutionDetailPage.js.map +1 -1
- package/dist/botlit/pages/ExecutionsPage.js +333 -210
- package/dist/botlit/pages/ExecutionsPage.js.map +1 -1
- package/dist/botlit/utils/executionStatus.d.ts +16 -0
- package/dist/botlit/utils/executionStatus.js +32 -0
- package/dist/botlit/utils/executionStatus.js.map +1 -0
- package/dist/botlit/utils/formatters.js +4 -2
- package/dist/botlit/utils/formatters.js.map +1 -1
- package/dist/generated/wspace-operations.d.ts +67 -0
- package/dist/generated/wspace-operations.js +101 -73
- package/dist/generated/wspace-operations.js.map +1 -1
- package/dist/generated/wspace-types.d.ts +55 -0
- package/dist/generated/wspace-types.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,329 +1,393 @@
|
|
|
1
1
|
import { useBotlit as e } from "../providers/BotlitProvider.js";
|
|
2
2
|
import { isNative as t, nativeCopyText as n, nativeToast as r } from "../../utils/nativeBridge.js";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
3
|
+
import { useTr as i } from "../../shared/hooks/useTr.js";
|
|
4
|
+
import { BOTMANOR_PERMISSIONS as a } from "../permissions/botmanorPermissions.js";
|
|
5
|
+
import { BotmanorPermissionGate as o } from "../permissions/useBotmanorPermissions.js";
|
|
6
|
+
import { PageLayout as s } from "../components/PageLayout.js";
|
|
7
|
+
import { EmptyState as c } from "../components/EmptyState.js";
|
|
8
|
+
import { Card as l, CardContent as u, CardDescription as d, CardHeader as f, CardTitle as p } from "../components/Card.js";
|
|
9
|
+
import { Button as m } from "../components/Button.js";
|
|
10
|
+
import { Badge as h } from "../components/Badge.js";
|
|
11
|
+
import { ErrorState as g } from "../components/ErrorState.js";
|
|
12
|
+
import { ExecutionModelFallback as ee } from "../components/ExecutionModelFallback.js";
|
|
13
|
+
import { ExecutionFeedback as te } from "../components/ExecutionFeedback.js";
|
|
14
|
+
import { useExecution as ne } from "../hooks/useExecutions.js";
|
|
15
|
+
import { useRerunExecution as _ } from "../hooks/useRerunExecution.js";
|
|
16
|
+
import { useLiveExecution as v } from "../hooks/useExecutionLiveUpdates.js";
|
|
17
|
+
import { LiveIndicator as re } from "../components/LiveIndicator.js";
|
|
18
|
+
import { formatCurrency as ie, formatDuration as y, formatNumber as b, formatRelativeTime as x } from "../utils/formatters.js";
|
|
19
|
+
import { ExecutionStatus as S } from "../../generated/wspace-types.js";
|
|
19
20
|
import "../permissions/index.js";
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
21
|
+
import { executionStatusLabel as ae, readablePayload as C } from "../utils/executionStatus.js";
|
|
22
|
+
import { useEffect as w } from "react";
|
|
23
|
+
import { PagePurpose as T } from "@burdenoff/fe-libs/ui";
|
|
24
|
+
import { Fragment as E, jsx as D, jsxs as O } from "react/jsx-runtime";
|
|
25
|
+
import { useParams as k } from "react-router";
|
|
26
|
+
import { AlertTriangle as A, ArrowLeft as oe, Ban as j, CheckCircle as M, Clock as N, Copy as P, DollarSign as F, Hourglass as I, Play as L, RefreshCw as R, Timer as z, XCircle as B, Zap as V } from "lucide-react";
|
|
27
|
+
import { toast as H } from "sonner";
|
|
26
28
|
// src/botlit/pages/ExecutionDetailPage.tsx
|
|
27
|
-
var
|
|
29
|
+
var U = 3e3, W = /* @__PURE__ */ new Set(["AGENT", "APP"]), G = (e) => {
|
|
28
30
|
switch (e) {
|
|
29
|
-
case
|
|
31
|
+
case S.Completed: return /* @__PURE__ */ D(M, {
|
|
30
32
|
className: "text-status-success-text",
|
|
31
33
|
size: 20
|
|
32
34
|
});
|
|
33
|
-
case
|
|
34
|
-
case E.Timeout: return /* @__PURE__ */ k(V, {
|
|
35
|
+
case S.Failed: return /* @__PURE__ */ D(B, {
|
|
35
36
|
className: "text-status-error-text",
|
|
36
37
|
size: 20
|
|
37
38
|
});
|
|
38
|
-
case
|
|
39
|
+
case S.Timeout: return /* @__PURE__ */ D(z, {
|
|
40
|
+
className: "text-status-error-text",
|
|
41
|
+
size: 20
|
|
42
|
+
});
|
|
43
|
+
case S.Cancelled: return /* @__PURE__ */ D(j, {
|
|
39
44
|
className: "text-text-secondary",
|
|
40
45
|
size: 20
|
|
41
46
|
});
|
|
42
|
-
case
|
|
47
|
+
case S.Running: return /* @__PURE__ */ D(R, {
|
|
43
48
|
className: "text-status-info-text motion-safe:animate-spin",
|
|
44
49
|
size: 20
|
|
45
50
|
});
|
|
46
|
-
case
|
|
51
|
+
case S.Pending: return /* @__PURE__ */ D(I, {
|
|
47
52
|
className: "text-status-warning-text",
|
|
48
53
|
size: 20
|
|
49
54
|
});
|
|
50
|
-
default: return /* @__PURE__ */
|
|
55
|
+
default: return /* @__PURE__ */ D(A, {
|
|
51
56
|
className: "text-text-secondary",
|
|
52
57
|
size: 20
|
|
53
58
|
});
|
|
54
59
|
}
|
|
55
|
-
},
|
|
60
|
+
}, K = (e) => {
|
|
56
61
|
switch (e) {
|
|
57
|
-
case
|
|
58
|
-
case
|
|
59
|
-
case
|
|
60
|
-
case
|
|
61
|
-
case
|
|
62
|
+
case S.Completed: return "success";
|
|
63
|
+
case S.Failed:
|
|
64
|
+
case S.Timeout: return "destructive";
|
|
65
|
+
case S.Pending: return "warning";
|
|
66
|
+
case S.Running: return "default";
|
|
62
67
|
default: return "secondary";
|
|
63
68
|
}
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
+
};
|
|
70
|
+
function q(e, t) {
|
|
71
|
+
let n = e?.[t];
|
|
72
|
+
return typeof n == "string" && n ? n : void 0;
|
|
73
|
+
}
|
|
74
|
+
function J(e, t) {
|
|
75
|
+
let n = e?.[t];
|
|
76
|
+
return typeof n == "number" && Number.isFinite(n) ? n : void 0;
|
|
77
|
+
}
|
|
78
|
+
var Y = ({ label: e, children: t, mono: n }) => /* @__PURE__ */ O("div", { children: [/* @__PURE__ */ D("dt", {
|
|
79
|
+
className: "text-sm text-text-secondary",
|
|
80
|
+
children: e
|
|
81
|
+
}), /* @__PURE__ */ D("dd", {
|
|
82
|
+
className: n ? "font-mono text-sm break-all" : "font-medium break-words",
|
|
83
|
+
children: t
|
|
84
|
+
})] }), X = ({ name: e, id: t }) => t ? /* @__PURE__ */ O(E, { children: [/* @__PURE__ */ D("span", {
|
|
85
|
+
className: "block",
|
|
86
|
+
children: e ?? t
|
|
87
|
+
}), e && /* @__PURE__ */ D("span", {
|
|
88
|
+
className: "block font-mono text-xs text-text-secondary",
|
|
89
|
+
children: t
|
|
90
|
+
})] }) : /* @__PURE__ */ D(E, { children: "—" }), se = ({ execution: e, t }) => {
|
|
91
|
+
let n = e.metadata, r = e.metrics, i = q(n, "model"), a = q(n, "providerType"), o = q(n, "agentVersionId"), s = r?.ragChunks ?? J(n, "ragChunksUsed"), c = J(n, "delegationCount"), m = n?.policyBlockedOutput === !0, h = t("botlit.executions.detail.notRecorded", "Not recorded");
|
|
92
|
+
return /* @__PURE__ */ O(l, { children: [/* @__PURE__ */ O(f, { children: [/* @__PURE__ */ D(p, { children: t("botlit.executions.detail.howAnswered", "How it was answered") }), /* @__PURE__ */ D(d, { children: t("botlit.executions.detail.howAnsweredHint", "What the runtime recorded for this run. Individual model and tool calls are not stored step by step.") })] }), /* @__PURE__ */ D(u, { children: /* @__PURE__ */ O("dl", {
|
|
93
|
+
className: "grid grid-cols-1 gap-6 md:grid-cols-3",
|
|
94
|
+
children: [
|
|
95
|
+
/* @__PURE__ */ D(Y, {
|
|
96
|
+
label: t("botlit.executions.detail.model", "Model"),
|
|
97
|
+
children: i ? a ? `${i} (${a})` : i : h
|
|
98
|
+
}),
|
|
99
|
+
/* @__PURE__ */ D(Y, {
|
|
100
|
+
label: t("botlit.executions.detail.agentVersion", "Agent version"),
|
|
101
|
+
mono: !0,
|
|
102
|
+
children: o ?? h
|
|
103
|
+
}),
|
|
104
|
+
/* @__PURE__ */ D(Y, {
|
|
105
|
+
label: t("botlit.executions.detail.tokenSplit", "Input / output tokens"),
|
|
106
|
+
children: r ? `${b(r.inputTokens)} / ${b(r.outputTokens)}` : h
|
|
107
|
+
}),
|
|
108
|
+
/* @__PURE__ */ D(Y, {
|
|
109
|
+
label: t("botlit.executions.detail.toolCalls", "Tool calls"),
|
|
110
|
+
children: r?.toolCalls ?? h
|
|
111
|
+
}),
|
|
112
|
+
/* @__PURE__ */ D(Y, {
|
|
113
|
+
label: t("botlit.executions.detail.knowledgeChunks", "Knowledge passages used"),
|
|
114
|
+
children: s ?? 0
|
|
115
|
+
}),
|
|
116
|
+
/* @__PURE__ */ D(Y, {
|
|
117
|
+
label: t("botlit.executions.detail.delegations", "Delegations to other agents"),
|
|
118
|
+
children: c ?? 0
|
|
119
|
+
}),
|
|
120
|
+
m && /* @__PURE__ */ D(Y, {
|
|
121
|
+
label: t("botlit.executions.detail.policy", "Policy"),
|
|
122
|
+
children: t("botlit.executions.detail.outputBlocked", "The answer was replaced because a content policy blocked it.")
|
|
123
|
+
})
|
|
124
|
+
]
|
|
125
|
+
}) })] });
|
|
126
|
+
}, Z = () => {
|
|
127
|
+
let E = i(), { executionId: j } = k(), { navigateTo: M } = e(), { data: I, loading: z, error: B, refetch: q } = ne(j), J = _(), Z = I?.status, Q = v(j, Z, () => void q());
|
|
128
|
+
if (w(() => {
|
|
129
|
+
if (Q === "live" || Z !== S.Pending && Z !== S.Running) return;
|
|
130
|
+
let e = setInterval(() => void q(), U);
|
|
69
131
|
return () => clearInterval(e);
|
|
70
132
|
}, [
|
|
71
|
-
$,
|
|
72
133
|
Q,
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
134
|
+
Z,
|
|
135
|
+
q
|
|
136
|
+
]), z && !I) return /* @__PURE__ */ D(s, {
|
|
137
|
+
title: E("botlit.executions.detail.loading", "Loading…"),
|
|
138
|
+
children: /* @__PURE__ */ D("div", { className: "h-96 bg-bg-sunken motion-safe:animate-vc-shimmer rounded-lg" })
|
|
77
139
|
});
|
|
78
|
-
if (
|
|
79
|
-
title: "Execution",
|
|
80
|
-
children: /* @__PURE__ */
|
|
140
|
+
if (B) return /* @__PURE__ */ D(s, {
|
|
141
|
+
title: E("botlit.executions.detail.title", "Execution"),
|
|
142
|
+
children: /* @__PURE__ */ D(g, {
|
|
81
143
|
resource: "this execution",
|
|
82
|
-
error:
|
|
83
|
-
onRetry: () => void
|
|
144
|
+
error: B,
|
|
145
|
+
onRetry: () => void q()
|
|
84
146
|
})
|
|
85
147
|
});
|
|
86
|
-
if (!
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
148
|
+
if (!I) {
|
|
149
|
+
let e = E("botlit.executions.detail.notFound", "Execution not found");
|
|
150
|
+
return /* @__PURE__ */ D(s, {
|
|
151
|
+
title: e,
|
|
152
|
+
children: /* @__PURE__ */ D(c, {
|
|
153
|
+
illustration: "empty-search",
|
|
154
|
+
title: e,
|
|
155
|
+
description: E("botlit.executions.detail.notFoundHint", "This execution does not exist in this workspace."),
|
|
156
|
+
action: /* @__PURE__ */ D(m, {
|
|
157
|
+
onClick: () => M("executions"),
|
|
158
|
+
children: E("botlit.executions.detail.back", "Back to Executions")
|
|
159
|
+
})
|
|
95
160
|
})
|
|
96
|
-
})
|
|
97
|
-
}
|
|
98
|
-
let
|
|
161
|
+
});
|
|
162
|
+
}
|
|
163
|
+
let ce = ae(E, I.status), $ = C(I.output), le = async () => {
|
|
99
164
|
try {
|
|
100
|
-
let e = await
|
|
101
|
-
|
|
165
|
+
let e = await J.mutateAsync(I.id);
|
|
166
|
+
H.success("Re-run started"), M(`executions/${e.id}`);
|
|
102
167
|
} catch (e) {
|
|
103
|
-
|
|
168
|
+
H.error(e instanceof Error ? e.message : "Failed to re-run execution");
|
|
104
169
|
}
|
|
105
170
|
};
|
|
106
|
-
return /* @__PURE__ */
|
|
107
|
-
title: /* @__PURE__ */
|
|
171
|
+
return /* @__PURE__ */ D(s, {
|
|
172
|
+
title: /* @__PURE__ */ O("div", {
|
|
108
173
|
className: "flex items-center gap-3",
|
|
109
174
|
children: [
|
|
110
|
-
/* @__PURE__ */
|
|
175
|
+
/* @__PURE__ */ D(m, {
|
|
111
176
|
variant: "ghost",
|
|
112
177
|
size: "icon",
|
|
113
|
-
onClick: () =>
|
|
114
|
-
|
|
178
|
+
onClick: () => M("executions"),
|
|
179
|
+
"aria-label": E("botlit.executions.detail.back", "Back to Executions"),
|
|
180
|
+
children: /* @__PURE__ */ D(oe, { size: 20 })
|
|
115
181
|
}),
|
|
116
|
-
|
|
117
|
-
/* @__PURE__ */
|
|
182
|
+
G(I.status),
|
|
183
|
+
/* @__PURE__ */ O("div", { children: [/* @__PURE__ */ O("div", {
|
|
118
184
|
className: "flex items-center gap-2",
|
|
119
185
|
children: [
|
|
120
|
-
/* @__PURE__ */
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
] }),
|
|
125
|
-
/* @__PURE__ */ k(m, {
|
|
126
|
-
variant: q(V.status),
|
|
127
|
-
children: V.status
|
|
186
|
+
/* @__PURE__ */ D("span", { children: E("botlit.executions.detail.heading", "Execution {{id}}…", { id: I.id.slice(0, 8) }) }),
|
|
187
|
+
/* @__PURE__ */ D(h, {
|
|
188
|
+
variant: K(I.status),
|
|
189
|
+
children: ce
|
|
128
190
|
}),
|
|
129
|
-
/* @__PURE__ */
|
|
191
|
+
/* @__PURE__ */ D(re, { state: Q })
|
|
130
192
|
]
|
|
131
|
-
}), /* @__PURE__ */
|
|
193
|
+
}), /* @__PURE__ */ O("p", {
|
|
132
194
|
className: "text-sm font-normal text-text-secondary",
|
|
133
195
|
children: [
|
|
134
|
-
|
|
135
|
-
" /
|
|
136
|
-
|
|
196
|
+
I.appName ?? I.appId ?? "—",
|
|
197
|
+
" /",
|
|
198
|
+
" ",
|
|
199
|
+
I.agentName ?? I.agentId ?? "—"
|
|
137
200
|
]
|
|
138
201
|
})] })
|
|
139
202
|
]
|
|
140
203
|
}),
|
|
141
|
-
actions: /* @__PURE__ */
|
|
204
|
+
actions: /* @__PURE__ */ O("div", {
|
|
142
205
|
className: "flex gap-2",
|
|
143
|
-
children: [/* @__PURE__ */
|
|
206
|
+
children: [/* @__PURE__ */ D(m, {
|
|
144
207
|
variant: "outline",
|
|
145
|
-
leftIcon: /* @__PURE__ */
|
|
208
|
+
leftIcon: /* @__PURE__ */ D(P, { size: 16 }),
|
|
146
209
|
onClick: () => {
|
|
147
|
-
n(
|
|
210
|
+
n(I.id), t() && r(E("botlit.executions.detail.copied", "Copied"));
|
|
148
211
|
},
|
|
149
|
-
children: "Copy ID"
|
|
150
|
-
}),
|
|
151
|
-
permission:
|
|
152
|
-
children: /* @__PURE__ */
|
|
153
|
-
leftIcon: /* @__PURE__ */
|
|
154
|
-
onClick: () => void
|
|
155
|
-
isLoading:
|
|
212
|
+
children: E("botlit.executions.detail.copyId", "Copy ID")
|
|
213
|
+
}), W.has(I.type) && /* @__PURE__ */ D(o, {
|
|
214
|
+
permission: a.EXECUTION_CREATE,
|
|
215
|
+
children: /* @__PURE__ */ D(m, {
|
|
216
|
+
leftIcon: /* @__PURE__ */ D(L, { size: 16 }),
|
|
217
|
+
onClick: () => void le(),
|
|
218
|
+
isLoading: J.isPending,
|
|
156
219
|
children: "Run again"
|
|
157
220
|
})
|
|
158
221
|
})]
|
|
159
222
|
}),
|
|
160
|
-
children: /* @__PURE__ */
|
|
223
|
+
children: /* @__PURE__ */ O("div", {
|
|
161
224
|
className: "space-y-6",
|
|
162
225
|
children: [
|
|
163
|
-
/* @__PURE__ */
|
|
164
|
-
icon: /* @__PURE__ */
|
|
165
|
-
children: "This is the record of one agent run — its status, how long it took, the tokens and cost it consumed,
|
|
226
|
+
/* @__PURE__ */ D(T, {
|
|
227
|
+
icon: /* @__PURE__ */ D(N, { size: 18 }),
|
|
228
|
+
children: E("botlit.executions.detail.purpose", "This is the record of one agent run — its status, how long it took, the tokens and cost it consumed, the model and agent version that answered, and its input and output. Use it to debug a failure, understand an unexpected answer, or audit what the agent did on a given request.")
|
|
166
229
|
}),
|
|
167
|
-
/* @__PURE__ */
|
|
230
|
+
/* @__PURE__ */ O("div", {
|
|
168
231
|
className: "grid grid-cols-2 md:grid-cols-4 gap-4",
|
|
169
232
|
children: [
|
|
170
|
-
/* @__PURE__ */
|
|
233
|
+
/* @__PURE__ */ D(l, {
|
|
171
234
|
treatment: "glass",
|
|
172
235
|
glow: !0,
|
|
173
|
-
children: /* @__PURE__ */
|
|
236
|
+
children: /* @__PURE__ */ O(u, {
|
|
174
237
|
className: "pt-6 text-center",
|
|
175
238
|
children: [
|
|
176
|
-
/* @__PURE__ */
|
|
177
|
-
/* @__PURE__ */
|
|
239
|
+
/* @__PURE__ */ D(N, { className: "h-6 w-6 mx-auto mb-2 text-text-secondary" }),
|
|
240
|
+
/* @__PURE__ */ D("p", {
|
|
178
241
|
className: "text-2xl font-bold tabular-nums",
|
|
179
|
-
children:
|
|
242
|
+
children: y(I.duration)
|
|
180
243
|
}),
|
|
181
|
-
/* @__PURE__ */
|
|
244
|
+
/* @__PURE__ */ D("p", {
|
|
182
245
|
className: "text-sm text-text-secondary",
|
|
183
|
-
children: "Duration"
|
|
246
|
+
children: E("botlit.executions.table.duration", "Duration")
|
|
184
247
|
})
|
|
185
248
|
]
|
|
186
249
|
})
|
|
187
250
|
}),
|
|
188
|
-
/* @__PURE__ */
|
|
251
|
+
/* @__PURE__ */ D(l, {
|
|
189
252
|
treatment: "metric",
|
|
190
|
-
children: /* @__PURE__ */
|
|
253
|
+
children: /* @__PURE__ */ O(u, {
|
|
191
254
|
className: "pt-6 text-center",
|
|
192
255
|
children: [
|
|
193
|
-
/* @__PURE__ */
|
|
194
|
-
/* @__PURE__ */
|
|
256
|
+
/* @__PURE__ */ D(V, { className: "h-6 w-6 mx-auto mb-2 text-text-secondary" }),
|
|
257
|
+
/* @__PURE__ */ D("p", {
|
|
195
258
|
className: "text-2xl font-bold tabular-nums",
|
|
196
|
-
children:
|
|
259
|
+
children: I.tokensUsed === null || I.tokensUsed === void 0 ? "—" : b(I.tokensUsed)
|
|
197
260
|
}),
|
|
198
|
-
/* @__PURE__ */
|
|
261
|
+
/* @__PURE__ */ D("p", {
|
|
199
262
|
className: "text-sm text-text-secondary",
|
|
200
|
-
children: "Tokens"
|
|
263
|
+
children: E("botlit.executions.table.tokens", "Tokens")
|
|
201
264
|
})
|
|
202
265
|
]
|
|
203
266
|
})
|
|
204
267
|
}),
|
|
205
|
-
/* @__PURE__ */
|
|
268
|
+
/* @__PURE__ */ D(l, {
|
|
206
269
|
treatment: "metric",
|
|
207
|
-
children: /* @__PURE__ */
|
|
270
|
+
children: /* @__PURE__ */ O(u, {
|
|
208
271
|
className: "pt-6 text-center",
|
|
209
272
|
children: [
|
|
210
|
-
/* @__PURE__ */
|
|
211
|
-
/* @__PURE__ */
|
|
273
|
+
/* @__PURE__ */ D(F, { className: "h-6 w-6 mx-auto mb-2 text-text-secondary" }),
|
|
274
|
+
/* @__PURE__ */ D("p", {
|
|
212
275
|
className: "text-2xl font-bold tabular-nums",
|
|
213
|
-
children:
|
|
276
|
+
children: ie(I.cost)
|
|
214
277
|
}),
|
|
215
|
-
/* @__PURE__ */
|
|
278
|
+
/* @__PURE__ */ D("p", {
|
|
216
279
|
className: "text-sm text-text-secondary",
|
|
217
|
-
children: "Cost"
|
|
280
|
+
children: I.cost === null || I.cost === void 0 ? E("botlit.executions.detail.costUnknown", "Cost (price unknown)") : E("botlit.executions.table.cost", "Cost")
|
|
218
281
|
})
|
|
219
282
|
]
|
|
220
283
|
})
|
|
221
284
|
}),
|
|
222
|
-
/* @__PURE__ */
|
|
285
|
+
/* @__PURE__ */ D(l, {
|
|
223
286
|
treatment: "metric",
|
|
224
|
-
children: /* @__PURE__ */
|
|
287
|
+
children: /* @__PURE__ */ O(u, {
|
|
225
288
|
className: "pt-6 text-center",
|
|
226
289
|
children: [
|
|
227
|
-
/* @__PURE__ */
|
|
228
|
-
/* @__PURE__ */
|
|
290
|
+
/* @__PURE__ */ D(R, { className: "h-6 w-6 mx-auto mb-2 text-text-secondary" }),
|
|
291
|
+
/* @__PURE__ */ D("p", {
|
|
229
292
|
className: "text-2xl font-bold capitalize",
|
|
230
|
-
children:
|
|
293
|
+
children: I.type.toLowerCase()
|
|
231
294
|
}),
|
|
232
|
-
/* @__PURE__ */
|
|
295
|
+
/* @__PURE__ */ D("p", {
|
|
233
296
|
className: "text-sm text-text-secondary",
|
|
234
|
-
children: "Type"
|
|
297
|
+
children: E("botlit.executions.detail.type", "Type")
|
|
235
298
|
})
|
|
236
299
|
]
|
|
237
300
|
})
|
|
238
301
|
})
|
|
239
302
|
]
|
|
240
303
|
}),
|
|
241
|
-
(
|
|
304
|
+
(I.errorMessage || I.errorCode) && /* @__PURE__ */ O(l, { children: [/* @__PURE__ */ O(f, { children: [/* @__PURE__ */ O(p, {
|
|
242
305
|
className: "flex items-center gap-2 text-status-error-text",
|
|
243
|
-
children: [/* @__PURE__ */
|
|
244
|
-
}),
|
|
306
|
+
children: [/* @__PURE__ */ D(A, { size: 18 }), E("botlit.executions.detail.failure", "Failure")]
|
|
307
|
+
}), I.errorCode && /* @__PURE__ */ D(d, { children: I.errorCode })] }), /* @__PURE__ */ O(u, {
|
|
245
308
|
className: "space-y-3",
|
|
246
|
-
children: [
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
309
|
+
children: [
|
|
310
|
+
I.errorCode === "ORPHANED" && /* @__PURE__ */ D("p", {
|
|
311
|
+
className: "text-sm text-text-primary",
|
|
312
|
+
children: E("botlit.executions.detail.orphanedHint", "This run never finished, so the cleanup job closed it as failed.")
|
|
313
|
+
}),
|
|
314
|
+
I.errorMessage && /* @__PURE__ */ D("p", {
|
|
315
|
+
className: "text-sm text-text-primary",
|
|
316
|
+
children: I.errorMessage
|
|
317
|
+
}),
|
|
318
|
+
I.errorDetails && /* @__PURE__ */ D("pre", {
|
|
319
|
+
className: "max-h-64 overflow-auto rounded-lg bg-bg-sunken p-3 font-mono text-xs",
|
|
320
|
+
children: JSON.stringify(I.errorDetails, null, 2)
|
|
321
|
+
})
|
|
322
|
+
]
|
|
253
323
|
})] }),
|
|
254
|
-
/* @__PURE__ */
|
|
324
|
+
/* @__PURE__ */ O(l, { children: [/* @__PURE__ */ D(f, { children: /* @__PURE__ */ D(p, { children: E("botlit.executions.detail.runDetails", "Run details") }) }), /* @__PURE__ */ D(u, { children: /* @__PURE__ */ O("dl", {
|
|
255
325
|
className: "grid grid-cols-1 gap-6 md:grid-cols-3",
|
|
256
326
|
children: [
|
|
257
|
-
/* @__PURE__ */
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
children:
|
|
284
|
-
})
|
|
285
|
-
/* @__PURE__ */
|
|
286
|
-
|
|
287
|
-
children:
|
|
288
|
-
})
|
|
289
|
-
className: "font-medium",
|
|
290
|
-
children: T(V.createdAt)
|
|
291
|
-
})] }),
|
|
292
|
-
/* @__PURE__ */ A("div", { children: [/* @__PURE__ */ k("p", {
|
|
293
|
-
className: "text-sm text-text-secondary",
|
|
294
|
-
children: "Completed"
|
|
295
|
-
}), /* @__PURE__ */ k("p", {
|
|
296
|
-
className: "font-medium",
|
|
297
|
-
children: T(V.completedAt)
|
|
298
|
-
})] })
|
|
327
|
+
/* @__PURE__ */ D(Y, {
|
|
328
|
+
label: E("botlit.executions.detail.executionId", "Execution ID"),
|
|
329
|
+
mono: !0,
|
|
330
|
+
children: I.id
|
|
331
|
+
}),
|
|
332
|
+
/* @__PURE__ */ D(Y, {
|
|
333
|
+
label: E("botlit.executions.filters.bot", "Bot"),
|
|
334
|
+
children: /* @__PURE__ */ D(X, {
|
|
335
|
+
name: I.appName,
|
|
336
|
+
id: I.appId
|
|
337
|
+
})
|
|
338
|
+
}),
|
|
339
|
+
/* @__PURE__ */ D(Y, {
|
|
340
|
+
label: E("botlit.executions.filters.agent", "Agent"),
|
|
341
|
+
children: /* @__PURE__ */ D(X, {
|
|
342
|
+
name: I.agentName,
|
|
343
|
+
id: I.agentId
|
|
344
|
+
})
|
|
345
|
+
}),
|
|
346
|
+
/* @__PURE__ */ D(Y, {
|
|
347
|
+
label: E("botlit.executions.detail.conversation", "Conversation"),
|
|
348
|
+
mono: !0,
|
|
349
|
+
children: I.conversationId ?? "—"
|
|
350
|
+
}),
|
|
351
|
+
/* @__PURE__ */ D(Y, {
|
|
352
|
+
label: E("botlit.executions.table.started", "Started"),
|
|
353
|
+
children: x(I.createdAt)
|
|
354
|
+
}),
|
|
355
|
+
/* @__PURE__ */ D(Y, {
|
|
356
|
+
label: E("botlit.executions.detail.completed", "Completed"),
|
|
357
|
+
children: x(I.completedAt)
|
|
358
|
+
})
|
|
299
359
|
]
|
|
300
360
|
}) })] }),
|
|
301
|
-
/* @__PURE__ */
|
|
361
|
+
/* @__PURE__ */ D(se, {
|
|
362
|
+
execution: I,
|
|
363
|
+
t: E
|
|
364
|
+
}),
|
|
365
|
+
/* @__PURE__ */ O("div", {
|
|
302
366
|
className: "grid grid-cols-1 gap-6 lg:grid-cols-2",
|
|
303
|
-
children: [/* @__PURE__ */
|
|
304
|
-
className: "max-h-96 overflow-auto whitespace-pre-wrap rounded-lg bg-bg-sunken p-3 text-sm",
|
|
305
|
-
children:
|
|
306
|
-
}) })] }), /* @__PURE__ */
|
|
307
|
-
className: "max-h-96 overflow-auto whitespace-pre-wrap rounded-lg bg-bg-sunken p-3 text-sm",
|
|
308
|
-
children:
|
|
309
|
-
}) : /* @__PURE__ */
|
|
367
|
+
children: [/* @__PURE__ */ O(l, { children: [/* @__PURE__ */ D(f, { children: /* @__PURE__ */ D(p, { children: E("botlit.executions.detail.input", "Input") }) }), /* @__PURE__ */ D(u, { children: /* @__PURE__ */ D("pre", {
|
|
368
|
+
className: "max-h-96 overflow-auto whitespace-pre-wrap break-words rounded-lg bg-bg-sunken p-3 font-sans text-sm",
|
|
369
|
+
children: C(I.input) || "—"
|
|
370
|
+
}) })] }), /* @__PURE__ */ O(l, { children: [/* @__PURE__ */ D(f, { children: /* @__PURE__ */ D(p, { children: E("botlit.executions.detail.output", "Output") }) }), /* @__PURE__ */ D(u, { children: $ ? /* @__PURE__ */ D("pre", {
|
|
371
|
+
className: "max-h-96 overflow-auto whitespace-pre-wrap break-words rounded-lg bg-bg-sunken p-3 font-sans text-sm",
|
|
372
|
+
children: $
|
|
373
|
+
}) : /* @__PURE__ */ D("p", {
|
|
310
374
|
className: "text-sm text-text-secondary",
|
|
311
|
-
children: "This run has not produced an output
|
|
375
|
+
children: E("botlit.executions.detail.noOutput", "This run has not produced an output.")
|
|
312
376
|
}) })] })]
|
|
313
377
|
}),
|
|
314
|
-
/* @__PURE__ */
|
|
315
|
-
/* @__PURE__ */
|
|
316
|
-
executionId:
|
|
317
|
-
status:
|
|
378
|
+
/* @__PURE__ */ D(ee, { metadata: I.metadata }),
|
|
379
|
+
/* @__PURE__ */ D(te, {
|
|
380
|
+
executionId: I.id,
|
|
381
|
+
status: I.status
|
|
318
382
|
}),
|
|
319
|
-
|
|
383
|
+
I.metadata && Object.keys(I.metadata).length > 0 && /* @__PURE__ */ O(l, { children: [/* @__PURE__ */ D(f, { children: /* @__PURE__ */ D(p, { children: E("botlit.executions.detail.rawMetadata", "Recorded metadata") }) }), /* @__PURE__ */ D(u, { children: /* @__PURE__ */ D("pre", {
|
|
320
384
|
className: "max-h-64 overflow-auto rounded-lg bg-bg-sunken p-3 font-mono text-xs",
|
|
321
|
-
children: JSON.stringify(
|
|
385
|
+
children: JSON.stringify(I.metadata, null, 2)
|
|
322
386
|
}) })] })
|
|
323
387
|
]
|
|
324
388
|
})
|
|
325
389
|
});
|
|
326
390
|
};
|
|
327
|
-
export {
|
|
391
|
+
export { Z as ExecutionDetailPage };
|
|
328
392
|
|
|
329
393
|
//# sourceMappingURL=ExecutionDetailPage.js.map
|