From baeeb337d2383b539f6ab3e3af03c97b944835ea Mon Sep 17 00:00:00 2001 From: asa1997 Date: Mon, 23 Feb 2026 22:21:28 +0530 Subject: [PATCH 1/3] Match new interpreter report format --- src/pages/ShowModelDetails/SummaryDashboard.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pages/ShowModelDetails/SummaryDashboard.tsx b/src/pages/ShowModelDetails/SummaryDashboard.tsx index 56896199..3e28ca5a 100644 --- a/src/pages/ShowModelDetails/SummaryDashboard.tsx +++ b/src/pages/ShowModelDetails/SummaryDashboard.tsx @@ -350,7 +350,7 @@ export const processData = (interpreterData: InterpreterDataArray) => { interpreterData.forEach((entry) => { const attackType = entry.attack_type[0]; // Assuming one attack type per entry - const responseText = entry.judge_response.outputs[0].text; + const responseText = entry.judge_response?.outputs?.[0]?.text ?? entry.judge_response; let category = 'Non-malicious'; if (/Potentially Malicious/i.test(responseText)) { From 56f3c1a18b366a82e85598a60fba1174ec6baf7b Mon Sep 17 00:00:00 2001 From: asa1997 Date: Mon, 23 Feb 2026 22:39:10 +0530 Subject: [PATCH 2/3] Added vuln exploitation bar --- .../ShowModelDetails/SummaryDashboard.tsx | 106 ++++++++++++++++++ 1 file changed, 106 insertions(+) diff --git a/src/pages/ShowModelDetails/SummaryDashboard.tsx b/src/pages/ShowModelDetails/SummaryDashboard.tsx index 3e28ca5a..04f65103 100644 --- a/src/pages/ShowModelDetails/SummaryDashboard.tsx +++ b/src/pages/ShowModelDetails/SummaryDashboard.tsx @@ -299,6 +299,14 @@ interface Interpreter { model: string } +interface Vulnerability { + [vulnerabilityType: string]: { + [language: string]: { + [modelName: string]: number + } + } +} + interface LeakReplayEntry { entry_type: string probe: string @@ -508,6 +516,7 @@ const SummaryDashboard = ({ model }: any) => { `${besecureMlAssessmentDataStore}/${selectedModel.name}/llm-benchmark/${selectedModel.name}-interpreter-test-detailed-report.json`, `${besecureMlAssessmentDataStore}/${selectedModel.name}/llm-safetyBenchmark/${selectedModel.name}-modelbench-detailed-report.json`, `${besecureMlAssessmentDataStore}/${selectedModel.name}/llm-benchmark/${selectedModel.name}-garak-test-summary-report.json`, + `${besecureMlAssessmentDataStore}/${selectedModel.name}/llm-benchmark/${selectedModel.name}-vulnerability-exploitation-test-summary-report.json`, ]; const [interpreterData, setInterpreterData] = useState({}); @@ -534,6 +543,8 @@ const SummaryDashboard = ({ model }: any) => { ); const [garakTestSummary, setGarakTestSummaryData] = useState({}); + const [vulnerabilityData, setVulnerabilityData] = + useState({}); const [openAutocomplete, setOpenAutocomplete] = useState(false); const [openInstruct, setOpenInstruct] = useState(false); const [openInterpreter, setOpenInterpreter] = useState(false); @@ -567,6 +578,7 @@ const SummaryDashboard = ({ model }: any) => { verifyLink(urls[10], setInterpreterTestDetailedData, []), verifyLink(urls[11], setSafetyBenchmarkData), verifyLink(urls[12], setGarakTestSummaryData), + verifyLink(urls[13], setVulnerabilityData), ]); } catch (err) { // Fix me later @@ -579,6 +591,35 @@ const SummaryDashboard = ({ model }: any) => { // eslint-disable-next-line react-hooks/exhaustive-deps }, [selectedModel.name]); + const processVulnerabilityData = (vulnData: Vulnerability) => { + const languageMap: Record = {}; + + Object.entries(vulnData).forEach(([vulnType, languages]) => { + Object.entries(languages).forEach(([language, models]) => { + if (!languageMap[language]) { + languageMap[language] = { language }; + } + Object.entries(models).forEach(([model, score]) => { + languageMap[language][vulnType] = (score * 100).toFixed(2); + }); + }); + }); + + return Object.values(languageMap); + }; + + const vulnerabilityChartData = processVulnerabilityData(vulnerabilityData); + + const vulnerabilityTypes = Object.keys(vulnerabilityData); + + const vulnerabilityColors: Record = { + constraint_satisfaction: '#FF6B6B', + buffer_overflow: '#4ECDC4', + memory_corruption: '#FFE66D', + sql_injection: '#95E1D3', + xss: '#F38181', + }; + const flattenedMockData = Object.entries(garakTestSummary).flatMap( ([category, subCategories]) => Object.entries(subCategories || {}).flatMap( @@ -1641,6 +1682,71 @@ const SummaryDashboard = ({ model }: any) => { + + + + + + Vulnerability Exploitation + + + { vulnerabilityChartData.length === 0 ? ( + + + Vulnerability data not available + + + ) : ( + + + + + + + { vulnerabilityTypes.map((vulnType) => ( + l.toUpperCase()) } + fill={ vulnerabilityColors[vulnType] || '#999' } + barSize={ 30 } + /> + )) } + + + ) } + + + Date: Mon, 23 Feb 2026 22:44:26 +0530 Subject: [PATCH 3/3] Updated name --- src/pages/ShowModelDetails/SummaryDashboard.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pages/ShowModelDetails/SummaryDashboard.tsx b/src/pages/ShowModelDetails/SummaryDashboard.tsx index 04f65103..89868fe7 100644 --- a/src/pages/ShowModelDetails/SummaryDashboard.tsx +++ b/src/pages/ShowModelDetails/SummaryDashboard.tsx @@ -1697,7 +1697,7 @@ const SummaryDashboard = ({ model }: any) => { variant="h5" sx={ { textAlign: 'center' } } > - Vulnerability Exploitation + Vulnerability Exploitation: Capture-the-Flag Challenge Performance { vulnerabilityChartData.length === 0 ? (