arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2407.17404cs.AI
收藏

基于大语言模型的语法化游戏描述生成

Grammar-based Game Description Generation using Large Language Models

Waseda University(早稻田大学)

Tsunehiko Tanaka, Edgar Simo-Serra

AI总结:

本文提出一种利用大语言模型从自然语言生成语法正确的游戏描述(GDL)的两阶段框架,通过语法引导的迭代改进显著优于直接使用LLM输出的基线方法。

摘要:

游戏描述语言(GDL)提供了一种标准化的方式,以机器可读的格式表达各种游戏,从而实现自动化的游戏模拟和评估。虽然以往的研究探索了使用基于搜索的方法进行游戏描述生成,但从自然语言生成GDL描述仍然是一项具有挑战性的任务。本文提出了一种新颖的框架,利用大语言模型(LLMs)从自然语言生成语法准确的游戏描述。我们的方法包含两个阶段:首先,我们基于GDL规范逐步生成一个最小语法;其次,我们通过语法引导的生成迭代地改进游戏描述。我们的框架采用了一个专门的解析器,从LLM响应中识别有效的子序列和候选符号,从而逐步细化输出以确保语法正确性。实验结果表明,我们的迭代改进方法显著优于直接使用LLM输出的基线方法。我们的代码可在 https://github.com/tsunehiko/ggdg 获取。

英文摘要:

Game Description Language (GDL) provides a standardized way to express diverse games in a machine-readable format, enabling automated game simulation, and evaluation. While previous research has explored game description generation using search-based methods, generating GDL descriptions from natural language remains a challenging task. This paper presents a novel framework that leverages Large Language Models (LLMs) to generate grammatically accurate game descriptions from natural language. Our approach consists of two stages: first, we gradually generate a minimal grammar based on GDL specifications; second, we iteratively improve the game description through grammar-guided generation. Our framework employs a specialized parser that identifies valid subsequences and candidate symbols from LLM responses, enabling gradual refinement of the output to ensure grammatical correctness. Experimental results demonstrate that our iterative improvement approach significantly outperforms baseline methods that directly use LLM outputs. Our code is available at https://github.com/tsunehiko/ggdg

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