JavaPhoenix: AI-powered code regeneration and error resolution for Java programs
Disclaimer: Please note that JavaPhoenix is a prototype and has not undergone extensive testing. While it demonstrates the concept of automated code repair using AI, it may not handle all edge cases or complex scenarios. We encourage users to test the tool in a safe environment and provide feedback for improvements. Use at your own risk.
JavaPhoenix is an AI-powered code assistance tool that gives Java programs the ability to regenerate and heal from errors. Inspired by the regenerative abilities of comic book characters, JavaPhoenix uses a language model to analyze Java code, identify errors, and suggest fixes to resolve them.
- Code Execution: Compiles and runs Java code to identify errors.
- Error Handling: Captures Java-specific error information for analysis.
- Language Model Interaction: Uses a language model API to suggest code fixes based on error details.
- Code Editing: Applies suggested edits to the Java code while considering Java-specific syntax and formatting.
- Java Development Kit (JDK) installed on your system.
- An API key for the language model API (e.g., OpenAI GPT-4).
-
Clone this repository to your local machine.
-
Open the project in your preferred Java IDE.
-
Locate the placeholder
YOUR_API_KEY_HERE
in the code and replace it with your own language model API key. Alternatively, set the API key as an environment variable.
- Use the provided methods in the JavaPhoenix class to execute and analyze your Java code.
- Input your Java code into the tool and run it to receive feedback on errors and suggested fixes.
We welcome contributions to the JavaPhoenix project! If you'd like to contribute, please feel free to fork the repository, make changes, and submit a pull request.
JavaPhoenix is a prototype tool and should be used with caution. Always review the suggested code changes and test the code thoroughly before deploying it to production environments.
This project is licensed under the MIT License.
- The original inspiration for this project came from the "wolverine" Python tool.
- Thank you to all contributors and users of JavaPhoenix!