@burdenoff/microfe-botmanor 2026.1127.3 → 2026.1127.4

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,21 +1,22 @@
1
- import { useBotlit as e } from "../providers/BotlitProvider.js";
2
- import { isNative as t, nativeImpact as n, nativeNotify as r } from "../../utils/nativeBridge.js";
3
- import { BOTMANOR_PERMISSIONS as i } from "../permissions/botmanorPermissions.js";
4
- import { BotmanorPermissionGate as a } from "../permissions/useBotmanorPermissions.js";
5
- import { PageLayout as o } from "../components/PageLayout.js";
6
- import { EmptyState as s } from "../components/EmptyState.js";
7
- import { Card as c, CardContent as l, CardDescription as u, CardHeader as d, CardTitle as f } from "../components/Card.js";
8
- import { Button as p } from "../components/Button.js";
9
- import { Badge as m, StatusBadge as h } from "../components/Badge.js";
10
- import { FormField as g, Input as _, Textarea as ee } from "../components/Input.js";
11
- import { useCreateRetrievalProfile as te, useDeleteRetrievalProfile as v, useRetrievalProfile as y, useUpdateRetrievalProfile as b } from "../hooks/useRetrievalProfiles.js";
12
- import { formatRelativeTime as x } from "../utils/formatters.js";
1
+ import { useTr as e } from "../../shared/hooks/useTr.js";
2
+ import { useBotlit as t } from "../providers/BotlitProvider.js";
3
+ import { isNative as n, nativeImpact as r, nativeNotify as i } from "../../utils/nativeBridge.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, StatusBadge as g } from "../components/Badge.js";
11
+ import { FormField as _, Input as v, Textarea as y } from "../components/Input.js";
12
+ import { useCreateRetrievalProfile as b, useDeleteRetrievalProfile as x, useRetrievalProfile as ee, useUpdateRetrievalProfile as S } from "../hooks/useRetrievalProfiles.js";
13
+ import { formatRelativeTime as C } from "../utils/formatters.js";
13
14
  import "../permissions/index.js";
14
- import { useEffect as S, useState as C } from "react";
15
- import { PagePurpose as w, ThemedSelect as T } from "@burdenoff/fe-libs/ui";
16
- import { Fragment as E, jsx as D, jsxs as O } from "react/jsx-runtime";
17
- import { useParams as ne } from "react-router";
18
- import { ArrowLeft as re, CheckSquare as k, Edit as A, FileText as j, Search as M, Settings as N, Target as P, Trash2 as ie } from "lucide-react";
15
+ import { useEffect as w, useState as T } from "react";
16
+ import { PagePurpose as E, ThemedSelect as D } from "@burdenoff/fe-libs/ui";
17
+ import { Fragment as O, jsx as k, jsxs as A } from "react/jsx-runtime";
18
+ import { useParams as j } from "react-router";
19
+ import { ArrowLeft as M, CheckSquare as N, Edit as te, FileText as ne, Search as re, Settings as P, Target as ie, Trash2 as ae } from "lucide-react";
19
20
  import { toast as F } from "sonner";
20
21
  // src/botlit/pages/RetrievalProfileDetailPage.tsx
