We propose a novel LLM-based framework for reasoning in discrete, game-theoretic tasks, illustrated with \emph{Tic-Tac-Toe}. The method integrates in-context learning with entropy-guided chain-of-thought (CoT) reasoning and adaptive context retrieval. The model dynamically adjusts both the number of retrieved examples and reasoning paths according to token-level uncertainty: concise reasoning with minimal context is used when uncertainty is low, whereas higher uncertainty triggers expanded multi-path CoT exploration. Experimental evaluation against a sub-optimal algorithmic opponent shows that entropy-aware adaptive reasoning substantially improves decision quality, increasing the average game outcome from \(-11.6\%\) with the baseline LLM to \(+9.5\%\) with entropy-guided adaptive reasoning over 100 games (win = +1, tie = 0, loss = -1), while maintaining a relatively low number of LLM queries per game. Statistical validation confirms that the improvement is significant, and correlation analysis reveals a negative association between token-level entropy and move optimality. These findings demonstrate that uncertainty-guided adaptive reasoning effectively enhances LLM performance in sequential decision-making environments.
翻译:我们提出了一种基于大语言模型的新型框架,用于离散博弈任务中的推理,并以井字棋为例进行说明。该方法将上下文学习与熵指导的思维链推理及自适应上下文检索相结合。模型根据词元级不确定性动态调整检索示例数量与推理路径:当不确定性较低时,采用最小上下文进行简洁推理;当不确定性较高时,则触发扩展的多路径思维链探索。在与次优算法对手的对比实验中,熵感知自适应推理显著提升了决策质量:在100局游戏中(胜=+1,平=0,负=-1),平均博弈结果从基线大语言模型的-11.6%提升至熵指导自适应推理的+9.5%,同时保持每局较低的大语言模型查询次数。统计检验证实了改进的显著性,相关分析揭示词元级熵与走棋最优性呈负相关。这些发现表明,不确定性引导的自适应推理能有效增强大语言模型在序列决策环境中的性能。