What is DLA (Document Layout Analysis)? A Summary of Core Technologies Determining RAG Preprocessing Quality and Retrieval Accuracy
DLA (Document Layout Analysis) is a core preprocessing technology that determines the success or failure of a RAG (Retrieval-Augmented Generation) system.
When an AI built on internal documents gives irrelevant answers, misreads figures in tables, or omits image information entirely, the cause is usually not the large language model (LLM). It’s because information is already lost during preprocessing—when documents are converted into a structure the AI can read. From chunking quality and retrieval accuracy to hallucination rates, I’ll walk you through, from a practical perspective, how DLA determines the outcome.
What is DLA?
DLA is a technology that doesn’t just extract text, but analyzes the positions and relationships of titles, body text, tables, images, and captions within a document. In other words, it is the process of identifying the structure and reading order of a document—much like organizing a book’s table of contents—and arranging it into a format that AI can utilize.
Definition and Core Concepts of DLA
The core of DLA is understanding a document not as a simple collection of characters, but as structured units of information. The same sentence or number can mean different things depending on whether it appears in a title, the body, or inside a table.
For example, if numbers from a table get mixed into the body text, the AI struggles to tell what those numbers describe. And if the title–body hierarchy disappears, content from different sections can blend together, undermining the evidence behind search results or answers.
That’s why DLA is a key preprocessing step that preserves the hierarchy and reading order of titles, body text, tables, images, and captions—so the document’s meaning remains intact through chunking, embedding, retrieval, and answer generation. Recent document parsing research (Document Parsing Unveiled, 2024) also describes parsing—converting unstructured documents into machine-readable representations—as an important preprocessing stage upstream of RAG.
How are OCR and DLA different?
OCR (Optical Character Recognition) is a technology that recognizes characters in images or documents and converts them into text. In contrast, DLA analyzes the structural context as well—what role the recognized text plays in the document, whether it’s a title or body text, table data, or an image description.
For example, OCR can read the number “95” in a table, but it’s hard to know whether that number is “2025 revenue” or a “customer satisfaction score.” DLA, on the other hand, identifies which table and which field the number belongs to, along with surrounding titles and body text, preserving the document’s meaning.
If OCR is about reading characters, DLA is about understanding a document’s structure and relationships. Extracting only text can flatten the structure of titles, tables, and lists and lose contextual information. But applying DLA helps preserve meaning more accurately through chunking, embedding, and retrieval. This is why, in RAG, using DLA alongside OCR is more advantageous for retrieval accuracy than OCR alone.

3 Reasons Why DLA Determines RAG Retrieval Accuracy
Preserving document hierarchy, restoring table structure, and structuring unstructured data are the core roles of DLA. This structural information is passed to chunking, embedding, and retrieval stages, determining the retrieval quality of a RAG system.
RAG chunking quality starts with preserving document hierarchy
For hierarchical chunking and semantic chunking to work properly, the document’s title/section/body hierarchy must be preserved first during parsing. If the hierarchy is lost, content from different topics may be bundled into a single chunk, or a single semantic unit may be split across multiple chunks. As a result, retrieval accuracy drops and answer quality can be affected.
Both semantic chunking and hierarchical chunking depend on the quality of DLA. That’s because titles, body text, and table structures must be analyzed accurately to preserve context and meaning during chunking. Research also shows that RAG systems with stronger structure awareness achieve higher answer accuracy than existing systems, and some studies report correctly answering about 47% more questions.
This issue is especially pronounced in Korean official documents. The indentation-based hierarchy typical of laws and reports is often not recognized properly by global general-purpose parsers. That’s why Hancom Data Loader separately embeds a Level inference engine that analyzes paragraph styles, indentation, and numbering schemes to automatically tag hierarchy levels.
Why TSR Restoration Reduces Errors in Numeric Queries
The moment a table is converted into flat text, row–column relationships are lost, and RAG starts producing wrong answers for numeric queries.
With simple parsing, merged cells and multi-level headers aren’t handled, causing the table structure to be lost. This is where AI begins referencing incorrect evidence and numeric query errors spike. It’s also why tables in financial reports and technical documents are considered a common failure point for RAG.
TSR (Table Structure Recognition) is the key technology that solves this problem. Hancom Data Loader recognizes borderless tables, merged cells, and even tables within tables (nested tables), and converts row/column structures at the cell level into Markdown.

