Large language models, prompted with in-context examples, can perform semantic parsing with little training data. They do better when we formulate the problem as paraphrasing into canonical utterances, which cast the underlying meaning representations into a controlled natural language-like representation. Intuitively, such models can more easily output canonical utterances as they are closer to the natural language used for pre-training. More recently, models also pre-trained on code, like OpenAI Codex, have risen in prominence. Since accurately modeling code requires understanding of executable semantics. such models may prove more adept at semantic parsing. In this paper, we test this hypothesis and find that Codex performs better at semantic parsing than equivalent GPT-3 models. We find that unlike GPT-3, Codex performs similarly when targeting meaning representations directly, perhaps as meaning representations used in semantic parsing are structured similar to code.
翻译:大语言模型,以内文本实例推导,可以使用少量培训数据进行语义分析。当我们将问题表述为可移植语句时,它们效果更好,因为我们将问题表述为可移植语句,将基本含义表述转化为受控制的自然语言相似的表达方式。直观地说,这些模型可以更容易地输出直截了当的语句,因为它们更接近用于培训前的自然语言。最近,类似 OpenAI Codex 等在代码方面受过预先训练的模型也越来越突出。由于精确的建模代码需要理解可执行的语义。这些模型可能更适合语义表达方式。在本文中,我们测试了这个假设,发现 Codex在语义表达方式上的表现比等同的GPT-3 模式要好。我们发现,与GPT-3, 代码在直接针对表达方式时表现得相似,也许因为语义表达方式所使用的意思与代码相似。