Link calibration rows to QA evidence map
GeoIntel CI / docs-smoke (push) Has been cancelled
GeoIntel CI / contract-smoke (push) Has been cancelled

This commit is contained in:
Codex
2026-07-08 13:23:42 +02:00
parent c0bebd609b
commit 0c826ef736
7 changed files with 78 additions and 0 deletions
@@ -79,6 +79,7 @@ interface DetectionLabProps {
onRunQa: () => void
onSetCalibrationThresholdText: (value: string) => void
onRunCalibration: () => void
onOpenCalibrationEvidence: (qualityCheckId: string) => void
}
export function DetectionLab({
@@ -133,6 +134,7 @@ export function DetectionLab({
onRunQa,
onSetCalibrationThresholdText,
onRunCalibration,
onOpenCalibrationEvidence,
}: DetectionLabProps): JSX.Element {
const selectedDetectionModel = detectionModels.find((model) => model.model_id === selectedDetectionModelId) ?? null
const selectedModelAsset = modelAssets.find((asset) => asset.model_asset_id === selectedModelAssetId) ?? null
@@ -583,6 +585,7 @@ export function DetectionLab({
<th>F1</th>
<th>False positives</th>
<th>False negatives</th>
<th>Evidence</th>
</tr>
</thead>
<tbody>
@@ -596,6 +599,17 @@ export function DetectionLab({
<td>{formatNullableNumber(row.f1_score ?? null, 3)}</td>
<td>{row.false_positives ?? 'n/a'}</td>
<td>{row.false_negatives ?? 'n/a'}</td>
<td>
<button
className="secondary-action table-action"
type="button"
onClick={() => row.quality_check_id ? onOpenCalibrationEvidence(row.quality_check_id) : undefined}
disabled={!row.quality_check_id || row.status !== 'success'}
aria-label={`Open evidence map for threshold ${row.threshold.toFixed(2)}`}
>
Open evidence map
</button>
</td>
</tr>
))}
</tbody>