LTLCodeGen: Code Generation of Syntactically Correct Temporal Logic for Robot Task Planning

Rabiei, Behrad, R., Mahesh Kumar A., Dai, Zhirui, Pilla, Surya L. S. R., Dong, Qiyue, Atanasov, Nikolay

arXiv.org Artificial Intelligence 

This paper focuses on planning robot navigation tasks from natural language specifications. We develop a modular approach, where a large language model (LLM) translates the natural language instructions into a linear temporal logic (LTL) formula with propositions defined by object classes in a semantic occupancy map. The LTL formula and the semantic occupancy map are provided to a motion planning algorithm to generate a collision-free robot path that satisfies the natural language instructions. Our main contribution is LTLCodeGen, a method to translate natural language to syntactically correct LTL using code generation. We demonstrate the complete task planning method in real-world experiments involving human speech to provide navigation instructions to a mobile robot. We also thoroughly evaluate our approach in simulated and real-world experiments in comparison to end-to-end LLM task planning and state-of-the-art LLM-to-LTL translation methods.