小程序
传感搜
传感圈

How AI Knows Things No One Told It

2023-05-18 13:14:06
关注

No one yet knows how ChatGPT and its artificial intelligence cousins will transform the world, and one reason is that no one really knows what goes on inside them. Some of these systems’ abilities go far beyond what they were trained to do—and even their inventors are baffled as to why. A growing number of tests suggest these AI systems develop internal models of the real world, much as our own brain does, though the machines’ technique is different.

“Everything we want to do with them in order to make them better or safer or anything like that seems to me like a ridiculous thing to ask ourselves to do if we don’t understand how they work,” says Ellie Pavlick of Brown University, one of the researchers working to fill that explanatory void.

At one level, she and her colleagues understand GPT (short for generative pretrained transformer) and other large language models, or LLMs, perfectly well. The models rely on a machine-learning system called a neural network. Such networks have a structure modeled loosely after the connected neurons of the human brain. The code for these programs is relatively simple and fills just a few screens. It sets up an autocorrection algorithm, which chooses the most likely word to complete a passage based on laborious statistical analysis of hundreds of gigabytes of Internet text. Additional training ensures the system will present its results in the form of dialogue. In this sense, all it does is regurgitate what it learned—it is a “stochastic parrot,” in the words of Emily Bender, a linguist at the University of Washington. But LLMs have also managed to ace the bar exam, explain the Higgs boson in iambic pentameter, and make an attempt to break up their users’ marriage. Few had expected a fairly straightforward autocorrection algorithm to acquire such broad abilities.

That GPT and other AI systems perform tasks they were not trained to do, giving them “emergent abilities,” has surprised even researchers who have been generally skeptical about the hype over LLMs. “I don’t know how they’re doing it or if they could do it more generally the way humans do—but they’ve challenged my views,” says Melanie Mitchell, an AI researcher at the Santa Fe Institute.

“It is certainly much more than a stochastic parrot, and it certainly builds some representation of the world—although I do not think that it is quite like how humans build an internal world model,” says Yoshua Bengio, an AI researcher at the University of Montreal.

At a conference at New York University in March, philosopher Raphaël Millière of Columbia University offered yet another jaw-dropping example of what LLMs can do. The models had already demonstrated the ability to write computer code, which is impressive but not too surprising because there is so much code out there on the Internet to mimic. Millière went a step further and showed that GPT can execute code, too, however. The philosopher typed in a program to calculate the 83rd number in the Fibonacci sequence. “It’s multistep reasoning of a very high degree,” he says. And the bot nailed it. When Millière asked directly for the 83rd Fibonacci number, however, GPT got it wrong: this suggests the system wasn’t just parroting the Internet. Rather it was performing its own calculations to reach the correct answer.

Although an LLM runs on a computer, it is not itself a computer. It lacks essential computational elements, such as working memory. In a tacit acknowledgement that GPT on its own should not be able to run code, its inventor, the tech company OpenAI, has since introduced a specialized plug-in—a tool ChatGPT can use when answering a query—that allows it to do so. But that plug-in was not used in Millière’s demonstration. Instead he hypothesizes that the machine improvised a memory by harnessing its mechanisms for interpreting words according to their context—a situation similar to how nature repurposes existing capacities for new functions.

This impromptu ability demonstrates that LLMs develop an internal complexity that goes well beyond a shallow statistical analysis. Researchers are finding that these systems seem to achieve genuine understanding of what they have learned. In one study presented last week at the International Conference on Learning Representations (ICLR), doctoral student Kenneth Li of Harvard University and his AI researcher colleagues—Aspen K. Hopkins of the Massachusetts Institute of Technology, David Bau of Northeastern University, and Fernanda Viégas, Hanspeter Pfister and Martin Wattenberg, all at Harvard—spun up their own smaller copy of the GPT neural network so they could study its inner workings. They trained it on millions of matches of the board game Othello by feeding in long sequences of moves in text form. Their model became a nearly perfect player.

