Information Extraction from Tree Documents by Learning Subtree Delimiters

Boris ChidlovskiiIIWeb 2003

Introduction

Traditional wrapper induction systems often treat HTML documents as flat sequences of tokens, relying on string-based delimiters to identify data fields. However, as web content becomes increasingly structured and nested, these one-dimensional approaches struggle to capture the necessary context for accurate extraction. This paper proposes a shift toward tree-based extraction, leveraging the inherent hierarchical structure of modern web documents to define more robust "subtree delimiters."

Methodology: From Strings to Trees

Tree Encoding and Binary Conversion

To handle the "unranked" nature of HTML—where a single node can have an arbitrary number of children—the authors first convert document trees into a binary format. This simplification preserves adjacency and hierarchical relationships while streamlining the processing logic.

Figure 2: Conversion of a standard HTML tree (a) into a binary tree structure (b) to facilitate path-based extraction.

Subtree Delimiters and Path Indexing

The core innovation lies in the use of simple path delimiters. Instead of looking for tags immediately preceding or following a data point, the system identifies paths that traverse from a leaf node up through its ancestors and horizontally to its siblings.

To manage these paths efficiently, the authors introduce a Candidate Path Index implemented as a trie. This structure stores "reverse paths" from annotated data points, allowing the system to incrementally learn and identify the most discriminative structural landmarks for specific data types, such as authors, titles, or page numbers.

Figure 5: The Candidate Path Index (trie) structure, showing how 'Up' and 'Right' traversals are used to calculate confidence scores for different labels.

Classification Logic

Extraction is performed by traversing the document tree and querying the Candidate Path Index. For each leaf node, the system evaluates the confidence of associated path delimiters and assigns the label with the highest statistical support.

Experimental Evaluation

The approach was tested using the XRCE Iwrap toolkit across 20 websites categorized by structural complexity.

  • Easy Sites (14): Major portals like Google and DBLP where data is relatively shallow.
  • Complex Sites (6): Intricate bibliographic and medical databases (e.g., IEEE, Medline) where nested structures are common.

Performance Comparison

The results demonstrate a significant advantage for tree-based methods on complex documents:

Site Category Wrapper Type Precision Recall Time Ratio (Tree/String)
Easy String 100% 98.8% 1.0
Tree 99.8% 99.1% 2.06
Complex String 89.6% 84.3% 1.0
Tree 96.3% 92.6% 3.21

While tree wrappers are approximately 2 to 3 times slower due to the overhead of verifying multiple structural paths, they provide a substantial boost in precision and recall for difficult-to-parse layouts.

Key Insights

  1. Structural Evolution: Analysis of web trends indicates that HTML is becoming "cleaner" and more deeply nested, making tree-based extraction both more viable and more necessary than in the past.
  2. Dimensional Advantage: Path delimiters capture structural patterns in a "two-dimensional" space (vertical hierarchy and horizontal adjacency) that are invisible to flat string parsers.
  3. Local Context, Global Power: By using the tree hierarchy, the model achieves the efficiency of local extraction while benefiting from the expressive power of global structural models.

Conclusion and Future Work

The transition from string delimiters to subtree delimiters marks a significant step forward in web data extraction. Future research will focus on optimizing the processing speed of tree wrappers and exploring more complex subtree shapes beyond simple paths to further improve accuracy on highly irregular documents.

Summary updated

BibTeX
@inproceedings{chidlovskii2003information,
  author = {Boris Chidlovskii},
  title = {{Information Extraction from Tree Documents by Learning Subtree Delimiters}},
  booktitle = {IIWeb},
  year = {2003},
}
Figure