GPT Code Review is an automatic code review application designed to provide feedback on GitLab Merge Requests using the GPT-4 model from OpenAI.
This application listens for webhooks from GitLab whenever a merge request is created or updated. It then uses GPT-4 to generate a review of the code changes and posts this review as a comment on the merge request.
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.
To run this project, you'll need to install the following:
- Python 3.7 or later
- Git
- Pip (Python package installer)
- Clone this repository:
git clone https://github.com/mgennings/GPT-code-review.git
cd GPT-code-review
- Install the required Python libraries:
pip install -r requirements.txt
- Create a
.env
file with your configuration values:
cp .env-example .env
- Update the
.env
file with your OpenAI API key, GitLab URL, and GitLab private token.
Run the application with the following command:
python app.py
We welcome contributions! Please see CONTRIBUTING.md for details on how to contribute.
This project is licensed under the MIT License - see the LICENSE.md file for details.