To study how the neural network encoded information, they adopted a technique that Bengio and Guillaume Alain, also at the University of Montreal, devised in 2016. They created a miniature “probe” network to analyze the main network layer by layer. Li compares this approach to neuroscience methods. “This is similar to when we put an electrical probe into the human brain,” he says. In the case of the AI, the probe showed that its “neural activity” matched the representation of an Othello game board, albeit in a convoluted form. To confirm this, the researchers ran the probe in reverse to implant information into the network—for instance, flipping one of the game’s black marker pieces to a white one. “Basically, we hack into the brain of these language models,” Li says. The network adjusted its moves accordingly. The researchers concluded that it was playing Othello roughly like a human: by keeping a game board in its “mind’s eye” and using this model to evaluate moves. Li says he thinks the system learns this skill because it is the most parsimonious description of its training data. “If you are given a whole lot of game scripts, trying to figure out the rule behind it is the best way to compress,” he adds.

This ability to infer the structure of the outside world is not limited to simple game-playing moves; it also shows up in dialogue. Belinda Li (no relation to Kenneth Li), Maxwell Nye and Jacob Andreas, all at M.I.T., studied networks that played a text-based adventure game. They fed in sentences such as “The key is in the treasure chest,” followed by “You take the key.” Using a probe, they found that the networks encoded within themselves variables corresponding to “chest” and “you,” each with the property of possessing a key or not, and updated these variables sentence by sentence. The system had no independent way of knowing what a box or key is, yet it picked up the concepts it needed for this task. “There is some representation of the state hidden inside of the model,” Belinda Li says.

Researchers marvel at how much LLMs are able to learn from text. For example, Pavlick and her then Ph.D. student Roma Patel found that these networks absorb color descriptions from Internet text and construct internal representations of color. When they see the word “red,” they process it not just as an abstract symbol but as a concept that has certain relationship to maroon, crimson, fuchsia, rust, and so on. Demonstrating this was somewhat tricky. Instead of inserting a probe into a network, the researchers studied its response to a series of text prompts. To check whether it was merely echoing color relationships from online references, they tried misdirecting the system by telling it that red is in fact green—like the old philosophical thought experiment in which one person’s red is another person’s green. Rather than parroting back an incorrect answer, the system’s color evaluations changed appropriately in order to maintain the correct relations.

Picking up on the idea that in order to perform its autocorrection function, the system seeks the underlying logic of its training data, machine learning researcher Sébastien Bubeck of Microsoft Research suggests that the wider the range of the data, the more general the rules the system will discover. “Maybe we’re seeing such a huge jump because we have reached a diversity of data, which is large enough that the only underlying principle to all of it is that intelligent beings produced them,” he says. “And so the only way to explain all of this data is [for the model] to become intelligent.”

In addition to extracting the underlying meaning of language, LLMs are able to learn on the fly. In the AI field, the term “learning” is usually reserved for the computationally intensive process in which developers expose the neural network to gigabytes of data and tweak its internal connections. By the time you type a query into ChatGPT, the network should be fixed; unlike humans, it should not continue to learn. So it came as a surprise that LLMs do, in fact, learn from their users’ prompts—an ability known as “in-context learning.” “It’s a different sort of learning that wasn’t really understood to exist before,” says Ben Goertzel, founder of the AI company SingularityNET.

One example of how an LLM learns comes from the way humans interact with chatbots such as ChatGPT. You can give the system examples of how you want it to respond, and it will obey. Its outputs are determined by the last several thousand words it has seen. What it does, given those words, is prescribed by its fixed internal connections—but the word sequence nonetheless offers some adaptability. Entire websites are devoted to “jailbreak” prompts that overcome the system’s “guardrails”—restrictions that stop the system from telling users how to make a pipe bomb, for example—typically by directing the model to pretend to be a system without guardrails. Some people use jailbreaking for sketchy purposes, yet others deploy it to elicit more creative answers. “It will answer scientific questions, I would say, better” than if you just ask it directly, without the special jailbreak prompt, says William Hahn, co-director of the Machine Perception and Cognitive Robotics Laboratory at Florida Atlantic University. “It’s better at scholarship.”

