Is the NEW JetBrains AI better than GitHub Copilot? | My AI Setup July 2024

Is the NEW JetBrains AI better than GitHub Copilot? | My AI Setup July 2024

On the first of July, JetBrains announced improved code completion in their AI Assistant, so I subscribed to test it out and save you some time and money. Is it going to be better than Copilot? Let’s discover it in the next few minutes!

Setting up

To try out the improved AI Assistant, you need the 2024.2 early access program version 7 of IntelliJ.

JetBrains claims that the new AI assistant offers improved single and multi-line code completion for Java and Kotlin. It’s powered by their own models, which should provide higher quality and reduced latency.

JetBrains announces improved code completion in AI Assistant

Let’s check it out.

Latency

When it comes to latency, I noticed immediately a definite improvement. Back in February, inline completion was slow and almost unusable, while today it produces suggestions timely. I still think is less responsive than Copilot and Codeium but it’s at least usable.

As you might know, IntelliJ performs code completion in two different ways: single-line and multi-line. Single-line suggestions are shown first because they are powered by a model deployed on our device with no interaction over the network with any cloud service. I think this is a clever trick to reduce the perceived latency without increasing traffic over the wire.

Once we accept a single-line suggestion, the assistant will display a multi-line suggestion if available.

Quality

Next, let’s talk about the quality of the suggested code.

I find JetBrains AI suggestions to be often very small snippets of code compared to Copilot or Codeium. One could argue that this approach should lead to more relevant suggestions. However, I don’t think that’s the case. You still have to discard many suggestions and there’s no way to quickly cycle through different options like you can do with Copilot.

Example of a code snippet suggested by JetBrains AI

I also noticed that the assistant often refuses to give a suggestion unless you add more context to the file you are editing. Sometimes, it’s just a matter of adding a comment specifying what you intend to implement. This is very different from Copilot and Codeium which, in my opinion, are better at capturing the project’s context and coming up with suggestions without needing any comment.

Prompts

The prompting system still feels clunky and slow. Even though it generates more code when prompted, the quality is still questionable. Something I find extremely irritating is when it includes the imports within the class body. I was hoping this issue would be addressed in this new version, but that’s not the case.

JetBrains Prompting System

Conclusion

In conclusion, I’ve already canceled my subscription for the JetBrains AI assistant because I don’t think it’s on par with the competition. Despite some noticeable improvements, I feel it’s still playing catchup with more mature products like GitHub Copilot.

The combo of Microsoft and GitHub with OpenAI will be very difficult to beat. I’ve been subscribing to ChatGPT Plus for $20 a month because I’m impressed by the capabilities of the GPT-4o model. It produces the best code suggestions I’ve seen in any tool and it’s incredibly fast. In fact, despite back in February I stated that I prefer inline code completion to prompts, I now changed my mind. I feel both approaches can coexist and lead to faster feature development and better code quality.

While in an enterprise context I’d use Copilot because of its deep integration with GitHub, I use Codeium as the AI assistant integrated into my personal IDE. The reason is that it’s free for individual use, fast, and the quality of the suggestions is similar to Copilot. The cost of monthly subscriptions can quickly add up and it’s annoying having to pay multiple services that are leveraging similar models.

What about your setup? Let me know in the comments! If you find the article useful, like and share so that everyone can learn something new.