[2304.10464] Learning to Program with Natural Language
Large Language Models (LLMs) have shown remarkable performance in various basic natural language tasks, which raises hopes for achieving Artificial General Intelligence. To better complete complex tasks, we need LLMs to program for the task and then follow the program to generate a specific solution for the test sample. We propose using natural language as a new programming language to describe task procedures, making them easily understandable to both humans and LLMs. LLMs are capable of directly generating natural language programs, but these programs may still contain factual errors or incomplete steps. Therefore, we further propose the Learning to Program (LP) method to ask LLMs themselves to learn natural language programs from the training dataset of complex tasks and then use the learned program to guide inference. Our experiments on the AMPS (high school math) and Math (competition mathematics problems) datasets demonstrate the effectiveness of our approach. When testing ChatGPT on 10 tasks from the AMPS dataset, our LP method's average performance outperformed the direct zero-shot test performance by 18.3$\%$. We release our code at \url{this https URL}.
Large Language Models (LLMs) have shown remarkable performance in various basic natural language tasks, which raises hopes for achieving Artificial General Intelligence. To better complete complex tasks, we need LLMs to program for the task and then follow the program to generate a specific solution for the test sample. We propose using natural language as a new programming language to describe task procedures, making them easily understandable to both humans and LLMs. LLMs are capable of directly generating natural language programs, but these programs may still contain factual errors or inco
Explore this link on the map →related reading
- LLM Powered Autonomous Agents | Lil'Loglilianweng.github.io
- Language Models can Solve Computer Tasksarxiv.org
- crawshaw - 2025-01-06crawshaw.io
- [2201.11903] Chain of Thought Prompting Elicits Reasoning in Large Language Modelsarxiv.org
- 2310.10631arxiv.org
- [2108.07732] Program Synthesis with Large Language Modelsarxiv.org
- Here’s how I use LLMs to help me write codesimonwillison.net
- [2210.02441] Ask Me Anything: A simple strategy for prompting language modelsarxiv.org
- LLMs and Programming in the first days of 2024 - <antirez>antirez.com
- Pathways Language Model (PaLM): Scaling to 540 Billion Parameters for Breakthrouai.googleblog.com
- [2406.02061] Alice in Wonderland: Simple Tasks Showing Complete Reasoning Breakdown in State-Of-the-Art Large Language Modelsarxiv.org
- To Teach Computers Math, Researchers Merge AI Approaches | Quanta Magazinequantamagazine.org