Another type of in-context learning happens via “chain of thought” prompting, which means asking the network to spell out each step of its reasoning—a tactic that makes it do better at logic or arithmetic problems requiring multiple steps. (But one thing that made Millière’s example so surprising is that the network found the Fibonacci number without any such coaching.)

In 2022 a team at Google Research and the Swiss Federal Institute of Technology in Zurich—Johannes von Oswald, Eyvind Niklasson, Ettore Randazzo, João Sacramento, Alexander Mordvintsev, Andrey Zhmoginov and Max Vladymyrov—showed that in-context learning follows the same basic computational procedure as standard learning, known as gradient descent. This procedure was not programmed; the system discovered it without help. “It would need to be a learned skill,” says Blaise Agüera y Arcas, a vice president at Google Research. In fact, he thinks LLMs may have other latent abilities that no one has discovered yet. “Every time we test for a new ability that we can quantify, we find it,” he says.

Although LLMs have enough blind spots not to qualify as artificial general intelligence, or AGI—the term for a machine that attains the resourcefulness of animal brains—these emergent abilities suggest to some researchers that tech companies are closer to AGI than even optimists had guessed. “They’re indirect evidence that we are probably not that far off from AGI,” Goertzel said in March at a conference on deep learning at Florida Atlantic University. OpenAI’s plug-ins have given ChatGPT a modular architecture a little like that of the human brain. “Combining GPT-4 [the latest version of the LLM that powers ChatGPT] with various plug-ins might be a route toward a humanlike specialization of function,” says M.I.T. researcher Anna Ivanova.

At the same time, though, researchers worry the window may be closing on their ability to study these systems. OpenAI has not divulged the details of how it designed and trained GPT-4, in part because it is locked in competition with Google and other companies—not to mention other countries. “Probably there’s going to be less open research from industry, and things are going to be more siloed and organized around building products,” says Dan Roberts, a theoretical physicist at M.I.T., who applies the techniques of his profession to understanding AI.

And this lack of transparency does not just harm researchers; it also hinders efforts to understand the social impacts of the rush to adopt AI technology. “Transparency about these models is the most important thing to ensure safety,” Mitchell says.

