top of page

Your one-stop guide to AutoCodeRover

josephcnsg

Welcome to AutoCodeRover


In this series of blogposts, we will explore how you can use AutoCodeRover to maintain your software systems, by generating patches for your code using various sources of issue description. Let's dive right into it!


Registration


On the login page, create an account for AutoCodeRover if you have not yet done so, or simply sign in using your Google or GitHub accounts.



Dashboard


After signing in, you will be greeted with your Dashboard containing the various Projects, Tasks, and Runs you have added. You will also be able to configure your user settings via the dropdown located on the top right corner of the page. Now, let us take a look at creating Projects and Tasks, and create your first Run using AutoCodeRover!



Projects


To create a new Project, first click on the 'Projects' section on the Navigation bar to the left. Here, you can see all the projects you have added, as well as create new projects or import them via a Version Control Service such as GitHub. For now, let us try manually adding and customizing our first project, by clicking the '+ Add Project' button.



For this example, we will add a public repository hosted on GitHub (stay tuned for adding private repositories!), and configure our AutoCodeRover Project to match the various project descriptions. Here is the link to our example public GitHub repo: https://github.com/AutoCodeRoverSG/simple-repo


On the 'Add New Project' page, choose a name for your new project, as well as an optional local path for this repository on your local machine, which, in a soon-to-be-deployed feature, will allow you to directly open and apply the patch generated by AutoCodeRover on your local IDEs. Select the appropriate repository source, visibility, and URL to ensure that AutoCodeRover can access your repository. As this example is for a public repo, we can leave the default repository token option as it is.


AutoCodeRover currently supports the following languages (with more on the way!) :

  • Python

  • C

  • C++

  • Java

  • JavaScript

  • TypeScript

  • PHP

  • Go


We will select 'Python' for our example, but you can also include all languages that apply for your own project.



Since GitHub supports both a Verision Control System and an Issue Tracker, let's also configure a Issue Tracker for our Project, by clicking on 'Add Issue Tracker' and filling in the information of our GitHub repository, as shown in the figure below:



Once that is done, click on 'Create Project' and -- voila! We have created a Project using information from our GitHub Repository, and we are now ready to create Tasks for AutoCodeRover, to help us generate patches for this Project.


Adding and Running Tasks


Continuing with the Project we had just created - we can see the project details page. Here, we can view the project descriptions we had just configured, and are free to modify them by clicking the 'Edit' button as well. If you wish to remove this Project, simply click on the 'Delete' button, which will remove this Projects and Tasks related to it as well. However, all Run records that AutoCodeRover had generated for this Project will be kept in your Activities tab, and you will be able to refer to them in future even after deleting the Project.


That said, it is time to create a Task! We can either manually add individual tasks, or import them from a Version Control Service like GitHub. Let's first take a look at manually adding a Task, using the same public GitHub repository as our example. After clicking on the '+ Add Task' button, we are prompted to fill in the Task details, and we will do so by taking the information from this GitHub Issue here: https://github.com/AutoCodeRoverSG/simple-repo/issues/1.


If the default GitHub Issue description is sufficient, we can simply provide the Issue link by adding that as the Task URL, as seen in the figure below. Alternatively, we can provide further elaborations in the Description field, that describes the Task we want AutoCodeRover to carry out when generating a patch. If we wish to provide our own description for the task, simply leave the URL field blank, and write the task descriptions in the description field.



Once the details have been filled, click on 'Create Task', and we will be directed to the Task details page, where we can select the LLM provider, model, and LLM API key that AutoCodeRover will be using to generate our code patch. As of the writing of this blog, we are providing all users with 20 free complimentary credits, which can be used to explore the features provided by AutoCodeRover.




Now, back to running our newly added Task: click on the 'Run' button, select your favourite LLM provider and model, choose a key, and click on 'Run Task' - Nice! AutoCodeRover is now working to generate a patch for our Project, in order to fix the issue described by the Task we have just added.



Tasks - Importing via GitHub


While we wait for AutoCodeRover to generate a patch for the previous Task we just added, let's take a look at how we can create Tasks more easily by importing them - from GitHub Issues.


Navigate back to the Project details page, and locate the 'Import Tasks' button that is right beside the 'Add Task' button. If we did not configure an issue tracker for our project previously, this 'Import Tasks' button will prompt us about that. However, since we have added GitHub as our issue tracker for this project, we can choose to import tasks from GitHub - instead of adding each one individually.



Now, we are prompted to choose a token for importing tasks. As our example repo is publicly visible, we can proceed with selecting 'No Token', and - there we go! All the Open GitHub Issues that belongs to this repo are loaded on this screen, and we can easily import them by either ticking the checkboxes or by entering their issue numbers, or both! If the default Task description from the Issue description is insufficient, we can also modify it on the Task details page by clicking the 'Edit' button.






Run Details


Let's see if AutoCodeRover has finished generating a patch for our previous task, shall we? Click on the Task which we manually added earlier, look at the section containing the Run History - and it seems that our Run is complete!



Let's click on the Run number (WebTask#171 in the example) to see what patch has AutoCodeRover generated for us. On the 'Info', 'Output' and 'Patch' tabs of our Run Details page, we can view the run information, the entire conversation dialogue, as well as the final patch generated. If the patch is to our liking, we can then choose to copy or download it as a .diff file onto our local machine, and apply it to our codebase.




With that, we have seen how we can easily setup AutoCodeRover to generate patches for our Public GitHub repositories. In the next guide, we will look at doing so for Private GitHub repoitories - which will require us to first add some GitHub Personal Access Tokens to our AutoCodeRover account.

22 views0 comments

Recent Posts

See All

Kommentit


bottom of page