Skip to main content
QUICK REVIEW

[논문 리뷰] An Analysis of the Automatic Bug Fixing Performance of ChatGPT

Dominik Sobania, Martin Briesch|arXiv (Cornell University)|2023. 01. 20.
Software Testing and Debugging Techniques인용 수 49
한 줄 요약

ChatGPT의 버그 수정 성능은 QuixBugs에서 Codex 및 CoCoNut과 경쟁력 있으며 표준 APR보다 훨씬 우수하며 대화 힌트를 사용하면 성공률이 크게 증가합니다(40문제 중 최대 31).

ABSTRACT

To support software developers in finding and fixing software bugs, several automated program repair techniques have been introduced. Given a test suite, standard methods usually either synthesize a repair, or navigate a search space of software edits to find test-suite passing variants. Recent program repair methods are based on deep learning approaches. One of these novel methods, which is not primarily intended for automated program repair, but is still suitable for it, is ChatGPT. The bug fixing performance of ChatGPT, however, is so far unclear. Therefore, in this paper we evaluate ChatGPT on the standard bug fixing benchmark set, QuixBugs, and compare the performance with the results of several other approaches reported in the literature. We find that ChatGPT's bug fixing performance is competitive to the common deep learning approaches CoCoNut and Codex and notably better than the results reported for the standard program repair approaches. In contrast to previous approaches, ChatGPT offers a dialogue system through which further information, e.g., the expected output for a certain input or an observed error message, can be entered. By providing such hints to ChatGPT, its success rate can be further increased, fixing 31 out of 40 bugs, outperforming state-of-the-art.

연구 동기 및 목표

  • 표준 벤치마크(QuixBugs)에서 ChatGPT의 자동 버그 수정 성능을 평가합니다.
  • ChatGPT를 Codex 및 전통적 딥러닝 APR 방법(CoCoNut, Codex)과 비교합니다.
  • 대화 기반 힌트가 ChatGPT의 버그 수정 성공에 어떤 영향을 미치는지 조사합니다.
  • ChatGPT 응답 유형을 특징짓고 후속 상호작용이 복구율에 미치는 영향을 분석합니다.

제안 방법

  • 벤치마크로 QuixBugs Python 버그(40문제)를 사용합니다.
  • 각 문제당 프롬프트 '이 프로그램에 버그가 있나요? 어떻게 고치나요?'를 주고 주석 없이 네 차례 ChatGPT를 질의합니다.
  • 결과를 Ye 등(2021)의 표준 APR 방법과 DL 기반 CoCoNut(Lutellier 등) 및 Codex(Prenner 등)와 같은 선행 문헌과 비교합니다.
  • ChatGPT의 응답을 미리 정의된 범주로 분류하고 응답 패턴을 분석합니다(예: 더 많은 정보 필요, 버그 없음 발견, 올바른 수정).
  • 힌트를 제공하고 수리율에 미치는 영향을 측정하는 대화 연구를 수행합니다(후속 요청).

실험 결과

연구 질문

  • RQ1QuixBugs에서 Codex, CoCoNut, 및 표준 APR 접근법에 비해 ChatGPT의 자동 버그 수정 성능은 어떠한가요?
  • RQ2대화 기반 힌트를 도입하면 ChatGPT의 버그 수정 성공률이 개선되나요?
  • RQ3버그 수정을 요청했을 때 ChatGPT가 어떤 유형의 응답을 생성하며 이것이 수리 결과에 어떤 영향을 미치나요?
  • RQ4후속 정보(힌트)가 ChatGPT의 버그 수정 능력을 어느 정도까지 증가시킬 수 있나요?

주요 결과

  • ChatGPT가 40개 버그 중 19개를 수정하며 Codex(21) 및 CoCoNut(19)과 비슷하고 표준 APR(7)보다 현저히 우수합니다.
  • 대화를 통해 성능이 향상될 수 있습니다: 힌트를 제공하면 40개 중 31개로 수정 수가 증가합니다.
  • ChatGPT의 결과는 문제당 변동성이 크게 나타나며(수정은 종종 1–2회의 실행에서 나타나고 Bucketsort/flatten 같은 경우 모든 실행에서 수정됨).
  • 전통적 APR과 비교하면 DL 기반 모델이 더 높은 버그 수정율을 보이며, 이는 더 넓은 탐색과 학습된 수리 패턴 때문일 가능성이 크고, 표준 APR은 테스트 슈트에 과적합합니다.
  • 대화 가능 상호작용은 실패 입력이나 기대 출력을 같은 대상 정보를 교환하는 식으로 수리 성공률을 크게 높일 수 있습니다.

더 나은 연구,지금 바로 시작하세요

논문 읽기부터 검토까지, 연구 시간을 획기적으로 줄여보세요.

카드 등록 없음 · 무료 플랜 제공

이 리뷰는 AI가 만들고, 인간 에디터가 검토했습니다.