/** * Constants and demo data for BQAS Dashboard */ import type { BQASMetrics, TrendData, TestRun } from './types' // API Configuration - Use internal proxy to avoid CORS issues export const BQAS_API_BASE = '/api/bqas' // Demo data for when API is not available export const DEMO_GOLDEN_METRICS: BQASMetrics = { total_tests: 97, passed_tests: 89, failed_tests: 8, avg_intent_accuracy: 91.7, avg_faithfulness: 4.2, avg_relevance: 4.1, avg_coherence: 4.3, safety_pass_rate: 0.98, avg_composite_score: 4.15, scores_by_intent: { korrektur_anfrage: 4.5, erklaerung_anfrage: 4.3, hilfe_anfrage: 4.1, feedback_anfrage: 3.9, smalltalk: 4.2, }, failed_test_ids: ['GT-023', 'GT-045', 'GT-067', 'GT-072', 'GT-081', 'GT-089', 'GT-092', 'GT-095'], } export const DEMO_TREND: TrendData = { dates: ['2026-01-02', '2026-01-09', '2026-01-16', '2026-01-23', '2026-01-30'], scores: [3.9, 4.0, 4.1, 4.15, 4.15], trend: 'improving', } export const DEMO_RUNS: TestRun[] = [ { id: 1, timestamp: '2026-01-30T07:00:00Z', git_commit: 'abc1234', golden_score: 4.15, synthetic_score: 3.9, total_tests: 97, passed_tests: 89, failed_tests: 8, duration_seconds: 45.2 }, { id: 2, timestamp: '2026-01-29T07:00:00Z', git_commit: 'def5678', golden_score: 4.12, synthetic_score: 3.85, total_tests: 97, passed_tests: 88, failed_tests: 9, duration_seconds: 44.8 }, { id: 3, timestamp: '2026-01-28T07:00:00Z', git_commit: '9ab0123', golden_score: 4.10, synthetic_score: 3.82, total_tests: 97, passed_tests: 87, failed_tests: 10, duration_seconds: 46.1 }, ]