[论文解读] Transformer-Based Neural Text Generation with Syntactic Guidance
本文提出GuiG,一种基于Transformer的文本生成模型,利用部分成分句法解析树作为句法引导,以提升可控 paraphrasing 效果。通过引入路径注意力机制以增强对树结构的感知,并采用多编码器注意力机制整合源文本与句法输入,GuiG 实现了最先进性能,BLEU得分从11.83提升至26.27,在语义与句法质量方面均显著优于先前方法。
We study the problem of using (partial) constituency parse trees as syntactic guidance for controlled text generation. Existing approaches to this problem use recurrent structures, which not only suffer from the long-term dependency problem but also falls short in modeling the tree structure of the syntactic guidance. We propose to leverage the parallelism of Transformer to better incorporate parse trees. Our method first expands a partial template constituency parse tree to a full-fledged parse tree tailored for the input source text, and then uses the expanded tree to guide text generation. The effectiveness of our model in this process hinges upon two new attention mechanisms: 1) a path attention mechanism that forces one node to attend to only other nodes located in its path in the syntax tree to better incorporate syntax guidance; 2) a multi-encoder attention mechanism that allows the decoder to dynamically attend to information from multiple encoders. Our experiments in the controlled paraphrasing task show that our method outperforms SOTA models both semantically and syntactically, improving the best baseline's BLEU score from 11.83 to 26.27.
研究动机与目标
- 为解决循环神经网络在文本生成过程中难以捕捉树状句法引导结构的局限性。
- 通过利用从部分模板扩展出的完整句法解析树,提升可控文本生成效果。
- 通过结构化的句法约束,增强生成文本的语义与句法对齐性。
- 设计更优的注意力机制,以更好地建模成分树中的层次句法依赖关系。
提出的方法
- 该模型首先利用句法展开模块,将部分模板成分句法解析树扩展为与输入源文本相匹配的完整句法解析树。
- 路径注意力机制限制每个节点的注意力仅作用于其在解析树中的祖先与后代节点,从而强化对层次句法结构的感知。
- 多编码器注意力机制使解码器能够动态关注来自源文本编码器与句法树编码器的表示。
- 句法展开模块与文本生成模块均基于Transformer架构构建,利用自注意力机制建模长距离依赖关系。
- 将句法解析树线性化为紧凑的节点级格式,以提升在Transformer框架内的处理效率。
- 模型在可控paraphrasing任务上进行端到端训练,同时接受语义与句法监督。
实验结果
研究问题
- RQ1与循环模型相比,基于Transformer的架构在文本生成中是否能更有效地建模树状句法引导?
- RQ2路径注意力在序列生成过程中是否能有效保持句法层次结构?
- RQ3多编码器注意力在多源信息融合方面能提升多少语义与句法信息的整合效果?
- RQ4将部分句法模板扩展为完整解析树,是否能带来更优的句法控制与语义保真度?
- RQ5所提方法在自动评估与人工评估指标上,与SOTA模型相比表现如何?
主要发现
- GuiG在可控paraphrasing任务上将最佳基线模型的BLEU得分从11.83提升至26.27。
- 与SOTA模型SCPN相比,该模型在句法质量上提升6.7%,在语义质量上提升122.1%。
- 人工评估显示,与基线相比,语义得分提升1.13分,句法得分提升0.62分。
- 消融实验表明,路径注意力机制对语义性能有显著贡献,而多编码器注意力则增强了模型处理多源输入的能力。
- 该模型能有效泛化至常见句法模板,生成语义一致且具有相似高层句法结构的句子。
- 句法展开模块能有效生成与源输入语义一致的完整句法解析树,从而实现精确的句法控制。
更好的研究,从现在开始
从阅读论文到最终审阅,大幅缩短您的研究时间。
无需绑定信用卡
本解读由 AI 生成,并经人工编辑审核。