
An artificial intelligence model that makes suggestions to another AI can get it to produce results that are as good as if the prompts came from humans. The technique could be used to improve the performance of AIs whose internal workings remain opaque.
Large language models (LLMs) are neural networks that are trained on vast data sets of online text and can produce convincing language. You give the model an input, called a prompt, and it gives you a response. No one knows exactly how these LLMs arrive at the results they do, but by tweaking the prompt, you can sometimes get better results.
For instance, adding the phrase 鈥let鈥檚 think step-by-step鈥 to prompts seems to make these language models better at solving problems that they tend to struggle with.
Advertisement
Now, at the University of Toronto in Canada and his colleagues have developed a model called Automatic Prompt Engineer (APE) that uses a language model to come up with similar prompts aimed at a desired outcome that appear to be just as effective, or better than, if a human was thinking up the suggestions.
鈥淯sing our algorithm, we find better prompts than a world-class human prompt engineer,鈥 says Zhou. For example, one prompt they found is 鈥淟et鈥檚 work this out in a step-by-step way to be sure that we have the right answer鈥, though Zhou says exactly why this works is a mystery. 鈥淚t is not quite obvious to humans why this prompt works better than just 鈥楲et鈥檚 work this out step-by-step鈥.鈥
The prompts that APE finds aren鈥檛 necessarily the best and there could be better ones out there 鈥 but they are now on par with anything a human operator could find.
APE works by showing a large language model a desired output from a particular input, then generating various inputs that it guesses will produce the output. It then decides how to rank these suggestions and picks the one that seems best, although how APE reaches its decision isn鈥檛 known.
Zhou and his team used APE to come up with prompts for 24 tasks that tackle different aspects of language understanding, such as identifying similarity or causality, and compared the results with those from prompts made by 10 human 鈥減rompt engineers鈥. They found that APE was comparable or better on 19 of the tasks.
This could be used to improve the performance of large language models for little extra effort, or even to increase the safety of these models. If APE finds a prompt that increases the trustworthiness or accuracy of an output, the prompt could then be added to all public-facing models to, for example, reduce the chances of AI-spread misinformation, says Zhou.
The results are impressive, says at University College London. 鈥淭he model doesn鈥檛 improve itself, but it improves the way it questions itself. This is very difficult and time-consuming from a human鈥檚 perspective.鈥
While the model only works for language, a useful extension could be in expanding APE to work for AI text-to-image generators like DALL-E or Imagen, says Lu. At the moment, prompts that seem similar to us, such as a 鈥済rey-haired man鈥 or 鈥渁 man with grey hair鈥, can lead to very different outputs. The model could take a prompt and then optimise it to make sure the output is as accurate as possible and reduce the variability between prompts, says Lu.
Reference: