Tokens:
- {row.original.total_tokens} ({row.original.prompt_tokens}+{row.original.completion_tokens})
+ {row.original.total_tokens} ({row.original.prompt_tokens} prompt tokens + {row.original.completion_tokens} completion tokens)
+
+
+ Cache Read Tokens:
+ {formatNumberWithCommas(row.original.metadata?.additional_usage_values?.cache_read_input_tokens || 0)}
+
+
+ Cache Creation Tokens:
+ {formatNumberWithCommas(row.original.metadata?.additional_usage_values.cache_creation_input_tokens)}
Cost:
diff --git a/ui/litellm-dashboard/src/contexts/ThemeContext.tsx b/ui/litellm-dashboard/src/contexts/ThemeContext.tsx
new file mode 100644
index 00000000000..619d6a1004a
--- /dev/null
+++ b/ui/litellm-dashboard/src/contexts/ThemeContext.tsx
@@ -0,0 +1,62 @@
+import React, { createContext, useContext, useState, useEffect, ReactNode } from 'react'
+import { getProxyBaseUrl } from '@/components/networking'
+
+interface ThemeContextType {
+ logoUrl: string | null;
+ setLogoUrl: (url: string | null) => void;
+}
+
+const ThemeContext = createContext(undefined)
+
+export const useTheme = () => {
+ const context = useContext(ThemeContext);
+ if (!context) {
+ throw new Error('useTheme must be used within a ThemeProvider');
+ }
+ return context;
+}
+
+interface ThemeProviderProps {
+ children: ReactNode;
+ accessToken?: string | null;
+}
+
+export const ThemeProvider: React.FC = ({ children, accessToken }) => {
+ const [logoUrl, setLogoUrl] = useState(null);
+
+ // Load logo URL from backend on mount
+ useEffect(() => {
+ const loadLogoSettings = async () => {
+ if (accessToken) {
+ try {
+ const proxyBaseUrl = getProxyBaseUrl();
+ const url = proxyBaseUrl ? `${proxyBaseUrl}/get/ui_theme_settings` : '/get/ui_theme_settings';
+ const response = await fetch(url, {
+ method: 'GET',
+ headers: {
+ 'Authorization': `Bearer ${accessToken}`,
+ 'Content-Type': 'application/json',
+ },
+ });
+
+ if (response.ok) {
+ const data = await response.json();
+ if (data.values?.logo_url) {
+ setLogoUrl(data.values.logo_url);
+ }
+ }
+ } catch (error) {
+ console.warn('Failed to load logo settings from backend:', error);
+ }
+ }
+ };
+
+ loadLogoSettings();
+ }, [accessToken]);
+
+ return (
+
+ {children}
+
+ );
+};
\ No newline at end of file