FauxPilot: Self Hosted AI Coding Assistant

FauxPilot is an AI coding assistant compatible with VScode, the OpenAI API (limited), and with curl. As its name suggests, FauxPilot is similar to Github Copilot, having essentially the same functions. In this article, I will go over my experience setting up and using FauxPilot.

Setup

FauxPilot has a server and a client. The server runs the API and AI processing while the client sends requests. FauxPilot mainly uses NVIDIA GPUs but some users have gotten AMD GPUs to work as well. The server uses docker and requires nvidia docker to get GPU processing.

This was my first roadblock, nvidia docker was not trivial to set up. As it turns out, cuda is not directly available on ubuntu and any guides not by nvidia are most likely outdated. The guide by nvidia is extremely long but I found that their cuda download page has all the necessary commands on it, allowing me to skip reading the documentation.After installing cuda, I needed to install nvidia docker(also called nvidia container toolkit). I followed nvidia’s docs and everything went smoothly.

To get the server containers all I needed to do was clone the FauxPilot repo and run the setup script.

Experience

FauxPilot has many model options. The bigger the model is the better the AI. However, the larger models take up more vram or video memory. I have a 3070ti 8GB so I was only able to run the 350M and 2B models. The 350M model took about 2GB of vram while the 2B model took about 7GB.

I used vscode as the client and it worked alright. I used it as a more advanced autocomplete than for code generation. When I did try code generation It would generate about two or three lines before repeating or bugging out. This was partially fixed by using asapelkin’s modified version of the FauxPilot extension (I think this fix has been added to the main extension) which sends more data for the ai to anaylize.

I’m sure I would have gotten better results with the larger models, but I don’t have the hardware or money to run them. Overall I would say FauxPilot is for people who have the money and really don’t want Microsoft getting their data with github copilot.


Posted

in

,

by

Comments

Leave a Reply