feat(ocr-pipeline): improve LLM review UI + add reconstruction step

StepLlmReview: Show full vocab table with image overlay, row-level
status tracking (pending/active/reviewed/corrected/skipped), and
auto-scroll during SSE streaming. Load previous results on mount.

StepReconstruction: New step 7 with editable text fields at original
bbox positions over dewarped image. Zoom controls, tab navigation,
color-coded columns, save to backend.

Backend: Add POST /sessions/{id}/reconstruction endpoint.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Benjamin Admin
2026-03-02 12:19:21 +01:00
parent 2a493890b6
commit dbf0db0c13
5 changed files with 849 additions and 197 deletions

View File

@@ -175,7 +175,7 @@ export default function OcrPipelinePage() {
case 5:
return <StepLlmReview sessionId={sessionId} onNext={handleNext} />
case 6:
return <StepReconstruction />
return <StepReconstruction sessionId={sessionId} onNext={handleNext} />
case 7:
return <StepGroundTruth />
default:

View File

@@ -165,6 +165,14 @@ export interface GridResult {
with_english?: number
with_german?: number
}
llm_review?: {
changes: { row_index: number; field: string; old: string; new: string }[]
model_used: string
duration_ms: number
entries_corrected: number
applied_count?: number
applied_at?: string
}
}
export interface WordEntry {