Use AI to Find Errors
Last updated 18/07/2023
Five's inbuilt AI allows you to check for errors in your code while in the Code Editor. You can either highlight a selection of code or run the check on the entire code block. By default, if no code is highlighted, the entire function will be checked for errors.caution
The length of your code block getting checked will determine how quickly the result is returned.
Check for Errors in Your Code
Prerequisites- OpenAI API key configured
- Code block is opened in Five's Code Editor
1. Highlight a section in your code block.
2. Click the Check for Errors button.
Figure 1 - Check for Errors button
info
Any errors found in the highlighted section will be returned with how to fix the issue. In this scenario a closing parenthesis is missing.
Figure 2 - Error returned
3. Edit your code.
Figure 3 - Edit your code
4. Highlight the same section in your code block.
5. Click the Check for Errors button.
Figure 4 - Check for Errors button
info
You are informed there are no syntax errors in the highlighted section, however, logical errors can't be determined due to the amount of lines highligthed,
you can easily rectify this by highlighting more lines of code.
Figure 5 - No syntax errors