Neural Transformer Automated Program Repair Using Stack Traces
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Despite efforts to ensure software quality through testing, source code bugs often remain undetected until after deployment, leading to increased maintenance costs and usability issues.
Innovation Solution
An automated program repair system utilizing a neural transformer model with attention is developed to predict and fix source code bugs by pre-training on natural language and programming languages, fine-tuning on synthetic bugs, and generating repaired code based on stack traces.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If software is tested prior to release, then the quality of the program is improved, but source code bugs may still remain undetected
Solution Approach 1:
The patent replaces traditional mechanical testing methods with an AI-based neural transformer system that automatically detects and repairs bugs. The system uses machine learning models trained on code repositories to identify bugs and generate fixes, substituting manual testing and code review processes with automated intelligent analysis.
Solution Approach 2:
The patent introduces an intermediary AI system that acts as a bridge between the source code and the testing process. The neural transformer model serves as a mediator that analyzes code, identifies bugs, and generates repair suggestions, facilitating more accurate bug detection without requiring exhaustive manual testing.
2Reliability
If software bugs are fixed after deployment, then the bugs are corrected, but the usability of the deployed program is hampered and maintenance costs increase
Solution Approach 1:
The patent applies preliminary action by detecting and fixing bugs before software deployment. The AI system analyzes source code in advance, identifies potential bugs, and generates repair suggestions prior to release, preventing bugs from reaching the deployed system and thereby maintaining usability without requiring post-deployment fixes.
3Reliability
If traditional testing methods are used, then software quality measures are taken, but the cost of software maintenance services increases
Solution Approach 1:
The patent implements self-service by enabling the system to automatically detect and repair its own bugs without requiring extensive manual intervention. The neural transformer model autonomously analyzes code, identifies bugs, and generates repair suggestions, reducing the need for expensive human maintenance services while maintaining high software quality.
Solution Approach 2:
The patent changes the parameter of bug detection from manual testing to automated AI analysis. By transforming the detection mechanism and using machine learning models trained on large code datasets, the system achieves better bug detection accuracy at lower maintenance costs compared to traditional testing methods.
Data Source
AI summary
An automated program repair system uses a neural transformer model with attention to predict a bug-free version of a method having a source code bug identified in an associated stack trace. The neural transformer model is pre-trained with English language text and the source code of a target programming language. The pre-trained neural transformer model is trained to create synthetic bugs in bug-free methods. The bug-free methods with the synthetic bugs are executed with a test case to obtain a stack trace of the source code bug. The method with the synthetic bug, without the bug, and its stack trace are used to train the neural transformer model to predict repairs for buggy methods.


