arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2305.14221cs.CL
收藏

将问答视为编程以解决时间敏感问题

Question Answering as Programming for Solving Time-Sensitive Questions

Shenzhen International Graduate School, Tsinghua University(清华大学深圳国际研究生院);Microsoft(微软)

Xinyu Zhu, Cheng Yang, Bei Chen, Siheng Li, Jian-Guang Lou, Yujiu Yang

AI总结:

针对LLMs因无法基于表层语义进行严格推理而难以解决时间敏感问答的问题,提出QAaP框架,将问答任务转化为编程任务,通过生成结构化代码从候选答案中选择最佳匹配项,在多个数据集上取得显著提升。

摘要:

问答在人类日常生活中扮演着关键角色,因为它涉及我们对世界知识的获取。然而,由于现实世界事实的动态变化特性,当问题中的时间约束发生改变时,答案可能完全不同。最近,大型语言模型(LLMs)在问答中展现出了卓越的智能,但我们的实验表明,上述问题仍然对现有的LLMs构成了重大挑战。这可以归因于LLMs无法基于表层文本语义进行严格的推理。为了克服这一局限性,我们不再要求LLMs直接回答问题,而是提出了一种新方法,将问答任务重新转化为编程(QAaP)。具体而言,通过利用现代LLMs在理解自然语言和编程语言方面的卓越能力,我们努力引导LLMs将多样化表达的文本表示为结构良好的代码,并通过编程从多个候选答案中选择最佳匹配项。我们在几个时间敏感问答数据集上评估了我们的QAaP框架,并取得了显著的改进,比强基线高出14.5%。我们的代码和数据可在 https://github.com/TianHongZXY/qaap 获取。

英文摘要:

Question answering plays a pivotal role in human daily life because it involves our acquisition of knowledge about the world. However, due to the dynamic and ever-changing nature of real-world facts, the answer can be completely different when the time constraint in the question changes. Recently, Large Language Models (LLMs) have shown remarkable intelligence in question answering, while our experiments reveal that the aforementioned problems still pose a significant challenge to existing LLMs. This can be attributed to the LLMs' inability to perform rigorous reasoning based on surface-level text semantics. To overcome this limitation, rather than requiring LLMs to directly answer the question, we propose a novel approach where we reframe the $\textbf{Q}$uestion $\textbf{A}$nswering task $\textbf{a}$s $\textbf{P}$rogramming ($\textbf{QAaP}$). Concretely, by leveraging modern LLMs' superior capability in understanding both natural language and programming language, we endeavor to harness LLMs to represent diversely expressed text as well-structured code and select the best matching answer from multiple candidates through programming. We evaluate our QAaP framework on several time-sensitive question answering datasets and achieve decent improvement, up to $14.5$% over strong baselines. Our codes and data are available at https://github.com/TianHongZXY/qaap

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