Continue.dev Setup Guide

Continue.dev: The Open Source AI Coding Assistant Setup Guide

Continue.dev is a leading open-source AI coding assistant that brings the power of large language models directly into your IDE. Unlike proprietary solutions, Continue gives you full control over which AI models you use, how your data is handled, and how the assistant behaves. This guide walks you through setting up Continue.dev with various AI backends, including how to use an API relay service for reliable, cost-effective access.

What Is Continue.dev?

Continue is a free, open-source extension for VS Code and JetBrains IDEs that provides AI-powered code completion, chat, and editing capabilities. It supports multiple LLM providers out of the box, including Claude, GPT, Gemini, Ollama, and any OpenAI-compatible API endpoint.

Installing Continue.dev

Getting started takes just a few steps. Open your IDE's extension marketplace, search for "Continue", and install it. Alternatively, use the command line:

# VS Code — install from the marketplace
code --install-extension Continue.continue

# JetBrains — install from the plugin marketplace
# Search "Continue" in Settings → Plugins → Marketplace

After installation, Continue will appear as a sidebar panel. You will need to configure at least one AI model provider before you can start using it.

Configuring AI Model Providers

Continue stores its configuration in ~/.continue/config.json (or config.yaml in newer versions). Here is how to set up the most popular providers:

Using Claude via API Relay

If you want to use Claude models without dealing with regional restrictions or rate limits, an API relay service like claude4u.com provides a reliable intermediary. Configure it as an OpenAI-compatible endpoint:

{
  "models": [
    {
      "title": "Claude Sonnet 4",
      "provider": "openai",
      "model": "claude-sonnet-4-20250514",
      "apiBase": "https://claude4u.com/v1",
      "apiKey": "your-relay-api-key"
    }
  ]
}
Using a relay service like claude4u.com gives you unified billing, automatic load balancing across multiple accounts, and avoids the hassle of managing API keys for each provider separately.

Using OpenAI Directly

{
  "models": [
    {
      "title": "GPT-4o",
      "provider": "openai",
      "model": "gpt-4o",
      "apiKey": "sk-..."
    }
  ]
}

Using Local Models with Ollama

{
  "models": [
    {
      "title": "CodeLlama Local",
      "provider": "ollama",
      "model": "codellama:13b"
    }
  ]
}

Setting Up Tab Autocomplete

Tab autocomplete is one of Continue's most productive features. It works best with fast models optimized for code completion. Configure it separately from chat models:

{
  "tabAutocompleteModel": {
    "title": "Claude Haiku (Fast)",
    "provider": "openai",
    "model": "claude-3-5-haiku-20241022",
    "apiBase": "https://claude4u.com/v1",
    "apiKey": "your-relay-api-key"
  }
}
For autocomplete, choose the fastest model available. Claude Haiku or GPT-4o-mini provide an excellent balance of speed and quality. You can use a different, more capable model for chat and inline editing.

Custom Slash Commands

Continue lets you create reusable prompt templates as slash commands. Add them to your configuration:

{
  "customCommands": [
    {
      "name": "review",
      "description": "Code review with best practices",
      "prompt": "Review the selected code for bugs, performance issues, and best practices. Suggest improvements with code examples."
    },
    {
      "name": "test",
      "description": "Generate unit tests",
      "prompt": "Write comprehensive unit tests for the selected code. Use the project's existing test framework."
    }
  ]
}

Context Providers

Continue can pull context from various sources to give the AI a deeper understanding of your project:

Best Practices for Continue.dev

  1. Use different models for different tasks. A fast model for autocomplete and a powerful model for complex refactoring keeps costs down while maintaining quality.
  2. Leverage context providers. The more context the model has, the better its suggestions will be. Use @codebase for large-scale changes.
  3. Create project-specific slash commands. Encode your team's coding standards and review checklists as custom commands.
  4. Use a relay service for production teams. Services like claude4u.com provide unified billing, rate limit management, and multi-model access through a single API key.
  5. Keep your configuration in version control. Share .continue/config.json across your team for consistent AI behavior.
Never commit API keys to version control. Use environment variables or a secrets manager, and configure Continue to read keys from environment variables using the CONTINUE_API_KEY variable.

Troubleshooting Common Issues

If Continue is not connecting to your AI provider, check these common causes: incorrect API base URL format (ensure no trailing slash), expired or invalid API keys, network proxy settings blocking outbound requests, and firewall rules preventing access to the API endpoint. The Continue output panel in VS Code shows detailed connection logs that help diagnose most issues.

Continue.dev represents the best of open-source AI tooling — flexible, transparent, and powerful. Combined with a reliable API relay service, it gives developers a professional-grade AI coding assistant without vendor lock-in.

Get Started with 轻舟 AI

Stable, fast AI API relay — supports Claude, OpenAI, Gemini and more

Sign Up Free