Evo ocr preprocess extract

From OpenLAIR/OpenSkill · View interactive version

Evo ocr preprocess extract is an AI agent skill from the GitHub repository OpenLAIR/OpenSkill. Preprocesses receipt images and extracts text using Tesseract OCR with optimal settings for receipt layouts.

How to use this skill

Skill file

evo-ocr-preprocess-extract

Preprocesses receipt images using Pillow (grayscale, upscaling, contrast enhancement, binarization) and extracts raw text using pytesseract with optimal PSM configuration for receipt layouts.

Key Functions

Usage

import sys
sys.path.insert(0, '/app/environment/skills/evo-ocr-preprocess-extract/scripts')
from utils import get_sorted_image_files, extract_text_from_image

files = get_sorted_image_files('/path/to/images')
for filename, filepath in files:
    text = extract_text_from_image(filepath)

Pipeline

  1. Grayscale conversion (handles RGBA/RGB)
  2. 2x upscale with LANCZOS resampling
  3. Contrast enhancement (factor 2.0)
  4. Median filter denoising
  5. Binarization (threshold 140)
  6. Tesseract OCR with PSM 4 (single column)
Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.