Manual Review Guide for OCR Outputs
Guides manual correction of OCR errors in CSV files from scanned PDFs, with a step-by-step workflow and common error patterns.
What this file does
Guides manual correction of OCR errors in CSV files from scanned PDFs, with a step-by-step workflow and common error patterns.
When to use it
- You need to fix OCR output that failed automated validation
- You have scanned PDF tables with low OCR confidence scores
- You want a systematic checklist for reviewing numeric data from scans
- You need to train reviewers on common OCR digit and character errors
Assumes this stack
Manual Review Guide for OCR Outputs
Comprehensive guide for manually verifying and correcting OCR-generated CSV files.
When is Manual Review Needed?
The OCR pipeline automatically flags outputs for manual review when:
- Low OCR confidence (< 85%)
- Validation errors detected:
- Missing expected columns
- Incorrect or missing sector names
- Non-numeric values in data columns
- Unrealistic values (> 500% or < -100%)
- High proportion of missing values (> 10%)
Review Workflow Overview
1. Check needs_review.txt
↓
2. Open review package for each flagged file
↓
3. Compare PDF with CSV
↓
4. Correct errors in CSV
↓
5. Save corrected CSV to output folder
↓
6. Delete review folder
↓
7. Verify corrections
Step-by-Step Instructions
Step 1: Identify Files Needing Review
# Check the needs-review list
cat OCR/needs_review.txt
# Or view in editor
notepad OCR/needs_review.txt
Example output:
Files Needing Manual Review
================================================================================
Total files: 3
ns_11_1994.pdf
Confidence: 78%
Issues:
- Missing columns
- Unclear sector names in rows 3-4
ns_15_1994.pdf
Confidence: 81%
Issues:
- Digit misrecognition in mining sector
...
Step 2: Open Review Package
For each flagged file, navigate to its review folder:
OCR/review/YYYY/ns_XX_YYYY/
├── original.pdf # Scanned source document
├── preprocessed.png # After image preprocessing
├── ocr_output.csv # OCR result needing correction
└── issues.txt # Detailed issues report
Example: For ns_11_1994.pdf, open:
OCR/review/1994/ns_11_1994/
Step 3: Compare PDF with CSV
- Open original.pdf in a PDF viewer
- Open ocr_output.csv in Excel or text editor
- Compare side-by-side:
- Check sector names in first two columns
- Verify numeric values column by column
- Look for missing or transposed digits
Pro tip: Use dual monitors or split-screen for easier comparison
Step 4: Common OCR Errors to Look For
A. Digit Misrecognition
| OCR Error | Should Be | Context |
|---|---|---|
| O (letter) | 0 (zero) | In numeric values: 1O.5 → 10.5 |
| l (lowercase L) | 1 (one) | In numeric values: l2.3 → 12.3 |
| S (letter) | 5 (five) | At end of number: 9.S → 9.5 |
| B (letter) | 8 (eight) | In numeric values: B.4 → 8.4 |
| Z (letter) | 2 (two) | Less common: Z.5 → 2.5 |
Example from actual table:
# OCR output (WRONG):
pesca;fishing;-29.B;-26.4;-lO.5;12.S
# Corrected:
pesca;fishing;-29.8;-26.4;-10.5;12.5
B. Missing Decimal Points
Problem: OCR sometimes misses decimal points, especially in faded scans
# WRONG:
agropecuario;agriculture;37;36;42
# CORRECT:
agropecuario;agriculture;3.7;3.6;4.2
How to detect: Values > 100 are unusual for monthly/quarterly growth rates
C. Transposed or Missing Digits
Problem: Digits can be misread or completely missed
# WRONG (transposed 96 → 69):
manufactura;manufacturing;-3.5;-2.3;69.8
# CORRECT:
manufactura;manufacturing;-3.5;-2.3;96.8
D. Sector Name Errors
Problem: Spanish sector names with accents or special characters
# WRONG:
minena;mining;... # Should be "mineria"
construcciOn;construction; # Should be "construccion"
electncidad;electricity; # Should be "electricidad"
# CORRECT:
mineria e hidrocarburos;mining and fuel;...
construccion;construction;...
electricidad y agua;electricity and water;...
E. Column Misalignment
Problem: OCR sometimes merges or splits columns incorrectly
# WRONG (values shifted):
sectores_economicos;economic_sectors;1992_ene;1992_feb
agropecuario agriculture;and livestock;3.7;3.6
# CORRECT:
sectores_economicos;economic_sectors;1992_ene;1992_feb
agropecuario;agriculture and livestock;3.7;3.6
F. Missing Negative Signs
Problem: Negative signs can be lost, especially for small fonts
# WRONG (should be negative):
pesca;fishing;29.8;26.4;55.9
# CORRECT:
pesca;fishing;-29.8;-26.4;-55.9
How to detect: Check if values seem unrealistic (fishing sector with consistent huge growth)
Step 5: Correction Workflow
Using Excel (Recommended)
-
Open CSV in Excel:
File → Open → Select "ocr_output.csv" -
Check delimiter:
- Should be semicolon (;)
- Excel may auto-detect or ask
-
Correction checklist:
- First column: Spanish sector names correct
- Second column: English sector names correct
- Remaining columns: All numeric values
- No missing decimal points
- No digit misrecognitions (O→0, l→1, etc.)
- Negative signs present where needed
- No column misalignments
-
Save corrected version:
File → Save As → CSV (Semicolon delimited) (*.csv)
Using Text Editor (Advanced)
For quick fixes, use VS Code, Notepad++, or similar:
-
Open ocr_output.csv
-
Use Find & Replace for systematic errors:
Find: ;O\. (semicolon + O + decimal) Replace: ;0. (semicolon + 0 + decimal) Find: ;l(\d) (semicolon + l + digit) Replace: ;1$1 (semicolon + 1 + digit) -
Manually fix unique errors
-
Save with UTF-8 encoding
Step 6: Save Corrected CSV
Important: Save to the correct output location!
# Correct location format:
OCR/output/table_1/YYYY/ns-XX-YYYY.csv
# OR
OCR/output/table_2/YYYY/ns-XX-YYYY.csv
Example for ns_11_1994.pdf (Table 1):
Source: OCR/review/1994/ns_11_1994/ocr_output.csv
Destination: OCR/output/table_1/1994/ns-11-1994.csv
Note the filename change: ns_11_1994 → ns-11-1994 (underscore → hyphen)
Step 7: Delete Review Folder
After saving corrected CSV:
# Delete review folder for this file
rm -rf OCR/review/1994/ns_11_1994/
# Or manually delete in file explorer
Why delete? Signals that review is complete and prevents re-flagging
Step 8: Verify Corrections
Run verification to ensure corrections are valid:
# Option 1: Verify specific file
python OCR/ocr_processors/validator.py OCR/output/table_1/1994/ns-11-1994.csv
# Option 2: Verify all outputs
python scripts/run_ocr_pipeline.py --verify
Expected output:
✓ Validation passed
Confidence Scores:
OCR: 78.0%
Combined: 88.0% # Improved after manual correction
Status: PASS
Quality Control Checklist
Before marking a file as reviewed, verify:
-
All sector names present:
- agropecuario / agriculture and livestock
- pesca / fishing
- mineria e hidrocarburos / mining and fuel
- manufactura / manufacturing
- electricidad y agua / electricity and water
- construccion / construction
- comercio / commerce
- otros servicios / other services
- pbi / gdp
-
Numeric columns:
- All values are numbers (no letters)
- Decimal points present where needed
- Negative signs correct
- No unrealistic outliers (check: -100% to +500% range)
-
Column structure:
- First column: Spanish sector names (semicolon)
- Second column: English sector names (semicolon)
- Remaining columns: Numeric data (semicolon-separated)
-
File naming:
- Saved to correct output folder (table_1 or table_2)
- Filename uses hyphens: ns-XX-YYYY.csv
Tips for Efficient Review
1. Prioritize by Confidence
Review lowest-confidence files first:
# Sort needs_review.txt by confidence
sort -t: -k2 -n OCR/needs_review.txt
2. Batch Similar Years
Process files from the same year together to spot patterns:
# Review all 1994 files at once
ls OCR/review/1994/
3. Use Excel Formulas for Validation
Create a validation column in Excel:
# Flag non-numeric values in column C
=IF(ISNUMBER(C2), "OK", "ERROR")
# Flag unrealistic values
=IF(OR(C2>500, C2<-100), "OUTLIER", "OK")
4. Keep Original PDF Open
Don't close the PDF - you may need to check multiple times
5. Document Patterns
If you notice systematic OCR errors (e.g., all 'O' should be '0'), note them for potential pipeline improvements
Troubleshooting
Problem: Excel Changes Formatting
Symptom: Dates become dates (1994_ene → 1/1994), decimals change
Solution:
- Open Excel
- File → Open (don't double-click CSV)
- Select "Text Import Wizard"
- Choose "Delimited" → Semicolon
- Set all columns as "Text" format
- Complete import
- Save as CSV (Semicolon delimited)
Problem: Can't Read PDF (Too Blurry)
Solution:
- Check
preprocessed.pngin review folder - If preprocessing improved quality, reference that
- If still unclear, note in issues and flag for re-scan
- Make best-effort correction based on context
Problem: Entire Row Missing
Solution:
- Check if sector is in PDF
- If yes, add manually:
pesca;fishing;-29.8;-26.4;... - Match column structure to other rows
Problem: Extra Columns or Rows
Solution:
- Check against PDF to determine correct structure
- Remove spurious columns/rows
- Ensure row count matches expected sectors (8 + GDP = 9 rows)
Examples
Example 1: Complete Review of ns_11_1994.pdf
Initial issues.txt:
Issues Detected (3):
1. Column 'sectores_economicos' has wrong name: 'sectores economicos'
2. Missing Spanish sector: construccion
3. Unrealistic values > 500% detected
Review process:
-
Open files:
original.pdfshows clear tableocr_output.csvhas errors
-
Identified errors:
- Header:
sectores economicos(space) →sectores_economicos(underscore) - Row 6 missing: construccion / construction
- manufactura row:
5O2.3→50.2(O→0, extra digit?)
- Header:
-
Corrections made:
# Fixed header sectores_economicos;economic_sectors;... # Added missing row construccion;construction;27.7;12.8;28.8;... # Fixed unrealistic value manufactura;manufacturing;-3.5;-2.3;50.2;... # was 5O2.3 -
Saved to:
OCR/output/table_1/1994/ns-11-1994.csv -
Verified: ✓ All checks passed
-
Deleted:
OCR/review/1994/ns_11_1994/
Example 2: Systematic Digit Error
Problem: All 'O' (letter O) should be '0' (zero) in one column
Solution using Find & Replace in Excel:
- Select the problematic column
- Ctrl+H (Find & Replace)
- Find:
O - Replace:
0 - Options: Match case ✓
- Replace All
Result: All 47 instances corrected instantly
Recording Your Work
Create a Review Log (Optional)
Keep track of corrections for documentation:
review_log.txt:
2026-01-07:
- ns_11_1994.pdf: Fixed O→0 errors (5 instances), added missing construccion row
- ns_15_1994.pdf: Corrected transposed digits in mining sector (96.8 not 69.8)
- ns_22_1994.pdf: Fixed missing negative signs in pesca sector
Total reviewed: 3 files
Time: ~45 minutes
Summary
Efficient manual review workflow:
- ✓ Check
needs_review.txtfor flagged files - ✓ Open review package (PDF + CSV + issues)
- ✓ Compare and identify errors systematically
- ✓ Correct using Excel or text editor
- ✓ Save to correct output location with proper filename
- ✓ Delete review folder
- ✓ Verify corrections
- ✓ Move to next file
Expected time: 15-30 minutes per file (depending on error severity)
Target: ~5-10% of 228 PDFs = 12-23 files needing review = 3-6 hours total
Need Help?
- Technical issues: Check OCR/README.md troubleshooting section
- Validation errors: Review error messages in
issues.txt - Unclear scans: Reference
preprocessed.pngfor enhanced version - Questions: Contact jj.cruza@up.edu.pe
Remember: Manual review is a normal and expected part of OCR workflows. Your corrections ensure the highest quality dataset for publication!
What's inside
8-step workflow, 6 error categories, 3 troubleshooting scenarios, 2 complete examples, and a quality checklist
Change this for your project
- Replace
OCR/paths with your own project's directory structure - Replace
ns_XX_YYYYandns-XX-YYYYfilename patterns with your own naming convention - Replace
jj.cruza@up.edu.pewith your own contact email - Replace sector names like
agropecuarioandpescawith your own expected categories
Where it goes
A standard operating procedure. Keep where the team or agent running the process will find it.
Worth borrowing
- Use a needs_review.txt file to track which outputs require manual attention
- Create a review package per file (original PDF, preprocessed image, CSV, issues report) to keep everything self-contained
- Document systematic OCR errors (like O→0, l→1) in a table so reviewers can apply find-and-replace fixes
Related Documents
Comprehensive AI Assistant Tools Reference
Lists 80+ tools with MCP server associations, bulk support, parallel capability, resource impact, and execution type for AI agent workflows.
iOS Deployment Guide
Walks through setting up an iOS development environment, building a Tauri app for iOS, and publishing to the App Store or alternative channels.
How to Add Resources to Your FastMCP Server
Teaches how to add static and dynamic MCP resources to a FastMCP server, with six ready-to-copy examples for a GitHub crawler.
Continue.dev MCP Integration Setup Guide
Walks through configuring Continue.dev to connect an MCP server for spatial transcriptomics tasks, with local and remote setup options.