ChatPaper.aiChatPaper

HDFlow:透過混合思維和動態工作流程增強LLM複雜問題解決

HDFlow: Enhancing LLM Complex Problem-Solving with Hybrid Thinking and Dynamic Workflows

September 25, 2024
作者: Wenlin Yao, Haitao Mi, Dong Yu
cs.AI

摘要

儘管近年來大型語言模型(LLMs)取得了重大進展,但它們在需要多步思考和結合各種技能的複雜推理問題上的表現仍然有限。為了應對這一挑戰,我們提出了一個新的框架 HDFlow,用於與LLMs進行複雜推理,該框架以自適應方式結合快速和慢速思考模式。我們的方法包括兩個關鍵組件:1)一種名為動態工作流的慢速、深思熟慮推理新方法,該方法自動將複雜問題分解為更易處理的子任務,並動態設計工作流程以組裝專用LLM或符號推理工具來解決子任務;2)混合思維,一個通用框架,根據問題的複雜性動態結合快速和慢速思考。最後,我們提出了一種易於擴展的方法,用於自動合成一個包含27K個具有挑戰性的推理問題的大規模數據集,以及一種混合思維調整方法,該方法在此數據集上訓練較小的LLMs,以內化快速/慢速混合推理策略。在四個推理基準數據集上的實驗表明,我們的慢速思考與動態工作流明顯優於思維鏈,而混合思維在提供最高準確性的同時,在計算效率和性能之間提供了有效的平衡。使用我們的混合思維方法進行微調還顯著提升了開源語言模型的複雜推理能力。這些結果展示了慢速思考、動態工作流和混合思維在擴展LLMs進行複雜問題解決的前沿中的潛力。代碼和數據將在 \url{https://github.com/wenlinyao/HDFlow.} 上發布。
English
Despite recent advancements in large language models (LLMs), their performance on complex reasoning problems requiring multi-step thinking and combining various skills is still limited. To address this, we propose a novel framework HDFlow for complex reasoning with LLMs that combines fast and slow thinking modes in an adaptive manner. Our approach consists of two key components: 1) a new approach for slow, deliberate reasoning called Dynamic Workflow, which automatically decomposes complex problems into more manageable sub-tasks and dynamically designs a workflow to assemble specialized LLM or symbolic reasoning tools to solve sub-tasks; 2) Hybrid Thinking, a general framework that dynamically combines fast and slow thinking based on problem complexity. Finally, we propose an easy-to-scale method for automatically synthesizing a large-scale dataset of 27K challenging reasoning problems for complex reasoning and a hybrid thinking tuning method that trains smaller LLMs on this dataset to internalize the fast/slow hybrid reasoning strategies. Experiments on four reasoning benchmark datasets demonstrate that our slow thinking with dynamic workflows significantly outperforms Chain-of-Thought, and hybrid thinking achieves the highest accuracy while providing an effective balance between computational efficiency and performance. Fine-tuning using our hybrid thinking approach also significantly boosts the complex reasoning capabilities of open-source language models. The results showcase the promise of slow thinking, dynamic workflows, and hybrid thinking in expanding the frontier of complex problem-solving with LLMsCode and data will be released at \url{https://github.com/wenlinyao/HDFlow.}.

Summary

AI-Generated Summary

PDF92November 16, 2024