kth.sePublications KTH
Change search
CiteExportLink to record
Permanent link

Direct link
Cite
Citation style
  • apa
  • ieee
  • modern-language-association-8th-edition
  • vancouver
  • Other style
More styles
Language
  • de-DE
  • en-GB
  • en-US
  • fi-FI
  • nn-NO
  • nn-NB
  • sv-SE
  • Other locale
More languages
Output format
  • html
  • text
  • asciidoc
  • rtf
StepCoder: Improving Code Generation with Reinforcement Learning from Compiler Feedback
School of Computer Science, Fudan University, School of Computer Science, Fudan University.
School of Computer Science, Fudan University, School of Computer Science, Fudan University.
Huazhong University of Science and Technology, Huazhong University of Science and Technology.
School of Computer Science, Fudan University, School of Computer Science, Fudan University.
Show others and affiliations
2024 (English)In: 62nd Annual Meeting of the Association for Computational Linguistics, ACL 2024 - Proceedings of the Conference, Association for Computational Linguistics (ACL) , 2024, p. 4571-4585Conference paper, Published paper (Refereed)
Abstract [en]

The advancement of large language models (LLMs) has significantly propelled the field of code generation. Previous work integrated reinforcement learning (RL) with compiler feedback for exploring the output space of LLMs to enhance code generation quality. However, the lengthy code generated by LLMs in response to complex human requirements makes RL exploration a challenge. Also, since the unit tests may not cover the complicated code, optimizing LLMs by using these unexecuted code snippets is ineffective. To tackle these challenges, we introduce StepCoder, a novel RL framework for code generation, consisting of two main components: CCCS addresses the exploration challenge by breaking the long sequences code generation task into a Curriculum of Code Completion Subtasks, while FGO only optimizes the model by masking the unexecuted code segments to provide Fine-Grained Optimization. In addition, we furthermore construct the APPS+ dataset for RL training, which is manually verified to ensure the correctness of unit tests. Experimental results show that our method improves the ability to explore the output space and outperforms state-of-the-art approaches in corresponding benchmarks.

Place, publisher, year, edition, pages
Association for Computational Linguistics (ACL) , 2024. p. 4571-4585
National Category
Software Engineering
Identifiers
URN: urn:nbn:se:kth:diva-354306DOI: 10.18653/v1/2024.acl-long.251Scopus ID: 2-s2.0-85204445491OAI: oai:DiVA.org:kth-354306DiVA, id: diva2:1902965
Conference
62nd Annual Meeting of the Association for Computational Linguistics, ACL 2024, Bangkok, Thailand, Aug 11 2024 - Aug 16 2024
Note

QC 20241003

Part of ISBN 9798891760943

Available from: 2024-10-02 Created: 2024-10-02 Last updated: 2025-05-27Bibliographically approved

Open Access in DiVA

No full text in DiVA

Other links

Publisher's full textScopus

Authority records

Shan, Junjie

Search in DiVA

By author/editor
Shan, Junjie
By organisation
School of Electrical Engineering and Computer Science (EECS)
Software Engineering

Search outside of DiVA

GoogleGoogle Scholar

doi
urn-nbn

Altmetric score

doi
urn-nbn
Total: 98 hits
CiteExportLink to record
Permanent link

Direct link
Cite
Citation style
  • apa
  • ieee
  • modern-language-association-8th-edition
  • vancouver
  • Other style
More styles
Language
  • de-DE
  • en-GB
  • en-US
  • fi-FI
  • nn-NO
  • nn-NB
  • sv-SE
  • Other locale
More languages
Output format
  • html
  • text
  • asciidoc
  • rtf