What do you need to make image and chart information usable in RAG retrieval?
Images and charts cannot become retrieval targets in RAG through text extraction alone. Without contextual information, AI treats visual information as if it doesn’t exist.
With simple parsing, image and chart information is excluded from retrieval. Only when image context keyword extraction is performed together can answer quality be completed. This is why image captioning and contextual keyword extraction determine the completeness of answer quality.
Based on DLA, Hancom Data Loader recognizes images and charts as separate objects within a document and stores them separately. The image captioning feature, which generates natural-language captions by understanding the context and relationships of objects within images, is currently in the PoC stage, and the commercial release schedule will be announced later.
💡Want to connect everything from HWP·HWPX to PDFs and images to your RAG pipeline as-is, without conversion?
Text Extraction vs. DLA: What’s the Difference?
Simple text extraction only pulls characters, while DLA preserves the role, position, and relationships those characters have within the document. Whether this structural information is preserved is a key difference that determines retrieval accuracy and answer quality.
Simple Text Extraction vs. DLA
| Comparison Item | Simple Text Extraction | DLA |
| Table handling | Row/column relationships lost | Restores even merged cells |
| Paragraph hierarchy | Flat text | Preserves title/body/list hierarchy |
| Images/charts | Ignored or omitted | Object recognition and separate storage |
| Chunk quality | Semantic units break | Hierarchy-based splitting possible |
| RAG retrieval accuracy | Low | High |
| Hallucinations | Frequent | Minimized |
The SCAN study (Findings of ACL: EACL 2026) reports that RAG systems applying DLA improve text-based QA accuracy by up to 9.0% and QA accuracy leveraging visual information such as images and charts by up to 6.4%, compared to systems that do not apply it.
Hancom Data Loader is a document parsing solution that converts HWP·HWPX, PDF, and OOXML into structured data. Semantix is a technology that integrates DLA, OCR, TSR, and image captioning into a single pipeline, and Hancom Data Loader is a solution that includes Semantix internally.

Why do RAG hallucinations occur?
Most RAG hallucinations are not due to large language model (LLM) performance, but begin when information enters the pipeline already lost during document preprocessing.
Maintaining Document Structure to Reduce Hallucinations
If information is lost at the parser stage, incorrect chunks and retrieval results are generated, and hallucinations can occur during answer generation based on them. When the wrong chunks are created, the retrieval stage pulls irrelevant evidence, and then a sophisticated wrong answer is produced on top of it. Even if you swap models, you’re only more elaborately reconstructing the wrong input—often making it even harder to find the real cause.
Conversely, the more document structure is preserved, the more accurately the AI retrieves the right semantic units, reducing errors that use irrelevant information as evidence. Structure-preserving parsing → accurate chunking → accurate retrieval → minimized hallucinations—this flow is the key.
Criteria for Selecting a DLA Solution for Enterprise Document AI Utilization
When choosing a document parsing solution for an enterprise environment, you must verify four things: whether it can parse HWP·HWPX originals, supports on-premises deployment, outputs structured JSON/HTML, and can operate in network-segregated environments.
It must be able to process major domestic document formats, including HWP·HWPX, in their original form, and it should minimize structural loss by extracting directly from the original files without converting to PDF.
For public and financial institutions, you must confirm that it runs on-premises without external transmission in closed or network-segregated environments. You also can’t overlook whether the extracted results are output in JSON/HTML formats so they can be connected directly to a RAG pipeline.
Hancom Data Loader is a document parsing solution that meets all requirements: HWP·HWPX original parsing, fully embedded on-premises deployment, structured JSON/HTML output, and support for network-segregated environments.

