Command Palette
Search for a command to run...
문서 검색 인지 청킹(D-RAC): PDF 정규화 및 멀티모달 Markdown 변환을 통한 기업 문서의 범용 검색 인지 수집
문서 검색 인지 청킹(D-RAC): PDF 정규화 및 멀티모달 Markdown 변환을 통한 기업 문서의 범용 검색 인지 수집
Uday Allu Abhivanth Sivaprakash Pratik Singh Aman Manocha
초록
기업 지식 베이스에서 작동하는 검색 증강 생성(RAG) 시스템은 복잡한 시각적 레이아웃, 다단 페이지, 밀집된 표 안에 콘텐츠가 잠겨 있는 이질적인 문서 형식(PDF, Word 문서, 프레젠테이션, 스캔본)을 수집해야 한다. 기존 수집 파이프라인은 규칙 기반 텍스트 추출이나 OCR에 의존하는데, 이는 종종 읽기 순서를 훼손하고 표를 평면화하며 제목 계층 구조를 상실시켜 하위 검색 품질을 저하시킨다. 원시 추출 텍스트에 대한 완전 에이전틱 청킹은 일부 의미적 응집성을 회복하지만 높은 토큰 비용과 환각 위험을 초래한다. 본 논문에서는 웹 검색 인지 청킹(W-RAC) 프레임워크를 임의 문서 형식으로 확장한 문서 검색 인지 청킹(D-RAC)을 제시한다. D-RAC는 먼저 모든 입력 문서(DOCX, PPTX, XLSX, 스캔 이미지 또는 네이티브 PDF)를 PDF로 정규화하는데, 이는 사실상 모든 문서 형식이 충실하고 결정적인 PDF 렌더링을 갖는다는 점을 활용한 것이다. 그런 다음 단일 멀티모달 LLM 패스를 적용하여 렌더링된 페이지를 검색 최적화 Markdown으로 변환한다. 이때 표를 자기 완결적 산문 문장으로 정규화하고 제목 계층 구조를 보존하며, 이후 청킹은 W-RAC과 동일하게 진행된다. 즉, ID로 주소 지정 가능한 단위로의 결정적 파싱 후 텍스트가 아닌 식별자에 대한 경량 LLM 기반 청크 계획 수립이 수행된다. 청킹 중에 원본 텍스트가 재생성되지 않으므로 W-RAC의 비용, 결정성, 관측 가능성 이점을 유지하면서 렌더링 가능한 모든 문서 형식을 일급 입력으로 활용할 수 있다. 236개 문서, 795페이지로 구성된 RAG-Multi-Corpus 벤치마크의 PDF 하위 집합(자동차, 학술, 클라우드 서비스, 기업 기술, 금융 분야 포함)에서 D-RAC는 전체 코퍼스를 72분 만에 오류 없이 변환 및 청킹하여 1,748개의 검색 준비 완료 청크를 생성했다. 최첨단 LLM을 사용한 에이전틱 청킹과 비교할 때 D-RAC는 청킹 단계 출력 토큰을 95.7% 줄였고, GPT-4.1 가격 기준으로 청킹 비용을 77.8%, Gemini 2.5 Pro 가격 기준으로 85.6% 절감했으며, 청킹 시간을 75% 단축했다. D-RAC는 500페이지가 넘는 문서까지 선형적으로 확장된다.
One-sentence Summary
Researchers at Yellow.ai propose Document Retrieval-Aware Chunking (D-RAC), which extends W-RAC by normalizing heterogeneous enterprise documents to PDF and applying a single multimodal LLM pass to produce retrieval-optimized Markdown, followed by deterministic ID-addressable parsing and lightweight identifier-based chunk planning without source-text regeneration; on the 236-document, 795-page PDF subset of the RAG-Multi-Corpus benchmark, D-RAC converts and chunks the corpus in 72 minutes with zero errors, producing 1,748 retrieval-ready chunks, and compared to agentic chunking it reduces chunking-stage output tokens by 95.7%, cuts cost by 77.8% under GPT-4.1 pricing and 85.6% under Gemini 2.5 Pro pricing, and reduces chunking time by 75%.
Key Contributions
- Document Retrieval-Aware Chunking (D-RAC) extends retrieval-aware chunking from web content to arbitrary enterprise documents by normalizing DOCX, PPTX, XLSX, scanned images, and native PDFs into PDF and applying a single multimodal LLM pass to convert rendered pages into retrieval-optimized Markdown with preserved heading hierarchy and self-contained prose table statements.
- The chunking stage parses the converted Markdown into ID-addressable units and performs lightweight LLM-based chunk planning over identifiers only, so source text is never regenerated during chunking and the one-time conversion cost is decoupled from repeatable re-chunking.
- On the 236-document, 795-page PDF subset of RAG-Multi-Corpus, D-RAC converts and chunks the corpus in 72 minutes with zero errors and 1,748 retrieval-ready chunks; compared with agentic chunking, it reduces chunking-stage output tokens by 95.7%, chunking cost by 77.8% under GPT-4.1 pricing and 85.6% under Gemini 2.5 Pro pricing, and chunking time by 75%, while scaling linearly to documents over 500 pages.
Introduction
Retrieval-Augmented Generation has become the standard way to ground large language models in enterprise knowledge, but enterprise corpora are dominated by PDFs whose presentation-oriented layout breaks conventional text extraction. Prior work, Web Retrieval-Aware Chunking (W-RAC), reduced chunking cost and latency by planning chunk boundaries over deterministic identifiers, yet it assumed recoverable HTML-like structure and therefore could not handle PDFs, while rule-based, OCR/layout-analysis, and agentic alternatives either inherit extraction artifacts or pay repeated text-generation costs. The authors introduce D-RAC, which normalizes any input document to PDF and adds one retrieval-aware multimodal pass that converts rendered pages into structured Markdown, allowing the unchanged W-RAC pipeline to ingest arbitrary enterprise documents.
Dataset
The authors use the PDF subset of RAG-Multi-Corpus, the benchmark introduced with W-RAC, for evaluation.
Dataset composition and sources
- Main evaluation corpus: 236 PDF documents totaling 795 pages across five fictional enterprise organizations in distinct industry verticals.
- Document types reflect enterprise knowledge base content: product sheets, FAQs, policy and procedure documents, parts catalogs, and service guides.
- Formatting is table-heavy and layout-rich, typical of each domain.
Query subset
- 762 curated queries with supporting-fact ground truth are used for retrieval evaluation.
- Queries cover four of the five organizations; CloudWay-24 has no annotated queries in the reference set.
- Queries are categorized into seven types to test factual recall, reasoning, comparison, and procedural understanding.
- Each query is annotated with one or more supporting facts: verbatim snippets from the source documents and their originating file.
Processing and usage
- Because all inputs are natively PDF, Stage 1 normalization is treated as identity.
- A separate 503-page financial prospectus is used as a scalability stress test.
- Processing uses AWS Bedrock with temperature 0.1.
- Conversion uses a maximum of 8,192 output tokens per batch and chunk planning of 16,384 tokens per section call.
- Documents are processed in 5-page batches with 5 parallel workers.
The provided excerpt focuses on evaluation data. It does not describe training splits, mixture ratios, filtering rules, or cropping strategies.
Method
The authors propose Document Retrieval-Aware Chunking (D-RAC), a pipeline designed to convert heterogeneous documents into retrieval-optimized chunks. The system architecture comprises four distinct stages: normalize and render, convert, parse and section, and plan and reconstruct.
Refer to the framework diagram for the overall pipeline structure.
In the first stage, the authors ensure format agnosticism by treating PDF as the universal visual interchange format. Any input document that is not already a PDF is converted using standard deterministic tooling. Each page of the normalized PDF is then rendered to a PNG image at 200 DPI, downscaled to ensure no dimension exceeds 1,568 pixels to match common vision-encoder input limits. This step is entirely deterministic and involves no LLM calls.
The second stage involves multimodal Markdown conversion. Rendered pages are grouped into batches and sent to a multimodal LLM. The conversion prompt enforces strict retrieval-aware output rules. Text content is preserved verbatim, and explicit hierarchy is reconstructed using Markdown heading levels. Crucially, the system applies retrieval-aware table normalization. Instead of using Markdown table syntax, every table row is transformed into a self-contained sentence using column headers as context.
As shown in the figure below, this row-level table prose ensures that every tabular fact becomes an independently embeddable statement.
The authors explicitly forbid collapsing multiple rows into disjunctive sentences to prevent precision loss during retrieval. Image suppression is also applied to omit logos and decorative graphics, preventing hallucinated captions from polluting the index.
In the third stage, the converted Markdown undergoes deterministic parsing and sectioning. The text is parsed into ID-addressable elements, such as headers and content blocks. For documents exceeding a planning budget, a recursive sectioning algorithm splits the element sequence at header boundaries. Each section is accompanied by its parent-header context, allowing the planner to understand the document hierarchy without re-sending content.
The final stage focuses on LLM chunk planning and reconstruction. The LLM receives only element IDs, truncated text previews, and hierarchy metadata, returning chunk plans as ordered ID lists. The planner is instructed to group content blocks around single topics and reuse header IDs across chunks for context. Coverage is verified programmatically to guarantee lossless ingestion. Final chunks are reconstructed locally by mapping IDs back to the verbatim converted text. Each chunk is prefixed with its full ancestor-heading chain and annotated with a human-readable breadcrumb before being embedded and indexed. Because the converted Markdown and element IDs are persisted, retrieval strategy changes require only re-planning, avoiding the need for re-conversion or re-OCR of the source PDF.
Experiment
The evaluation uses the PDF subset of RAG-Multi-Corpus across five enterprise domains, with 762 annotated queries covering seven reasoning types. Experiments show that D-RAC converts all documents without errors and scales linearly on a large stress test, while chunk planning remains inexpensive, stable, and lossless. Retrieval results indicate D-RAC outperforms fixed-size parsing and matches or exceeds agentic chunking, especially on boundary-sensitive query types, with consistent performance across domains. Cost analysis further shows D-RAC reaches this quality at a fraction of agentic chunking cost by minimizing output tokens and avoiding prose regeneration.
D-RAC achieves the highest structure recovery and retrievability among the compared ingestion strategies while keeping chunking output costs very low and avoiding prose generation. It matches or exceeds agentic chunking on overall metrics even though it processes rendered PDF pages, and its planning-only re-chunking scales more efficiently than full regeneration. The approach is stable across domains and shows the largest quality gains on boundary-sensitive query types. D-RAC is the only strategy with high structure recovery, high retrievability, and high scalability to large page counts at the same time. Agentic chunking incurs high LLM output cost and some hallucination risk, while D-RAC reduces output to planning-only identifiers with very low to no hallucination surface. D-RAC matches or exceeds agentic chunking across all seven overall metrics despite working from rendered PDF pages, the hardest input format. The largest gains appear for temporal, comparative, and analytical queries, while boolean queries remain an edge case where agentic chunking retains an advantage.
The evaluated PDF subset spans five fictional enterprise domains and includes realistic table-heavy documents such as product sheets, FAQs, policy documents, parts catalogs, and service guides. D-RAC matches or exceeds agentic chunking on overall retrieval metrics while working directly from rendered PDF pages, with the largest gains on temporal, comparative, and analytical queries. Its planning stage also cuts output tokens and processing time substantially compared with agentic rewriting, while recall remains stable across domains. The evaluated subset spans five fictional enterprise domains, with banking and academia contributing the heaviest page loads and cloud services the lightest. The documents mirror realistic enterprise knowledge base content, including product sheets, FAQs, policy documents, parts catalogs, and service guides, with table-heavy layouts. D-RAC matches or exceeds agentic chunking on overall retrieval metrics despite working from rendered PDF pages rather than clean structured sources. Temporal, comparative, and analytical queries gain the most from topic-coherent chunk boundaries; boolean queries are the one area where agentic chunking remains ahead. Recall stays consistent across organizations, indicating the pipeline does not overfit to a particular document style. D-RAC's planning output is far smaller than agentic rewriting, so output token costs collapse and processing time drops substantially.
The evaluated query set spans seven categories designed to balance factual recall, reasoning, comparison, and procedural understanding. Procedural questions form the largest category, while temporal questions are the smallest. Retrieval gains from topic-coherent chunking are most pronounced for temporal, comparative, and analytical queries, though boolean queries remain the one category where agentic chunking retains an edge. Procedural queries form the largest category, followed by comparative and descriptive questions. Temporal queries are the smallest category but benefit most from topic-coherent chunk boundaries and row-level table prose. Boolean queries are the sole category where agentic chunking keeps an advantage over topic-coherent chunking.
Across five organizations, the corpus of 236 PDF documents and 795 pages converted into roughly one million characters of Markdown with zero errors. Average file conversion times ranged from about 12 to 22 seconds, and page-level throughput varied by organization, with Cendara University being the fastest per page and Velvera Technologies the slowest. Rendering overhead was minimal, with multimodal inference dominating conversion cost. All 236 documents converted without a single error, including parts catalogs, fee-schedule tables, and multi-column product sheets. Page rendering was negligible, while multimodal inference was the main driver of conversion time and scaled across parallel page batches.
Chunk planning covers every content element exactly once with zero chunking errors, and it remains inexpensive relative to conversion and agentic chunking because the planner outputs only ID arrays. Average chunk sizes stay within a stable, dense retriever friendly range across organizations without hard size limits. Planning cost is a small fraction of conversion time and much lower than agentic chunking, driven by minimal ID-only output. Chunk sizes remain stable and retriever-friendly across organizations, averaging between about 580 and 850 characters.
The experiments evaluate D-RAC against agentic and other chunking strategies on a table-heavy enterprise PDF corpus spanning five fictional domains and on a query set covering factual, procedural, comparative, temporal, and boolean questions. D-RAC validates that planning-only, identifier-based chunking recovers document structure most accurately, preserves retrievability, and scales to large page counts without prose generation or high LLM output cost. It matches or exceeds agentic chunking on overall retrieval quality even from rendered PDF pages, with the largest gains for temporal, comparative, and analytical queries and stable recall across domains, while boolean queries remain the one category where agentic chunking retains an edge. The pipeline also shows high reliability in practice, with error-free document conversion, negligible rendering overhead dominated by multimodal inference, and inexpensive zero-error chunk planning that yields stable retriever-friendly chunk sizes.