Skip to main content
QUICK REVIEW

[论文解读] DOM-LM: Learning Generalizable Representations for HTML Documents

Xiang Deng, Prashant Shiralkar|arXiv (Cornell University)|Jan 25, 2022
Web Data Mining and Analysis被引用 9
一句话总结

DOM-LM 提出了一种基于 Transformer 的自监督表示学习模型,用于 HTML 文档,通过联合编码文本和 DOM 树结构,捕捉语义和结构语义。在属性提取、开放信息抽取和问答任务中,其性能优于现有方法,尤其在少样本和零样本设置下表现突出,展现出在真实网络应用中的强大泛化能力。

ABSTRACT

HTML documents are an important medium for disseminating information on the Web for human consumption. An HTML document presents information in multiple text formats including unstructured text, structured key-value pairs, and tables. Effective representation of these documents is essential for machine understanding to enable a wide range of applications, such as Question Answering, Web Search, and Personalization. Existing work has either represented these documents using visual features extracted by rendering them in a browser, which is typically computationally expensive, or has simply treated them as plain text documents, thereby failing to capture useful information presented in their HTML structure. We argue that the text and HTML structure together convey important semantics of the content and therefore warrant a special treatment for their representation learning. In this paper, we introduce a novel representation learning approach for web pages, dubbed DOM-LM, which addresses the limitations of existing approaches by encoding both text and DOM tree structure with a transformer-based encoder and learning generalizable representations for HTML documents via self-supervised pre-training. We evaluate DOM-LM on a variety of webpage understanding tasks, including Attribute Extraction, Open Information Extraction, and Question Answering. Our extensive experiments show that DOM-LM consistently outperforms all baselines designed for these tasks. In particular, DOM-LM demonstrates better generalization performance both in few-shot and zero-shot settings, making it attractive for making it suitable for real-world application settings with limited labeled data.

研究动机与目标

  • 为解决现有方法将 HTML 文档视为纯文本或依赖计算成本较高的视觉渲染所导致的局限性。
  • 学习可泛化的表示,以捕捉来自 DOM 树的文本内容和结构语义。
  • 在极少标注数据的情况下,提升属性提取、开放信息抽取和问答等下游任务的性能。
  • 在标注数据有限的真实网络应用中,实现有效的少样本和零样本泛化。
  • 通过学习上下文化的树表示,克服先前树编码模型中基于启发式方法的上下文构建的不足。

提出的方法

  • DOM-LM 使用 Transformer 编码器联合编码标记和 DOM 树节点,通过多种位置嵌入引入结构信息。
  • 在预训练过程中,通过掩码单个标记和整个 DOM 节点,应用自监督的掩码语言建模(MLM)目标。
  • 通过滑动窗口机制处理 DOM 树,以保留相关的结构上下文,在每一步中修剪旧节点并添加新节点。
  • 位置嵌入被设计用于建模 DOM 树内的层次和顺序关系,从而实现结构感知的表示学习。
  • 最终的节点和标记表示在下游任务(如属性提取、OpenIE 和问答)上进行微调。
  • 该方法直接使用原始 HTML 源码,避免了渲染过程,因此相比视觉特征提取,更加高效且可扩展。

实验结果

研究问题

  • RQ1与仅使用文本或基于视觉的基线相比,自监督且具备结构感知能力的表示模型是否能提升 HTML 文档理解任务的性能?
  • RQ2在少样本或零样本设置下,基于多样化 HTML 文档预训练的模型在未见过的网站上能实现多大程度的泛化?
  • RQ3对文本和 DOM 树结构进行联合建模,在半结构化网络内容中能否有效捕捉语义和句法关系?
  • RQ4在 Transformer 编码器中使用结构化位置嵌入,是否能比基于启发式的方法检索上下文,带来更好的 DOM 节点上下文表示?
  • RQ5该模型是否能在不依赖渲染视觉特征的情况下,优于现有方法在属性提取和问答等任务中的表现?

主要发现

  • DOM-LM 在属性提取、开放信息抽取和问答任务中,始终优于所有基线模型。
  • 该模型在少样本和零样本设置下展现出卓越的泛化能力,表明其对未见过的网站和模板具有强大的迁移能力。
  • 通过联合编码文本和结构,DOM-LM 捕获了仅使用原始文本时会丢失的元素间关系。
  • 通过掩码节点和标记的自监督预训练,模型学习到鲁棒且可泛化的表示,无需依赖标注数据。
  • DOM-LM 在避免渲染或存储视觉特征的计算开销的同时,实现了最先进(SOTA)的性能。
  • 在低资源场景下,该模型的性能提升尤为显著,验证了其在标注数据有限的真实应用中的适用性。

更好的研究,从现在开始

从阅读论文到最终审阅,大幅缩短您的研究时间。

无需绑定信用卡

本解读由 AI 生成,并经人工编辑审核。