Layout-Aware Document Parsing and Knowledge Graph Extraction
Abstract
The problem of parsing heterogeneous PDF documents is still unresolved because of the use of complex layouts, embedded watermarks, and the disposition of the current systems to generate incoherent knowledge graphs (KGs) consisting of hundreds of nodes that are loosely connected and do not contribute a lot to education. Current solutions are based on extensive outside APIs and large language models that generate token-level graphs that cannot be read by humans or annotated by students or subjected to downstream reasoning tests. In response to this, we develop a document parsing and knowledge graph extraction system as a fully offline system, which transforms raw PDF documents into clean, concept-based KGs that are aligned with the way students and educators approach and edit documents naturally. The system recognizes document structure, eliminates visual noise, extracts text in any region and a new algorithm of graph extraction which harvests meaningful concepts, resolves surface-form variants, assigns semantic roles and deduces typed relations with complete provenance to the source sentences. The resultant graphs are much smaller, denser, free of isolated concepts, and entirely readable connections, which can be traced to the original document. The system is fully implemented on commodity hardware and does not rely on any external components and generates interactive visual representations that facilitate the educational revision processes, which show significant increase in the graphic compactness and interpretability as compared to the traditional token-based extraction strategies.