Inspiration

While Git is a powerful tool, it can be difficult for new users to remember which commands are needed to perform a specific task. Git Assistant hopes to ease this difficulty by using AI to work out what command the user needs to run based on a simple natural language description of what they're trying to do, which should hopefully make it easier for new users to get into using Git. This system could ultimately be expanded to work with a variety of non-git commands, making it easier for beginners to start using the command line in general, without having to memorize lots of specific commands.

What it does

Git Assistant is a fairly simple piece of software. It takes natural language from the command line, and sends it to BJSS's chat bot Accelerator API for processing in the cloud. We have trained our bot to recognize some common Git tasks, such as committing and switching branches. The Accelerator bot responds by telling the client application which Git command to run in order to complete the user's request. Rather than using Git directly, Git Assistant actually uses Metro, our simplified Git wrapper that aims to make Git easier to use and therefore more suitable for control via natural language.

How we built it

Git Assistant is written in Python, using HTTPS to communicate with the Accelerator API.

Challenges we ran into

We were unable to access the repository for the client software normally used to access the API, so we had to learn how to use HTTPS to access the API directly. This process was somewhat convoluted due to the very specific way in which the connection details have to be formatted and hashed, but we worked it out eventually! We also had to come up with a lot of training samples to ensure that the bot is able to understand a wide variety of strange phrasings for commands.

Accomplishments that we're proud of

Actually finishing a hackathon project for once! Most of our hackathon projects in the past have taken too long or turned out to be technically infeasible, so it is good to be able to finish a project that could be useful to people in the future.

What we learned

How chat bots are built and trained, and how to send HTTP requests from Python.

What's next for Git Assistant

The next steps will be to add more training examples so it is better at understanding commands phrased in different ways, and expand it to work with more of Metro and Git.

Built With

Share this project:

Updates