Skip to main content

Cursor AI IDE

Cursor is an AI-powered code editor / IDE. Using LLMs to generate and review code, Cursor is an alternative to the very popular GitHub Copilot. You can use Cursor with your own Gaia node as the LLM backend. There are two big reasons for that

  • Your Gaia node could be supplemented by a knowledge base that is specific to your proprietary code repository, programming language choices, and coding guidelines / styles.
  • Your Gaia node could ensure that your code stays private within your organization.

Prerequisites

You will need a Gaia node to provide LLM API services. You can

In this tutorial, we will use public Qwen 2.5 Coder nodes to power Cursor.

Model typeAPI base URLModel name
Coderhttps://coder.gaia.domains/v1coder
Rust experthttps://rustcoder.gaia.domains/v1rustcoder

A limitation of Cursor is that it does not support local LLM services. A Gaia node comes with a default networking tunnel that turns your local LLM service into a HTTPS service accessible from the Internet. That allows Cursor to use your own private LLM for coding. Start your own Qwen Coder or Qwen Coder with Rust nodes today!

Configure Cursor

First, download and install Cursor. Click on the Settings button on the top right. Then, click on Models to configure the backend LLM service.

Second, add a model named coder and turn off all the other models like gpt-4o.

Third, go to the OpenAI API Key section,

  • Click on Override OpenAI Base URL. Type https://coder.gaia.domains/v1 here.
  • For the OpenAI API key, you can use any random chars such as GAIA. Click on Verfiy to test if the connection is correct.

Use Cursor

You can use

  • command + K to edit the highlighted code
  • command + L to open the chat room and ask questions about the code.