We introduce CogRE, a novel framework for relation extraction (RE), enhancing RE from both accuracy and explainability. The framework has two key components: (i) a reasoning mechanism that formulates relation extraction as a series of text-processing steps inspired by cognitive science, and (ii) an optimization process driven by a novel reinforcement learning (RL) reward function. Our framework introduces relation keywords and rewards generating such keywords using an automatically constructed keywords dictionary. This design addresses the lack of language-based explanations in traditional RE and provides supervision for explanation during RL training. Our experiments show that CogRE improves explanation quality by addressing two common failure patterns in one-shot RE: poor attention focus and limited one-shot learning capability. For example, our cognitive-structured reasoning with Qwen2.5-15B-Instruct on One-shot NYT29 achieves 24.65% F1, surpassing prior reasoning-based designs. Optimizing this approach with RL using our reward further improves performance by +23.46% (absolute). Further, models trained on NYT29 with our reward achieve a +16.9% F1 gain on out-of-distribution WIKIDATA. Finally, human evaluation shows that our best model generates relational keywords closely aligned with gold labels, increasing human explanation quality ratings by 54% (relative).
翻译:我们提出CogRE,一种新颖的关系抽取框架,从准确性和可解释性两方面增强关系抽取。该框架包含两个关键组件:(i) 受认知科学启发的推理机制,将关系抽取形式化为一系列文本处理步骤;(ii) 由新型强化学习奖励函数驱动的优化过程。本框架引入关系关键词,并通过自动构建的关键词词典奖励生成此类关键词。该设计解决了传统关系抽取中缺乏基于语言的解释的问题,并在强化学习训练期间为解释提供监督。实验表明,CogRE通过解决单样本关系抽取中两种常见失效模式——注意力聚焦不良和单样本学习能力有限——提升了解释质量。例如,我们基于Qwen2.5-15B-Instruct的认知结构化推理在One-shot NYT29数据集上达到24.65%的F1值,超越了先前基于推理的设计。使用我们的奖励函数通过强化学习优化该方法,性能进一步提升了+23.46%(绝对值)。此外,在NYT29数据集上使用我们的奖励函数训练的模型,在分布外数据集WIKIDATA上实现了+16.9%的F1增益。最后,人工评估表明,我们的最佳模型生成的关系关键词与黄金标注高度吻合,将人工解释质量评分提升了54%(相对值)。