diff --git a/apps/fabro-web/app/components/ui.tsx b/apps/fabro-web/app/components/ui.tsx index 6c4701ca8..485941dbf 100644 --- a/apps/fabro-web/app/components/ui.tsx +++ b/apps/fabro-web/app/components/ui.tsx @@ -68,7 +68,7 @@ export function Tooltip({ label, children, }: { - label: string; + label: React.ReactNode; children: React.ReactNode; }) { const [open, setOpen] = useState(false); @@ -92,7 +92,7 @@ export function Tooltip({ {rect && portalTarget ? createPortal( - {label} - , + , portalTarget, ) : null} diff --git a/apps/fabro-web/app/routes/run-stages.tsx b/apps/fabro-web/app/routes/run-stages.tsx index 39ec1a7c8..c564c75f2 100644 --- a/apps/fabro-web/app/routes/run-stages.tsx +++ b/apps/fabro-web/app/routes/run-stages.tsx @@ -433,8 +433,8 @@ function formatDurationMs(ms: number): string { function formatTokenCount(n: number): string { if (n < 1000) return `${n}`; - if (n < 1_000_000) return `${(n / 1000).toFixed(1)}k`; - return `${(n / 1_000_000).toFixed(1)}M`; + if (n < 1_000_000) return `${Math.round(n / 1000)}k`; + return `${Math.round(n / 1_000_000)}M`; } export function turnMetric(turn: TurnType): string | null { @@ -488,6 +488,17 @@ function EventRow({ }) { const metric = turnMetric(turn); const MetricIcon = metric == null ? null : turn.kind === "assistant" ? CircleStackIcon : ClockIcon; + const metricSpan = ( + + {turn.kind === "tool" && turn.isError && ( + + Error + + )} + {MetricIcon && + ); return (