21
22
  var I = {
@@ -85,169 +86,169 @@ function H(e, t) {
85
86
  return e.trim() !== "" && Number.isFinite(n) ? n : t;
86
87
  }
87
88
  var U = ({ isNew: z = !1 }) => {
88
- let { profileId: U } = ne(), { navigateTo: W } = e(), { data: G, loading: K, refetch: q } = y(z ? void 0 : U), { create: J, loading: ae } = te(), { update: oe, loading: se } = b(), { remove: ce, loading: le } = v(), [Y, X] = C(z), [ue, Z] = C(!1), [Q, $] = C(I);
89
- if (S(() => {
90
- G && !z && $(B(G));
91
- }, [G, z]), K && !z) return /* @__PURE__ */ D(o, {
92
- title: "Loading...",
93
- children: /* @__PURE__ */ D("div", { className: "h-96 bg-bg-sunken motion-safe:animate-vc-shimmer rounded-lg" })
89
+ let U = e(), { profileId: W } = j(), { navigateTo: G } = t(), { data: K, loading: q, refetch: oe } = ee(z ? void 0 : W), { create: se, loading: ce } = b(), { update: le, loading: ue } = S(), { remove: de, loading: J } = x(), [Y, X] = T(z), [fe, Z] = T(!1), [Q, $] = T(I);
90
+ if (w(() => {
91
+ K && !z && $(B(K));
92
+ }, [K, z]), q && !z) return /* @__PURE__ */ k(s, {
93
+ title: U("botlit.retrievalProfileDetail.loading", "Loading..."),
94
+ children: /* @__PURE__ */ k("div", { className: "h-96 bg-bg-sunken motion-safe:animate-vc-shimmer rounded-lg" })
94
95
  });
95
- if (!G && !z) return /* @__PURE__ */ D(o, {
96
- title: "Profile Not Found",
97
- children: /* @__PURE__ */ D(s, {
96
+ if (!K && !z) return /* @__PURE__ */ k(s, {
97
+ title: U("botlit.retrievalProfileDetail.profileNotFound", "Profile Not Found"),
98
+ children: /* @__PURE__ */ k(c, {
98
99
  kind: "not-found",
99
100
  illustration: "empty-files",
100
- title: "Profile Not Found",
101
- description: "The retrieval profile doesn't exist.",
102
- action: /* @__PURE__ */ D(p, {
103
- onClick: () => W("retrieval-profiles"),
104
- children: "Back to Profiles"
101
+ title: U("botlit.retrievalProfileDetail.profileNotFound", "Profile Not Found"),
102
+ description: U("botlit.retrievalProfileDetail.theRetrievalProfileDoesnT", "The retrieval profile doesn't exist."),
103
+ action: /* @__PURE__ */ k(m, {
104
+ onClick: () => G("retrieval-profiles"),
105
+ children: U("botlit.retrievalProfileDetail.backToProfiles", "Back to Profiles")
105
106
  })
106
107
  })
107
108
  });
108
- let de = async () => {
109
- if (!Q.name.trim()) F.error("Name is required");
109
+ let pe = async () => {
110
+ if (!Q.name.trim()) F.error(U("botlit.retrievalProfileDetail.nameIsRequired", "Name is required"));
110
111
  else try {
111
112
  if (z) {
112
- let e = await J(V(Q));
113
- F.success(`Profile "${e.name}" created`), W(`retrieval-profiles/${e.id}`);
113
+ let e = await se(V(Q));
114
+ F.success(U("botlit.retrievalProfileDetail.profileNameCreated", "Profile \"{{name}}\" created", { name: e.name })), G(`retrieval-profiles/${e.id}`);
114
115
  return;
115
116
  }
116
- if (!U) return;
117
- await oe({
118
- profileId: U,
117
+ if (!W) return;
118
+ await le({
119
+ profileId: W,
119
120
  input: V(Q)
120
- }), await q(), F.success("Retrieval profile updated"), X(!1);
121
+ }), await oe(), F.success(U("botlit.retrievalProfileDetail.retrievalProfileUpdated", "Retrieval profile updated")), X(!1);
121
122
  } catch (e) {
122
- F.error(e instanceof Error ? e.message : "Failed to save retrieval profile");
123
+ F.error(e instanceof Error ? e.message : U("botlit.retrievalProfileDetail.failedToSaveRetrievalProfile", "Failed to save retrieval profile"));
123
124
  }
124
- }, fe = async () => {
125
- if (U) try {
126
- await ce(U), t() && r("success"), F.success("Retrieval profile deleted"), W("retrieval-profiles");
125
+ }, me = async () => {
126
+ if (W) try {
127
+ await de(W), n() && i("success"), F.success(U("botlit.retrievalProfileDetail.retrievalProfileDeleted", "Retrieval profile deleted")), G("retrieval-profiles");
127
128
  } catch (e) {
128
- t() && r("error"), F.error(e instanceof Error ? e.message : "Failed to delete retrieval profile");
129
+ n() && i("error"), F.error(e instanceof Error ? e.message : U("botlit.retrievalProfileDetail.failedToDeleteRetrievalProfile", "Failed to delete retrieval profile"));
129
130
  }
130
131
  };
131
- return /* @__PURE__ */ D(o, {
132
- title: /* @__PURE__ */ O("div", {
132
+ return /* @__PURE__ */ k(s, {
133
+ title: /* @__PURE__ */ A("div", {
133
134
  className: "flex items-center gap-3",
134
135
  children: [
135
- /* @__PURE__ */ D(p, {
136
+ /* @__PURE__ */ k(m, {
136
137
  variant: "ghost",
137
138
  size: "icon",
138
- onClick: () => W("retrieval-profiles"),
139
- children: /* @__PURE__ */ D(re, { size: 20 })
139
+ onClick: () => G("retrieval-profiles"),
140
+ children: /* @__PURE__ */ k(M, { size: 20 })
140
141
  }),
141
- /* @__PURE__ */ D(M, {
142
+ /* @__PURE__ */ k(re, {
142
143
  size: 24,
143
144
  className: "text-primary"
144
145
  }),
145
- /* @__PURE__ */ O("div", { children: [/* @__PURE__ */ O("div", {
146
+ /* @__PURE__ */ A("div", { children: [/* @__PURE__ */ A("div", {
146
147
  className: "flex items-center gap-2",
147
- children: [/* @__PURE__ */ D("span", { children: z ? "New Retrieval Profile" : G?.name }), !z && G && /* @__PURE__ */ D(h, { status: G.status })]
148
- }), !z && G?.description && /* @__PURE__ */ D("p", {
148
+ children: [/* @__PURE__ */ k("span", { children: z ? U("botlit.retrievalProfileDetail.newRetrievalProfile", "New Retrieval Profile") : K?.name }), !z && K && /* @__PURE__ */ k(g, { status: K.status })]
149
+ }), !z && K?.description && /* @__PURE__ */ k("p", {
149
150
  className: "text-sm font-normal text-text-secondary",
150
- children: G.description
151
+ children: K.description
151
152
  })] })
152
153
  ]
153
154
  }),
154
- actions: /* @__PURE__ */ D("div", {
155
+ actions: /* @__PURE__ */ k("div", {
155
156
  className: "flex gap-2",
156
- children: Y ? /* @__PURE__ */ O(E, { children: [/* @__PURE__ */ D(p, {
157
+ children: Y ? /* @__PURE__ */ A(O, { children: [/* @__PURE__ */ k(m, {
157
158
  variant: "outline",
158
159
  onClick: () => {
159
- z ? W("retrieval-profiles") : (G && $(B(G)), X(!1));
160
+ z ? G("retrieval-profiles") : (K && $(B(K)), X(!1));
160
161
  },
161
- children: "Cancel"
162
- }), /* @__PURE__ */ D(p, {
163
- onClick: de,
164
- isLoading: ae || se,
165
- children: z ? "Create Profile" : "Save Changes"
166
- })] }) : /* @__PURE__ */ O(E, { children: [/* @__PURE__ */ D(a, {
167
- permission: i.RETRIEVAL_PROFILE_UPDATE,
168
- children: /* @__PURE__ */ D(p, {
162
+ children: U("botlit.retrievalProfileDetail.cancel", "Cancel")
163
+ }), /* @__PURE__ */ k(m, {
164
+ onClick: pe,
165
+ isLoading: ce || ue,
166
+ children: z ? U("botlit.retrievalProfileDetail.createProfile", "Create Profile") : U("botlit.retrievalProfileDetail.saveChanges", "Save Changes")
167
+ })] }) : /* @__PURE__ */ A(O, { children: [/* @__PURE__ */ k(o, {
168
+ permission: a.RETRIEVAL_PROFILE_UPDATE,
169
+ children: /* @__PURE__ */ k(m, {
169
170
  variant: "outline",
170
- leftIcon: /* @__PURE__ */ D(A, { size: 16 }),
171
+ leftIcon: /* @__PURE__ */ k(te, { size: 16 }),
171
172
  onClick: () => {
172
- G && $(B(G)), X(!0);
173
+ K && $(B(K)), X(!0);
173
174
  },
174
- children: "Edit"
175
+ children: U("botlit.retrievalProfileDetail.edit", "Edit")
175
176
  })
176
- }), ue ? /* @__PURE__ */ O("div", {
177
+ }), fe ? /* @__PURE__ */ A("div", {
177
178
  className: "flex gap-2",
178
- children: [/* @__PURE__ */ D(p, {
179
+ children: [/* @__PURE__ */ k(m, {
179
180
  variant: "outline",
180
181
  size: "sm",
181
182
  onClick: () => Z(!1),
182
- children: "Cancel"
183
- }), /* @__PURE__ */ D(p, {
183
+ children: U("botlit.retrievalProfileDetail.cancel", "Cancel")
184
+ }), /* @__PURE__ */ k(m, {
184
185
  variant: "destructive",
185
186
  size: "sm",
186
187
  onClick: () => {
187
- n("medium"), fe();
188
+ r("medium"), me();
188
189
  },
189
- isLoading: le,
190
- children: "Confirm Delete"
190
+ isLoading: J,
191
+ children: U("botlit.retrievalProfileDetail.confirmDelete", "Confirm Delete")
191
192
  })]
192
- }) : /* @__PURE__ */ D(a, {
193
- permission: i.RETRIEVAL_PROFILE_DELETE,
194
- children: /* @__PURE__ */ D(p, {
193
+ }) : /* @__PURE__ */ k(o, {
194
+ permission: a.RETRIEVAL_PROFILE_DELETE,
195
+ children: /* @__PURE__ */ k(m, {
195
196
  variant: "destructive",
196
- leftIcon: /* @__PURE__ */ D(ie, { size: 16 }),
197
+ leftIcon: /* @__PURE__ */ k(ae, { size: 16 }),
197
198
  onClick: () => Z(!0),
198
- children: "Delete"
199
+ children: U("botlit.retrievalProfileDetail.delete", "Delete")
199
200
  })
200
201
  })] })
201
202
  }),
202
- children: /* @__PURE__ */ O("div", {
203
+ children: /* @__PURE__ */ A("div", {
203
204
  className: "space-y-6",
204
205
  children: [
205
- /* @__PURE__ */ D(w, {
206
- icon: /* @__PURE__ */ D(N, { size: 18 }),
207
- children: "This profile defines exactly how an agent searches your knowledge — the retrieval mode, how many results to pull, whether to rerank them and whether to rewrite the query first. Adjust the strategy here to dial in the balance between answer accuracy and speed, then attach the profile to the agents that should use it."
206
+ /* @__PURE__ */ k(E, {
207
+ icon: /* @__PURE__ */ k(P, { size: 18 }),
208
+ children: U("botlit.retrievalProfileDetail.thisProfileDefinesExactlyHow", "This profile defines exactly how an agent searches your knowledge — the retrieval mode, how many results to pull, whether to rerank them and whether to rewrite the query first. Adjust the strategy here to dial in the balance between answer accuracy and speed, then attach the profile to the agents that should use it.")
208
209
  }),
209
- Y ? /* @__PURE__ */ O(c, { children: [/* @__PURE__ */ D(d, { children: /* @__PURE__ */ D(f, { children: "Basic Information" }) }), /* @__PURE__ */ O(l, {
210
+ Y ? /* @__PURE__ */ A(l, { children: [/* @__PURE__ */ k(f, { children: /* @__PURE__ */ k(p, { children: U("botlit.retrievalProfileDetail.basicInformation", "Basic Information") }) }), /* @__PURE__ */ A(u, {
210
211
  className: "space-y-4",
211
- children: [/* @__PURE__ */ D(g, {
212
- label: "Name",
212
+ children: [/* @__PURE__ */ k(_, {
213
+ label: U("botlit.retrievalProfileDetail.name", "Name"),
213
214
  required: !0,
214
- children: /* @__PURE__ */ D(_, {
215
+ children: /* @__PURE__ */ k(v, {
215
216
  value: Q.name,
216
217
  onChange: (e) => $({
217
218
  ...Q,
218
219
  name: e.target.value
219
220
  }),
220
- placeholder: "e.g., Default Hybrid Search"
221
+ placeholder: U("botlit.retrievalProfileDetail.exampleDefaultHybridSearch", "e.g., Default Hybrid Search")
221
222
  })
222
- }), /* @__PURE__ */ D(g, {
223
- label: "Description",
224
- children: /* @__PURE__ */ D(ee, {
223
+ }), /* @__PURE__ */ k(_, {
224
+ label: U("botlit.retrievalProfileDetail.description", "Description"),
225
+ children: /* @__PURE__ */ k(y, {
225
226
  value: Q.description,
226
227
  onChange: (e) => $({
227
228
  ...Q,
228
229
  description: e.target.value
229
230
  }),
230
- placeholder: "Describe when to use this profile...",
231
+ placeholder: U("botlit.retrievalProfileDetail.describeWhenToUseThis", "Describe when to use this profile..."),
231
232
  rows: 3
232
233
  })
233
234
  })]
234
235
  })] }) : null,
235
- /* @__PURE__ */ O(c, {
236
+ /* @__PURE__ */ A(l, {
236
237
  treatment: "glass",
237
238
  glow: !0,
238
- children: [/* @__PURE__ */ O(d, { children: [/* @__PURE__ */ O(f, {
239
+ children: [/* @__PURE__ */ A(f, { children: [/* @__PURE__ */ A(p, {
239
240
  className: "flex items-center gap-2",
240
- children: [/* @__PURE__ */ D(N, { size: 18 }), "Retrieval Strategy"]
241
- }), /* @__PURE__ */ D(u, { children: "How documents are searched and ranked" })] }), /* @__PURE__ */ D(l, {
241
+ children: [/* @__PURE__ */ k(P, { size: 18 }), U("botlit.retrievalProfileDetail.retrievalStrategy", "Retrieval Strategy")]
242
+ }), /* @__PURE__ */ k(d, { children: U("botlit.retrievalProfileDetail.howDocumentsAreSearchedAnd", "How documents are searched and ranked") })] }), /* @__PURE__ */ k(u, {
242
243
  className: "space-y-4",
243
- children: Y ? /* @__PURE__ */ O(E, { children: [
244
- /* @__PURE__ */ D(g, {
245
- label: "Retrieval Mode",
246
- children: /* @__PURE__ */ D("div", {
244
+ children: Y ? /* @__PURE__ */ A(O, { children: [
245
+ /* @__PURE__ */ k(_, {
246
+ label: U("botlit.retrievalProfileDetail.retrievalMode", "Retrieval Mode"),
247
+ children: /* @__PURE__ */ k("div", {
247
248
  className: "flex gap-4",
248
- children: L.map((e) => /* @__PURE__ */ O("label", {
249
+ children: L.map((e) => /* @__PURE__ */ A("label", {
249
250
  className: "flex items-center gap-2",
250
- children: [/* @__PURE__ */ D("input", {
251
+ children: [/* @__PURE__ */ k("input", {
251
252
  type: "radio",
252
253
  name: "strategyMode",
253
254
  checked: Q.strategyMode === e,
@@ -255,18 +256,18 @@ var U = ({ isNew: z = !1 }) => {
255
256
  ...Q,
256
257
  strategyMode: e
257
258
  })
258
- }), /* @__PURE__ */ D("span", {
259
+ }), /* @__PURE__ */ k("span", {
259
260
  className: "capitalize",
260
261
  children: e.replace("_", " ")
261
262
  })]
262
263
  }, e))
263
264
  })
264
265
  }),
265
- /* @__PURE__ */ O("div", {
266
+ /* @__PURE__ */ A("div", {
266
267
  className: "grid grid-cols-2 gap-4",
267
- children: [/* @__PURE__ */ D(g, {
268
- label: "Top K Results",
269
- children: /* @__PURE__ */ D(_, {
268
+ children: [/* @__PURE__ */ k(_, {
269
+ label: U("botlit.retrievalProfileDetail.topKResults", "Top K Results"),
270
+ children: /* @__PURE__ */ k(v, {
270
271
  type: "number",
271
272
  value: Q.topK,
272
273
  onChange: (e) => $({
@@ -274,133 +275,133 @@ var U = ({ isNew: z = !1 }) => {
274
275
  topK: H(e.target.value, I.topK)
275
276
  })
276
277
  })
277
- }), /* @__PURE__ */ D(g, {
278
- label: "Reranker",
279
- children: /* @__PURE__ */ O(T, {
278
+ }), /* @__PURE__ */ k(_, {
279
+ label: U("botlit.retrievalProfileDetail.reranker", "Reranker"),
280
+ children: /* @__PURE__ */ A(D, {
280
281
  className: "flex h-10 w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm",
281
282
  value: Q.reranker,
282
283
  onChange: (e) => $({
283
284
  ...Q,
284
285
  reranker: R(e.target.value)
285
286
  }),
286
- children: [/* @__PURE__ */ D("option", {
287
+ children: [/* @__PURE__ */ k("option", {
287
288
  value: "OFF",
288
- children: "Disabled"
289
- }), /* @__PURE__ */ D("option", {
289
+ children: U("botlit.retrievalProfileDetail.disabled", "Disabled")
290
+ }), /* @__PURE__ */ k("option", {
290
291
  value: "ON",
291
- children: "Enabled"
292
+ children: U("botlit.retrievalProfileDetail.enabled", "Enabled")
292
293
  })]
293
294
  })
294
295
  })]
295
296
  }),
296
- /* @__PURE__ */ O("div", {
297
+ /* @__PURE__ */ A("div", {
297
298
  className: "grid grid-cols-2 gap-4",
298
- children: [/* @__PURE__ */ D(g, {
299
- label: "Query Rewrite",
300
- children: /* @__PURE__ */ O(T, {
299
+ children: [/* @__PURE__ */ k(_, {
300
+ label: U("botlit.retrievalProfileDetail.queryRewrite", "Query Rewrite"),
301
+ children: /* @__PURE__ */ A(D, {
301
302
  className: "flex h-10 w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm",
302
303
  value: Q.queryRewrite,
303
304
  onChange: (e) => $({
304
305
  ...Q,
305
306
  queryRewrite: R(e.target.value)
306
307
  }),
307
- children: [/* @__PURE__ */ D("option", {
308
+ children: [/* @__PURE__ */ k("option", {
308
309
  value: "OFF",
309
- children: "Disabled"
310
- }), /* @__PURE__ */ D("option", {
310
+ children: U("botlit.retrievalProfileDetail.disabled", "Disabled")
311
+ }), /* @__PURE__ */ k("option", {
311
312
  value: "ON",
312
- children: "Enabled"
313
+ children: U("botlit.retrievalProfileDetail.enabled", "Enabled")
313
314
  })]
314
315
  })
315
- }), /* @__PURE__ */ D(g, {
316
- label: "Multi-Hop",
317
- children: /* @__PURE__ */ O(T, {
316
+ }), /* @__PURE__ */ k(_, {
317
+ label: U("botlit.retrievalProfileDetail.multiHop", "Multi-Hop"),
318
+ children: /* @__PURE__ */ A(D, {
318
319
  className: "flex h-10 w-full rounded-md border border-border-default bg-bg-surface px-3 py-2 text-sm",
319
320
  value: Q.multiHop,
320
321
  onChange: (e) => $({
321
322
  ...Q,
322
323
  multiHop: R(e.target.value)
323
324
  }),
324
- children: [/* @__PURE__ */ D("option", {
325
+ children: [/* @__PURE__ */ k("option", {
325
326
  value: "OFF",
326
- children: "Disabled"
327
- }), /* @__PURE__ */ D("option", {
327
+ children: U("botlit.retrievalProfileDetail.disabled", "Disabled")
328
+ }), /* @__PURE__ */ k("option", {
328
329
  value: "ON",
329
- children: "Enabled"
330
+ children: U("botlit.retrievalProfileDetail.enabled", "Enabled")
330
331
  })]
331
332
  })
332
333
  })]
333
334
  })
334
- ] }) : /* @__PURE__ */ O("div", {
335
+ ] }) : /* @__PURE__ */ A("div", {
335
336
  className: "grid grid-cols-2 md:grid-cols-4 gap-4",
336
337
  children: [
337
- /* @__PURE__ */ O("div", { children: [/* @__PURE__ */ D("p", {
338
+ /* @__PURE__ */ A("div", { children: [/* @__PURE__ */ k("p", {
338
339
  className: "text-sm text-text-secondary",
339
- children: "Mode"
340
- }), /* @__PURE__ */ D(m, {
340
+ children: U("botlit.retrievalProfileDetail.mode", "Mode")
341
+ }), /* @__PURE__ */ k(h, {
341
342
  variant: "outline",
342
- children: G?.strategyMode
343
+ children: K?.strategyMode
343
344
  })] }),
344
- /* @__PURE__ */ O("div", { children: [/* @__PURE__ */ D("p", {
345
+ /* @__PURE__ */ A("div", { children: [/* @__PURE__ */ k("p", {
345
346
  className: "text-sm text-text-secondary",
346
- children: "Top K"
347
- }), /* @__PURE__ */ D("p", {
347
+ children: U("botlit.retrievalProfileDetail.topK", "Top K")
348
+ }), /* @__PURE__ */ k("p", {
348
349
  className: "font-medium",
349
- children: G?.topK
350
+ children: K?.topK
350
351
  })] }),
351
- /* @__PURE__ */ O("div", { children: [/* @__PURE__ */ D("p", {
352
+ /* @__PURE__ */ A("div", { children: [/* @__PURE__ */ k("p", {
352
353
  className: "text-sm text-text-secondary",
353
- children: "Reranker"
354
- }), /* @__PURE__ */ D(m, {
355
- variant: G?.reranker === "ON" ? "success" : "secondary",
356
- children: G?.reranker
354
+ children: U("botlit.retrievalProfileDetail.reranker", "Reranker")
355
+ }), /* @__PURE__ */ k(h, {
356
+ variant: K?.reranker === "ON" ? "success" : "secondary",
357
+ children: K?.reranker
357
358
  })] }),
358
- /* @__PURE__ */ O("div", { children: [/* @__PURE__ */ D("p", {
359
+ /* @__PURE__ */ A("div", { children: [/* @__PURE__ */ k("p", {
359
360
  className: "text-sm text-text-secondary",
360
- children: "Query Rewrite"
361
- }), /* @__PURE__ */ D(m, {
362
- variant: G?.queryRewrite === "ON" ? "success" : "secondary",
363
- children: G?.queryRewrite
361
+ children: U("botlit.retrievalProfileDetail.queryRewrite", "Query Rewrite")
362
+ }), /* @__PURE__ */ k(h, {
363
+ variant: K?.queryRewrite === "ON" ? "success" : "secondary",
364
+ children: K?.queryRewrite
364
365
  })] })
365
366
  ]
366
367
  })
367
368
  })]
368
369
  }),
369
- /* @__PURE__ */ O(c, { children: [/* @__PURE__ */ O(d, { children: [/* @__PURE__ */ O(f, {
370
+ /* @__PURE__ */ A(l, { children: [/* @__PURE__ */ A(f, { children: [/* @__PURE__ */ A(p, {
370
371
  className: "flex items-center gap-2",
371
- children: [/* @__PURE__ */ D(j, { size: 18 }), "Grounding & Citations"]
372
- }), /* @__PURE__ */ D(u, { children: "How sources are cited in responses" })] }), /* @__PURE__ */ D(l, {
372
+ children: [/* @__PURE__ */ k(ne, { size: 18 }), U("botlit.retrievalProfileDetail.groundingCitations", "Grounding & Citations")]
373
+ }), /* @__PURE__ */ k(d, { children: U("botlit.retrievalProfileDetail.howSourcesAreCitedIn", "How sources are cited in responses") })] }), /* @__PURE__ */ k(u, {
373
374
  className: "space-y-4",
374
- children: Y ? /* @__PURE__ */ O(E, { children: [
375
- /* @__PURE__ */ O("div", {
375
+ children: Y ? /* @__PURE__ */ A(O, { children: [
376
+ /* @__PURE__ */ A("div", {
376
377
  className: "flex items-center gap-4",
377
- children: [/* @__PURE__ */ O("label", {
378
+ children: [/* @__PURE__ */ A("label", {
378
379
  className: "flex items-center gap-2",
379
- children: [/* @__PURE__ */ D("input", {
380
+ children: [/* @__PURE__ */ k("input", {
380
381
  type: "checkbox",
381
382
  checked: Q.citationsRequired,
382
383
  onChange: (e) => $({
383
384
  ...Q,
384
385
  citationsRequired: e.target.checked
385
386
  })
386
- }), /* @__PURE__ */ D("span", { children: "Citations Required" })]
387
- }), /* @__PURE__ */ O("label", {
387
+ }), /* @__PURE__ */ k("span", { children: U("botlit.retrievalProfileDetail.citationsRequired", "Citations Required") })]
388
+ }), /* @__PURE__ */ A("label", {
388
389
  className: "flex items-center gap-2",
389
- children: [/* @__PURE__ */ D("input", {
390
+ children: [/* @__PURE__ */ k("input", {
390
391
  type: "checkbox",
391
392
  checked: Q.showSources,
392
393
  onChange: (e) => $({
393
394
  ...Q,
394
395
  showSources: e.target.checked
395
396
  })
396
- }), /* @__PURE__ */ D("span", { children: "Show Sources" })]
397
+ }), /* @__PURE__ */ k("span", { children: U("botlit.retrievalProfileDetail.showSources", "Show Sources") })]
397
398
  })]
398
399
  }),
399
- /* @__PURE__ */ O("div", {
400
+ /* @__PURE__ */ A("div", {
400
401
  className: "grid grid-cols-2 gap-4",
401
- children: [/* @__PURE__ */ D(g, {
402
- label: "Min Sources",
403
- children: /* @__PURE__ */ D(_, {
402
+ children: [/* @__PURE__ */ k(_, {
403
+ label: U("botlit.retrievalProfileDetail.minSources", "Min Sources"),
404
+ children: /* @__PURE__ */ k(v, {
404
405
  type: "number",
405
406
  value: Q.minSources,
406
407
  onChange: (e) => $({
@@ -408,9 +409,9 @@ var U = ({ isNew: z = !1 }) => {
408
409
  minSources: H(e.target.value, I.minSources)
409
410
  })
410
411
  })
411
- }), /* @__PURE__ */ D(g, {
412
- label: "Max Snippet Chars",
413
- children: /* @__PURE__ */ D(_, {
412
+ }), /* @__PURE__ */ k(_, {
413
+ label: U("botlit.retrievalProfileDetail.maxSnippetChars", "Max Snippet Chars"),
414
+ children: /* @__PURE__ */ k(v, {
414
415
  type: "number",
415
416
  value: Q.snippetMaxChars,
416
417
  onChange: (e) => $({
@@ -420,9 +421,9 @@ var U = ({ isNew: z = !1 }) => {
420
421
  })
421
422
  })]
422
423
  }),
423
- /* @__PURE__ */ D(g, {
424
- label: "Citation Format Template",
425
- children: /* @__PURE__ */ D(_, {
424
+ /* @__PURE__ */ k(_, {
425
+ label: U("botlit.retrievalProfileDetail.citationFormatTemplate", "Citation Format Template"),
426
+ children: /* @__PURE__ */ k(v, {
426
427
  value: Q.citationFormat,
427
428
  onChange: (e) => $({
428
429
  ...Q,
@@ -431,50 +432,50 @@ var U = ({ isNew: z = !1 }) => {
431
432
  placeholder: "[{index}]"
432
433
  })
433
434
  })
434
- ] }) : /* @__PURE__ */ O("div", {
435
+ ] }) : /* @__PURE__ */ A("div", {
435
436
  className: "grid grid-cols-2 md:grid-cols-4 gap-4",
436
437
  children: [
437
- /* @__PURE__ */ O("div", { children: [/* @__PURE__ */ D("p", {
438
+ /* @__PURE__ */ A("div", { children: [/* @__PURE__ */ k("p", {
438
439
  className: "text-sm text-text-secondary",
439
- children: "Citations Required"
440
- }), /* @__PURE__ */ D(m, {
441
- variant: G?.citationsRequired ? "success" : "secondary",
442
- children: G?.citationsRequired ? "Yes" : "No"
440
+ children: U("botlit.retrievalProfileDetail.citationsRequired", "Citations Required")
441
+ }), /* @__PURE__ */ k(h, {
442
+ variant: K?.citationsRequired ? "success" : "secondary",
443
+ children: K?.citationsRequired ? U("botlit.retrievalProfileDetail.yes", "Yes") : U("botlit.retrievalProfileDetail.no", "No")
443
444
  })] }),
444
- /* @__PURE__ */ O("div", { children: [/* @__PURE__ */ D("p", {
445
+ /* @__PURE__ */ A("div", { children: [/* @__PURE__ */ k("p", {
445
446
  className: "text-sm text-text-secondary",
446
- children: "Min Sources"
447
- }), /* @__PURE__ */ D("p", {
447
+ children: U("botlit.retrievalProfileDetail.minSources", "Min Sources")
448
+ }), /* @__PURE__ */ k("p", {
448
449
  className: "font-medium",
449
- children: G?.minSources
450
+ children: K?.minSources
450
451
  })] }),
451
- /* @__PURE__ */ O("div", { children: [/* @__PURE__ */ D("p", {
452
+ /* @__PURE__ */ A("div", { children: [/* @__PURE__ */ k("p", {
452
453
  className: "text-sm text-text-secondary",
453
- children: "Max Snippet"
454
- }), /* @__PURE__ */ O("p", {
454
+ children: U("botlit.retrievalProfileDetail.maxSnippet", "Max Snippet")
455
+ }), /* @__PURE__ */ k("p", {
455
456
  className: "font-medium",
456
- children: [G?.snippetMaxChars, " chars"]
457
+ children: U("botlit.retrievalProfileDetail.snippetLength", "{{count}} chars", { count: K?.snippetMaxChars ?? "—" })
457
458
  })] }),
458
- /* @__PURE__ */ O("div", { children: [/* @__PURE__ */ D("p", {
459
+ /* @__PURE__ */ A("div", { children: [/* @__PURE__ */ k("p", {
459
460
  className: "text-sm text-text-secondary",
460
- children: "Citation Format"
461
- }), /* @__PURE__ */ D("code", {
461
+ children: U("botlit.retrievalProfileDetail.citationFormat", "Citation Format")
462
+ }), /* @__PURE__ */ k("code", {
462
463
  className: "text-sm",
463
- children: G?.citationFormat ?? "—"
464
+ children: K?.citationFormat ?? "—"
464
465
  })] })
465
466
  ]
466
467
  })
467
468
  })] }),
468
- /* @__PURE__ */ O(c, { children: [/* @__PURE__ */ O(d, { children: [/* @__PURE__ */ O(f, {
469
+ /* @__PURE__ */ A(l, { children: [/* @__PURE__ */ A(f, { children: [/* @__PURE__ */ A(p, {
469
470
  className: "flex items-center gap-2",
470
- children: [/* @__PURE__ */ D(P, { size: 18 }), "Relevance Thresholds"]
471
- }), /* @__PURE__ */ D(u, { children: "Minimum quality requirements for results" })] }), /* @__PURE__ */ D(l, {
471
+ children: [/* @__PURE__ */ k(ie, { size: 18 }), U("botlit.retrievalProfileDetail.relevanceThresholds", "Relevance Thresholds")]
472
+ }), /* @__PURE__ */ k(d, { children: U("botlit.retrievalProfileDetail.minimumQualityRequirementsForResults", "Minimum quality requirements for results") })] }), /* @__PURE__ */ k(u, {
472
473
  className: "space-y-4",
473
- children: Y ? /* @__PURE__ */ O("div", {
474
+ children: Y ? /* @__PURE__ */ A("div", {
474
475
  className: "grid grid-cols-2 gap-4",
475
- children: [/* @__PURE__ */ D(g, {
476
- label: "Min Relevance Score (0-1)",
477
- children: /* @__PURE__ */ D(_, {
476
+ children: [/* @__PURE__ */ k(_, {
477
+ label: U("botlit.retrievalProfileDetail.minRelevanceScore01", "Min Relevance Score (0-1)"),
478
+ children: /* @__PURE__ */ k(v, {
478
479
  type: "number",
479
480
  step: "0.1",
480
481
  min: "0",
@@ -485,70 +486,70 @@ var U = ({ isNew: z = !1 }) => {
485
486
  minRelevanceScore: H(e.target.value, I.minRelevanceScore)
486
487
  })
487
488
  })
488
- }), /* @__PURE__ */ D("div", {
489
+ }), /* @__PURE__ */ k("div", {
489
490
  className: "flex items-center",
490
- children: /* @__PURE__ */ O("label", {
491
+ children: /* @__PURE__ */ A("label", {
491
492
  className: "flex items-center gap-2",
492
- children: [/* @__PURE__ */ D("input", {
493
+ children: [/* @__PURE__ */ k("input", {
493
494
  type: "checkbox",
494
495
  checked: Q.noAnswerIfBelowThreshold,
495
496
  onChange: (e) => $({
496
497
  ...Q,
497
498
  noAnswerIfBelowThreshold: e.target.checked
498
499
  })
499
- }), /* @__PURE__ */ D("span", { children: "No Answer if Below Threshold" })]
500
+ }), /* @__PURE__ */ k("span", { children: U("botlit.retrievalProfileDetail.noAnswerIfBelowThreshold", "No Answer if Below Threshold") })]
500
501
  })
501
502
  })]
502
- }) : /* @__PURE__ */ O("div", {
503
+ }) : /* @__PURE__ */ A("div", {
503
504
  className: "grid grid-cols-2 gap-4",
504
- children: [/* @__PURE__ */ O("div", { children: [/* @__PURE__ */ D("p", {
505
+ children: [/* @__PURE__ */ A("div", { children: [/* @__PURE__ */ k("p", {
505
506
  className: "text-sm text-text-secondary",
506
- children: "Min Relevance Score"
507
- }), /* @__PURE__ */ D("p", {
507
+ children: U("botlit.retrievalProfileDetail.minRelevanceScore", "Min Relevance Score")
508
+ }), /* @__PURE__ */ k("p", {
508
509
  className: "font-medium",
509
- children: G?.minRelevanceScore ?? "Not set"
510
- })] }), /* @__PURE__ */ O("div", { children: [/* @__PURE__ */ D("p", {
510
+ children: K?.minRelevanceScore ?? U("botlit.retrievalProfileDetail.notSet", "Not set")
511
+ })] }), /* @__PURE__ */ A("div", { children: [/* @__PURE__ */ k("p", {
511
512
  className: "text-sm text-text-secondary",
512
- children: "No Answer Below Threshold"
513
- }), /* @__PURE__ */ D(m, {
514
- variant: G?.noAnswerIfBelowThreshold ? "warning" : "secondary",
515
- children: G?.noAnswerIfBelowThreshold ? "Yes" : "No"
513
+ children: U("botlit.retrievalProfileDetail.noAnswerBelowThreshold", "No Answer Below Threshold")
514
+ }), /* @__PURE__ */ k(h, {
515
+ variant: K?.noAnswerIfBelowThreshold ? "warning" : "secondary",
516
+ children: K?.noAnswerIfBelowThreshold ? U("botlit.retrievalProfileDetail.yes", "Yes") : U("botlit.retrievalProfileDetail.no", "No")
516
517
  })] })]
517
518
  })
518
519
  })] }),
519
- !z && G && /* @__PURE__ */ O(c, { children: [/* @__PURE__ */ D(d, { children: /* @__PURE__ */ O(f, {
520
+ !z && K && /* @__PURE__ */ A(l, { children: [/* @__PURE__ */ k(f, { children: /* @__PURE__ */ A(p, {
520
521
  className: "flex items-center gap-2",
521
- children: [/* @__PURE__ */ D(k, { size: 18 }), "Metadata"]
522
- }) }), /* @__PURE__ */ D(l, { children: /* @__PURE__ */ O("div", {
522
+ children: [/* @__PURE__ */ k(N, { size: 18 }), U("botlit.retrievalProfileDetail.metadata", "Metadata")]
523
+ }) }), /* @__PURE__ */ k(u, { children: /* @__PURE__ */ A("div", {
523
524
  className: "grid grid-cols-2 md:grid-cols-4 gap-4 text-sm",
524
525
  children: [
525
- /* @__PURE__ */ O("div", { children: [/* @__PURE__ */ D("p", {
526
+ /* @__PURE__ */ A("div", { children: [/* @__PURE__ */ k("p", {
526
527
  className: "text-text-secondary",
527
- children: "Created"
528
- }), /* @__PURE__ */ D("p", {
528
+ children: U("botlit.retrievalProfileDetail.created", "Created")
529
+ }), /* @__PURE__ */ k("p", {
529
530
  className: "font-medium",
530
- children: x(G.createdAt)
531
+ children: C(K.createdAt)
531
532
  })] }),
532
- /* @__PURE__ */ O("div", { children: [/* @__PURE__ */ D("p", {
533
+ /* @__PURE__ */ A("div", { children: [/* @__PURE__ */ k("p", {
533
534
  className: "text-text-secondary",
534
- children: "Updated"
535
- }), /* @__PURE__ */ D("p", {
535
+ children: U("botlit.retrievalProfileDetail.updated", "Updated")
536
+ }), /* @__PURE__ */ k("p", {
536
537
  className: "font-medium",
537
- children: x(G.updatedAt)
538
+ children: C(K.updatedAt)
538
539
  })] }),
539
- /* @__PURE__ */ O("div", { children: [/* @__PURE__ */ D("p", {
540
+ /* @__PURE__ */ A("div", { children: [/* @__PURE__ */ k("p", {
540
541
  className: "text-text-secondary",
541
- children: "Revision"
542
- }), /* @__PURE__ */ D("p", {
542
+ children: U("botlit.retrievalProfileDetail.revision", "Revision")
543
+ }), /* @__PURE__ */ k("p", {
543
544
  className: "font-medium",
544
- children: G.revision
545
+ children: K.revision
545
546
  })] }),
546
- /* @__PURE__ */ O("div", { children: [/* @__PURE__ */ D("p", {
547
+ /* @__PURE__ */ A("div", { children: [/* @__PURE__ */ k("p", {
547
548
  className: "text-text-secondary",
548
- children: "Visibility"
549
- }), /* @__PURE__ */ D(m, {
549
+ children: U("botlit.retrievalProfileDetail.visibility", "Visibility")
550
+ }), /* @__PURE__ */ k(h, {
550
551
  variant: "outline",
551
- children: G.visibility
552
+ children: K.visibility
552
553
  })] })
553
554
  ]
554
555
  }) })] })