Can large language models explore in-context?
We investigate the extent to which contemporary Large Language Models (LLMs)
can engage in exploration, a core capability in reinforcement learning and
decision making. We focus on native performance of existing LLMs, without
training interventions. We deploy LLMs as agents in simple multi-armed bandit
environments, specifying the environment description and interaction history
entirely in-context, i.e., within the LLM prompt. We experiment with GPT-3.5,
GPT-4, and Llama2, using a variety of prompt designs, and find that the models
do not robustly engage in exploration without substantial interventions: i)
Across all of our experiments, only one configuration resulted in satisfactory
exploratory behavior: GPT-4 with chain-of-thought reasoning and an externally
summarized interaction history, presented as sufficient statistics; ii) All
other configurations did not result in robust exploratory behavior, including
those with chain-of-thought reasoning but unsummarized history. Although these
findings can be interpreted positively, they suggest that external
summarization -- which may not be possible in more complex settings -- is
important for obtaining desirable behavior from LLM agents. We conclude that
non-trivial algorithmic interventions, such as fine-tuning or dataset curation,
may be required to empower LLM-based decision making agents in complex
settings.
6600d47a8270811586f9fe3a
Akshay Krishnamurthy
admin_assigned
2024-03-25T10:11:50.638Z
64b71a5efa7eabaae5f35442
/avatars/347f58f15820630e96908a54dd25ed81.svg
Akshay Krishnamurthy
user
akshaykrish
6600d47a8270811586f9fe3b
Keegan Harris
claimed_verified
2024-03-25T11:42:48.432Z
64b85a44cf14c2fabe8e929f
/avatars/21e106c247bf6f027c0384dec8910426.svg
Keegan Harris
user
keeganharris
6600d47a8270811586f9fe3c
Dylan J. Foster
6600d47a8270811586f9fe3d
Cyril Zhang
admin_assigned
2024-03-25T10:12:55.961Z
63a6a3a93d8cc9b1183c6593
https://cdn-avatars.huggingface.co/v1/production/uploads/63a6a3a93d8cc9b1183c6593/UF-9ostqBHiAGDOuEtIw_.png
Cyril Zhang
user
cyrilzhang
6600d47a8270811586f9fe3e
Aleksandrs Slivkins
Can large language models explore in-context?
We investigate the extent to which contemporary Large Language Models (LLMs)
can engage in exploration, a core capability in reinforcement learning and
decision making. We focus on native performance of existing LLMs, without
training interventions. We deploy LLMs as agents in simple multi-armed bandit
environments, specifying the environment description and interaction history
entirely in-context, i.e., within the LLM prompt. We experiment with GPT-3.5,
GPT-4, and Llama2, using a variety of prompt designs, and find that the models
do not robustly engage in exploration without substantial interventions: i)
Across all of our experiments, only one configuration resulted in satisfactory
exploratory behavior: GPT-4 with chain-of-thought reasoning and an externally
summarized interaction history, presented as sufficient statistics; ii) All
other configurations did not result in robust exploratory behavior, including
those with chain-of-thought reasoning but unsummarized history. Although these
findings can be interpreted positively, they suggest that external
summarization -- which may not be possible in more complex settings -- is
important for obtaining desirable behavior from LLM agents. We conclude that
non-trivial algorithmic interventions, such as fine-tuning or dataset curation,
may be required to empower LLM-based decision making agents in complex
settings.
Experimentation with LLMs in multi-armed bandit environments reveals that robust exploration requires specific prompts, external summarization of history, or algorithmic interventions.
Large Language Models LLMs reinforcement learning decision making multi-armed bandit environments chain-of-thought reasoning externally summarized interaction history fine-tuning dataset curation