Is Temperature the Creativity Parameter of Large Language Models?

Fuente: arXiv
Gespeichert in:
Bibliographische Detailangaben
Hauptverfasser: Peeperkorn, Max, Kouwenhoven, Tom, Brown, Dan, Jordanous, Anna
Format: Preprint
Veröffentlicht: 2024
Schlagworte:
Online-Zugang:
Tags: Tag hinzufügen
Keine Tags, Fügen Sie den ersten Tag hinzu!
_version_ 1866916230583025664
author Peeperkorn, Max
Kouwenhoven, Tom
Brown, Dan
Jordanous, Anna
author_facet Peeperkorn, Max
Kouwenhoven, Tom
Brown, Dan
Jordanous, Anna
contents Large language models (LLMs) are applied to all sorts of creative tasks, and their outputs vary from beautiful, to peculiar, to pastiche, into plain plagiarism. The temperature parameter of an LLM regulates the amount of randomness, leading to more diverse outputs; therefore, it is often claimed to be the creativity parameter. Here, we investigate this claim using a narrative generation task with a predetermined fixed context, model and prompt. Specifically, we present an empirical analysis of the LLM output for different temperature values using four necessary conditions for creativity in narrative generation: novelty, typicality, cohesion, and coherence. We find that temperature is weakly correlated with novelty, and unsurprisingly, moderately correlated with incoherence, but there is no relationship with either cohesion or typicality. However, the influence of temperature on creativity is far more nuanced and weak than suggested by the "creativity parameter" claim; overall results suggest that the LLM generates slightly more novel outputs as temperatures get higher. Finally, we discuss ideas to allow more controlled LLM creativity, rather than relying on chance via changing the temperature parameter.
format Preprint
id arxiv_https___arxiv_org_abs_2405_00492
institution arXiv
publishDate 2024
record_format arxiv
spellingShingle Is Temperature the Creativity Parameter of Large Language Models?
Peeperkorn, Max
Kouwenhoven, Tom
Brown, Dan
Jordanous, Anna
Computation and Language
Artificial Intelligence
Large language models (LLMs) are applied to all sorts of creative tasks, and their outputs vary from beautiful, to peculiar, to pastiche, into plain plagiarism. The temperature parameter of an LLM regulates the amount of randomness, leading to more diverse outputs; therefore, it is often claimed to be the creativity parameter. Here, we investigate this claim using a narrative generation task with a predetermined fixed context, model and prompt. Specifically, we present an empirical analysis of the LLM output for different temperature values using four necessary conditions for creativity in narrative generation: novelty, typicality, cohesion, and coherence. We find that temperature is weakly correlated with novelty, and unsurprisingly, moderately correlated with incoherence, but there is no relationship with either cohesion or typicality. However, the influence of temperature on creativity is far more nuanced and weak than suggested by the "creativity parameter" claim; overall results suggest that the LLM generates slightly more novel outputs as temperatures get higher. Finally, we discuss ideas to allow more controlled LLM creativity, rather than relying on chance via changing the temperature parameter.
title Is Temperature the Creativity Parameter of Large Language Models?
topic Computation and Language
Artificial Intelligence
url https://arxiv.org/abs/2405.00492