ChunkNorris: A High-Performance and Low-Energy Approach to PDF Parsing and Chunking
Mathieu Ciancone, Clovis Varangot-Reille, Marion Schaeffer
TL;DR
ChunkNorris presents a fast, heuristic-based, ML-free approach to PDF parsing and chunking designed for production-friendly RAG pipelines. The method employs a PyMuPDF-based PdfParser and a MarkdownChunker that uses a ToC-driven tree to produce coherent, context-preserving chunks in Markdown. Through a large open benchmark (PIRE) across diverse document types and embedding models, ChunkNorris delivers superior recall@10 and NDCG@10 with lower parsing time and energy consumption compared to several ML-assisted parsers, highlighting its practical impact for energy-efficient IR tasks. The work provides open-source tooling and an extensible benchmark framework to accelerate adoption and future improvements in real-world document ingestion workloads.
Abstract
In Retrieval-Augmented Generation applications, the Information Retrieval part is central as it provides the contextual information that enables a Large Language Model to generate an appropriate and truthful response. High quality parsing and chunking are critical as efficient data segmentation directly impacts downstream tasks, i.e. Information Retrieval and answer generation. In this paper, we introduce ChunkNorris, a novel heuristic-based technique designed to optimise the parsing and chunking of PDF documents. Our approach does not rely on machine learning and employs a suite of simple yet effective heuristics to achieve high performance with minimal computational overhead. We demonstrate the efficiency of ChunkNorris through a comprehensive benchmark against existing parsing and chunking methods, evaluating criteria such as execution time, energy consumption, and retrieval accuracy. We propose an open-access dataset to produce our results. ChunkNorris outperforms baseline and more advanced techniques, offering a practical and efficient alternative for Information Retrieval tasks. Therefore, this research highlights the potential of heuristic-based methods for real-world, resource-constrained RAG use cases.