Why global parsing solutions don’t fit Korean enterprise RAG
It’s well known that DLA determines RAG quality. However, in Korean enterprise environments, there are practical constraints like the following that are difficult to solve with global general-purpose solutions alone.
First, most global enterprise document parsing APIs only support general-purpose formats such as PDF, JPEG, PNG, and TIFF, and do not support direct parsing of original HWP or HWPX files. If HWP/HWPX files are processed after being converted to PDF, hierarchy and table structures are lost, leading to a decline in RAG quality.
Second, cloud API approaches cannot be used in closed or network-segregated environments of public, financial, and legal institutions by design.
Third, the hierarchical structure unique to Korean official documents is often outside the training scope of global DLA models. Reflecting these characteristics, the government is also converting public documents to an open HWPX system that AI can read. Central government ministries have already mandated HWPX use in the Onnara System since 2022, and starting May 18, 2026, the same standard will be expanded to local government Onnara Systems as well.
Hancom Data Loader is a solution that satisfies all three requirements: HWP original parsing, on-premises security, and Korean document structure recognition.
✅ Directly parses HWP·HWPX originals based on the HWP SDK
✅ Fully embeds on-premises document parsing via a Docker REST API
✅ Uses a Level inference engine optimized for Korean official documents
✅ Hancom Data Loader holds GS certification
If you need accurate HWP·HWPX original parsing, get started with Hancom Data Loader.
👉 Go use the Hancom Data Loader live demo
👉 Inquire About Hancom Data Loader

DLA Frequently Asked Questions
Can I use HWP·HWPX files directly in a RAG pipeline?
General-purpose frameworks such as LangChain and LlamaIndex do not natively support the HWP·HWPX format. If you convert to PDF and process it, structure is lost, so you need a solution that supports HWP SDK-based original parsing. Hancom Data Loader provides a REST API for integration with external RAG frameworks, and with JSON output that preserves the original HWP·HWPX structure, you can connect it directly to your RAG pipeline.
What problems occur if RAG is built without DLA?
If RAG is built without DLA, text is flattened, and the hierarchy of titles, tables, and images is entirely lost. Chunks are cut without regard for semantic units, and hallucinations surge as the retrieval stage pulls irrelevant evidence. In particular, table data is listed as just numbers with row-column relationships lost, leading to high error rates in numeric queries. Even if the LLM is replaced, the same errors will repeat if preprocessing quality is low, making it harder to find the root cause.
Can we adopt a Document Layout Analysis solution even in network-segregated or closed-network environments?
Cloud API-based parsing solutions fundamentally cannot be used in the closed-network or network-separated environments of public, financial, and legal institutions. A solution that supports on-premises document parsing is required, and Hancom Data Loader can be operated without an external network by being fully internalized into the customer’s internal server in the form of a Docker REST API. With a structure optimized for the network-separated environments of public institutions and financial firms, its adoption is proven even in public procurement environments through its GS certification.
References
- Lewis et al., “Retrieval-Augmented Generation for Knowledge-Intensive NLP Tasks”, NeurIPS 2020
- Lin, “Revolutionizing RAG with Enhanced PDF Structure Recognition”, arXiv:2401.12599
- Zhang et al., “Document Parsing Unveiled: Techniques, Challenges, and Prospects”, arXiv:2410.21169
- Ueda et al., “SCAN: Semantic Document Layout Analysis for Textual and Visual Retrieval-Augmented Generation”, Findings of ACL: EACL 2026
- AWS, “What is Retrieval-Augmented Generation (RAG)?”
- IBM, “What is RAG (Retrieval-Augmented Generation)?”
- Supported document formats for AWS Textract
- Supported formats for Azure Document Intelligence
- Supported file types for Google Document AI
- Danbinews, “Korean documents can’t be read by AI?”, 2026.02.01
- Yonhap News, “Mandatory conversion of public documents to HWPX”, 2026.04.23