@sanity/ailf-studio 1.2.0 → 1.2.2
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/index.d.ts +2 -0
- package/dist/index.js +346 -519
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1321,6 +1321,12 @@ var reportSchema = defineType4({
|
|
|
1321
1321
|
title: "Model ID",
|
|
1322
1322
|
type: "string"
|
|
1323
1323
|
}),
|
|
1324
|
+
defineField4({
|
|
1325
|
+
description: "True when the model failed to produce output (empty response, API error, or refusal) rather than producing incorrect output.",
|
|
1326
|
+
name: "outputFailure",
|
|
1327
|
+
title: "Output Failure",
|
|
1328
|
+
type: "boolean"
|
|
1329
|
+
}),
|
|
1324
1330
|
defineField4({
|
|
1325
1331
|
description: "Documentation pages the task expected the model to use.",
|
|
1326
1332
|
name: "canonicalDocs",
|
|
@@ -5696,14 +5702,14 @@ function LatestReports({
|
|
|
5696
5702
|
import { ArrowLeftIcon as ArrowLeftIcon3 } from "@sanity/icons";
|
|
5697
5703
|
import {
|
|
5698
5704
|
Badge as Badge7,
|
|
5699
|
-
Box as
|
|
5705
|
+
Box as Box21,
|
|
5700
5706
|
Button as Button8,
|
|
5701
|
-
Flex as
|
|
5702
|
-
Stack as
|
|
5707
|
+
Flex as Flex25,
|
|
5708
|
+
Stack as Stack27,
|
|
5703
5709
|
Tab,
|
|
5704
5710
|
TabList,
|
|
5705
5711
|
TabPanel,
|
|
5706
|
-
Text as
|
|
5712
|
+
Text as Text33,
|
|
5707
5713
|
Tooltip as Tooltip8
|
|
5708
5714
|
} from "@sanity/ui";
|
|
5709
5715
|
import {
|
|
@@ -6185,15 +6191,7 @@ function DiagnosticsOverview({
|
|
|
6185
6191
|
value: Math.round(overall.avgDocLift)
|
|
6186
6192
|
}
|
|
6187
6193
|
) }),
|
|
6188
|
-
|
|
6189
|
-
ScoreCard,
|
|
6190
|
-
{
|
|
6191
|
-
label: "FLOOR",
|
|
6192
|
-
sentiment: scoreSentiment(overall.avgFloorScore ?? 0),
|
|
6193
|
-
subtitle: "Without docs baseline",
|
|
6194
|
-
value: Math.round(overall.avgFloorScore ?? 0)
|
|
6195
|
-
}
|
|
6196
|
-
) }) : /* @__PURE__ */ jsx25(HoverTip, { display: "block", text: GLOSSARY.tests, children: /* @__PURE__ */ jsx25(
|
|
6194
|
+
/* @__PURE__ */ jsx25(HoverTip, { display: "block", text: GLOSSARY.tests, children: /* @__PURE__ */ jsx25(
|
|
6197
6195
|
ScoreCard,
|
|
6198
6196
|
{
|
|
6199
6197
|
label: "TESTS",
|
|
@@ -6210,7 +6208,7 @@ function DiagnosticsOverview({
|
|
|
6210
6208
|
style: {
|
|
6211
6209
|
display: "grid",
|
|
6212
6210
|
gap: 12,
|
|
6213
|
-
gridTemplateColumns: showDocMetrics ? "repeat(
|
|
6211
|
+
gridTemplateColumns: showDocMetrics ? "repeat(2, 1fr)" : "1fr"
|
|
6214
6212
|
},
|
|
6215
6213
|
children: [
|
|
6216
6214
|
showDocMetrics && /* @__PURE__ */ jsx25(HoverTip, { display: "block", text: GLOSSARY.negativeDocLiftMetric, children: /* @__PURE__ */ jsx25(
|
|
@@ -6221,7 +6219,6 @@ function DiagnosticsOverview({
|
|
|
6221
6219
|
value: `${negativeDocLiftCount} area${negativeDocLiftCount === 1 ? "" : "s"}`
|
|
6222
6220
|
}
|
|
6223
6221
|
) }),
|
|
6224
|
-
showDocMetrics && /* @__PURE__ */ jsx25(HoverTip, { display: "block", text: GLOSSARY.tests, children: /* @__PURE__ */ jsx25(MetricCard, { label: "Tests", value: String(totalTests ?? 0) }) }),
|
|
6225
6222
|
durationMs != null && durationMs > 0 ? /* @__PURE__ */ jsx25(
|
|
6226
6223
|
HoverTip,
|
|
6227
6224
|
{
|
|
@@ -6751,6 +6748,13 @@ function judgmentSlug(j) {
|
|
|
6751
6748
|
const slugify4 = (s) => s.toLowerCase().replace(/[()]/g, "").replace(/[^a-z0-9]+/g, "-").replace(/^-+|-+$/g, "");
|
|
6752
6749
|
return `${slugify4(area)}--${slugify4(task)}--${slugify4(j.dimension)}--${slugify4(j.modelId)}`;
|
|
6753
6750
|
}
|
|
6751
|
+
function isOutputFailure(j) {
|
|
6752
|
+
if (j.outputFailure) return true;
|
|
6753
|
+
return j.score === 0 && j.taskId.includes("(baseline)");
|
|
6754
|
+
}
|
|
6755
|
+
function pruneNoise(judgments) {
|
|
6756
|
+
return judgments.filter((j) => !isOutputFailure(j));
|
|
6757
|
+
}
|
|
6754
6758
|
function groupByArea(judgments) {
|
|
6755
6759
|
const byArea = /* @__PURE__ */ new Map();
|
|
6756
6760
|
for (const j of judgments) {
|
|
@@ -6759,7 +6763,7 @@ function groupByArea(judgments) {
|
|
|
6759
6763
|
if (!byArea.has(area)) byArea.set(area, []);
|
|
6760
6764
|
byArea.get(area).push(j);
|
|
6761
6765
|
}
|
|
6762
|
-
return [...byArea.entries()].sort(([a], [b]) => a.localeCompare(b)).map(([area, js]) => [area, js.sort((a, b) =>
|
|
6766
|
+
return [...byArea.entries()].sort(([a], [b]) => a.localeCompare(b)).map(([area, js]) => [area, js.sort((a, b) => b.score - a.score)]);
|
|
6763
6767
|
}
|
|
6764
6768
|
function dimensionLabel2(dim) {
|
|
6765
6769
|
return dim.split("-").map((w) => w.charAt(0).toUpperCase() + w.slice(1)).join(" ");
|
|
@@ -6770,7 +6774,10 @@ function JudgmentList({
|
|
|
6770
6774
|
onFocusChange
|
|
6771
6775
|
}) {
|
|
6772
6776
|
if (judgments.length === 0) return null;
|
|
6773
|
-
const
|
|
6777
|
+
const pruned = pruneNoise(judgments);
|
|
6778
|
+
if (pruned.length === 0) return null;
|
|
6779
|
+
const outputFailureCount = judgments.length - pruned.length;
|
|
6780
|
+
const grouped = groupByArea(pruned);
|
|
6774
6781
|
return /* @__PURE__ */ jsxs23(Stack20, { space: 3, children: [
|
|
6775
6782
|
/* @__PURE__ */ jsxs23(Flex16, { align: "center", gap: 2, children: [
|
|
6776
6783
|
/* @__PURE__ */ jsx28(ErrorOutlineIcon2, { style: { color: "#f87171" } }),
|
|
@@ -6797,10 +6804,42 @@ function JudgmentList({
|
|
|
6797
6804
|
padding: "2px 10px"
|
|
6798
6805
|
},
|
|
6799
6806
|
children: [
|
|
6800
|
-
|
|
6807
|
+
pruned.length,
|
|
6801
6808
|
" below 70"
|
|
6802
6809
|
]
|
|
6803
6810
|
}
|
|
6811
|
+
),
|
|
6812
|
+
outputFailureCount > 0 && /* @__PURE__ */ jsx28(
|
|
6813
|
+
Tooltip7,
|
|
6814
|
+
{
|
|
6815
|
+
content: /* @__PURE__ */ jsx28(Box16, { padding: 2, style: { maxWidth: 280 }, children: /* @__PURE__ */ jsxs23(Text25, { size: 2, children: [
|
|
6816
|
+
outputFailureCount,
|
|
6817
|
+
" judgment",
|
|
6818
|
+
outputFailureCount === 1 ? "" : "s",
|
|
6819
|
+
" hidden where the model failed to produce output (empty response, API error, or token exhaustion). These are infrastructure issues, not content quality problems."
|
|
6820
|
+
] }) }),
|
|
6821
|
+
placement: "bottom",
|
|
6822
|
+
portal: true,
|
|
6823
|
+
children: /* @__PURE__ */ jsxs23(
|
|
6824
|
+
"span",
|
|
6825
|
+
{
|
|
6826
|
+
style: {
|
|
6827
|
+
backgroundColor: "var(--card-muted-bg-color, rgba(255,255,255,0.06))",
|
|
6828
|
+
borderRadius: 999,
|
|
6829
|
+
color: "var(--card-muted-fg-color)",
|
|
6830
|
+
fontSize: 13,
|
|
6831
|
+
fontWeight: 500,
|
|
6832
|
+
padding: "2px 10px"
|
|
6833
|
+
},
|
|
6834
|
+
children: [
|
|
6835
|
+
outputFailureCount,
|
|
6836
|
+
" output failure",
|
|
6837
|
+
outputFailureCount === 1 ? "" : "s",
|
|
6838
|
+
" hidden"
|
|
6839
|
+
]
|
|
6840
|
+
}
|
|
6841
|
+
)
|
|
6842
|
+
}
|
|
6804
6843
|
)
|
|
6805
6844
|
] }),
|
|
6806
6845
|
/* @__PURE__ */ jsx28(Box16, { style: neutralCardStyle, children: grouped.map(([area, areaJudgments], groupIndex) => /* @__PURE__ */ jsx28(
|
|
@@ -7045,7 +7084,6 @@ function DocBadge({
|
|
|
7045
7084
|
// src/components/report-detail/ProvenanceCard.tsx
|
|
7046
7085
|
import { Card as Card14, Flex as Flex17, Grid as Grid3, Stack as Stack21, Text as Text26 } from "@sanity/ui";
|
|
7047
7086
|
import { jsx as jsx29, jsxs as jsxs24 } from "react/jsx-runtime";
|
|
7048
|
-
var VIEWABLE_PROMPTFOO_MODES = /* @__PURE__ */ new Set(["agentic", "observed"]);
|
|
7049
7087
|
function ProvenanceCard({ provenance }) {
|
|
7050
7088
|
return /* @__PURE__ */ jsx29(Card14, { padding: 4, radius: 2, shadow: 1, children: /* @__PURE__ */ jsxs24(Stack21, { space: 4, children: [
|
|
7051
7089
|
/* @__PURE__ */ jsx29(Text26, { size: 3, weight: "semibold", children: "Provenance" }),
|
|
@@ -7123,17 +7161,13 @@ function PromptfooLinks({
|
|
|
7123
7161
|
provenance
|
|
7124
7162
|
}) {
|
|
7125
7163
|
if (provenance.promptfooUrls && provenance.promptfooUrls.length > 0) {
|
|
7126
|
-
|
|
7127
|
-
(e) => VIEWABLE_PROMPTFOO_MODES.has(e.mode)
|
|
7128
|
-
);
|
|
7129
|
-
if (viewable.length === 0) return null;
|
|
7130
|
-
return /* @__PURE__ */ jsx29(Flex17, { gap: 3, wrap: "wrap", children: viewable.map((entry) => /* @__PURE__ */ jsx29(Text26, { size: 2, children: /* @__PURE__ */ jsxs24("a", { href: entry.url, rel: "noopener noreferrer", target: "_blank", children: [
|
|
7164
|
+
return /* @__PURE__ */ jsx29(Flex17, { align: "center", gap: 3, wrap: "wrap", children: provenance.promptfooUrls.map((entry) => /* @__PURE__ */ jsx29(Text26, { size: 2, children: /* @__PURE__ */ jsxs24("a", { href: entry.url, rel: "noopener noreferrer", target: "_blank", children: [
|
|
7131
7165
|
"View in Promptfoo (",
|
|
7132
7166
|
entry.mode,
|
|
7133
7167
|
") \u2192"
|
|
7134
7168
|
] }) }, entry.mode)) });
|
|
7135
7169
|
}
|
|
7136
|
-
if (provenance.promptfooUrl
|
|
7170
|
+
if (provenance.promptfooUrl) {
|
|
7137
7171
|
return /* @__PURE__ */ jsx29(Text26, { size: 2, children: /* @__PURE__ */ jsx29(
|
|
7138
7172
|
"a",
|
|
7139
7173
|
{
|
|
@@ -7144,216 +7178,27 @@ function PromptfooLinks({
|
|
|
7144
7178
|
}
|
|
7145
7179
|
) });
|
|
7146
7180
|
}
|
|
7147
|
-
return
|
|
7181
|
+
return /* @__PURE__ */ jsx29(PromptfooUnavailable, { reason: "not-shared" });
|
|
7148
7182
|
}
|
|
7149
|
-
|
|
7150
|
-
|
|
7151
|
-
import { BoltIcon } from "@sanity/icons";
|
|
7152
|
-
import { Box as Box17, Flex as Flex18, Stack as Stack22, Text as Text27 } from "@sanity/ui";
|
|
7153
|
-
import { jsx as jsx30, jsxs as jsxs25 } from "react/jsx-runtime";
|
|
7154
|
-
function tableTier(width) {
|
|
7155
|
-
if (width >= 800) return "full";
|
|
7156
|
-
if (width >= 600) return "compact";
|
|
7157
|
-
return "narrow";
|
|
7158
|
-
}
|
|
7159
|
-
var GRID2 = {
|
|
7160
|
-
full: "1fr 1fr 2fr 72px 90px",
|
|
7161
|
-
compact: "1fr 1fr 2fr 90px",
|
|
7162
|
-
narrow: "1fr 1fr"
|
|
7183
|
+
var UNAVAILABLE_TOOLTIPS = {
|
|
7184
|
+
"not-shared": "No Promptfoo share link was generated for this report. This usually means the evaluation was run locally without the --share flag."
|
|
7163
7185
|
};
|
|
7164
|
-
function
|
|
7165
|
-
|
|
7166
|
-
})
|
|
7167
|
-
|
|
7168
|
-
const tier = tableTier(width);
|
|
7169
|
-
if (recommendations.gaps.length === 0) return null;
|
|
7170
|
-
return /* @__PURE__ */ jsxs25(Stack22, { space: 3, children: [
|
|
7171
|
-
/* @__PURE__ */ jsxs25(Flex18, { align: "center", gap: 2, children: [
|
|
7172
|
-
/* @__PURE__ */ jsx30(BoltIcon, { style: { color: "#fbbf24" } }),
|
|
7173
|
-
/* @__PURE__ */ jsx30(Text27, { size: 2, weight: "medium", children: "Recommendations" }),
|
|
7174
|
-
/* @__PURE__ */ jsx30(InfoTip, { text: GLOSSARY.recommendations }),
|
|
7175
|
-
/* @__PURE__ */ jsxs25(
|
|
7176
|
-
"span",
|
|
7177
|
-
{
|
|
7178
|
-
style: {
|
|
7179
|
-
backgroundColor: "rgba(16,185,129,0.2)",
|
|
7180
|
-
borderRadius: 999,
|
|
7181
|
-
color: "#34d399",
|
|
7182
|
-
fontSize: 13,
|
|
7183
|
-
fontWeight: 500,
|
|
7184
|
-
marginLeft: 4,
|
|
7185
|
-
padding: "2px 10px"
|
|
7186
|
-
},
|
|
7187
|
-
children: [
|
|
7188
|
-
"+",
|
|
7189
|
-
recommendations.totalPotentialLift.toFixed(1),
|
|
7190
|
-
" pts lift"
|
|
7191
|
-
]
|
|
7192
|
-
}
|
|
7193
|
-
)
|
|
7194
|
-
] }),
|
|
7195
|
-
/* @__PURE__ */ jsxs25(Box17, { ref, style: { ...neutralCardStyle, overflow: "auto" }, children: [
|
|
7196
|
-
/* @__PURE__ */ jsxs25(
|
|
7197
|
-
"div",
|
|
7198
|
-
{
|
|
7199
|
-
style: {
|
|
7200
|
-
borderBottom: "1px solid var(--card-border-color)",
|
|
7201
|
-
display: "grid",
|
|
7202
|
-
gap: "0 12px",
|
|
7203
|
-
gridTemplateColumns: GRID2[tier],
|
|
7204
|
-
padding: "12px 16px 8px"
|
|
7205
|
-
},
|
|
7206
|
-
children: [
|
|
7207
|
-
/* @__PURE__ */ jsx30(ColHeader2, { label: "Area" }),
|
|
7208
|
-
/* @__PURE__ */ jsx30(ColHeader2, { label: "Failure Mode", tooltip: GLOSSARY.failureMode }),
|
|
7209
|
-
tier !== "narrow" && /* @__PURE__ */ jsx30(ColHeader2, { label: "Action" }),
|
|
7210
|
-
tier === "full" && /* @__PURE__ */ jsx30(ColHeader2, { label: "Lift", tooltip: GLOSSARY.estimatedLift }),
|
|
7211
|
-
tier !== "narrow" && /* @__PURE__ */ jsx30(ColHeader2, { label: "Confidence", tooltip: GLOSSARY.confidence })
|
|
7212
|
-
]
|
|
7213
|
-
}
|
|
7214
|
-
),
|
|
7215
|
-
recommendations.gaps.map((gap, i) => /* @__PURE__ */ jsx30(RecommendationRow, { gap, index: i, tier }, `gap-${i}`))
|
|
7216
|
-
] })
|
|
7186
|
+
function PromptfooUnavailable({ reason }) {
|
|
7187
|
+
return /* @__PURE__ */ jsxs24(Flex17, { align: "center", gap: 2, children: [
|
|
7188
|
+
/* @__PURE__ */ jsx29(Text26, { muted: true, size: 2, children: "Promptfoo report not available" }),
|
|
7189
|
+
/* @__PURE__ */ jsx29(InfoTip, { text: UNAVAILABLE_TOOLTIPS[reason] ?? "" })
|
|
7217
7190
|
] });
|
|
7218
7191
|
}
|
|
7219
|
-
function ColHeader2({ label, tooltip }) {
|
|
7220
|
-
return /* @__PURE__ */ jsxs25(Flex18, { align: "center", gap: 1, children: [
|
|
7221
|
-
/* @__PURE__ */ jsx30(
|
|
7222
|
-
Text27,
|
|
7223
|
-
{
|
|
7224
|
-
muted: true,
|
|
7225
|
-
size: 1,
|
|
7226
|
-
style: {
|
|
7227
|
-
letterSpacing: "0.06em",
|
|
7228
|
-
textTransform: "uppercase"
|
|
7229
|
-
},
|
|
7230
|
-
weight: "semibold",
|
|
7231
|
-
children: label
|
|
7232
|
-
}
|
|
7233
|
-
),
|
|
7234
|
-
tooltip && /* @__PURE__ */ jsx30(InfoTip, { text: tooltip })
|
|
7235
|
-
] });
|
|
7236
|
-
}
|
|
7237
|
-
var FAILURE_MODE_COLORS = {
|
|
7238
|
-
"missing-docs": { bg: "rgba(239,68,68,0.2)", text: "#f87171" },
|
|
7239
|
-
"incorrect-docs": { bg: "rgba(239,68,68,0.2)", text: "#f87171" },
|
|
7240
|
-
"outdated-docs": { bg: "rgba(245,158,11,0.2)", text: "#fbbf24" },
|
|
7241
|
-
"poor-structure": { bg: "rgba(245,158,11,0.2)", text: "#fbbf24" }
|
|
7242
|
-
};
|
|
7243
|
-
var fmLabel = {
|
|
7244
|
-
fontWeight: 600
|
|
7245
|
-
};
|
|
7246
|
-
var FAILURE_MODE_DESCS = {
|
|
7247
|
-
"missing-docs": "This feature has no documentation at all. AI agents have nothing to reference when implementing it.",
|
|
7248
|
-
"incorrect-docs": "The documentation contains factual errors \u2014 wrong API signatures, incorrect parameters, or misleading examples.",
|
|
7249
|
-
"outdated-docs": "The docs describe old APIs or deprecated patterns. AI agents follow them and produce code that doesn't work with current versions.",
|
|
7250
|
-
"poor-structure": "The docs exist but are hard to find or understand. AI agents struggle to locate the right information or misinterpret it."
|
|
7251
|
-
};
|
|
7252
|
-
function failureModeTip(mode) {
|
|
7253
|
-
const desc = FAILURE_MODE_DESCS[mode];
|
|
7254
|
-
if (!desc) return GLOSSARY.failureMode;
|
|
7255
|
-
return /* @__PURE__ */ jsxs25(Text27, { size: 2, style: { lineHeight: 1.5 }, children: [
|
|
7256
|
-
/* @__PURE__ */ jsx30("span", { style: fmLabel, children: mode }),
|
|
7257
|
-
" \u2014 ",
|
|
7258
|
-
desc
|
|
7259
|
-
] });
|
|
7260
|
-
}
|
|
7261
|
-
var CONFIDENCE_DESCS = {
|
|
7262
|
-
high: "Strong keyword and structural signal agreement \u2014 this diagnosis is reliable.",
|
|
7263
|
-
medium: "Partial signal agreement \u2014 likely correct but worth verifying manually.",
|
|
7264
|
-
low: "Weak signals only \u2014 treat as a hypothesis to investigate, not a confirmed diagnosis."
|
|
7265
|
-
};
|
|
7266
|
-
function confidenceTip(level) {
|
|
7267
|
-
const desc = CONFIDENCE_DESCS[level];
|
|
7268
|
-
if (!desc) return GLOSSARY.confidence;
|
|
7269
|
-
const icons = { high: "\u{1F7E2}", medium: "\u{1F7E1}", low: "\u{1F534}" };
|
|
7270
|
-
return /* @__PURE__ */ jsxs25(Text27, { size: 2, style: { lineHeight: 1.5 }, children: [
|
|
7271
|
-
icons[level],
|
|
7272
|
-
" ",
|
|
7273
|
-
/* @__PURE__ */ jsxs25("span", { style: fmLabel, children: [
|
|
7274
|
-
level,
|
|
7275
|
-
" confidence"
|
|
7276
|
-
] }),
|
|
7277
|
-
" \u2014 ",
|
|
7278
|
-
desc
|
|
7279
|
-
] });
|
|
7280
|
-
}
|
|
7281
|
-
function RecommendationRow({
|
|
7282
|
-
gap,
|
|
7283
|
-
index,
|
|
7284
|
-
tier
|
|
7285
|
-
}) {
|
|
7286
|
-
const confIcon = gap.confidence === "high" ? "\u{1F7E2}" : gap.confidence === "medium" ? "\u{1F7E1}" : "\u{1F534}";
|
|
7287
|
-
const fmColors = FAILURE_MODE_COLORS[gap.failureMode] ?? {
|
|
7288
|
-
bg: "var(--card-muted-bg-color)",
|
|
7289
|
-
text: "var(--card-muted-fg-color)"
|
|
7290
|
-
};
|
|
7291
|
-
return /* @__PURE__ */ jsxs25(
|
|
7292
|
-
"div",
|
|
7293
|
-
{
|
|
7294
|
-
style: {
|
|
7295
|
-
alignItems: "center",
|
|
7296
|
-
display: "grid",
|
|
7297
|
-
gap: "0 12px",
|
|
7298
|
-
gridTemplateColumns: GRID2[tier],
|
|
7299
|
-
padding: "10px 16px",
|
|
7300
|
-
...index > 0 ? dividerStyle : {}
|
|
7301
|
-
},
|
|
7302
|
-
children: [
|
|
7303
|
-
/* @__PURE__ */ jsx30(Text27, { size: 2, weight: "medium", children: gap.area }),
|
|
7304
|
-
/* @__PURE__ */ jsx30(HoverTip, { text: failureModeTip(gap.failureMode), children: /* @__PURE__ */ jsx30(
|
|
7305
|
-
"span",
|
|
7306
|
-
{
|
|
7307
|
-
style: {
|
|
7308
|
-
backgroundColor: fmColors.bg,
|
|
7309
|
-
borderRadius: 4,
|
|
7310
|
-
color: fmColors.text,
|
|
7311
|
-
fontSize: 13,
|
|
7312
|
-
fontWeight: 500,
|
|
7313
|
-
padding: "3px 8px"
|
|
7314
|
-
},
|
|
7315
|
-
children: gap.failureMode
|
|
7316
|
-
}
|
|
7317
|
-
) }),
|
|
7318
|
-
tier !== "narrow" && /* @__PURE__ */ jsx30(Text27, { muted: true, size: 2, children: gap.remediation }),
|
|
7319
|
-
tier === "full" && /* @__PURE__ */ jsxs25(
|
|
7320
|
-
"span",
|
|
7321
|
-
{
|
|
7322
|
-
style: {
|
|
7323
|
-
backgroundColor: "rgba(16,185,129,0.2)",
|
|
7324
|
-
borderRadius: 4,
|
|
7325
|
-
color: "#34d399",
|
|
7326
|
-
fontFamily: "var(--font-code-size, monospace)",
|
|
7327
|
-
fontSize: 14,
|
|
7328
|
-
fontWeight: 600,
|
|
7329
|
-
padding: "3px 8px",
|
|
7330
|
-
textAlign: "right"
|
|
7331
|
-
},
|
|
7332
|
-
children: [
|
|
7333
|
-
"+",
|
|
7334
|
-
gap.estimatedLift.toFixed(1)
|
|
7335
|
-
]
|
|
7336
|
-
}
|
|
7337
|
-
),
|
|
7338
|
-
tier !== "narrow" && /* @__PURE__ */ jsx30(HoverTip, { text: confidenceTip(gap.confidence), children: /* @__PURE__ */ jsxs25(Text27, { size: 2, children: [
|
|
7339
|
-
confIcon,
|
|
7340
|
-
" ",
|
|
7341
|
-
gap.confidence
|
|
7342
|
-
] }) })
|
|
7343
|
-
]
|
|
7344
|
-
}
|
|
7345
|
-
);
|
|
7346
|
-
}
|
|
7347
7192
|
|
|
7348
7193
|
// src/components/report-detail/report-actions/ActionButton.tsx
|
|
7349
7194
|
import { Button as Button4, useToast as useToast3 } from "@sanity/ui";
|
|
7350
|
-
import { jsx as
|
|
7195
|
+
import { jsx as jsx30 } from "react/jsx-runtime";
|
|
7351
7196
|
|
|
7352
7197
|
// src/components/report-detail/report-actions/ReportActions.tsx
|
|
7353
7198
|
import { ChevronDownIcon, CopyIcon as CopyIcon3 } from "@sanity/icons";
|
|
7354
7199
|
import {
|
|
7355
7200
|
Button as Button6,
|
|
7356
|
-
Flex as
|
|
7201
|
+
Flex as Flex19,
|
|
7357
7202
|
Menu,
|
|
7358
7203
|
MenuButton,
|
|
7359
7204
|
MenuDivider,
|
|
@@ -7367,7 +7212,7 @@ import { ClipboardIcon } from "@sanity/icons";
|
|
|
7367
7212
|
import { MenuItem, useToast as useToast4 } from "@sanity/ui";
|
|
7368
7213
|
import { useCallback as useCallback16, useState as useState13 } from "react";
|
|
7369
7214
|
import { useClient as useClient6 } from "sanity";
|
|
7370
|
-
import { jsx as
|
|
7215
|
+
import { jsx as jsx31 } from "react/jsx-runtime";
|
|
7371
7216
|
function CopyReportAction({ documentId }) {
|
|
7372
7217
|
const client = useClient6({ apiVersion: API_VERSION });
|
|
7373
7218
|
const toast = useToast4();
|
|
@@ -7404,7 +7249,7 @@ function CopyReportAction({ documentId }) {
|
|
|
7404
7249
|
setCopying(false);
|
|
7405
7250
|
}
|
|
7406
7251
|
}, [client, documentId, toast]);
|
|
7407
|
-
return /* @__PURE__ */
|
|
7252
|
+
return /* @__PURE__ */ jsx31(
|
|
7408
7253
|
MenuItem,
|
|
7409
7254
|
{
|
|
7410
7255
|
disabled: copying,
|
|
@@ -7419,7 +7264,7 @@ function CopyReportAction({ documentId }) {
|
|
|
7419
7264
|
import { CopyIcon as CopyIcon2 } from "@sanity/icons";
|
|
7420
7265
|
import { MenuItem as MenuItem2, useToast as useToast5 } from "@sanity/ui";
|
|
7421
7266
|
import { useCallback as useCallback17 } from "react";
|
|
7422
|
-
import { jsx as
|
|
7267
|
+
import { jsx as jsx32 } from "react/jsx-runtime";
|
|
7423
7268
|
function CopyReportIdAction({ reportId }) {
|
|
7424
7269
|
const toast = useToast5();
|
|
7425
7270
|
const handleClick = useCallback17(() => {
|
|
@@ -7440,14 +7285,14 @@ function CopyReportIdAction({ reportId }) {
|
|
|
7440
7285
|
}
|
|
7441
7286
|
);
|
|
7442
7287
|
}, [reportId, toast]);
|
|
7443
|
-
return /* @__PURE__ */
|
|
7288
|
+
return /* @__PURE__ */ jsx32(MenuItem2, { icon: CopyIcon2, onClick: handleClick, text: "Copy report ID" });
|
|
7444
7289
|
}
|
|
7445
7290
|
|
|
7446
7291
|
// src/components/report-detail/report-actions/CopyVisionQueryAction.tsx
|
|
7447
7292
|
import { SearchIcon as SearchIcon5 } from "@sanity/icons";
|
|
7448
7293
|
import { MenuItem as MenuItem3, useToast as useToast6 } from "@sanity/ui";
|
|
7449
7294
|
import { useCallback as useCallback18 } from "react";
|
|
7450
|
-
import { jsx as
|
|
7295
|
+
import { jsx as jsx33 } from "react/jsx-runtime";
|
|
7451
7296
|
function CopyVisionQueryAction({
|
|
7452
7297
|
reportId
|
|
7453
7298
|
}) {
|
|
@@ -7472,7 +7317,7 @@ function CopyVisionQueryAction({
|
|
|
7472
7317
|
}
|
|
7473
7318
|
);
|
|
7474
7319
|
}, [reportId, toast]);
|
|
7475
|
-
return /* @__PURE__ */
|
|
7320
|
+
return /* @__PURE__ */ jsx33(
|
|
7476
7321
|
MenuItem3,
|
|
7477
7322
|
{
|
|
7478
7323
|
icon: SearchIcon5,
|
|
@@ -7483,25 +7328,25 @@ function CopyVisionQueryAction({
|
|
|
7483
7328
|
}
|
|
7484
7329
|
|
|
7485
7330
|
// src/components/report-detail/report-actions/DeleteConfirmDialog.tsx
|
|
7486
|
-
import { Box as
|
|
7487
|
-
import { jsx as
|
|
7331
|
+
import { Box as Box17, Button as Button5, Card as Card15, Dialog, Flex as Flex18, Stack as Stack22, Text as Text27 } from "@sanity/ui";
|
|
7332
|
+
import { jsx as jsx34, jsxs as jsxs25 } from "react/jsx-runtime";
|
|
7488
7333
|
function DeleteConfirmDialog({
|
|
7489
7334
|
isDeleting,
|
|
7490
7335
|
onClose,
|
|
7491
7336
|
onConfirm,
|
|
7492
7337
|
reportId
|
|
7493
7338
|
}) {
|
|
7494
|
-
return /* @__PURE__ */
|
|
7339
|
+
return /* @__PURE__ */ jsx34(
|
|
7495
7340
|
Dialog,
|
|
7496
7341
|
{
|
|
7497
7342
|
header: "Delete Report",
|
|
7498
7343
|
id: "delete-report-dialog",
|
|
7499
7344
|
onClose,
|
|
7500
7345
|
width: 1,
|
|
7501
|
-
children: /* @__PURE__ */
|
|
7502
|
-
/* @__PURE__ */
|
|
7503
|
-
/* @__PURE__ */
|
|
7504
|
-
|
|
7346
|
+
children: /* @__PURE__ */ jsx34(Box17, { padding: 4, children: /* @__PURE__ */ jsxs25(Stack22, { space: 4, children: [
|
|
7347
|
+
/* @__PURE__ */ jsx34(Text27, { children: "Are you sure you want to delete this report? This action cannot be undone." }),
|
|
7348
|
+
/* @__PURE__ */ jsx34(Card15, { border: true, padding: 3, radius: 2, tone: "transparent", children: /* @__PURE__ */ jsx34(
|
|
7349
|
+
Text27,
|
|
7505
7350
|
{
|
|
7506
7351
|
muted: true,
|
|
7507
7352
|
size: 1,
|
|
@@ -7509,8 +7354,8 @@ function DeleteConfirmDialog({
|
|
|
7509
7354
|
children: reportId
|
|
7510
7355
|
}
|
|
7511
7356
|
) }),
|
|
7512
|
-
/* @__PURE__ */
|
|
7513
|
-
/* @__PURE__ */
|
|
7357
|
+
/* @__PURE__ */ jsxs25(Flex18, { gap: 2, justify: "flex-end", children: [
|
|
7358
|
+
/* @__PURE__ */ jsx34(
|
|
7514
7359
|
Button5,
|
|
7515
7360
|
{
|
|
7516
7361
|
disabled: isDeleting,
|
|
@@ -7519,7 +7364,7 @@ function DeleteConfirmDialog({
|
|
|
7519
7364
|
text: "Cancel"
|
|
7520
7365
|
}
|
|
7521
7366
|
),
|
|
7522
|
-
/* @__PURE__ */
|
|
7367
|
+
/* @__PURE__ */ jsx34(
|
|
7523
7368
|
Button5,
|
|
7524
7369
|
{
|
|
7525
7370
|
disabled: isDeleting,
|
|
@@ -7537,11 +7382,11 @@ function DeleteConfirmDialog({
|
|
|
7537
7382
|
// src/components/report-detail/report-actions/DeleteReportAction.tsx
|
|
7538
7383
|
import { TrashIcon } from "@sanity/icons";
|
|
7539
7384
|
import { MenuItem as MenuItem4 } from "@sanity/ui";
|
|
7540
|
-
import { jsx as
|
|
7385
|
+
import { jsx as jsx35 } from "react/jsx-runtime";
|
|
7541
7386
|
function DeleteReportAction({
|
|
7542
7387
|
onRequestDelete
|
|
7543
7388
|
}) {
|
|
7544
|
-
return /* @__PURE__ */
|
|
7389
|
+
return /* @__PURE__ */ jsx35(
|
|
7545
7390
|
MenuItem4,
|
|
7546
7391
|
{
|
|
7547
7392
|
icon: TrashIcon,
|
|
@@ -7557,7 +7402,7 @@ import { DownloadIcon } from "@sanity/icons";
|
|
|
7557
7402
|
import { MenuItem as MenuItem5, useToast as useToast7 } from "@sanity/ui";
|
|
7558
7403
|
import { useCallback as useCallback19, useState as useState14 } from "react";
|
|
7559
7404
|
import { useClient as useClient7 } from "sanity";
|
|
7560
|
-
import { jsx as
|
|
7405
|
+
import { jsx as jsx36 } from "react/jsx-runtime";
|
|
7561
7406
|
function DownloadReportAction({
|
|
7562
7407
|
documentId,
|
|
7563
7408
|
reportId
|
|
@@ -7605,7 +7450,7 @@ function DownloadReportAction({
|
|
|
7605
7450
|
setDownloading(false);
|
|
7606
7451
|
}
|
|
7607
7452
|
}, [client, documentId, reportId, toast]);
|
|
7608
|
-
return /* @__PURE__ */
|
|
7453
|
+
return /* @__PURE__ */ jsx36(
|
|
7609
7454
|
MenuItem5,
|
|
7610
7455
|
{
|
|
7611
7456
|
disabled: downloading,
|
|
@@ -7635,7 +7480,7 @@ function extractEvalScope(provenance) {
|
|
|
7635
7480
|
}
|
|
7636
7481
|
|
|
7637
7482
|
// src/components/report-detail/report-actions/RerunEvaluationAction.tsx
|
|
7638
|
-
import { jsx as
|
|
7483
|
+
import { jsx as jsx37 } from "react/jsx-runtime";
|
|
7639
7484
|
var EVAL_REQUEST_TYPE2 = "ailf.evalRequest";
|
|
7640
7485
|
function slugify2(s) {
|
|
7641
7486
|
return s.toLowerCase().replace(/[^a-z0-9]+/g, "-").replace(/^-+|-+$/g, "").slice(0, 40);
|
|
@@ -7702,7 +7547,7 @@ function RerunEvaluationAction({
|
|
|
7702
7547
|
setRequesting(false);
|
|
7703
7548
|
}
|
|
7704
7549
|
}, [client, currentUser?.id, provenance, reportId, toast]);
|
|
7705
|
-
return /* @__PURE__ */
|
|
7550
|
+
return /* @__PURE__ */ jsx37(
|
|
7706
7551
|
MenuItem6,
|
|
7707
7552
|
{
|
|
7708
7553
|
disabled: requesting,
|
|
@@ -7714,7 +7559,7 @@ function RerunEvaluationAction({
|
|
|
7714
7559
|
}
|
|
7715
7560
|
|
|
7716
7561
|
// src/components/report-detail/report-actions/ReportActions.tsx
|
|
7717
|
-
import { Fragment as Fragment10, jsx as
|
|
7562
|
+
import { Fragment as Fragment10, jsx as jsx38, jsxs as jsxs26 } from "react/jsx-runtime";
|
|
7718
7563
|
function ReportActions({
|
|
7719
7564
|
documentId,
|
|
7720
7565
|
onDeleted,
|
|
@@ -7770,9 +7615,9 @@ function ReportActions({
|
|
|
7770
7615
|
setDeleting(false);
|
|
7771
7616
|
}
|
|
7772
7617
|
}, [client, documentId, onDeleted, toast]);
|
|
7773
|
-
return /* @__PURE__ */
|
|
7774
|
-
/* @__PURE__ */
|
|
7775
|
-
/* @__PURE__ */
|
|
7618
|
+
return /* @__PURE__ */ jsxs26(Fragment10, { children: [
|
|
7619
|
+
/* @__PURE__ */ jsxs26(Flex19, { children: [
|
|
7620
|
+
/* @__PURE__ */ jsx38(
|
|
7776
7621
|
Button6,
|
|
7777
7622
|
{
|
|
7778
7623
|
icon: CopyIcon3,
|
|
@@ -7786,10 +7631,10 @@ function ReportActions({
|
|
|
7786
7631
|
text: "Copy Report ID"
|
|
7787
7632
|
}
|
|
7788
7633
|
),
|
|
7789
|
-
/* @__PURE__ */
|
|
7634
|
+
/* @__PURE__ */ jsx38(
|
|
7790
7635
|
MenuButton,
|
|
7791
7636
|
{
|
|
7792
|
-
button: /* @__PURE__ */
|
|
7637
|
+
button: /* @__PURE__ */ jsx38(
|
|
7793
7638
|
Button6,
|
|
7794
7639
|
{
|
|
7795
7640
|
icon: ChevronDownIcon,
|
|
@@ -7802,33 +7647,33 @@ function ReportActions({
|
|
|
7802
7647
|
}
|
|
7803
7648
|
),
|
|
7804
7649
|
id: "report-actions-menu",
|
|
7805
|
-
menu: /* @__PURE__ */
|
|
7806
|
-
/* @__PURE__ */
|
|
7807
|
-
/* @__PURE__ */
|
|
7650
|
+
menu: /* @__PURE__ */ jsxs26(Menu, { children: [
|
|
7651
|
+
/* @__PURE__ */ jsx38(CopyReportIdAction, { reportId }),
|
|
7652
|
+
/* @__PURE__ */ jsx38(
|
|
7808
7653
|
RerunEvaluationAction,
|
|
7809
7654
|
{
|
|
7810
7655
|
provenance,
|
|
7811
7656
|
reportId
|
|
7812
7657
|
}
|
|
7813
7658
|
),
|
|
7814
|
-
/* @__PURE__ */
|
|
7815
|
-
/* @__PURE__ */
|
|
7659
|
+
/* @__PURE__ */ jsx38(MenuDivider, {}),
|
|
7660
|
+
/* @__PURE__ */ jsx38(
|
|
7816
7661
|
DownloadReportAction,
|
|
7817
7662
|
{
|
|
7818
7663
|
documentId,
|
|
7819
7664
|
reportId
|
|
7820
7665
|
}
|
|
7821
7666
|
),
|
|
7822
|
-
/* @__PURE__ */
|
|
7823
|
-
/* @__PURE__ */
|
|
7824
|
-
/* @__PURE__ */
|
|
7825
|
-
/* @__PURE__ */
|
|
7667
|
+
/* @__PURE__ */ jsx38(CopyReportAction, { documentId }),
|
|
7668
|
+
/* @__PURE__ */ jsx38(CopyVisionQueryAction, { reportId }),
|
|
7669
|
+
/* @__PURE__ */ jsx38(MenuDivider, {}),
|
|
7670
|
+
/* @__PURE__ */ jsx38(DeleteReportAction, { onRequestDelete: handleRequestDelete })
|
|
7826
7671
|
] }),
|
|
7827
7672
|
popover: { placement: "bottom-end", portal: true }
|
|
7828
7673
|
}
|
|
7829
7674
|
)
|
|
7830
7675
|
] }),
|
|
7831
|
-
deleteDialogOpen && /* @__PURE__ */
|
|
7676
|
+
deleteDialogOpen && /* @__PURE__ */ jsx38(
|
|
7832
7677
|
DeleteConfirmDialog,
|
|
7833
7678
|
{
|
|
7834
7679
|
isDeleting: deleting,
|
|
@@ -7842,8 +7687,8 @@ function ReportActions({
|
|
|
7842
7687
|
|
|
7843
7688
|
// src/components/report-detail/ReportHeader.tsx
|
|
7844
7689
|
import { ArrowLeftIcon as ArrowLeftIcon2 } from "@sanity/icons";
|
|
7845
|
-
import { Button as Button7, Flex as
|
|
7846
|
-
import { jsx as
|
|
7690
|
+
import { Button as Button7, Flex as Flex20, Stack as Stack23, Text as Text28 } from "@sanity/ui";
|
|
7691
|
+
import { jsx as jsx39, jsxs as jsxs27 } from "react/jsx-runtime";
|
|
7847
7692
|
function ReportHeader({
|
|
7848
7693
|
completedAt,
|
|
7849
7694
|
onBack,
|
|
@@ -7853,11 +7698,11 @@ function ReportHeader({
|
|
|
7853
7698
|
const dateLabel = formatCardDate(completedAt);
|
|
7854
7699
|
const displayTitle = title ?? tag ?? dateLabel;
|
|
7855
7700
|
const hasSubtitle = Boolean(title ?? tag);
|
|
7856
|
-
return /* @__PURE__ */
|
|
7857
|
-
/* @__PURE__ */
|
|
7858
|
-
/* @__PURE__ */
|
|
7859
|
-
/* @__PURE__ */
|
|
7860
|
-
hasSubtitle && /* @__PURE__ */
|
|
7701
|
+
return /* @__PURE__ */ jsxs27(Flex20, { align: "center", gap: 3, children: [
|
|
7702
|
+
/* @__PURE__ */ jsx39(Button7, { icon: ArrowLeftIcon2, mode: "bleed", onClick: onBack, text: "Back" }),
|
|
7703
|
+
/* @__PURE__ */ jsxs27(Stack23, { flex: 1, space: 1, children: [
|
|
7704
|
+
/* @__PURE__ */ jsx39(Text28, { size: 4, weight: "bold", children: displayTitle }),
|
|
7705
|
+
hasSubtitle && /* @__PURE__ */ jsx39(Text28, { muted: true, size: 2, children: dateLabel })
|
|
7861
7706
|
] })
|
|
7862
7707
|
] });
|
|
7863
7708
|
}
|
|
@@ -7865,7 +7710,7 @@ function ReportHeader({
|
|
|
7865
7710
|
// src/components/report-detail/StrengthsList.tsx
|
|
7866
7711
|
import { useMemo as useMemo8 } from "react";
|
|
7867
7712
|
import { CheckmarkCircleIcon as CheckmarkCircleIcon2, SearchIcon as SearchIcon6 } from "@sanity/icons";
|
|
7868
|
-
import { Box as
|
|
7713
|
+
import { Box as Box19, Flex as Flex23, Stack as Stack25, Text as Text31 } from "@sanity/ui";
|
|
7869
7714
|
|
|
7870
7715
|
// src/components/report-detail/AreaScoresGrid.tsx
|
|
7871
7716
|
import React3, {
|
|
@@ -7874,8 +7719,8 @@ import React3, {
|
|
|
7874
7719
|
useState as useState17
|
|
7875
7720
|
} from "react";
|
|
7876
7721
|
import { WarningOutlineIcon as WarningOutlineIcon2 } from "@sanity/icons";
|
|
7877
|
-
import { Box as
|
|
7878
|
-
import { Fragment as Fragment11, jsx as
|
|
7722
|
+
import { Box as Box18, Flex as Flex21, Stack as Stack24, Text as Text29 } from "@sanity/ui";
|
|
7723
|
+
import { Fragment as Fragment11, jsx as jsx40, jsxs as jsxs28 } from "react/jsx-runtime";
|
|
7879
7724
|
var DIMENSION_TOOLTIPS2 = {
|
|
7880
7725
|
agentOutput: "Quality and completeness of the agent's output. Graded 0\u2013100.",
|
|
7881
7726
|
assertionPassRate: "Fraction of structural assertions that passed. Graded 0\u2013100.",
|
|
@@ -7884,7 +7729,7 @@ var DIMENSION_TOOLTIPS2 = {
|
|
|
7884
7729
|
taskCompletion: GLOSSARY.taskCompletion,
|
|
7885
7730
|
toolUsage: "How effectively the agent used available tools (file read/write, shell, etc.). Graded 0\u2013100."
|
|
7886
7731
|
};
|
|
7887
|
-
function
|
|
7732
|
+
function tableTier(width) {
|
|
7888
7733
|
if (width >= 900) return "full";
|
|
7889
7734
|
if (width >= 600) return "compact";
|
|
7890
7735
|
return "narrow";
|
|
@@ -7895,7 +7740,6 @@ function gridColumns(tier, dimCount, showLift, hasActual) {
|
|
|
7895
7740
|
case "full": {
|
|
7896
7741
|
const parts = ["120px", "1fr", dims];
|
|
7897
7742
|
if (showLift) parts.push("80px");
|
|
7898
|
-
if (showLift) parts.push("72px");
|
|
7899
7743
|
if (hasActual) parts.push("72px");
|
|
7900
7744
|
return parts.join(" ");
|
|
7901
7745
|
}
|
|
@@ -7915,7 +7759,7 @@ function AreaScoresGrid({
|
|
|
7915
7759
|
perModel
|
|
7916
7760
|
}) {
|
|
7917
7761
|
const { ref: containerRef, width } = useContainerWidth();
|
|
7918
|
-
const tier =
|
|
7762
|
+
const tier = tableTier(width);
|
|
7919
7763
|
const hasActual = useMemo6(
|
|
7920
7764
|
() => scores.some((s) => s.actualScore != null),
|
|
7921
7765
|
[scores]
|
|
@@ -7968,8 +7812,8 @@ function AreaScoresGrid({
|
|
|
7968
7812
|
}
|
|
7969
7813
|
return map;
|
|
7970
7814
|
}, [perModel]);
|
|
7971
|
-
return /* @__PURE__ */
|
|
7972
|
-
/* @__PURE__ */
|
|
7815
|
+
return /* @__PURE__ */ jsxs28(Box18, { ref: containerRef, style: { ...neutralCardStyle, overflow: "auto" }, children: [
|
|
7816
|
+
/* @__PURE__ */ jsxs28(
|
|
7973
7817
|
"div",
|
|
7974
7818
|
{
|
|
7975
7819
|
style: {
|
|
@@ -7985,8 +7829,8 @@ function AreaScoresGrid({
|
|
|
7985
7829
|
padding: "12px 16px 8px"
|
|
7986
7830
|
},
|
|
7987
7831
|
children: [
|
|
7988
|
-
/* @__PURE__ */
|
|
7989
|
-
|
|
7832
|
+
/* @__PURE__ */ jsx40(
|
|
7833
|
+
ColHeader2,
|
|
7990
7834
|
{
|
|
7991
7835
|
active: sortField === "score",
|
|
7992
7836
|
direction: sortDir,
|
|
@@ -7995,8 +7839,8 @@ function AreaScoresGrid({
|
|
|
7995
7839
|
tooltip: GLOSSARY.score
|
|
7996
7840
|
}
|
|
7997
7841
|
),
|
|
7998
|
-
/* @__PURE__ */
|
|
7999
|
-
|
|
7842
|
+
/* @__PURE__ */ jsx40(
|
|
7843
|
+
ColHeader2,
|
|
8000
7844
|
{
|
|
8001
7845
|
active: sortField === "area",
|
|
8002
7846
|
direction: sortDir,
|
|
@@ -8004,8 +7848,8 @@ function AreaScoresGrid({
|
|
|
8004
7848
|
onClick: () => handleSort("area")
|
|
8005
7849
|
}
|
|
8006
7850
|
),
|
|
8007
|
-
dimKeys.map((key) => /* @__PURE__ */
|
|
8008
|
-
|
|
7851
|
+
dimKeys.map((key) => /* @__PURE__ */ jsx40(
|
|
7852
|
+
ColHeader2,
|
|
8009
7853
|
{
|
|
8010
7854
|
active: sortField === key,
|
|
8011
7855
|
direction: sortDir,
|
|
@@ -8015,8 +7859,8 @@ function AreaScoresGrid({
|
|
|
8015
7859
|
},
|
|
8016
7860
|
key
|
|
8017
7861
|
)),
|
|
8018
|
-
tier !== "narrow" && showLift && /* @__PURE__ */
|
|
8019
|
-
|
|
7862
|
+
tier !== "narrow" && showLift && /* @__PURE__ */ jsx40(
|
|
7863
|
+
ColHeader2,
|
|
8020
7864
|
{
|
|
8021
7865
|
active: sortField === "lift",
|
|
8022
7866
|
direction: sortDir,
|
|
@@ -8025,13 +7869,12 @@ function AreaScoresGrid({
|
|
|
8025
7869
|
tooltip: GLOSSARY.docLift
|
|
8026
7870
|
}
|
|
8027
7871
|
),
|
|
8028
|
-
tier === "full" &&
|
|
8029
|
-
tier === "full" && hasActual && /* @__PURE__ */ jsx41(ColHeader3, { label: "Actual", tooltip: GLOSSARY.actualScore })
|
|
7872
|
+
tier === "full" && hasActual && /* @__PURE__ */ jsx40(ColHeader2, { label: "Actual", tooltip: GLOSSARY.actualScore })
|
|
8030
7873
|
]
|
|
8031
7874
|
}
|
|
8032
7875
|
),
|
|
8033
|
-
sorted.map((area) => /* @__PURE__ */
|
|
8034
|
-
/* @__PURE__ */
|
|
7876
|
+
sorted.map((area) => /* @__PURE__ */ jsxs28(React3.Fragment, { children: [
|
|
7877
|
+
/* @__PURE__ */ jsx40(
|
|
8035
7878
|
AreaRow,
|
|
8036
7879
|
{
|
|
8037
7880
|
area,
|
|
@@ -8042,7 +7885,7 @@ function AreaScoresGrid({
|
|
|
8042
7885
|
tier
|
|
8043
7886
|
}
|
|
8044
7887
|
),
|
|
8045
|
-
modelScoresByFeature && /* @__PURE__ */
|
|
7888
|
+
modelScoresByFeature && /* @__PURE__ */ jsx40(
|
|
8046
7889
|
ModelSubRows,
|
|
8047
7890
|
{
|
|
8048
7891
|
dimKeys,
|
|
@@ -8063,7 +7906,7 @@ function ModelSubRows({
|
|
|
8063
7906
|
tier
|
|
8064
7907
|
}) {
|
|
8065
7908
|
if (!models || models.length === 0) return null;
|
|
8066
|
-
return /* @__PURE__ */
|
|
7909
|
+
return /* @__PURE__ */ jsx40(Fragment11, { children: models.map((entry) => /* @__PURE__ */ jsx40(
|
|
8067
7910
|
ModelRow,
|
|
8068
7911
|
{
|
|
8069
7912
|
dimKeys,
|
|
@@ -8085,7 +7928,7 @@ function ModelRow({
|
|
|
8085
7928
|
tier
|
|
8086
7929
|
}) {
|
|
8087
7930
|
const isNarrow = tier === "narrow";
|
|
8088
|
-
return /* @__PURE__ */
|
|
7931
|
+
return /* @__PURE__ */ jsxs28(
|
|
8089
7932
|
"div",
|
|
8090
7933
|
{
|
|
8091
7934
|
style: {
|
|
@@ -8103,8 +7946,8 @@ function ModelRow({
|
|
|
8103
7946
|
padding: isNarrow ? "6px 12px 6px 20px" : "6px 16px 6px 28px"
|
|
8104
7947
|
},
|
|
8105
7948
|
children: [
|
|
8106
|
-
/* @__PURE__ */
|
|
8107
|
-
|
|
7949
|
+
/* @__PURE__ */ jsx40(Flex21, { align: "center", children: /* @__PURE__ */ jsx40(
|
|
7950
|
+
Text29,
|
|
8108
7951
|
{
|
|
8109
7952
|
size: 1,
|
|
8110
7953
|
style: {
|
|
@@ -8115,8 +7958,8 @@ function ModelRow({
|
|
|
8115
7958
|
children: Math.round(scores.totalScore)
|
|
8116
7959
|
}
|
|
8117
7960
|
) }),
|
|
8118
|
-
/* @__PURE__ */
|
|
8119
|
-
dimKeys.map((key) => /* @__PURE__ */
|
|
7961
|
+
/* @__PURE__ */ jsx40(Flex21, { align: "center", gap: 2, children: /* @__PURE__ */ jsx40(Text29, { muted: true, size: 1, children: label }) }),
|
|
7962
|
+
dimKeys.map((key) => /* @__PURE__ */ jsx40(
|
|
8120
7963
|
DimCell,
|
|
8121
7964
|
{
|
|
8122
7965
|
area: label,
|
|
@@ -8126,8 +7969,8 @@ function ModelRow({
|
|
|
8126
7969
|
},
|
|
8127
7970
|
key
|
|
8128
7971
|
)),
|
|
8129
|
-
!isNarrow && showLift && /* @__PURE__ */
|
|
8130
|
-
|
|
7972
|
+
!isNarrow && showLift && /* @__PURE__ */ jsxs28(
|
|
7973
|
+
Text29,
|
|
8131
7974
|
{
|
|
8132
7975
|
size: 1,
|
|
8133
7976
|
style: {
|
|
@@ -8141,17 +7984,8 @@ function ModelRow({
|
|
|
8141
7984
|
]
|
|
8142
7985
|
}
|
|
8143
7986
|
),
|
|
8144
|
-
tier === "full" &&
|
|
8145
|
-
|
|
8146
|
-
{
|
|
8147
|
-
muted: true,
|
|
8148
|
-
size: 1,
|
|
8149
|
-
style: { fontFamily: "var(--font-code-size, monospace)" },
|
|
8150
|
-
children: Math.round(scores.floorScore ?? 0)
|
|
8151
|
-
}
|
|
8152
|
-
),
|
|
8153
|
-
tier === "full" && hasActual && /* @__PURE__ */ jsx41(
|
|
8154
|
-
Text30,
|
|
7987
|
+
tier === "full" && hasActual && /* @__PURE__ */ jsx40(
|
|
7988
|
+
Text29,
|
|
8155
7989
|
{
|
|
8156
7990
|
size: 1,
|
|
8157
7991
|
style: {
|
|
@@ -8175,7 +8009,7 @@ function AreaRow({
|
|
|
8175
8009
|
tier
|
|
8176
8010
|
}) {
|
|
8177
8011
|
const isNarrow = tier === "narrow";
|
|
8178
|
-
return /* @__PURE__ */
|
|
8012
|
+
return /* @__PURE__ */ jsxs28(
|
|
8179
8013
|
"div",
|
|
8180
8014
|
{
|
|
8181
8015
|
style: {
|
|
@@ -8192,15 +8026,15 @@ function AreaRow({
|
|
|
8192
8026
|
padding: isNarrow ? "8px 12px" : "10px 16px"
|
|
8193
8027
|
},
|
|
8194
8028
|
children: [
|
|
8195
|
-
/* @__PURE__ */
|
|
8196
|
-
/* @__PURE__ */
|
|
8029
|
+
/* @__PURE__ */ jsxs28(Flex21, { align: "center", gap: isNarrow ? 0 : 2, children: [
|
|
8030
|
+
/* @__PURE__ */ jsx40(
|
|
8197
8031
|
HoverTip,
|
|
8198
8032
|
{
|
|
8199
|
-
text: /* @__PURE__ */
|
|
8200
|
-
/* @__PURE__ */
|
|
8033
|
+
text: /* @__PURE__ */ jsxs28(Text29, { size: 2, style: { lineHeight: 1.5 }, children: [
|
|
8034
|
+
/* @__PURE__ */ jsx40("span", { style: { fontWeight: 600 }, children: area.feature }),
|
|
8201
8035
|
" score:",
|
|
8202
8036
|
" ",
|
|
8203
|
-
/* @__PURE__ */
|
|
8037
|
+
/* @__PURE__ */ jsx40(
|
|
8204
8038
|
"span",
|
|
8205
8039
|
{
|
|
8206
8040
|
style: {
|
|
@@ -8211,12 +8045,12 @@ function AreaRow({
|
|
|
8211
8045
|
children: Math.round(area.totalScore)
|
|
8212
8046
|
}
|
|
8213
8047
|
),
|
|
8214
|
-
/* @__PURE__ */
|
|
8048
|
+
/* @__PURE__ */ jsx40("span", { style: { color: "var(--card-muted-fg-color)" }, children: "/100" }),
|
|
8215
8049
|
".",
|
|
8216
8050
|
" ",
|
|
8217
8051
|
GLOSSARY.score
|
|
8218
8052
|
] }),
|
|
8219
|
-
children: /* @__PURE__ */
|
|
8053
|
+
children: /* @__PURE__ */ jsx40(
|
|
8220
8054
|
"div",
|
|
8221
8055
|
{
|
|
8222
8056
|
style: {
|
|
@@ -8237,11 +8071,11 @@ function AreaRow({
|
|
|
8237
8071
|
)
|
|
8238
8072
|
}
|
|
8239
8073
|
),
|
|
8240
|
-
!isNarrow && delta != null && delta !== 0 && /* @__PURE__ */
|
|
8074
|
+
!isNarrow && delta != null && delta !== 0 && /* @__PURE__ */ jsx40(HoverTip, { text: GLOSSARY.areaDelta, children: /* @__PURE__ */ jsx40(DeltaIndicator, { delta, icon: true, size: 1 }) })
|
|
8241
8075
|
] }),
|
|
8242
|
-
/* @__PURE__ */
|
|
8243
|
-
/* @__PURE__ */
|
|
8244
|
-
area.negativeDocLift && showLift && /* @__PURE__ */
|
|
8076
|
+
/* @__PURE__ */ jsxs28(Flex21, { align: "center", gap: 2, wrap: "wrap", children: [
|
|
8077
|
+
/* @__PURE__ */ jsx40(Text29, { size: 2, weight: "medium", children: area.feature }),
|
|
8078
|
+
area.negativeDocLift && showLift && /* @__PURE__ */ jsx40(HoverTip, { text: GLOSSARY.docsHurt, children: /* @__PURE__ */ jsx40(
|
|
8245
8079
|
"span",
|
|
8246
8080
|
{
|
|
8247
8081
|
style: {
|
|
@@ -8254,11 +8088,11 @@ function AreaRow({
|
|
|
8254
8088
|
gap: 3,
|
|
8255
8089
|
padding: "1px 5px"
|
|
8256
8090
|
},
|
|
8257
|
-
children: /* @__PURE__ */
|
|
8091
|
+
children: /* @__PURE__ */ jsx40(WarningOutlineIcon2, {})
|
|
8258
8092
|
}
|
|
8259
8093
|
) })
|
|
8260
8094
|
] }),
|
|
8261
|
-
dimKeys.map((key) => /* @__PURE__ */
|
|
8095
|
+
dimKeys.map((key) => /* @__PURE__ */ jsx40(
|
|
8262
8096
|
DimCell,
|
|
8263
8097
|
{
|
|
8264
8098
|
area: area.feature,
|
|
@@ -8267,14 +8101,14 @@ function AreaRow({
|
|
|
8267
8101
|
},
|
|
8268
8102
|
key
|
|
8269
8103
|
)),
|
|
8270
|
-
!isNarrow && showLift && /* @__PURE__ */
|
|
8104
|
+
!isNarrow && showLift && /* @__PURE__ */ jsx40(
|
|
8271
8105
|
HoverTip,
|
|
8272
8106
|
{
|
|
8273
|
-
text: /* @__PURE__ */
|
|
8274
|
-
/* @__PURE__ */
|
|
8107
|
+
text: /* @__PURE__ */ jsxs28(Text29, { size: 2, style: { lineHeight: 1.5 }, children: [
|
|
8108
|
+
/* @__PURE__ */ jsx40("span", { style: { fontWeight: 600 }, children: area.feature }),
|
|
8275
8109
|
" doc lift:",
|
|
8276
8110
|
" ",
|
|
8277
|
-
/* @__PURE__ */
|
|
8111
|
+
/* @__PURE__ */ jsxs28(
|
|
8278
8112
|
"span",
|
|
8279
8113
|
{
|
|
8280
8114
|
style: {
|
|
@@ -8292,8 +8126,8 @@ function AreaRow({
|
|
|
8292
8126
|
"pts. ",
|
|
8293
8127
|
GLOSSARY.docLift
|
|
8294
8128
|
] }),
|
|
8295
|
-
children: /* @__PURE__ */
|
|
8296
|
-
|
|
8129
|
+
children: /* @__PURE__ */ jsxs28(
|
|
8130
|
+
Text29,
|
|
8297
8131
|
{
|
|
8298
8132
|
size: 2,
|
|
8299
8133
|
style: {
|
|
@@ -8309,21 +8143,12 @@ function AreaRow({
|
|
|
8309
8143
|
)
|
|
8310
8144
|
}
|
|
8311
8145
|
),
|
|
8312
|
-
tier === "full" &&
|
|
8313
|
-
Text30,
|
|
8314
|
-
{
|
|
8315
|
-
muted: true,
|
|
8316
|
-
size: 2,
|
|
8317
|
-
style: { fontFamily: "var(--font-code-size, monospace)" },
|
|
8318
|
-
children: Math.round(area.floorScore ?? 0)
|
|
8319
|
-
}
|
|
8320
|
-
),
|
|
8321
|
-
tier === "full" && hasActual && /* @__PURE__ */ jsx41(
|
|
8146
|
+
tier === "full" && hasActual && /* @__PURE__ */ jsx40(
|
|
8322
8147
|
HoverTip,
|
|
8323
8148
|
{
|
|
8324
8149
|
text: area.actualScore != null ? `${area.feature} actual score: ${Math.round(area.actualScore)}/100. ${GLOSSARY.actualScore}` : `No agentic data for ${area.feature}.`,
|
|
8325
|
-
children: /* @__PURE__ */
|
|
8326
|
-
|
|
8150
|
+
children: /* @__PURE__ */ jsx40(
|
|
8151
|
+
Text29,
|
|
8327
8152
|
{
|
|
8328
8153
|
size: 2,
|
|
8329
8154
|
style: {
|
|
@@ -8352,17 +8177,17 @@ function DimCell({
|
|
|
8352
8177
|
const tooltip = dimKey ? DIMENSION_TOOLTIPS2[dimKey] : "";
|
|
8353
8178
|
const textSize = size === "small" ? 0 : 1;
|
|
8354
8179
|
const barHeight = size === "small" ? 3 : 4;
|
|
8355
|
-
return /* @__PURE__ */
|
|
8180
|
+
return /* @__PURE__ */ jsx40(
|
|
8356
8181
|
HoverTip,
|
|
8357
8182
|
{
|
|
8358
|
-
text: /* @__PURE__ */
|
|
8359
|
-
/* @__PURE__ */
|
|
8183
|
+
text: /* @__PURE__ */ jsxs28(Text29, { size: 2, style: { lineHeight: 1.5 }, children: [
|
|
8184
|
+
/* @__PURE__ */ jsx40("span", { style: { fontWeight: 600 }, children: area }),
|
|
8360
8185
|
" \u2192",
|
|
8361
8186
|
" ",
|
|
8362
|
-
/* @__PURE__ */
|
|
8187
|
+
/* @__PURE__ */ jsx40("span", { style: { fontWeight: 600 }, children: dim }),
|
|
8363
8188
|
":",
|
|
8364
8189
|
" ",
|
|
8365
|
-
/* @__PURE__ */
|
|
8190
|
+
/* @__PURE__ */ jsx40(
|
|
8366
8191
|
"span",
|
|
8367
8192
|
{
|
|
8368
8193
|
style: {
|
|
@@ -8373,14 +8198,14 @@ function DimCell({
|
|
|
8373
8198
|
children: Math.round(value)
|
|
8374
8199
|
}
|
|
8375
8200
|
),
|
|
8376
|
-
/* @__PURE__ */
|
|
8201
|
+
/* @__PURE__ */ jsx40("span", { style: { color: "var(--card-muted-fg-color)" }, children: "/100" }),
|
|
8377
8202
|
".",
|
|
8378
8203
|
" ",
|
|
8379
8204
|
tooltip
|
|
8380
8205
|
] }),
|
|
8381
|
-
children: /* @__PURE__ */
|
|
8382
|
-
/* @__PURE__ */
|
|
8383
|
-
|
|
8206
|
+
children: /* @__PURE__ */ jsxs28(Stack24, { space: 1, style: { width: "100%" }, children: [
|
|
8207
|
+
/* @__PURE__ */ jsx40(
|
|
8208
|
+
Text29,
|
|
8384
8209
|
{
|
|
8385
8210
|
size: textSize,
|
|
8386
8211
|
style: {
|
|
@@ -8391,7 +8216,7 @@ function DimCell({
|
|
|
8391
8216
|
children: Math.round(value)
|
|
8392
8217
|
}
|
|
8393
8218
|
),
|
|
8394
|
-
/* @__PURE__ */
|
|
8219
|
+
/* @__PURE__ */ jsx40(
|
|
8395
8220
|
"div",
|
|
8396
8221
|
{
|
|
8397
8222
|
style: {
|
|
@@ -8401,7 +8226,7 @@ function DimCell({
|
|
|
8401
8226
|
overflow: "hidden",
|
|
8402
8227
|
width: "100%"
|
|
8403
8228
|
},
|
|
8404
|
-
children: /* @__PURE__ */
|
|
8229
|
+
children: /* @__PURE__ */ jsx40(
|
|
8405
8230
|
"div",
|
|
8406
8231
|
{
|
|
8407
8232
|
style: {
|
|
@@ -8419,7 +8244,7 @@ function DimCell({
|
|
|
8419
8244
|
}
|
|
8420
8245
|
);
|
|
8421
8246
|
}
|
|
8422
|
-
function
|
|
8247
|
+
function ColHeader2({
|
|
8423
8248
|
active,
|
|
8424
8249
|
direction,
|
|
8425
8250
|
label,
|
|
@@ -8436,8 +8261,8 @@ function ColHeader3({
|
|
|
8436
8261
|
[onClick]
|
|
8437
8262
|
);
|
|
8438
8263
|
const arrow = active ? direction === "asc" ? " \u2191" : " \u2193" : "";
|
|
8439
|
-
return /* @__PURE__ */
|
|
8440
|
-
/* @__PURE__ */
|
|
8264
|
+
return /* @__PURE__ */ jsxs28(Flex21, { align: "center", gap: 1, children: [
|
|
8265
|
+
/* @__PURE__ */ jsx40(
|
|
8441
8266
|
"div",
|
|
8442
8267
|
{
|
|
8443
8268
|
onClick,
|
|
@@ -8448,8 +8273,8 @@ function ColHeader3({
|
|
|
8448
8273
|
userSelect: "none"
|
|
8449
8274
|
},
|
|
8450
8275
|
tabIndex: onClick ? 0 : void 0,
|
|
8451
|
-
children: /* @__PURE__ */
|
|
8452
|
-
|
|
8276
|
+
children: /* @__PURE__ */ jsxs28(
|
|
8277
|
+
Text29,
|
|
8453
8278
|
{
|
|
8454
8279
|
muted: true,
|
|
8455
8280
|
size: 1,
|
|
@@ -8466,14 +8291,14 @@ function ColHeader3({
|
|
|
8466
8291
|
)
|
|
8467
8292
|
}
|
|
8468
8293
|
),
|
|
8469
|
-
tooltip && /* @__PURE__ */
|
|
8294
|
+
tooltip && /* @__PURE__ */ jsx40(InfoTip, { text: tooltip })
|
|
8470
8295
|
] });
|
|
8471
8296
|
}
|
|
8472
8297
|
|
|
8473
8298
|
// src/components/report-detail/ModelSelector.tsx
|
|
8474
8299
|
import { useCallback as useCallback23 } from "react";
|
|
8475
|
-
import { Flex as
|
|
8476
|
-
import { jsx as
|
|
8300
|
+
import { Flex as Flex22, Text as Text30 } from "@sanity/ui";
|
|
8301
|
+
import { jsx as jsx41, jsxs as jsxs29 } from "react/jsx-runtime";
|
|
8477
8302
|
var pillBase = {
|
|
8478
8303
|
borderColor: "var(--card-border-color)",
|
|
8479
8304
|
borderRadius: 999,
|
|
@@ -8504,8 +8329,8 @@ function ModelSelector({
|
|
|
8504
8329
|
selection,
|
|
8505
8330
|
onChange
|
|
8506
8331
|
}) {
|
|
8507
|
-
return /* @__PURE__ */
|
|
8508
|
-
/* @__PURE__ */
|
|
8332
|
+
return /* @__PURE__ */ jsxs29(Flex22, { align: "center", gap: 1, wrap: "wrap", children: [
|
|
8333
|
+
/* @__PURE__ */ jsx41(
|
|
8509
8334
|
Pill2,
|
|
8510
8335
|
{
|
|
8511
8336
|
isSelected: selection === null,
|
|
@@ -8513,7 +8338,7 @@ function ModelSelector({
|
|
|
8513
8338
|
onClick: () => onChange(null)
|
|
8514
8339
|
}
|
|
8515
8340
|
),
|
|
8516
|
-
models.map((model) => /* @__PURE__ */
|
|
8341
|
+
models.map((model) => /* @__PURE__ */ jsx41(
|
|
8517
8342
|
Pill2,
|
|
8518
8343
|
{
|
|
8519
8344
|
isSelected: selection === model.modelId,
|
|
@@ -8522,7 +8347,7 @@ function ModelSelector({
|
|
|
8522
8347
|
},
|
|
8523
8348
|
model.modelId
|
|
8524
8349
|
)),
|
|
8525
|
-
/* @__PURE__ */
|
|
8350
|
+
/* @__PURE__ */ jsx41(
|
|
8526
8351
|
"div",
|
|
8527
8352
|
{
|
|
8528
8353
|
style: {
|
|
@@ -8533,7 +8358,7 @@ function ModelSelector({
|
|
|
8533
8358
|
}
|
|
8534
8359
|
}
|
|
8535
8360
|
),
|
|
8536
|
-
/* @__PURE__ */
|
|
8361
|
+
/* @__PURE__ */ jsx41(
|
|
8537
8362
|
Pill2,
|
|
8538
8363
|
{
|
|
8539
8364
|
isSelected: selection === "expanded",
|
|
@@ -8557,7 +8382,7 @@ function Pill2({
|
|
|
8557
8382
|
},
|
|
8558
8383
|
[onClick]
|
|
8559
8384
|
);
|
|
8560
|
-
return /* @__PURE__ */
|
|
8385
|
+
return /* @__PURE__ */ jsx41(
|
|
8561
8386
|
"span",
|
|
8562
8387
|
{
|
|
8563
8388
|
onClick,
|
|
@@ -8565,8 +8390,8 @@ function Pill2({
|
|
|
8565
8390
|
role: "button",
|
|
8566
8391
|
style: isSelected ? pillSelected : pillDefault,
|
|
8567
8392
|
tabIndex: 0,
|
|
8568
|
-
children: /* @__PURE__ */
|
|
8569
|
-
|
|
8393
|
+
children: /* @__PURE__ */ jsx41(
|
|
8394
|
+
Text30,
|
|
8570
8395
|
{
|
|
8571
8396
|
size: 1,
|
|
8572
8397
|
style: {
|
|
@@ -8609,7 +8434,7 @@ function useModelSelection({
|
|
|
8609
8434
|
}
|
|
8610
8435
|
|
|
8611
8436
|
// src/components/report-detail/StrengthsList.tsx
|
|
8612
|
-
import { jsx as
|
|
8437
|
+
import { jsx as jsx42, jsxs as jsxs30 } from "react/jsx-runtime";
|
|
8613
8438
|
function StrengthsList({
|
|
8614
8439
|
mode,
|
|
8615
8440
|
scores,
|
|
@@ -8633,13 +8458,13 @@ function StrengthsList({
|
|
|
8633
8458
|
(a, b) => (b.infrastructureEfficiency ?? 0) - (a.infrastructureEfficiency ?? 0)
|
|
8634
8459
|
);
|
|
8635
8460
|
if (displayedScores.length === 0) return null;
|
|
8636
|
-
return /* @__PURE__ */
|
|
8637
|
-
/* @__PURE__ */
|
|
8638
|
-
/* @__PURE__ */
|
|
8639
|
-
/* @__PURE__ */
|
|
8640
|
-
/* @__PURE__ */
|
|
8641
|
-
/* @__PURE__ */
|
|
8642
|
-
hasModels && /* @__PURE__ */
|
|
8461
|
+
return /* @__PURE__ */ jsxs30(Stack25, { space: 5, children: [
|
|
8462
|
+
/* @__PURE__ */ jsxs30(Stack25, { space: 3, children: [
|
|
8463
|
+
/* @__PURE__ */ jsxs30(Flex23, { align: "center", gap: 2, wrap: "wrap", children: [
|
|
8464
|
+
/* @__PURE__ */ jsx42(CheckmarkCircleIcon2, { style: { color: "#34d399" } }),
|
|
8465
|
+
/* @__PURE__ */ jsx42(Text31, { size: 2, weight: "medium", children: "Strong Areas (70+)" }),
|
|
8466
|
+
/* @__PURE__ */ jsx42(InfoTip, { text: GLOSSARY.strengths }),
|
|
8467
|
+
hasModels && /* @__PURE__ */ jsx42(Box19, { style: { marginLeft: "auto" }, children: /* @__PURE__ */ jsx42(
|
|
8643
8468
|
ModelSelector,
|
|
8644
8469
|
{
|
|
8645
8470
|
models: perModel,
|
|
@@ -8648,7 +8473,7 @@ function StrengthsList({
|
|
|
8648
8473
|
}
|
|
8649
8474
|
) })
|
|
8650
8475
|
] }),
|
|
8651
|
-
/* @__PURE__ */
|
|
8476
|
+
/* @__PURE__ */ jsx42(
|
|
8652
8477
|
AreaScoresGrid,
|
|
8653
8478
|
{
|
|
8654
8479
|
mode,
|
|
@@ -8658,33 +8483,33 @@ function StrengthsList({
|
|
|
8658
8483
|
}
|
|
8659
8484
|
)
|
|
8660
8485
|
] }),
|
|
8661
|
-
retrievalSuccesses.length > 0 && /* @__PURE__ */
|
|
8662
|
-
/* @__PURE__ */
|
|
8663
|
-
|
|
8486
|
+
retrievalSuccesses.length > 0 && /* @__PURE__ */ jsxs30(Box19, { style: neutralCardStyle, children: [
|
|
8487
|
+
/* @__PURE__ */ jsx42(
|
|
8488
|
+
Box19,
|
|
8664
8489
|
{
|
|
8665
8490
|
padding: 4,
|
|
8666
8491
|
style: { borderBottom: "1px solid var(--card-border-color)" },
|
|
8667
|
-
children: /* @__PURE__ */
|
|
8668
|
-
/* @__PURE__ */
|
|
8669
|
-
/* @__PURE__ */
|
|
8492
|
+
children: /* @__PURE__ */ jsxs30(Flex23, { align: "center", gap: 2, children: [
|
|
8493
|
+
/* @__PURE__ */ jsx42(SearchIcon6, { style: { color: "#34d399" } }),
|
|
8494
|
+
/* @__PURE__ */ jsxs30(Text31, { size: 2, weight: "medium", children: [
|
|
8670
8495
|
"Retrieval Successes (",
|
|
8671
8496
|
Math.round(EFFICIENCY_POSITIVE * 100),
|
|
8672
8497
|
"%+ efficiency)"
|
|
8673
8498
|
] }),
|
|
8674
|
-
/* @__PURE__ */
|
|
8499
|
+
/* @__PURE__ */ jsx42(InfoTip, { text: GLOSSARY.retrievalExcellence })
|
|
8675
8500
|
] })
|
|
8676
8501
|
}
|
|
8677
8502
|
),
|
|
8678
|
-
/* @__PURE__ */
|
|
8679
|
-
|
|
8503
|
+
/* @__PURE__ */ jsx42(Stack25, { children: retrievalSuccesses.map((area, i) => /* @__PURE__ */ jsxs30(
|
|
8504
|
+
Flex23,
|
|
8680
8505
|
{
|
|
8681
8506
|
align: "center",
|
|
8682
8507
|
justify: "space-between",
|
|
8683
8508
|
padding: 4,
|
|
8684
8509
|
style: i > 0 ? dividerStyle : void 0,
|
|
8685
8510
|
children: [
|
|
8686
|
-
/* @__PURE__ */
|
|
8687
|
-
/* @__PURE__ */
|
|
8511
|
+
/* @__PURE__ */ jsx42(Text31, { size: 2, children: area.feature }),
|
|
8512
|
+
/* @__PURE__ */ jsx42(
|
|
8688
8513
|
"span",
|
|
8689
8514
|
{
|
|
8690
8515
|
style: {
|
|
@@ -8711,11 +8536,11 @@ import {
|
|
|
8711
8536
|
ErrorOutlineIcon as ErrorOutlineIcon3,
|
|
8712
8537
|
SearchIcon as SearchIcon7,
|
|
8713
8538
|
WarningOutlineIcon as WarningOutlineIcon3,
|
|
8714
|
-
BoltIcon
|
|
8539
|
+
BoltIcon,
|
|
8715
8540
|
ArrowDownIcon as ArrowDownIcon2
|
|
8716
8541
|
} from "@sanity/icons";
|
|
8717
|
-
import { Box as
|
|
8718
|
-
import { jsx as
|
|
8542
|
+
import { Box as Box20, Flex as Flex24, Stack as Stack26, Text as Text32 } from "@sanity/ui";
|
|
8543
|
+
import { jsx as jsx43, jsxs as jsxs31 } from "react/jsx-runtime";
|
|
8719
8544
|
function WeaknessesList({
|
|
8720
8545
|
mode,
|
|
8721
8546
|
scores,
|
|
@@ -8745,13 +8570,13 @@ function WeaknessesList({
|
|
|
8745
8570
|
);
|
|
8746
8571
|
const hasContent = weakAreas.length > 0 || docsHurt.length > 0 || retrievalIssues.length > 0 || dimWeaknesses.length > 0 || regressed.length > 0 || efficiencyAnomalies.length > 0;
|
|
8747
8572
|
if (!hasContent) return null;
|
|
8748
|
-
return /* @__PURE__ */
|
|
8749
|
-
weakAreas.length > 0 && /* @__PURE__ */
|
|
8750
|
-
/* @__PURE__ */
|
|
8751
|
-
/* @__PURE__ */
|
|
8752
|
-
/* @__PURE__ */
|
|
8753
|
-
/* @__PURE__ */
|
|
8754
|
-
hasModels && /* @__PURE__ */
|
|
8573
|
+
return /* @__PURE__ */ jsxs31(Stack26, { space: 5, children: [
|
|
8574
|
+
weakAreas.length > 0 && /* @__PURE__ */ jsxs31(Stack26, { space: 3, children: [
|
|
8575
|
+
/* @__PURE__ */ jsxs31(Flex24, { align: "center", gap: 2, wrap: "wrap", children: [
|
|
8576
|
+
/* @__PURE__ */ jsx43(ErrorOutlineIcon3, { style: { color: "#f87171" } }),
|
|
8577
|
+
/* @__PURE__ */ jsx43(Text32, { size: 2, weight: "medium", children: "Weak Areas (<70)" }),
|
|
8578
|
+
/* @__PURE__ */ jsx43(InfoTip, { text: GLOSSARY.weakAreas }),
|
|
8579
|
+
hasModels && /* @__PURE__ */ jsx43(Box20, { style: { marginLeft: "auto" }, children: /* @__PURE__ */ jsx43(
|
|
8755
8580
|
ModelSelector,
|
|
8756
8581
|
{
|
|
8757
8582
|
models: perModel,
|
|
@@ -8760,7 +8585,7 @@ function WeaknessesList({
|
|
|
8760
8585
|
}
|
|
8761
8586
|
) })
|
|
8762
8587
|
] }),
|
|
8763
|
-
/* @__PURE__ */
|
|
8588
|
+
/* @__PURE__ */ jsx43(
|
|
8764
8589
|
AreaScoresGrid,
|
|
8765
8590
|
{
|
|
8766
8591
|
mode,
|
|
@@ -8770,22 +8595,22 @@ function WeaknessesList({
|
|
|
8770
8595
|
}
|
|
8771
8596
|
)
|
|
8772
8597
|
] }),
|
|
8773
|
-
docsHurt.length > 0 && /* @__PURE__ */
|
|
8774
|
-
/* @__PURE__ */
|
|
8775
|
-
/* @__PURE__ */
|
|
8776
|
-
/* @__PURE__ */
|
|
8777
|
-
/* @__PURE__ */
|
|
8598
|
+
docsHurt.length > 0 && /* @__PURE__ */ jsxs31(Stack26, { space: 3, children: [
|
|
8599
|
+
/* @__PURE__ */ jsxs31(Flex24, { align: "center", gap: 2, children: [
|
|
8600
|
+
/* @__PURE__ */ jsx43(ErrorOutlineIcon3, { style: { color: "#f87171" } }),
|
|
8601
|
+
/* @__PURE__ */ jsx43(Text32, { size: 2, weight: "medium", children: "Docs Hurt Performance (Negative Doc Lift)" }),
|
|
8602
|
+
/* @__PURE__ */ jsx43(InfoTip, { text: GLOSSARY.docsHurt })
|
|
8778
8603
|
] }),
|
|
8779
|
-
/* @__PURE__ */
|
|
8780
|
-
|
|
8604
|
+
/* @__PURE__ */ jsx43(Box20, { style: sectionStyle("red"), children: docsHurt.map((area, i) => /* @__PURE__ */ jsxs31(
|
|
8605
|
+
Box20,
|
|
8781
8606
|
{
|
|
8782
8607
|
padding: 4,
|
|
8783
8608
|
style: i > 0 ? { borderTop: "1px solid rgba(239,68,68,0.2)" } : void 0,
|
|
8784
8609
|
children: [
|
|
8785
|
-
/* @__PURE__ */
|
|
8786
|
-
/* @__PURE__ */
|
|
8787
|
-
/* @__PURE__ */
|
|
8788
|
-
/* @__PURE__ */
|
|
8610
|
+
/* @__PURE__ */ jsxs31(Flex24, { align: "center", justify: "space-between", wrap: "wrap", children: [
|
|
8611
|
+
/* @__PURE__ */ jsxs31(Flex24, { align: "center", gap: 2, children: [
|
|
8612
|
+
/* @__PURE__ */ jsx43(Text32, { size: 2, weight: "medium", children: area.feature }),
|
|
8613
|
+
/* @__PURE__ */ jsx43(
|
|
8789
8614
|
"span",
|
|
8790
8615
|
{
|
|
8791
8616
|
style: {
|
|
@@ -8800,7 +8625,7 @@ function WeaknessesList({
|
|
|
8800
8625
|
}
|
|
8801
8626
|
)
|
|
8802
8627
|
] }),
|
|
8803
|
-
/* @__PURE__ */
|
|
8628
|
+
/* @__PURE__ */ jsx43(
|
|
8804
8629
|
"span",
|
|
8805
8630
|
{
|
|
8806
8631
|
style: {
|
|
@@ -8813,8 +8638,8 @@ function WeaknessesList({
|
|
|
8813
8638
|
}
|
|
8814
8639
|
)
|
|
8815
8640
|
] }),
|
|
8816
|
-
/* @__PURE__ */
|
|
8817
|
-
area.invertedRetrievalGap && /* @__PURE__ */
|
|
8641
|
+
/* @__PURE__ */ jsx43(Box20, { paddingTop: 2, children: /* @__PURE__ */ jsxs31(Text32, { muted: true, size: 2, children: [
|
|
8642
|
+
area.invertedRetrievalGap && /* @__PURE__ */ jsxs31("span", { style: { color: "#fbbf24" }, children: [
|
|
8818
8643
|
"Agent does better by NOT finding these docs.",
|
|
8819
8644
|
" "
|
|
8820
8645
|
] }),
|
|
@@ -8829,22 +8654,22 @@ function WeaknessesList({
|
|
|
8829
8654
|
area.feature
|
|
8830
8655
|
)) })
|
|
8831
8656
|
] }),
|
|
8832
|
-
retrievalIssues.length > 0 && /* @__PURE__ */
|
|
8833
|
-
/* @__PURE__ */
|
|
8834
|
-
/* @__PURE__ */
|
|
8835
|
-
/* @__PURE__ */
|
|
8836
|
-
/* @__PURE__ */
|
|
8657
|
+
retrievalIssues.length > 0 && /* @__PURE__ */ jsxs31(Stack26, { space: 3, children: [
|
|
8658
|
+
/* @__PURE__ */ jsxs31(Flex24, { align: "center", gap: 2, children: [
|
|
8659
|
+
/* @__PURE__ */ jsx43(SearchIcon7, { style: { color: "#fbbf24" } }),
|
|
8660
|
+
/* @__PURE__ */ jsx43(Text32, { size: 2, weight: "medium", children: "Retrieval Issues (<70% efficiency)" }),
|
|
8661
|
+
/* @__PURE__ */ jsx43(InfoTip, { text: GLOSSARY.retrievalIssues })
|
|
8837
8662
|
] }),
|
|
8838
|
-
/* @__PURE__ */
|
|
8839
|
-
|
|
8663
|
+
/* @__PURE__ */ jsx43(Box20, { style: sectionStyle("amber"), children: retrievalIssues.map((area, i) => /* @__PURE__ */ jsxs31(
|
|
8664
|
+
Box20,
|
|
8840
8665
|
{
|
|
8841
8666
|
padding: 4,
|
|
8842
8667
|
style: i > 0 ? { borderTop: "1px solid rgba(245,158,11,0.2)" } : void 0,
|
|
8843
8668
|
children: [
|
|
8844
|
-
/* @__PURE__ */
|
|
8845
|
-
/* @__PURE__ */
|
|
8846
|
-
/* @__PURE__ */
|
|
8847
|
-
/* @__PURE__ */
|
|
8669
|
+
/* @__PURE__ */ jsxs31(Flex24, { align: "center", justify: "space-between", wrap: "wrap", children: [
|
|
8670
|
+
/* @__PURE__ */ jsxs31(Flex24, { align: "center", gap: 2, children: [
|
|
8671
|
+
/* @__PURE__ */ jsx43(Text32, { size: 2, weight: "medium", children: area.feature }),
|
|
8672
|
+
/* @__PURE__ */ jsx43(
|
|
8848
8673
|
"span",
|
|
8849
8674
|
{
|
|
8850
8675
|
style: {
|
|
@@ -8859,7 +8684,7 @@ function WeaknessesList({
|
|
|
8859
8684
|
}
|
|
8860
8685
|
)
|
|
8861
8686
|
] }),
|
|
8862
|
-
/* @__PURE__ */
|
|
8687
|
+
/* @__PURE__ */ jsx43(
|
|
8863
8688
|
"span",
|
|
8864
8689
|
{
|
|
8865
8690
|
style: {
|
|
@@ -8872,7 +8697,7 @@ function WeaknessesList({
|
|
|
8872
8697
|
}
|
|
8873
8698
|
)
|
|
8874
8699
|
] }),
|
|
8875
|
-
/* @__PURE__ */
|
|
8700
|
+
/* @__PURE__ */ jsx43(Box20, { paddingTop: 2, children: /* @__PURE__ */ jsxs31(Text32, { muted: true, size: 2, children: [
|
|
8876
8701
|
"Actual score (",
|
|
8877
8702
|
Math.round(area.actualScore ?? 0),
|
|
8878
8703
|
") is much lower than ceiling (",
|
|
@@ -8887,21 +8712,21 @@ function WeaknessesList({
|
|
|
8887
8712
|
area.feature
|
|
8888
8713
|
)) })
|
|
8889
8714
|
] }),
|
|
8890
|
-
dimWeaknesses.length > 0 && /* @__PURE__ */
|
|
8891
|
-
/* @__PURE__ */
|
|
8892
|
-
/* @__PURE__ */
|
|
8893
|
-
/* @__PURE__ */
|
|
8894
|
-
/* @__PURE__ */
|
|
8715
|
+
dimWeaknesses.length > 0 && /* @__PURE__ */ jsxs31(Stack26, { space: 3, children: [
|
|
8716
|
+
/* @__PURE__ */ jsxs31(Flex24, { align: "center", gap: 2, children: [
|
|
8717
|
+
/* @__PURE__ */ jsx43(WarningOutlineIcon3, { style: { color: "#fbbf24" } }),
|
|
8718
|
+
/* @__PURE__ */ jsx43(Text32, { size: 2, weight: "medium", children: "Dimension Weaknesses (<50)" }),
|
|
8719
|
+
/* @__PURE__ */ jsx43(InfoTip, { text: GLOSSARY.dimWeaknesses })
|
|
8895
8720
|
] }),
|
|
8896
|
-
/* @__PURE__ */
|
|
8897
|
-
|
|
8721
|
+
/* @__PURE__ */ jsx43(Box20, { style: neutralCardStyle, children: dimWeaknesses.map(({ area, dims }, i) => /* @__PURE__ */ jsxs31(
|
|
8722
|
+
Box20,
|
|
8898
8723
|
{
|
|
8899
8724
|
padding: 4,
|
|
8900
8725
|
style: i > 0 ? dividerStyle : void 0,
|
|
8901
8726
|
children: [
|
|
8902
|
-
/* @__PURE__ */
|
|
8903
|
-
/* @__PURE__ */
|
|
8904
|
-
/* @__PURE__ */
|
|
8727
|
+
/* @__PURE__ */ jsxs31(Flex24, { align: "center", gap: 2, paddingBottom: 2, children: [
|
|
8728
|
+
/* @__PURE__ */ jsx43(Text32, { size: 2, weight: "medium", children: area.feature }),
|
|
8729
|
+
/* @__PURE__ */ jsx43(
|
|
8905
8730
|
"span",
|
|
8906
8731
|
{
|
|
8907
8732
|
style: {
|
|
@@ -8916,7 +8741,7 @@ function WeaknessesList({
|
|
|
8916
8741
|
}
|
|
8917
8742
|
)
|
|
8918
8743
|
] }),
|
|
8919
|
-
/* @__PURE__ */
|
|
8744
|
+
/* @__PURE__ */ jsx43(Flex24, { gap: 2, wrap: "wrap", children: dims.map((w) => /* @__PURE__ */ jsx43(HoverTip, { text: w.tip, children: /* @__PURE__ */ jsxs31(
|
|
8920
8745
|
"span",
|
|
8921
8746
|
{
|
|
8922
8747
|
style: {
|
|
@@ -8938,33 +8763,33 @@ function WeaknessesList({
|
|
|
8938
8763
|
area.feature
|
|
8939
8764
|
)) })
|
|
8940
8765
|
] }),
|
|
8941
|
-
regressed.length > 0 && /* @__PURE__ */
|
|
8942
|
-
/* @__PURE__ */
|
|
8943
|
-
|
|
8766
|
+
regressed.length > 0 && /* @__PURE__ */ jsxs31(Box20, { style: neutralCardStyle, children: [
|
|
8767
|
+
/* @__PURE__ */ jsx43(
|
|
8768
|
+
Box20,
|
|
8944
8769
|
{
|
|
8945
8770
|
padding: 4,
|
|
8946
8771
|
style: { borderBottom: "1px solid var(--card-border-color)" },
|
|
8947
|
-
children: /* @__PURE__ */
|
|
8948
|
-
/* @__PURE__ */
|
|
8949
|
-
/* @__PURE__ */
|
|
8772
|
+
children: /* @__PURE__ */ jsxs31(Flex24, { align: "center", gap: 2, children: [
|
|
8773
|
+
/* @__PURE__ */ jsx43(ArrowDownIcon2, { style: { color: "#f87171" } }),
|
|
8774
|
+
/* @__PURE__ */ jsx43(Text32, { size: 2, weight: "medium", children: "Regressed Since Last Run" })
|
|
8950
8775
|
] })
|
|
8951
8776
|
}
|
|
8952
8777
|
),
|
|
8953
|
-
/* @__PURE__ */
|
|
8778
|
+
/* @__PURE__ */ jsx43(Stack26, { children: regressed.map((featureName, i) => {
|
|
8954
8779
|
const area = scores.find((s) => s.feature === featureName);
|
|
8955
8780
|
const areaDelta = perArea?.[featureName];
|
|
8956
|
-
return /* @__PURE__ */
|
|
8957
|
-
|
|
8781
|
+
return /* @__PURE__ */ jsxs31(
|
|
8782
|
+
Flex24,
|
|
8958
8783
|
{
|
|
8959
8784
|
align: "center",
|
|
8960
8785
|
justify: "space-between",
|
|
8961
8786
|
padding: 4,
|
|
8962
8787
|
style: i > 0 ? dividerStyle : void 0,
|
|
8963
8788
|
children: [
|
|
8964
|
-
/* @__PURE__ */
|
|
8965
|
-
/* @__PURE__ */
|
|
8966
|
-
areaDelta != null && /* @__PURE__ */
|
|
8967
|
-
area && /* @__PURE__ */
|
|
8789
|
+
/* @__PURE__ */ jsx43(Text32, { size: 2, children: featureName }),
|
|
8790
|
+
/* @__PURE__ */ jsxs31(Flex24, { align: "center", gap: 3, children: [
|
|
8791
|
+
areaDelta != null && /* @__PURE__ */ jsx43(DeltaIndicator, { delta: areaDelta, icon: true }),
|
|
8792
|
+
area && /* @__PURE__ */ jsx43(
|
|
8968
8793
|
"span",
|
|
8969
8794
|
{
|
|
8970
8795
|
style: {
|
|
@@ -8986,32 +8811,32 @@ function WeaknessesList({
|
|
|
8986
8811
|
);
|
|
8987
8812
|
}) })
|
|
8988
8813
|
] }),
|
|
8989
|
-
efficiencyAnomalies.length > 0 && /* @__PURE__ */
|
|
8990
|
-
/* @__PURE__ */
|
|
8991
|
-
|
|
8814
|
+
efficiencyAnomalies.length > 0 && /* @__PURE__ */ jsxs31(Box20, { style: neutralCardStyle, children: [
|
|
8815
|
+
/* @__PURE__ */ jsx43(
|
|
8816
|
+
Box20,
|
|
8992
8817
|
{
|
|
8993
8818
|
padding: 4,
|
|
8994
8819
|
style: { borderBottom: "1px solid var(--card-border-color)" },
|
|
8995
|
-
children: /* @__PURE__ */
|
|
8996
|
-
/* @__PURE__ */
|
|
8997
|
-
/* @__PURE__ */
|
|
8998
|
-
/* @__PURE__ */
|
|
8999
|
-
/* @__PURE__ */
|
|
8820
|
+
children: /* @__PURE__ */ jsxs31(Stack26, { space: 2, children: [
|
|
8821
|
+
/* @__PURE__ */ jsxs31(Flex24, { align: "center", gap: 2, children: [
|
|
8822
|
+
/* @__PURE__ */ jsx43(BoltIcon, { style: { color: "#fbbf24" } }),
|
|
8823
|
+
/* @__PURE__ */ jsx43(Text32, { size: 2, weight: "medium", children: "Efficiency Anomalies (>100%)" }),
|
|
8824
|
+
/* @__PURE__ */ jsx43(InfoTip, { text: GLOSSARY.efficiencyAnomalies })
|
|
9000
8825
|
] }),
|
|
9001
|
-
/* @__PURE__ */
|
|
8826
|
+
/* @__PURE__ */ jsx43(Text32, { muted: true, size: 2, children: "Agent outperforms injected docs \u2014 may indicate doc quality issues or agent memorization." })
|
|
9002
8827
|
] })
|
|
9003
8828
|
}
|
|
9004
8829
|
),
|
|
9005
|
-
/* @__PURE__ */
|
|
9006
|
-
|
|
8830
|
+
/* @__PURE__ */ jsx43(Stack26, { children: efficiencyAnomalies.map((area, i) => /* @__PURE__ */ jsxs31(
|
|
8831
|
+
Flex24,
|
|
9007
8832
|
{
|
|
9008
8833
|
align: "center",
|
|
9009
8834
|
justify: "space-between",
|
|
9010
8835
|
padding: 4,
|
|
9011
8836
|
style: i > 0 ? dividerStyle : void 0,
|
|
9012
8837
|
children: [
|
|
9013
|
-
/* @__PURE__ */
|
|
9014
|
-
/* @__PURE__ */
|
|
8838
|
+
/* @__PURE__ */ jsx43(Text32, { size: 2, children: area.feature }),
|
|
8839
|
+
/* @__PURE__ */ jsx43(
|
|
9015
8840
|
"span",
|
|
9016
8841
|
{
|
|
9017
8842
|
style: {
|
|
@@ -9039,12 +8864,12 @@ var tipArea = {
|
|
|
9039
8864
|
fontWeight: 600
|
|
9040
8865
|
};
|
|
9041
8866
|
function dimTip(area, dim, score, description) {
|
|
9042
|
-
return /* @__PURE__ */
|
|
9043
|
-
/* @__PURE__ */
|
|
8867
|
+
return /* @__PURE__ */ jsxs31(Text32, { size: 2, style: { lineHeight: 1.5 }, children: [
|
|
8868
|
+
/* @__PURE__ */ jsx43("span", { style: tipArea, children: area }),
|
|
9044
8869
|
" scores",
|
|
9045
8870
|
" ",
|
|
9046
|
-
/* @__PURE__ */
|
|
9047
|
-
/* @__PURE__ */
|
|
8871
|
+
/* @__PURE__ */ jsx43("span", { style: tipValue, children: score }),
|
|
8872
|
+
/* @__PURE__ */ jsx43("span", { style: { color: "var(--card-muted-fg-color)" }, children: "/100" }),
|
|
9048
8873
|
" on",
|
|
9049
8874
|
" ",
|
|
9050
8875
|
dim.toLowerCase(),
|
|
@@ -9073,7 +8898,7 @@ function getDimensionWeaknesses(area) {
|
|
|
9073
8898
|
}
|
|
9074
8899
|
|
|
9075
8900
|
// src/components/report-detail/ReportDetail.tsx
|
|
9076
|
-
import { jsx as
|
|
8901
|
+
import { jsx as jsx44, jsxs as jsxs32 } from "react/jsx-runtime";
|
|
9077
8902
|
var OVERVIEW_TAB = { id: "overview", label: "Overview" };
|
|
9078
8903
|
var DIAGNOSTICS_TAB = { id: "diagnostics", label: "Diagnostics" };
|
|
9079
8904
|
var ACTIVITY_TAB = { id: "activity", label: "Agent Activity" };
|
|
@@ -9109,7 +8934,7 @@ function ReportDetail({
|
|
|
9109
8934
|
}, [client, reportId]);
|
|
9110
8935
|
const { summary } = report ?? {};
|
|
9111
8936
|
const hasWeaknesses = Boolean(
|
|
9112
|
-
summary?.
|
|
8937
|
+
summary?.lowScoringJudgments && summary.lowScoringJudgments.length > 0
|
|
9113
8938
|
);
|
|
9114
8939
|
const hasDiagnostics = Boolean(
|
|
9115
8940
|
summary?.scores && summary.scores.length > 0 || hasWeaknesses
|
|
@@ -9139,11 +8964,11 @@ function ReportDetail({
|
|
|
9139
8964
|
[onTabChange]
|
|
9140
8965
|
);
|
|
9141
8966
|
if (loading) {
|
|
9142
|
-
return /* @__PURE__ */
|
|
8967
|
+
return /* @__PURE__ */ jsx44(LoadingState, { message: "Loading report\u2026" });
|
|
9143
8968
|
}
|
|
9144
8969
|
if (!report || !summary) {
|
|
9145
|
-
return /* @__PURE__ */
|
|
9146
|
-
/* @__PURE__ */
|
|
8970
|
+
return /* @__PURE__ */ jsx44(Box21, { padding: 5, children: /* @__PURE__ */ jsxs32(Stack27, { space: 4, children: [
|
|
8971
|
+
/* @__PURE__ */ jsx44(
|
|
9147
8972
|
Button8,
|
|
9148
8973
|
{
|
|
9149
8974
|
icon: ArrowLeftIcon3,
|
|
@@ -9152,13 +8977,13 @@ function ReportDetail({
|
|
|
9152
8977
|
text: "Back"
|
|
9153
8978
|
}
|
|
9154
8979
|
),
|
|
9155
|
-
/* @__PURE__ */
|
|
8980
|
+
/* @__PURE__ */ jsx44(Text33, { align: "center", muted: true, size: 3, children: "Report not found" })
|
|
9156
8981
|
] }) });
|
|
9157
8982
|
}
|
|
9158
8983
|
const { comparison, provenance } = report;
|
|
9159
8984
|
const totalTests = summary.scores.reduce((n, s) => n + s.testCount, 0);
|
|
9160
|
-
return /* @__PURE__ */
|
|
9161
|
-
/* @__PURE__ */
|
|
8985
|
+
return /* @__PURE__ */ jsx44(Box21, { padding: 4, children: /* @__PURE__ */ jsxs32(Stack27, { space: 5, children: [
|
|
8986
|
+
/* @__PURE__ */ jsx44(
|
|
9162
8987
|
ReportHeader,
|
|
9163
8988
|
{
|
|
9164
8989
|
completedAt: report.completedAt,
|
|
@@ -9167,11 +8992,11 @@ function ReportDetail({
|
|
|
9167
8992
|
title: report.title
|
|
9168
8993
|
}
|
|
9169
8994
|
),
|
|
9170
|
-
/* @__PURE__ */
|
|
9171
|
-
/* @__PURE__ */
|
|
8995
|
+
/* @__PURE__ */ jsxs32(Flex25, { align: "center", gap: 2, wrap: "wrap", children: [
|
|
8996
|
+
/* @__PURE__ */ jsx44(TabList, { space: 1, children: tabs.map((tab) => {
|
|
9172
8997
|
const isDisabled = disabledTabs.has(tab.id);
|
|
9173
8998
|
const tooltip = getDisabledTabTooltip(tab.id, summary);
|
|
9174
|
-
const tabElement = /* @__PURE__ */
|
|
8999
|
+
const tabElement = /* @__PURE__ */ jsx44(
|
|
9175
9000
|
Tab,
|
|
9176
9001
|
{
|
|
9177
9002
|
"aria-controls": `panel-${tab.id}`,
|
|
@@ -9182,27 +9007,27 @@ function ReportDetail({
|
|
|
9182
9007
|
selected: currentTab === tab.id
|
|
9183
9008
|
}
|
|
9184
9009
|
);
|
|
9185
|
-
return isDisabled && tooltip ? /* @__PURE__ */
|
|
9010
|
+
return isDisabled && tooltip ? /* @__PURE__ */ jsx44(
|
|
9186
9011
|
Tooltip8,
|
|
9187
9012
|
{
|
|
9188
|
-
content: /* @__PURE__ */
|
|
9013
|
+
content: /* @__PURE__ */ jsx44(Box21, { padding: 2, style: { maxWidth: 280 }, children: tooltip }),
|
|
9189
9014
|
placement: "bottom",
|
|
9190
9015
|
portal: true,
|
|
9191
|
-
children: /* @__PURE__ */
|
|
9016
|
+
children: /* @__PURE__ */ jsx44("span", { style: { display: "inline-block" }, children: tabElement })
|
|
9192
9017
|
},
|
|
9193
9018
|
tab.id
|
|
9194
|
-
) : /* @__PURE__ */
|
|
9019
|
+
) : /* @__PURE__ */ jsx44("span", { children: tabElement }, tab.id);
|
|
9195
9020
|
}) }),
|
|
9196
|
-
/* @__PURE__ */
|
|
9197
|
-
/* @__PURE__ */
|
|
9021
|
+
/* @__PURE__ */ jsxs32(Flex25, { align: "center", gap: 2, style: { marginLeft: "auto" }, children: [
|
|
9022
|
+
/* @__PURE__ */ jsx44(
|
|
9198
9023
|
HoverTip,
|
|
9199
9024
|
{
|
|
9200
9025
|
text: SOURCE_TIP[provenance.source.name] ?? GLOSSARY.reportMode,
|
|
9201
|
-
children: /* @__PURE__ */
|
|
9026
|
+
children: /* @__PURE__ */ jsx44(Badge7, { mode: "outline", tone: "default", children: provenance.source.name })
|
|
9202
9027
|
}
|
|
9203
9028
|
),
|
|
9204
|
-
/* @__PURE__ */
|
|
9205
|
-
/* @__PURE__ */
|
|
9029
|
+
/* @__PURE__ */ jsx44(HoverTip, { text: MODE_TIP2[provenance.mode] ?? GLOSSARY.reportMode, children: /* @__PURE__ */ jsx44(Badge7, { tone: "primary", children: provenance.mode }) }),
|
|
9030
|
+
/* @__PURE__ */ jsx44(
|
|
9206
9031
|
ReportActions,
|
|
9207
9032
|
{
|
|
9208
9033
|
documentId: report._id,
|
|
@@ -9213,14 +9038,14 @@ function ReportDetail({
|
|
|
9213
9038
|
)
|
|
9214
9039
|
] })
|
|
9215
9040
|
] }),
|
|
9216
|
-
currentTab === "overview" && /* @__PURE__ */
|
|
9041
|
+
currentTab === "overview" && /* @__PURE__ */ jsx44(
|
|
9217
9042
|
TabPanel,
|
|
9218
9043
|
{
|
|
9219
9044
|
"aria-labelledby": "tab-overview",
|
|
9220
9045
|
hidden: currentTab !== "overview",
|
|
9221
9046
|
id: "panel-overview",
|
|
9222
|
-
children: /* @__PURE__ */
|
|
9223
|
-
/* @__PURE__ */
|
|
9047
|
+
children: /* @__PURE__ */ jsxs32(Stack27, { space: 5, children: [
|
|
9048
|
+
/* @__PURE__ */ jsx44(
|
|
9224
9049
|
DiagnosticsOverview,
|
|
9225
9050
|
{
|
|
9226
9051
|
comparison,
|
|
@@ -9231,12 +9056,12 @@ function ReportDetail({
|
|
|
9231
9056
|
totalTests
|
|
9232
9057
|
}
|
|
9233
9058
|
),
|
|
9234
|
-
/* @__PURE__ */
|
|
9235
|
-
/* @__PURE__ */
|
|
9059
|
+
/* @__PURE__ */ jsx44(LineageCard, { provenance, reportId: report.reportId }),
|
|
9060
|
+
/* @__PURE__ */ jsx44(ProvenanceCard, { provenance })
|
|
9236
9061
|
] })
|
|
9237
9062
|
}
|
|
9238
9063
|
),
|
|
9239
|
-
currentTab === "diagnostics" && hasDiagnostics && /* @__PURE__ */
|
|
9064
|
+
currentTab === "diagnostics" && hasDiagnostics && /* @__PURE__ */ jsx44(
|
|
9240
9065
|
DiagnosticsPanel,
|
|
9241
9066
|
{
|
|
9242
9067
|
comparison,
|
|
@@ -9245,18 +9070,17 @@ function ReportDetail({
|
|
|
9245
9070
|
mode: provenance.mode,
|
|
9246
9071
|
onNavigate: (newSubTab, newFocus) => onTabChange("diagnostics", newSubTab, newFocus),
|
|
9247
9072
|
perModel: summary.perModel,
|
|
9248
|
-
recommendations: summary.recommendations,
|
|
9249
9073
|
scores: summary.scores,
|
|
9250
9074
|
subTab
|
|
9251
9075
|
}
|
|
9252
9076
|
),
|
|
9253
|
-
currentTab === "activity" && hasAgentActivity && /* @__PURE__ */
|
|
9077
|
+
currentTab === "activity" && hasAgentActivity && /* @__PURE__ */ jsx44(
|
|
9254
9078
|
TabPanel,
|
|
9255
9079
|
{
|
|
9256
9080
|
"aria-labelledby": "tab-activity",
|
|
9257
9081
|
hidden: currentTab !== "activity",
|
|
9258
9082
|
id: "panel-activity",
|
|
9259
|
-
children: /* @__PURE__ */
|
|
9083
|
+
children: /* @__PURE__ */ jsx44(
|
|
9260
9084
|
AgentActivitySection,
|
|
9261
9085
|
{
|
|
9262
9086
|
agentBehavior: summary.agentBehavior,
|
|
@@ -9282,7 +9106,6 @@ function DiagnosticsPanel({
|
|
|
9282
9106
|
mode,
|
|
9283
9107
|
onNavigate,
|
|
9284
9108
|
perModel,
|
|
9285
|
-
recommendations,
|
|
9286
9109
|
scores,
|
|
9287
9110
|
subTab: subTabParam
|
|
9288
9111
|
}) {
|
|
@@ -9290,9 +9113,9 @@ function DiagnosticsPanel({
|
|
|
9290
9113
|
const issueCount = scores.filter((s) => s.totalScore < SCORE_CAUTION).length + scores.filter((s) => s.negativeDocLift).length + scores.filter(
|
|
9291
9114
|
(s) => s.infrastructureEfficiency != null && s.infrastructureEfficiency < EFFICIENCY_CAUTION && !s.invertedRetrievalGap
|
|
9292
9115
|
).length;
|
|
9293
|
-
return /* @__PURE__ */
|
|
9294
|
-
/* @__PURE__ */
|
|
9295
|
-
|
|
9116
|
+
return /* @__PURE__ */ jsx44(TabPanel, { "aria-labelledby": "tab-diagnostics", id: "panel-diagnostics", children: /* @__PURE__ */ jsxs32(Stack27, { space: 4, children: [
|
|
9117
|
+
/* @__PURE__ */ jsx44(
|
|
9118
|
+
Flex25,
|
|
9296
9119
|
{
|
|
9297
9120
|
align: "center",
|
|
9298
9121
|
gap: 1,
|
|
@@ -9301,7 +9124,7 @@ function DiagnosticsPanel({
|
|
|
9301
9124
|
paddingBottom: 8
|
|
9302
9125
|
},
|
|
9303
9126
|
wrap: "wrap",
|
|
9304
|
-
children: DIAG_TABS.map((tab) => /* @__PURE__ */
|
|
9127
|
+
children: DIAG_TABS.map((tab) => /* @__PURE__ */ jsxs32(
|
|
9305
9128
|
"button",
|
|
9306
9129
|
{
|
|
9307
9130
|
onClick: () => onNavigate(tab.id === "strengths" ? null : tab.id, null),
|
|
@@ -9321,7 +9144,7 @@ function DiagnosticsPanel({
|
|
|
9321
9144
|
type: "button",
|
|
9322
9145
|
children: [
|
|
9323
9146
|
tab.label,
|
|
9324
|
-
tab.id === "issues" && issueCount > 0 && /* @__PURE__ */
|
|
9147
|
+
tab.id === "issues" && issueCount > 0 && /* @__PURE__ */ jsx44(
|
|
9325
9148
|
"span",
|
|
9326
9149
|
{
|
|
9327
9150
|
style: {
|
|
@@ -9341,7 +9164,7 @@ function DiagnosticsPanel({
|
|
|
9341
9164
|
))
|
|
9342
9165
|
}
|
|
9343
9166
|
),
|
|
9344
|
-
subTab === "strengths" && /* @__PURE__ */
|
|
9167
|
+
subTab === "strengths" && /* @__PURE__ */ jsx44(
|
|
9345
9168
|
StrengthsList,
|
|
9346
9169
|
{
|
|
9347
9170
|
comparison,
|
|
@@ -9350,8 +9173,8 @@ function DiagnosticsPanel({
|
|
|
9350
9173
|
scores
|
|
9351
9174
|
}
|
|
9352
9175
|
),
|
|
9353
|
-
subTab === "issues" && /* @__PURE__ */
|
|
9354
|
-
/* @__PURE__ */
|
|
9176
|
+
subTab === "issues" && /* @__PURE__ */ jsxs32(Stack27, { space: 5, children: [
|
|
9177
|
+
/* @__PURE__ */ jsx44(
|
|
9355
9178
|
WeaknessesList,
|
|
9356
9179
|
{
|
|
9357
9180
|
comparison,
|
|
@@ -9360,8 +9183,7 @@ function DiagnosticsPanel({
|
|
|
9360
9183
|
scores
|
|
9361
9184
|
}
|
|
9362
9185
|
),
|
|
9363
|
-
|
|
9364
|
-
judgments && judgments.length > 0 && /* @__PURE__ */ jsx45(
|
|
9186
|
+
judgments && judgments.length > 0 && /* @__PURE__ */ jsx44(
|
|
9365
9187
|
JudgmentList,
|
|
9366
9188
|
{
|
|
9367
9189
|
focus,
|
|
@@ -9395,17 +9217,17 @@ function getDisabledTabTooltip(tabId, summary) {
|
|
|
9395
9217
|
if (!summary) return null;
|
|
9396
9218
|
switch (tabId) {
|
|
9397
9219
|
case "diagnostics":
|
|
9398
|
-
return /* @__PURE__ */
|
|
9220
|
+
return /* @__PURE__ */ jsx44(Text33, { muted: true, size: 2, children: "No diagnostic data available. Diagnostics require at least one scored feature area." });
|
|
9399
9221
|
case "activity":
|
|
9400
|
-
return summary.evaluationMode === "baseline" ? /* @__PURE__ */
|
|
9222
|
+
return summary.evaluationMode === "baseline" ? /* @__PURE__ */ jsxs32(Text33, { muted: true, size: 2, children: [
|
|
9401
9223
|
"Not available for baseline-only evaluations. Run with",
|
|
9402
9224
|
" ",
|
|
9403
|
-
/* @__PURE__ */
|
|
9225
|
+
/* @__PURE__ */ jsx44("code", { style: inlineCodeStyle, children: "--mode full" }),
|
|
9404
9226
|
" or",
|
|
9405
9227
|
" ",
|
|
9406
|
-
/* @__PURE__ */
|
|
9228
|
+
/* @__PURE__ */ jsx44("code", { style: inlineCodeStyle, children: "--mode agentic" }),
|
|
9407
9229
|
" to capture agent browsing behavior."
|
|
9408
|
-
] }) : /* @__PURE__ */
|
|
9230
|
+
] }) : /* @__PURE__ */ jsx44(Text33, { muted: true, size: 2, children: "No agent activity data was recorded for this evaluation." });
|
|
9409
9231
|
default:
|
|
9410
9232
|
return null;
|
|
9411
9233
|
}
|
|
@@ -9413,12 +9235,12 @@ function getDisabledTabTooltip(tabId, summary) {
|
|
|
9413
9235
|
|
|
9414
9236
|
// src/components/report-detail/AreaScoreRow.tsx
|
|
9415
9237
|
import { WarningOutlineIcon as WarningOutlineIcon4 } from "@sanity/icons";
|
|
9416
|
-
import { Box as
|
|
9417
|
-
import { jsx as
|
|
9238
|
+
import { Box as Box22, Flex as Flex26, Stack as Stack28, Text as Text34 } from "@sanity/ui";
|
|
9239
|
+
import { jsx as jsx45, jsxs as jsxs33 } from "react/jsx-runtime";
|
|
9418
9240
|
|
|
9419
9241
|
// src/components/report-detail/AreaScoreTable.tsx
|
|
9420
9242
|
import React4 from "react";
|
|
9421
|
-
import { Card as Card17, Stack as
|
|
9243
|
+
import { Card as Card17, Stack as Stack29, Text as Text36 } from "@sanity/ui";
|
|
9422
9244
|
|
|
9423
9245
|
// src/lib/scoring.ts
|
|
9424
9246
|
var HEX_MAP = {
|
|
@@ -9435,18 +9257,23 @@ function scoreHex(score) {
|
|
|
9435
9257
|
}
|
|
9436
9258
|
|
|
9437
9259
|
// src/components/primitives/ScoreCell.tsx
|
|
9438
|
-
import { Card as Card16, Text as
|
|
9439
|
-
import { jsx as
|
|
9260
|
+
import { Card as Card16, Text as Text35 } from "@sanity/ui";
|
|
9261
|
+
import { jsx as jsx46 } from "react/jsx-runtime";
|
|
9440
9262
|
|
|
9441
9263
|
// src/components/report-detail/AreaScoreTable.tsx
|
|
9442
|
-
import { jsx as
|
|
9264
|
+
import { jsx as jsx47, jsxs as jsxs34 } from "react/jsx-runtime";
|
|
9443
9265
|
|
|
9444
9266
|
// src/components/report-detail/ComparisonSummary.tsx
|
|
9445
|
-
import { Badge as Badge8, Box as
|
|
9446
|
-
import { jsx as
|
|
9267
|
+
import { Badge as Badge8, Box as Box23, Card as Card18, Flex as Flex27, Grid as Grid4, Stack as Stack30, Text as Text37, Tooltip as Tooltip9 } from "@sanity/ui";
|
|
9268
|
+
import { jsx as jsx48, jsxs as jsxs35 } from "react/jsx-runtime";
|
|
9447
9269
|
|
|
9448
9270
|
// src/components/report-detail/OverviewStats.tsx
|
|
9449
9271
|
import { Grid as Grid5 } from "@sanity/ui";
|
|
9272
|
+
import { jsx as jsx49, jsxs as jsxs36 } from "react/jsx-runtime";
|
|
9273
|
+
|
|
9274
|
+
// src/components/report-detail/RecommendationsSection.tsx
|
|
9275
|
+
import { BoltIcon as BoltIcon2 } from "@sanity/icons";
|
|
9276
|
+
import { Box as Box24, Flex as Flex28, Stack as Stack31, Text as Text38 } from "@sanity/ui";
|
|
9450
9277
|
import { jsx as jsx50, jsxs as jsxs37 } from "react/jsx-runtime";
|
|
9451
9278
|
|
|
9452
9279
|
// src/components/report-detail/ThreeLayerTable.tsx
|