Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Info

If it is the first time you are using the app, most of the ChatGPT configuration are pre-filled for you. Some steps might therefore be already done.

As a repository administrator, follow these steps:

...

Repository Admin, go the Code Review Assistant repository settings

...

page. Make sure

...

to be on the AI Review Assistant tab on top

...

Request section

Section

Instructions

API URL

Enter the REST API address for ChatGPT: https://api.openai.com/v1/chat/completions.

If you are using Azure OpenAI, the address will be of the form https://{resource-name}.openai.azure.com/openai/deployments/{deployment-id}/completions instead.

...

API Key

Enter your ChatGPT API key

Headers

Click on the “Add Header” button and enter Authorization on the left side, and Bearer $API_KEY on the right side, as shown below

...

...

image-20250131-104028.pngImage Added

Query Parameters

(For Azure OpenAI Service Only) Click on the “Add Query Parameter” button and enter api-version on the name, and 2024-06-01 in the value.

Make sure to review what is the up-to-date version in the official Azure Documentation and use the latest value.

Request Body

  1. Click on the ➕ icon. Enter model in the input, then click on Add > Text and enter gpt-4o-2024-08-06.

The gpt-4-1106-preview model is the most up-to-date model at the time of this writing. Make sure to check-out the available models in their official documentation.

image-20250120-153634.pngImage Modified
  1. (Optional/Advanced) Customize the request body even further.

...

  1. Add other optional parameters as documented in the official OpenAI documentation.

...

In the API Key section, enter your ChatGPT API key.

...

Response Section

Section

Instructions

Success Query

Enter choices[0].message.content

...

...

Error Query

Enter error.message

...

Test and Save

Click on the

...

Test button

...

and verify that you

...

receive a confirmation message that everything is configured properly.

image-20250131-105140.pngImage Added

Click

...

on the Save button.

Info

If you have trouble in configuring our AI Review Assistant, we are happy to help! 🎉

...