Language models (LMs) often generate incoherent outputs: they refer to events and entity states that are incompatible with the state of the world described in their inputs. We introduce SituationSupervision, a family of approaches for improving coherence in LMs by training them to construct and condition on explicit representations of entities and their states. SituationSupervision has two components: an auxiliary situation modeling task that trains models to predict state representations in context, and a latent state inference procedure that imputes these states from partially annotated training data. SituationSupervision can be applied to both fine-tuning (by supervising LMs to encode state variables in their hidden representations) and prompting (by inducing LMs to interleave textual descriptions of entity states with output text). In both cases, SituationSupervision requires only a small number of state annotations to produce major coherence improvements (between 4-11%), showing that standard LMs can be sample-efficiently trained to model not just language but the situations it describes.
translated by 谷歌翻译
We describe PromptBoosting, a query-efficient procedure for building a text classifier from a neural language model (LM) without access to the LM's parameters, gradients, or hidden representations. This form of "black-box" classifier training has become increasingly important as the cost of training and inference in large-scale LMs grows. But existing black-box LM classifier learning approaches are themselves computationally inefficient, typically specializing LMs to the target task by searching in a large space of (discrete or continuous) prompts using zeroth-order optimization methods. Instead of directly optimizing in prompt space, PromptBoosting obtains a small pool of prompts via a gradient-free approach and then constructs a large pool of weak learners by pairing these prompts with different elements of the LM's output distribution. These weak learners are then ensembled using the AdaBoost algorithm. The entire learning process requires only a small number of forward passes and no backward pass. Experiments show that PromptBoosting achieves state-of-the-art performance in multiple black-box few-shot classification tasks, and matches or outperforms full fine-tuning in both few-shot and standard learning paradigms, while training 10x faster than existing black-box methods.
translated by 谷歌翻译
Language models (LMs) are trained on collections of documents, written by individual human agents to achieve specific goals in an outside world. During training, LMs have access only to text of these documents, with no direct evidence of the internal states of the agents that produced them -- a fact often used to argue that LMs are incapable of modeling goal-directed aspects of human language production and comprehension. Can LMs trained on text learn anything at all about the relationship between language and use? I argue that LMs are models of intentional communication in a specific, narrow sense. When performing next word prediction given a textual context, an LM can infer and represent properties of an agent likely to have produced that context. These representations can in turn influence subsequent LM generation in the same way that agents' communicative intentions influence their language. I survey findings from the recent literature showing that -- even in today's non-robust and error-prone models -- LMs infer and use representations of fine-grained communicative intentions and more abstract beliefs and goals. Despite the limited nature of their training data, they can thus serve as building blocks for systems that communicate and act intentionally.
translated by 谷歌翻译
Neural sequence models, especially transformers, exhibit a remarkable capacity for in-context learning. They can construct new predictors from sequences of labeled examples $(x, f(x))$ presented in the input without further parameter updates. We investigate the hypothesis that transformer-based in-context learners implement standard learning algorithms implicitly, by encoding smaller models in their activations, and updating these implicit models as new examples appear in the context. Using linear regression as a prototypical problem, we offer three sources of evidence for this hypothesis. First, we prove by construction that transformers can implement learning algorithms for linear models based on gradient descent and closed-form ridge regression. Second, we show that trained in-context learners closely match the predictors computed by gradient descent, ridge regression, and exact least-squares regression, transitioning between different predictors as transformer depth and dataset noise vary, and converging to Bayesian estimators for large widths and depths. Third, we present preliminary evidence that in-context learners share algorithmic features with these predictors: learners' late layers non-linearly encode weight vectors and moment matrices. These results suggest that in-context learning is understandable in algorithmic terms, and that (at least in the linear case) learners may rediscover standard estimation algorithms. Code and reference implementations are released at https://github.com/ekinakyurek/google-research/blob/master/incontext.
translated by 谷歌翻译
When trained on language data, do transformers learn some arbitrary computation that utilizes the full capacity of the architecture or do they learn a simpler, tree-like computation, hypothesized to underlie compositional meaning systems like human languages? There is an apparent tension between compositional accounts of human language understanding, which are based on a restricted bottom-up computational process, and the enormous success of neural models like transformers, which can route information arbitrarily between different parts of their input. One possibility is that these models, while extremely flexible in principle, in practice learn to interpret language hierarchically, ultimately building sentence representations close to those predictable by a bottom-up, tree-structured model. To evaluate this possibility, we describe an unsupervised and parameter-free method to \emph{functionally project} the behavior of any transformer into the space of tree-structured networks. Given an input sentence, we produce a binary tree that approximates the transformer's representation-building process and a score that captures how "tree-like" the transformer's behavior is on the input. While calculation of this score does not require training any additional models, it provably upper-bounds the fit between a transformer and any tree-structured approximation. Using this method, we show that transformers for three different tasks become more tree-like over the course of training, in some cases unsupervisedly recovering the same trees as supervised parsers. These trees, in turn, are predictive of model behavior, with more tree-like models generalizing better on tests of compositional generalization.
translated by 谷歌翻译
在现实世界中的对话系统中,生成的响应必须满足几个互锁的限制:内容丰富,真实且易于控制。语言生成中的两个主要范式 - 神经语言建模和基于规则的一代 - 都难以满足这些约束。即使是最好的神经模型,也容易出现信息的幻觉和省略,而现有的基于规则的形式的形式使得很难编写既灵活又流利的语法。我们描述了对话响应产生的混合体系结构,结合了两种方法的优势。该体系结构有两个组件。首先,使用新的正式框架定义的基于规则的内容选择模型,称为数据流转导,该模型使用声明性规则将对话代理的计算(表示为数据流图)转换为代表上下文可接受响应空间的无上下文语法。其次,使用这些语法来限制神经语言模型的输出的受约束解码过程,该过程选择流利的话语。最终的系统在人类对流利,相关性和真实性的评估中的表现都优于基于规则的方法和学识渊博的方法。
translated by 谷歌翻译
语言模型既展示了定量的改进,又展示了新的定性功能,随着规模的增加。尽管它们具有潜在的变革性影响,但这些新能力的特征却很差。为了为未来的研究提供信息,为破坏性的新模型能力做准备,并改善社会有害的效果,至关重要的是,我们必须了解目前和近乎未来的能力和语言模型的局限性。为了应对这一挑战,我们介绍了超越模仿游戏基准(Big Bench)。 Big Bench目前由204个任务组成,由132家机构的442位作者贡献。任务主题是多样的,从语言学,儿童发展,数学,常识性推理,生物学,物理学,社会偏见,软件开发等等。 Big-Bench专注于被认为超出当前语言模型的功能的任务。我们评估了OpenAI的GPT型号,Google内部密集变压器体系结构和大型基础上的开关稀疏变压器的行为,跨越了数百万到数十亿个参数。此外,一个人类专家评估者团队执行了所有任务,以提供强大的基准。研究结果包括:模型性能和校准都随规模改善,但绝对的术语(以及与评估者的性能相比);在模型类中的性能非常相似,尽管带有稀疏性。逐渐和预测的任务通常涉及大量知识或记忆成分,而在临界规模上表现出“突破性”行为的任务通常涉及多个步骤或组成部分或脆性指标;社交偏见通常会随着含糊不清的环境而随着规模而增加,但这可以通过提示来改善。
translated by 谷歌翻译
考虑到人类行为的例子,我们考虑在多种代理决策问题中建立强大但人类的政策的任务。仿制学习在预测人类行为方面有效,但可能与专家人类的实力不符,而自助学习和搜索技术(例如,alphakero)导致强大的性能,但可能会产生难以理解和协调的政策。我们在国际象棋中显示,并通过应用Monte Carlo树搜索产生具有更高人为预测准确性的策略并比仿制政策更强大的kl差异,基于kl发散的正规化搜索策略。然后我们介绍一种新的遗憾最小化算法,该算法基于来自模仿的政策的KL发散规范,并显示将该算法应用于无按压外交产生的策略,使得在基本上同时保持与模仿学习相同的人类预测准确性的策略更强。
translated by 谷歌翻译
当一个神经语言模型(LM)适于执行新任务时,任务的哪些方面预测了模型的最终性能?在NLP中,LM概括到个别示例的系统特征很好,但LM对新任务的系统的系统性方面并不理解。我们使用500个程序生成的序列建模任务构建的新基准测试,展示了LM适应性的特性和限制的大规模实证研究。这些任务组合了语言处理的核心方面,包括词汇语义,序列处理,记忆,逻辑推理和世界知识。使用TaskBench500,我们评估了三个适应性的方面,发现:(1)适应程序在他们记忆小型数据集的能力中急剧差异; (2)在任务类型的子集中,适应程序表现出对复杂任务的组成适应性; (3)未能匹配培训标签分布,在预测个别标签的内在难度中解释了不匹配。我们的实验表明,可以系统地描述和理解新的任务,如新示例的泛化,以及讨论可以使用新基准研究的适应性的其他方面的结论。
translated by 谷歌翻译
乳腺癌是女性最常见的恶性肿瘤,每年负责超过50万人死亡。因此,早期和准确的诊断至关重要。人类专业知识是诊断和正确分类乳腺癌并定义适当的治疗,这取决于评价不同生物标志物如跨膜蛋白受体HER2的表达。该评估需要几个步骤,包括免疫组织化学或原位杂交等特殊技术,以评估HER2状态。通过降低诊断中的步骤和人类偏差的次数的目标,赫洛挑战是组织的,作为第16届欧洲数字病理大会的并行事件,旨在自动化仅基于苏木精和曙红染色的HER2地位的评估侵袭性乳腺癌的组织样本。评估HER2状态的方法是在全球21个团队中提出的,并通过一些提议的方法实现了潜在的观点,以推进最先进的。
translated by 谷歌翻译