PatchFinder: Leveraging Visual Language Models for Accurate Information Retrieval Using Model Uncertainty

Roman Colman, Minh Vu, Manish Bhattarai, Martin Ma, Hari S. Viswanathan, Daniel O'Malley, Javier E. Santos

Introduction: The Challenge of Noisy Documents

For decades, critical data—ranging from medical records to historical climate patterns—has been trapped in millions of scanned, often "noisy" documents. These records are frequently smudged, faded, or poorly formatted, making automated extraction difficult.

The traditional approach to digitizing these records involves a two-step process: Optical Character Recognition (OCR) to convert pixels to text, followed by a Large Language Model (LLM) to process that text. However, this pipeline is brittle; if OCR misinterprets a character due to a document artifact, the LLM lacks the visual context to correct it. While modern Vision Language Models (VLMs) can process images directly, they struggle with high-resolution documents because their internal "vision" is limited to specific window sizes. When forced to process a whole page at once, they often lose the fine details necessary for precise data extraction.

The PatchFinder Approach

PatchFinder addresses this "Resolution Paradox" by treating the VLM like a researcher with a magnifying glass. Instead of asking the model to process an entire page, PatchFinder intelligently partitions the image into overlapping patches and selects the most reliable output based on model uncertainty.

The PatchFinder workflow: from patch extraction and VLM inference to maximum-likelihood prediction based on Patch Confidence.

Methodology

The PatchFinder workflow consists of three primary stages:

  1. Patch Confidence (PC): The system utilizes a scoring metric based on Maximum Softmax Probability (MSP). By analyzing the model's internal probability distribution for each generated word, PatchFinder determines if the model is "sure" of its output or merely "guessing."
  2. Patch Size Optimization: The algorithm identifies an optimal "Goldilocks" size for image patches. If a patch is too small, it lacks necessary context; if too large, information density exceeds the model's processing capacity. Research indicates that for historical records, patches covering 22% to 25% of the image are ideal.
  3. Confidence-Based Prediction: The document is divided into overlapping patches, each processed by a VLM (specifically Phi-3v, a 4.2B parameter model). PatchFinder then selects the final answer from the patch that yielded the highest confidence score.

Experimental Results

The study primarily focused on Historical Well Records, a challenging real-world dataset of 190 scanned documents used to locate abandoned oil and gas wells. To test generalization, the method was also evaluated on the CORD (receipts) and FUNSD (noisy forms) datasets, as well as historical financial statements with added Gaussian noise.

Quantitative comparison of PatchFinder against baseline VLMs and OCR-based pipelines across different document sets.

Key Performance Metrics

  • Superior Accuracy: On the historical well dataset, PatchFinder achieved 94% accuracy, significantly outperforming ChatGPT-4o (75.4%) and a "vanilla" Phi-3v without patching (61.8%).
  • Robustness to Noise: In tests involving extreme degradation (Gaussian noise), PatchFinder maintained 53.3% accuracy, while ChatGPT-4o dropped to 36.7% and the standard Phi-3v failed completely.
  • Zero-Shot Success: The method requires no fine-tuning, making it a highly accessible solution for organizations with limited computational resources.

Insights and Future Directions

The core insight of PatchFinder is that a model’s internal uncertainty (MSP) is a powerful signal that correlates strongly with actual accuracy. By listening to when a model is "unsure," hallucinations can be effectively discarded. Furthermore, the results demonstrate that a smaller, specialized VLM (4.2B parameters) can outperform giant models like GPT-4o if the input is pre-processed to fit the model's "comfort zone."

While powerful, PatchFinder involves higher computational costs due to multiple inference passes per document. Future work will focus on exploring more sophisticated uncertainty measures beyond MSP and optimizing the multi-patch inference process for greater speed.

Reference: Colman, R., et al. "PatchFinder: Leveraging Visual Language Models for Accurate Information Retrieval using Model Uncertainty." WACV, 2025.

Summary updated

BibTeX
@inproceedings{colman2025patchfinder,
  author = {Roman Colman and Minh Vu and Manish Bhattarai and Martin Ma and Hari S. Viswanathan and Daniel O'Malley and Javier E. Santos},
  title = {{PatchFinder: Leveraging Visual Language Models for Accurate Information Retrieval Using Model Uncertainty}},
  booktitle = {IEEE/CVF Winter Conference on Applications of Computer Vision},
  year = {2025},
  doi = {10.1109/wacv61041.2025.00886},
}
Figure