The inference ability defects exposed by large language models (LLMs) in scenarios such as mathematical proofs, medical diagnosis, and complex decision planning seriously restrict its reliable implementation in high-risk areas. In order to improve the performance of LLM in complex reasoning tasks, Chain-of-Thought (CoT) emerged as an effective prompt strategy by explicitly generating intermediate reasoning steps. However, the generalized CoT Prompting process has exposed an extremely high sensitivity to changes in prompts, which affects the stability and reliability of the reasoning results. In this paper, we propose an adaptive and dynamic framework GAN-CoT for prompt generation and optimization. GAN-CoT fully utilizes the generation characteristics of Generative Adversarial Network (GAN) and CoT Prompting, weakening the dependence of LLMs on precise prompts through adversarial training. Specifically, the generator iteratively optimizes prompt templates based on meta-prompts, and the discriminator evaluates the quality of the answers generated by the templates, significantly reducing the sensitivity of the model to prompts. The extensive experiments on MGSM, BBH and Game of 24 demonstrate that GAN-CoT significantly improves the performance of LLMs in logical reasoning tasks over previous methods, which has great application value in high-risk scenarios.

错误:搜索内容不能为空,请输入英文关键词
错误:关键词超出字数限制,请精简
高级检索

Chain-of-Thought Prompt Optimization of Large Language Models via Generative Adversarial

  • Yihui Wang,
  • Haoran Yu,
  • Weifeng Liu

摘要

The inference ability defects exposed by large language models (LLMs) in scenarios such as mathematical proofs, medical diagnosis, and complex decision planning seriously restrict its reliable implementation in high-risk areas. In order to improve the performance of LLM in complex reasoning tasks, Chain-of-Thought (CoT) emerged as an effective prompt strategy by explicitly generating intermediate reasoning steps. However, the generalized CoT Prompting process has exposed an extremely high sensitivity to changes in prompts, which affects the stability and reliability of the reasoning results. In this paper, we propose an adaptive and dynamic framework GAN-CoT for prompt generation and optimization. GAN-CoT fully utilizes the generation characteristics of Generative Adversarial Network (GAN) and CoT Prompting, weakening the dependence of LLMs on precise prompts through adversarial training. Specifically, the generator iteratively optimizes prompt templates based on meta-prompts, and the discriminator evaluates the quality of the answers generated by the templates, significantly reducing the sensitivity of the model to prompts. The extensive experiments on MGSM, BBH and Game of 24 demonstrate that GAN-CoT significantly improves the performance of LLMs in logical reasoning tasks over previous methods, which has great application value in high-risk scenarios.