Dies ist eine Übersichtsseite mit Metadaten zu dieser wissenschaftlichen Arbeit. Der vollständige Artikel ist beim Verlag verfügbar.
An empirical study of prompt mode in code generation based on ChatGPT
2
Zitationen
1
Autoren
2024
Jahr
Abstract
In recent years, with the continuous advancement of technologies such as Large Language Models (LLMs) and Chat Generative Pre-trained Transformer (ChatGPT), an increasing number of developers have turned to AI-assisted code generation. However, in the context of code generation, simple question-and-answer approaches may not yield the desired results. To address this challenge, we introduce prompt engineering as a means to construct efficient prompting methods for guiding models in generating the intended code. This paper empirically explores the impact of different prompting methods on code-generation tasks. We introduce several prompt-sensitive code tasks in our experiments and assess the effectiveness of various prompt methods in terms of the quality of generated code. Ultimately, we find that guiding the model from a specific role perspective yields the best results, while other methods exhibit varying degrees of effectiveness. This research provides valuable insights into the application of prompt engineering in code generation, encouraging future efforts to further optimize prompting methods and enhance the accuracy and practicality of generated code.
Ähnliche Arbeiten
Explainable Artificial Intelligence (XAI): Concepts, taxonomies, opportunities and challenges toward responsible AI
2019 · 8.527 Zit.
Stop explaining black box machine learning models for high stakes decisions and use interpretable models instead
2019 · 8.419 Zit.
High-performance medicine: the convergence of human and artificial intelligence
2018 · 7.909 Zit.
Proceedings of the 19th International Joint Conference on Artificial Intelligence
2005 · 5.781 Zit.
Peeking Inside the Black-Box: A Survey on Explainable Artificial Intelligence (XAI)
2018 · 5.578 Zit.