From 4f93fe2b5206965f0ea8883b6f305afd821fa234 Mon Sep 17 00:00:00 2001 From: Cursor Agent Date: Tue, 3 Feb 2026 16:18:33 +0000 Subject: [PATCH] feat(ui): Add team-alias column to Models Health Status UI - Added Team Alias column to the Models Health Status table - Updated HealthCheckComponent to accept teams prop - Updated health_check_columns to display team alias based on team_id - Falls back to team_id if team alias not found, or shows '-' if no team - Updated parent components to pass teams data to HealthCheckComponent Co-authored-by: ishaan --- .../ModelsAndEndpointsView.tsx | 1 + .../model_dashboard/HealthCheckComponent.tsx | 4 +++ .../model_dashboard/health_check_columns.tsx | 27 +++++++++++++++++++ .../components/templates/model_dashboard.tsx | 1 + 4 files changed, 33 insertions(+) diff --git a/ui/litellm-dashboard/src/app/(dashboard)/models-and-endpoints/ModelsAndEndpointsView.tsx b/ui/litellm-dashboard/src/app/(dashboard)/models-and-endpoints/ModelsAndEndpointsView.tsx index 6a4882a92a2..8bfbaa8d3a6 100644 --- a/ui/litellm-dashboard/src/app/(dashboard)/models-and-endpoints/ModelsAndEndpointsView.tsx +++ b/ui/litellm-dashboard/src/app/(dashboard)/models-and-endpoints/ModelsAndEndpointsView.tsx @@ -400,6 +400,7 @@ const ModelsAndEndpointsView: React.FC = ({ premiumUser, te all_models_on_proxy={allModelsOnProxy} getDisplayModelName={getDisplayModelName} setSelectedModelId={setSelectedModelId} + teams={teams} /> string; setSelectedModelId?: (modelId: string) => void; + teams?: Team[] | null; } const HealthCheckComponent: React.FC = ({ @@ -32,6 +34,7 @@ const HealthCheckComponent: React.FC = ({ all_models_on_proxy, getDisplayModelName, setSelectedModelId, + teams, }) => { const [modelHealthStatuses, setModelHealthStatuses] = useState<{ [key: string]: HealthStatus }>({}); const [selectedModelsForHealth, setSelectedModelsForHealth] = useState([]); @@ -574,6 +577,7 @@ const HealthCheckComponent: React.FC = ({ showErrorModal, showSuccessModal, setSelectedModelId, + teams, )} data={modelData.data.map((model: any) => { const modelName = model.model_name; diff --git a/ui/litellm-dashboard/src/components/model_dashboard/health_check_columns.tsx b/ui/litellm-dashboard/src/components/model_dashboard/health_check_columns.tsx index 077b9d1004f..22c908e7848 100644 --- a/ui/litellm-dashboard/src/components/model_dashboard/health_check_columns.tsx +++ b/ui/litellm-dashboard/src/components/model_dashboard/health_check_columns.tsx @@ -2,6 +2,7 @@ import { ColumnDef } from "@tanstack/react-table"; import { Tooltip, Checkbox } from "antd"; import { Text } from "@tremor/react"; import { InformationCircleIcon, PlayIcon, RefreshIcon } from "@heroicons/react/outline"; +import { Team } from "@/components/key_team_helpers/key_list"; interface HealthCheckData { model_name: string; @@ -42,6 +43,7 @@ export const healthCheckColumns = ( showErrorModal?: (modelName: string, cleanedError: string, fullError: string) => void, showSuccessModal?: (modelName: string, response: any) => void, setSelectedModelId?: (modelId: string) => void, + teams?: Team[] | null, ): ColumnDef[] => [ { header: () => ( @@ -100,6 +102,31 @@ export const healthCheckColumns = ( ); }, }, + { + header: "Team Alias", + accessorKey: "model_info.team_id", + enableSorting: true, + sortingFn: "alphanumeric", + cell: ({ row }) => { + const model = row.original; + const teamId = model.model_info?.team_id; + + if (!teamId) { + return -; + } + + const team = teams?.find((t) => t.team_id === teamId); + const teamAlias = team?.team_alias || teamId; + + return ( +
+ +
{teamAlias}
+
+
+ ); + }, + }, { header: "Health Status", accessorKey: "health_status", diff --git a/ui/litellm-dashboard/src/components/templates/model_dashboard.tsx b/ui/litellm-dashboard/src/components/templates/model_dashboard.tsx index e4dc896f55d..6f3ce27567c 100644 --- a/ui/litellm-dashboard/src/components/templates/model_dashboard.tsx +++ b/ui/litellm-dashboard/src/components/templates/model_dashboard.tsx @@ -1368,6 +1368,7 @@ const OldModelDashboard: React.FC = ({ all_models_on_proxy={all_models_on_proxy} getDisplayModelName={getDisplayModelName} setSelectedModelId={setSelectedModelId} + teams={teams} />