Visualize AI debug runs with phase bar charts

This commit is contained in:
2026-02-20 14:16:29 +01:00
parent af3b07b80f
commit 46fc27600e
3 changed files with 262 additions and 1 deletions

View File

@@ -154,6 +154,107 @@
margin-bottom: 10px;
}
.ai-debug-inline-metric {
display: flex;
flex-direction: column;
gap: 4px;
}
.ai-debug-inline-bar {
display: block;
width: 100%;
height: 6px;
border-radius: 999px;
background: #e2e8f0;
overflow: hidden;
}
.ai-debug-inline-bar > span {
display: block;
height: 100%;
border-radius: 999px;
background: linear-gradient(90deg, #0ea5e9 0%, #0284c7 100%);
}
.ai-debug-viz {
display: flex;
flex-direction: column;
gap: 12px;
margin-bottom: 10px;
}
.ai-debug-viz-empty {
color: #64748b;
font-size: 13px;
}
.ai-debug-viz-group {
border: 1px solid #e2e8f0;
border-radius: 8px;
padding: 10px;
background: #f8fafc;
}
.ai-debug-viz-group h4 {
margin: 0 0 8px;
font-size: 13px;
color: #1e293b;
}
.ai-debug-bars {
margin: 0;
padding: 0;
list-style: none;
display: flex;
flex-direction: column;
gap: 7px;
}
.ai-debug-bar-row {
display: grid;
grid-template-columns: minmax(120px, 180px) minmax(60px, 1fr) auto;
align-items: center;
gap: 8px;
}
.ai-debug-bar-label {
font-size: 12px;
color: #334155;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.ai-debug-bar-track {
display: block;
width: 100%;
height: 10px;
border-radius: 999px;
background: #dbeafe;
overflow: hidden;
}
.ai-debug-bar-fill {
display: block;
height: 100%;
border-radius: 999px;
background: linear-gradient(90deg, #38bdf8 0%, #2563eb 100%);
}
.ai-debug-bar-value {
font-size: 12px;
color: #0f172a;
white-space: nowrap;
}
.ai-debug-bar-row--peak .ai-debug-bar-track {
background: #fee2e2;
}
.ai-debug-bar-row--peak .ai-debug-bar-fill {
background: linear-gradient(90deg, #fb7185 0%, #dc2626 100%);
}
.ai-debug-json {
margin: 0;
max-height: 60vh;
@@ -177,4 +278,8 @@
.ai-debug-json {
max-height: 42vh;
}
.ai-debug-bar-row {
grid-template-columns: minmax(100px, 140px) minmax(40px, 1fr) auto;
}
}