参考译文
人工智能如何了解从未被告诉的事物# 示例输入和输出 **输入** 人工智能(AI)是计算机科学的一个分支,旨在开发表现出人类智能的软件或机器。这包括从经验中学习、理解自然语言、解决问题以及识别模式。 **输出** 人工智能(AI)是计算机科学的一个分支,旨在开发表现出人类智能的软件或机器。这包括从经验中学习、理解自然语言、解决问题以及识别模式。
目前,尚无人知晓ChatGPT及其人工智能“表亲”将如何改变世界,原因之一就是我们尚不清楚它们的内部运作。一些系统的性能远远超出它们被训练来执行的任务范围,连它们的创造者也难以理解个中缘由。越来越多的测试表明,这些人工智能系统在某种程度上发展出了对现实世界的内部模型,正如我们大脑所做的那样,尽管它们的方法不同。布朗大学的埃莉·帕夫利克(Ellie Pavlick)是致力于填补这一解释空白的研究人员之一,她表示:“如果我们不清楚它们是如何运作的,那么试图让它们变得更好或更安全,似乎是一个荒谬的要求。”在某种程度上,帕夫利克及其同事对GPT(生成式预训练Transformer,简称GPT)和其他大型语言模型(LLMs)的运作机制理解得非常清楚。这些模型依赖于一种称为神经网络的机器学习系统。这些网络的结构大致模拟了人类大脑中相互连接的神经元。这些程序的代码相对简单,只需占据几页屏幕。它设置了一个自动纠正算法,该算法基于对数百GB互联网文本的详尽统计分析,来选择最有可能完成一段文字的词汇。额外的训练确保系统将以对话形式呈现结果。从这个意义上说,它所做的只是复述自己所学的内容,正如华盛顿大学的语言学家艾米丽·本德(Emily Bender)所言,它是一个“随机鹦鹉”。然而,LLMs还成功通过了律师考试,用抑扬五步格诗解释了希格斯玻色子,甚至试图劝阻用户结束婚姻。很少有人预料到一个基本的自动纠正算法会具备如此广泛的能力。GPT和其他人工智能系统在它们没有被训练过的任务上表现出能力,使其产生了“涌现能力”,这甚至让那些对LLMs炒作持普遍怀疑态度的研究人员感到惊讶。圣塔菲研究所的人工智能研究员梅勒妮·米切尔(Melanie Mitchell)表示:“我不知道它们是怎么做到的,也不知道它们是否能像人类那样更一般地做到这一点,但它们确实改变了我的看法。”蒙特利尔大学的人工智能研究员约舒亚·本吉奥(Yoshua Bengio)表示:“这显然远不止是一个随机鹦鹉,而且它确实建立了一些关于世界的表现——尽管我认为它建立的模型与人类建立的内部世界模型并不完全相同。”在3月纽约大学举办的一次会议上,哥伦比亚大学的哲学家拉斐尔·米利亚尔(Raphaël Millière)展示了LLMs的另一个惊人的例子。这些模型已经展现出编写计算机代码的能力,这虽然令人印象深刻,但并不太令人意外,因为互联网上有很多代码可供模仿。米利亚尔更进一步,展示出GPT还能执行代码。这位哲学家输入了一个计算斐波那契数列第83个数字的程序。“这需要非常复杂的多步骤推理,”他说。而AI给出了正确的答案。然而,当米利亚尔直接询问第83个斐波那契数字时,GPT却给出了错误答案:这表明系统并非简单地在模仿互联网内容,而是自己进行了计算,得出了正确结果。尽管LLM在计算机上运行,但它本身并不是计算机。它缺乏关键的计算组件,如工作记忆。为了承认GPT本身无法执行代码这一事实,其发明者科技公司OpenAI随后引入了一种专用插件——一种ChatGPT在回答问题时可以使用的工具,允许其执行代码。但米利亚尔的演示中并未使用这种插件。相反,他推测机器通过利用其根据上下文解释词语的机制,临时创造了一种记忆。这种临时表现的能力说明,LLMs发展出了超越浅层统计分析的内部复杂性。研究人员发现,这些系统似乎真正理解了它们所学的内容。在上周于国际学习表征会议(ICLR)上展示的一项研究中,哈佛大学的博士生肯尼斯·李(Kenneth Li)和他的AI研究员同事——麻省理工学院的艾森·K·霍普金斯(Aspen K. Hopkins)、东北大学的大卫·鲍(David Bau)以及哈佛大学的费尔南达·维加斯(Fernanda Viégas)、汉斯皮特·皮弗斯特(Hanspeter Pfister)和马丁·瓦滕伯格(Martin Wattenberg)——建立了一个GPT神经网络的缩小版,以便研究其内部运作。他们用数百万盘棋类游戏奥赛罗的对局文本数据训练它。他们的模型成为了一个几乎完美的玩家。为了研究神经网络如何编码信息,他们采用了本吉奥和蒙特利尔大学的格雷厄姆·阿兰(Guillaume Alain)在2016年设计的一种技术。他们创建了一个微型“探测器”网络,逐层分析主网络。李将这种方法与神经科学方法进行了类比。“这类似于我们将电极探针插入人脑中的时候,”他说。在AI系统中,这种探测器显示其“神经活动”与奥赛罗棋盘的表现相匹配,尽管形式复杂。为了验证这一点,研究人员反向运行探测器,将信息植入网络中,例如将棋盘上的黑色标记翻转为白色。李说:“基本上,我们入侵了这些语言模型的‘大脑’。”网络相应地调整了它的走法。研究人员得出结论,它下棋的方式与人类几乎相同:通过在头脑中构建棋盘,进行多步推理。LLMs的另一个学习方式来自人类与像ChatGPT这样的聊天机器人互动的方式。你可以给系统提供你希望它如何回应的例子,它会遵从。它的输出由它最近看到的几千个词决定。在这些词的引导下,其输出由固定内部连接决定,但词序仍然提供了一定的适应性。一些网站专门提供“越狱”提示,以绕过系统的“护栏”——例如防止系统告诉用户如何制造炸弹的限制——通常是让模型假装自己没有这些限制。一些人利用越狱达到可疑的目的,但其他人则用它来激发更具创造性的答案。佛罗里达大西洋大学机器感知与认知机器人实验室的联合主任威廉·哈恩(William Hahn)表示:“在没有特别越狱提示的情况下,如果你只是直接提问,它在回答科学问题方面会更好。它更擅长学术。”另一种上下文学习方式是通过“推理链”提示,即要求网络逐步说明其推理过程——这种方法使其在解决需要多步推理的逻辑或数学问题时表现得更好。(但让米利亚尔例子如此令人惊讶的一点是,网络在没有这种引导的情况下就找到了斐波那契数。)2022年,一支由谷歌研究和瑞士苏黎世联邦理工学院的研究团队——乔安尼斯·冯·奥斯瓦尔德(Johannes von Oswald)、埃夫因德·尼克拉森(Eyvind Niklasson)、埃托雷·兰达佐(Ettore Randazzo)、若昂·萨尔瓦多(João Sacramento)、亚历山大·莫德文采夫(Alexander Mordvintsev)、安德烈·扎莫金诺夫(Andrey Zhmoginov)和马克·弗拉季米尔(Max Vladymyrov)——展示了上下文学习遵循与标准学习相同的计算过程,即梯度下降。这种过程并未被编程,而是系统自行发现的。“这必须是一种学习能力,”谷歌研究的副总裁布莱斯·阿格尔亚·亚克斯(Blaise Agüera y Arcas)说。事实上,他认为LLM可能还有其他尚未被发现的潜在能力。“每次我们测试新的可量化能力时,我们都会发现它,”他说。尽管LLMs存在盲点,不足以被归类为人工通用智能(AGI)——这是指机器具备动物大脑的多功能性——这些涌现能力表明,一些研究人员认为科技公司可能比乐观主义者所预期的更接近AGI。“它们是间接证据,表明我们可能离AGI并不那么遥远,”3月在佛罗里达大西洋大学举办的深度学习会议上,Goertzel这样说。OpenAI的插件使ChatGPT具备了一种模块化架构,类似于人脑的架构。麻省理工学院的研究员安娜·伊万诺娃(Anna Ivanova)表示:“将GPT-4(为ChatGPT提供动力的LLM最新版本)与各种插件结合,可能是实现类人功能专业化的路径。”与此同时,研究人员却担心他们研究这些系统的机会可能会逐渐消失。OpenAI并未公开GPT-4的设计和训练细节,部分原因是它正与谷歌和其他公司,乃至其他国家陷入竞争。麻省理工学院的理论物理学家丹·罗伯茨(Dan Roberts)表示,他将自己专业的研究方法应用于理解人工智能。“可能来自产业界的开放研究将减少,事情将变得更加封闭,围绕着产品构建组织。”他说。这种不透明不仅损害了研究人员,也阻碍了对人工智能技术快速采用的社会影响的理解。米切尔表示:“关于这些模型的透明度是确保安全的最重要因素。”
您觉得本篇内容如何
评分

评论

您需要登录才可以回复|注册

提交评论

广告

scientific

这家伙很懒,什么描述也没留下

关注

点击进入下一篇

解放军报聚焦:生成式AI如何影响未来战争

提取码
复制提取码
点击跳转至百度网盘