Better Zero-Shot Reasoning with Role-Play Prompting

Aobo Kong, Shiwan Zhao, Hao Chen, Qicheng Li, Yong Qin +4 more
8/15/2023
cs.CL

Official code: NKU-HLT/Role-Play-Prompting (36 stars, last commit 2023-11-14).

Abstract

Modern large language models (LLMs) exhibit a remarkable capacity for role-playing, enabling them to embody not only human characters but also non-human entities. This versatility allows them to simulate complex human-like interactions and behaviors within various contexts, as well as to emulate specific objects or systems. While these capabilities have enhanced user engagement and introduced novel modes of interaction, the influence of role-playing on LLMs' reasoning abilities remains underexplored. In this study, we introduce a strategically designed role-play prompting methodology and assess its performance under the zero-shot setting across twelve diverse reasoning benchmarks. Our empirical results illustrate that role-play prompting consistently surpasses the standard zero-shot approach across most datasets. Notably, in experiments conducted using ChatGPT, accuracy on AQuA rises from 53.5% to 63.8%, and on Last Letter from 23.8% to 84.2%.Upon further comparison with the Zero-Shot-CoT technique, which prompts the model to "think step by step", our study demonstrates that role-play prompting acts as a more effective trigger for the CoT process. This highlights its potential to augment the reasoning capabilities of LLMs. We release our code at https://github.com/NKU-HLT/Role-Play-Prompting.

View on arXivView PDF

Code Implementations(1)

[NAACL 2024] Better Zero-Shot Reasoning with Role-Play Prompting

362Shell, PythonAug 15, 20232 years ago

Similar Papers

Cite this paper

@article{kong2023better,
  title  = {Better Zero-Shot Reasoning with Role-Play Prompting},
  author = {Aobo Kong and Shiwan Zhao and Hao Chen and Qicheng Li and Yong Qin and Ruiqi Sun and Xin Zhou and Enzhi Wang and Xiaohang Dong},
  year   = {2023},
  eprint = {2308.07702},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2308.07702v2}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2308.07702.svg)](https://codeofpaper.com/paper/2308.07702)

Discussion