Code Generation Using LLMs
Abstract
Code generation using Large Language Models has brought a significant change in the software industry helping people in various things like understanding the code, writing a code, completion of the code. The main challenge that the Code Generation Models are facing is Hallucinations wherein the given code may not satisfy the users requirements completely or might deviate from the user’s requirements. There are many kinds of hallucinations and are divided into different types like the intent conflicting which consists of semantic conflicts, context deviation which includes inconsistency, repetition, dead code. So, to help with the problem of code repetition type of hallucination we proposed a solution that is fine-tuning a pre-trained model on a specific dataset to help in code generation and to reduce the repetition type hallucination. Repetitive code hallucinations occur when the model generates redundant lines increasing complexity and confusing developers. Repetitive code hallucinations remain a key challenge for LLMs. To address this, we curated a dataset of Python code snippets extracted from GitHub repositories. We have also created a User Interface for efficient usability. We made a comparative study with different models and their results. This can further be improvised using prompt engineering, using more vast datasets for finetuning the model for different languages and can be trained to give more accurate and efficient results.
How to Cite This Article
Tenneti Lekhya Sri Durga, Mallak Keshava Gayatri, Mukku Deepthi Prabha, Dr. D Shravani (2025). Code Generation Using LLMs . International Journal of Future Engineering Innovations (IJFEI), 2(2), 16-22. DOI: https://doi.org/10.54660/IJFEI.2025.2.2.16-22