AI Code Review
Use the SDLC-Ainergy integration to perform initial code review with AI in the connected Git repositories.
For the integration to work, both SDLC and Ainergy applications need to be installed on your instance, and the Git integration needs to be active. There also needs to be an active profile settings record with the completed Connect field.
The prompt used by the integration is in Russian, and if you want the Ainergy to add comments in English, you need to edit the prompt in all instances of the Developer Panel widget. To do so, complete the following steps:
- Navigate to Portal Structure → Widget Instances.
- Use search to find the Developer Panel widget instances. Open one of them. You can view the table on the form of which this widget instance is located in the UI Form Elements related list.
- Edit the value of the Schema option values field: find the
Все комментарии — на русском;text and replace it withВсе комментарии — на английском;. - Do not change any other parts of the prompt: this could cause errors. Save the record.
- Repeat steps 2-4 for all instances of the Developer Panel widget to ensure the comments are added in English to tasks of all types.
Use the integration
You can perfom the AI code review of the tasks that you are allowed to edit.
To review the code with AI, complete the following steps:
- Open the form of the task whose merge request needs to be reviewed. Note that you can only review Open merge requests.
- Switch to the Developer Panel tab and there select Merge requests.
- Move the pointer over an Open merge request and click the icon that appears:

-
Wait for the AI to process the request and perform the code review. Do not close the page. The AI code review action will remain unavailable until the process is completed. You will see a toast message when the review is done.
- If code defects were found during the review, comments marked with AI Assistant will be added to the merge request in GitLab.
- If no code defects were found during the review, you will see a corresponding toast message.
- If errors occur, use the table below to find the solution.
noteDue to the difficulties in calculating the position of the comments, some of them might be located one or two lines higher or lower than the code they refer to.
Possible errors
If errors occur when you work with the integration, use the table below to find the solution.
| Error text | Description |
|---|---|
Error when reviewing the code in the !{number} merge request. View AI message | An error occurred in the work of the AI. Open the AI message via the link from the toast message for more details. |
| Failed to connect to the AI model from the configuration | Check the value of the sdlc.ai_chat.nexus system property: it might be incorrect or contain a nexus that is not of the Chat type. |
| Comment publication error in the !{number} merge request. Contact administrator. | The review has been completed successfully, but an error occurred during the publication of the comments. View the error message in the Main Log for more details. |
| Incorrect prompt. Configure the Developer Panel widget instance. | Check the Schema option values field value of the Developer Panel widget instance. There are two methods to do that. First method:
|
| No changes to be reviewed in the !{number} merge request | The merge request that you wanted to review is empty. Before initiating the review, ensure that the changes have been committed to the correct branch in GitLab. |
| Failed to fetch the data from Gitlab. Contact administrator. | An error occurred in GitLab. View the error message in the Main Log for more details. |
Incorrect or no positioning parameters for comments. View AI message | The AI response is incorrect. Try again. |