Large Language Models (LLMs) have achieved remarkable success in many formal language oriented tasks, such as structural data-to-text and semantic parsing. However current benchmarks mostly follow the data distribution of the pre-training data of LLMs. Therefore, a natural question rises that do LLMs really understand the structured semantics of formal languages. In this paper, we investigate this problem on a special case, converse binary relation. We introduce a new benchmark ConvRe focusing on converse relations, which contains 17 relations and 1240 triples extracted from popular knowledge graph completion datasets. Our ConvRE features two tasks, Re2Text and Text2Re, which are formulated as multi-choice question answering to evaluate LLMs' ability to determine the matching between relations and associated text. For the evaluation protocol, apart from different prompting methods, we further introduce variants to the test text and few-shot example text. We conduct experiments on three popular LLM families and have observed various scaling trends. The results suggest that LLMs often resort to shortcut learning and still face challenges on our proposed benchmark.
翻译:大语言模型(LLMs)在诸多面向形式语言的任务中取得了显著成功,例如结构化数据到文本的生成与语义解析。然而,当前基准测试大多遵循LLMs预训练数据的数据分布。因此,一个自然而然的疑问是:LLMs是否真正理解形式语言的结构化语义?本文以逆二元关系为特例,系统研究了该问题。我们提出了聚焦逆关系的新基准ConvRe,该基准包含从主流知识图谱补全数据集中提取的17种关系及1240个三元组。ConvRe设计了两项任务(Re2Text与Text2Re),通过多项选择问答形式评估LLMs在关系与对应文本间进行匹配的能力。在评估方案上,除采用不同提示方法外,我们还对测试文本和少样本示例文本引入了变体。我们在三个主流LLM系列上进行了实验,观察到多种扩展趋势。结果表明,LLMs常依赖于捷径学习,并在我们提出的基准上仍面临挑战。