tools

development

AI

Top Free AI Coding Assistants

Explore some of the finest free AI coding assistants that elevate your coding experience by offering intelligent suggestions, identify code smells & security vulnerabilities, and provide invaluable debugging assistance. Boost your productivity, write cleaner code faster and focus on what's important

August 9, 2023
05 Mins read

Share it:

Coding assistance has been available in IDEs such as Visual Studio and Eclipse for quite some time. This capability, commonly referred to as intelligent code completion, presented users with features like auto-completion suggestions during typing, insights into function parameters, and prompts for syntax errors. While undeniably beneficial, these offerings were somewhat limited in their true “intelligence” factor.

Five years ago, Microsoft announced IntelliCode, a progression of the IntelliSense feature in Visual Studio. With IntelliCode, developers got a peek into the realm of true AI-assisted coding. IntelliCode introduced the capability to suggest entire lines of code - a big leap over existing intelligent code completion tools.

Today, the rapid emergence of AI-assisted coding tools, powered by Large Language Models, is reshaping the coding landscape at an astonishing pace. AI-coding assitants save developers from reading a lot of technology documentation and writing/re-writing of otherwise boilerplate code.

Empowered by AI coding companions, developers can swiftly handle low-level coding tasks, freeing up valuable time to concentrate on more strategic and creative aspects - higher order tasks such as engaging with business, brainstorming, optimizing, and designing.

Without further ado, lets get into our top picks for free/freemium AI-assisted coding tools

Cody

Cody is a free and open source AI coding assistant developed by Sourcegraph to provide intelligent code completions and suggestions. Cody is quickly emerging as a worthy contender to GitHub Copilot with its ability to provide relevant suggestions from massive codebases, identify code smells and security issues, and offer debugging hints.

Context awareness is a key strength of Cody. It takes the context of the repository you’re working on and scans the whole codebase as opposed to just the file(s) you’re working on. This enables it to provide suggestions that are tailored to the specific codebase and coding style. Its also very useful to new team members trying to understand an existing codebase.

Apart from intelligent code completions & an IDE integrated ChatGPT like inteface, one can run refactoring commands via the context menu or with an inline chat interface like below

Cody Inline Chat

There is also the Cody App which is a native desktop application that can be used without an IDE. It can scan multiple local repositories/codebases and provides suggestions based on the context. The Cody VS code extension works only on current codebase open in the IDE, to work with multiple codebases, connect Cody App & the VS code extension.

LLM’s used: Anthropic Claude/OpenAI GPT-4 with reasonable per-user rate limits

Try Cody

Bito

Bito is another very promising AI coding assistant combining code intelligence, documentation, test generation, and analysis into a single productivity tool for developers. Bito has an IDE integrate ChatGPT like interface for asking queries and getting suggestions. At the time of this writing Bito doesn’t seem to provide code suggestions inline in code files. Bito helps you generate code from the chat interface and can insert code directly at the cursor position in code files.

Most of the Bito’s features are summarized in the image below - you would select a section of code and use the templates to perform a specific task. Initially the chat interface is used for inference and providing suggestions, but Bito also generates code snippets that are shown in a diff panel and can be inserted at the cursor or replace selected code.

Bito Templates

Bito also has a CLI for automation, that stands out from other assistants. You can run commands from the terminal to perform tasks like creating documentation, git commit messages, etc. The CLI opens up many possibilities of creating automation workflows for CI/CD pipelines, for instance.

Bito currently has a personal plan with access to all features. Bito is under heavy development and more features are being added at a rapid pace, some of which may go in the enterprise plan eventually.

LLM’s used: Anthropic Claude/OpenAI GTP3.5 Turbo/GPT-4

Try Bito

Amazon CodeWhisperer

From the house of Amazon comes Amazon CodeWhisperer, an AI-powered coding assistant designed to assist developers in writing clean, unbaised & secure code. Amazon CodeWhisperer takes GitHub Copilot head on with similar features and its free tier for individual developers.

CodeWhisperer has three main features

  • Code suggestions
  • Code security scans
  • Reference tracking

Code suggestions feature is similar to other products in this space, powered by LLMs trained on large amounts of amazon & open source code. If you are using AWS services, CodeWhisperer would be a better choice since its code suggestions are optimnized for AWS APIs.

Security scans identify vulnerabilities (such as top 10 OWASP) and provide intelligent suggestions on how to remediate them. Security scans are currently only supported for Python, Java & JavaScript. More languages maybe supported in future.

Reference tracking is a feature which detects and flags if a code suggestion resembles open-source training data. This is important because not all open-source projects have permissive licenses, reuse of code from many open-source projects will require proper license attribution.

Try Amazon CodeWhisperer


So far we have reviewed tools that, in the free plan atleast, send code snippets from your local system to the remotely hosted model and that maynot be ideal/acceptable in many cases. One should make sure to check and comply with company/client policies to ensure code/data privacy while using tools leveraging remote hosted models like above in an enterprise setting.

Can we have self-hosted AI coding assistants? Lets review a couple options

Tabby

Tabby brands itself as an opensource self-hosted alternative to GitHub Copilot. While in early alpha phase, Tabby offers a great choice to individuals and enterprises that want to avoid sending their data and code to remote models.

Tabby has two parts

  • IDE extension (VS code, IntelliJ…)
  • Tabby server (self-hosted model)

The IDE extension needs to be configured to talk to Tabby Server.

Tabby

Checkout Tabby

StarCoder

StarCoder is a 16B parameter model trained on one trillion tokens sourced from 80+ programming languages, GitHub issues, Git commits, and Jupyter notebooks, all permissively licensed.

Although more work, the model could be self hosted and a coding assistant can be created. Here is a detailed article on how to achieve this.

Checkout StarCoder

UPDATE: 30/8/2023 (Added Code Llama)

Code Llama

Meta AI recently released Code Llama that can be used for code generation and is free for research and commercial use. Code Llama is a code-specialized version of Llama 2 that was created by further training Llama 2 on its code-specific datasets. Code Llama can generate code, and natural language about code, from both code and natural language prompts. Code Llama has been released in three sizes - small (7B parameters), medium (13B parameters) and large (34B parameters). The 34B model returns the best results and allows for better coding assistance, but the smaller 7B and 13B models are faster and more suitable for tasks that require low latency, like real-time code completion. The models can be downloaded after requesting access.

llama2-webui is one good option to run Code Llama locally with an UI.

Summary

AI coding assistants have transformed the way developers write code. By leveraging the power of artificial intelligence, developers can now benefit from smart suggestions, accurate completions, and code error detection, making their coding journey smoother and more productive. Among the top free AI coding assistants covered in this blog, each tool brings unique capabilities to cater to the diverse needs of developers. Incorporating these intelligent coding assistants into your workflow will undoubtedly help you write cleaner code, boost your productivity, and stay ahead in the ever evolving world of programming.


Disclaimer
This blog post is intended for informational purposes only. While efforts have been made to ensure the accuracy of the information presented, the author does not assume any responsibility for errors, inaccuracies or omissions. Mention of any product, service or company does not constitute an endorsement.