@parhelia/benchmark 0.4.12825 → 0.4.12871
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,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { Accordion, AccordionContent, AccordionItem, AccordionTrigger, Alert, AlertDescription, Button, SettingsCard, Tooltip, TooltipContent, TooltipTrigger } from "@parhelia/core";
|
|
2
|
+
import { Accordion, AccordionContent, AccordionItem, AccordionTrigger, Alert, AlertAction, AlertDescription, Button, SettingsCard, Tooltip, TooltipContent, TooltipTrigger } from "@parhelia/core";
|
|
3
3
|
import { AlertCircle, ArrowLeft, Gauge, Info, ListChecks, Loader2, MessageSquare, Square } from "lucide-react";
|
|
4
4
|
import { agentLink } from "../agentLink";
|
|
5
5
|
import { cost, count, duration, parseGraderReport, parseJson, percent } from "../format";
|
|
@@ -13,7 +13,7 @@ function Stat({ label, value, hint, explanation }) {
|
|
|
13
13
|
export function BenchmarkRunDetail({ detail, back, cancel, busy }) {
|
|
14
14
|
const run = detail.run;
|
|
15
15
|
if (!run)
|
|
16
|
-
return _jsxs(Alert, { variant: "warning", children: [_jsx(AlertCircle, { className: "h-4 w-4", strokeWidth: 1.5 }), _jsxs(AlertDescription, {
|
|
16
|
+
return _jsxs(Alert, { variant: "warning", children: [_jsx(AlertCircle, { className: "h-4 w-4", strokeWidth: 1.5 }), _jsxs(AlertDescription, { children: ["This run no longer exists.", _jsx(AlertAction, { onClick: back, children: "Back to runs" })] })] });
|
|
17
17
|
const tokens = run.inputTokens + run.outputTokens + run.cachedTokens + run.cacheWriteTokens;
|
|
18
18
|
const completed = detail.tasks.filter(t => t.status === "Completed").length;
|
|
19
19
|
const active = run.status === "Running" || run.status === "Queued";
|
|
@@ -10,5 +10,5 @@ const recoveryReasons = {
|
|
|
10
10
|
export function RecoveryBanner({ tasks, busy, recover }) {
|
|
11
11
|
if (!tasks.length)
|
|
12
12
|
return null;
|
|
13
|
-
return _jsxs(Alert, { "data-testid": "benchmark-recovery-banner", variant: "warning", role: "status", children: [_jsx(AlertTriangle, { className: "h-4 w-4", strokeWidth: 1.5 }), _jsxs("div", { className: "flex flex-wrap items-start justify-between gap-x-6 gap-y-3", children: [_jsxs("div", { className: "min-w-0 flex-1", children: [_jsxs(AlertTitle, { children: [tasks.length, " ", tasks.length === 1 ? "task needs" : "tasks need", " recovery"] }), _jsxs(AlertDescription, {
|
|
13
|
+
return _jsxs(Alert, { "data-testid": "benchmark-recovery-banner", variant: "warning", role: "status", children: [_jsx(AlertTriangle, { className: "h-4 w-4", strokeWidth: 1.5 }), _jsxs("div", { className: "flex flex-wrap items-start justify-between gap-x-6 gap-y-3", children: [_jsxs("div", { className: "min-w-0 flex-1", children: [_jsxs(AlertTitle, { children: [tasks.length, " ", tasks.length === 1 ? "task needs" : "tasks need", " recovery"] }), _jsxs(AlertDescription, { children: [_jsx("p", { children: "Recover these tasks to safely stop any remaining agents and clean up their test data before starting another benchmark." }), _jsx("ul", { className: "mt-2 space-y-0.5", children: tasks.map(t => _jsxs("li", { children: [_jsx("span", { className: "font-medium", children: t.taskTitle }), " \u00B7 ", recoveryReasons[t.shutdownState]] }, t.taskResultId)) })] })] }), _jsx(Button, { size: "sm", disabled: busy, onClick: recover, children: "Recover now" })] })] });
|
|
14
14
|
}
|