> ## Documentation Index
> Fetch the complete documentation index at: https://docs.lithosai.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Use LithosAI with VS Code

> Connect the built-in chat in VS Code to LithosAI with a Custom Endpoint model.

<Note>
  This guide configures the chat built into VS Code. Agent extensions keep their own
  provider settings: if you use Kilo Code in VS Code, follow the
  [Kilo Code guide](/agent-integrations/kilo-code) instead.
</Note>

## Before you begin

Install VS Code 1.122 or later, create a key on the [API Keys](https://console.lithosai.cloud/keys) page,
and choose a model on the [Models](https://console.lithosai.cloud/models) page.

<Steps>
  <Step title="Add a Custom Endpoint">
    In the Chat view, open the model picker (**Models**) and select **+**, or run
    **Chat: Manage Language Models** from the Command Palette.
    The **Language Models** editor opens.

    Select **Add Models → Custom Endpoint**. VS Code asks for these values in turn:

    | Prompt | Value |
    | - | - |
    | Group Name | `LithosAI` |
    | API Key | Your LithosAI API key |
    | API Type | **Chat Completions** |
  </Step>

  <Step title="Configure the model">
    VS Code opens `chatLanguageModels.json` with a `LithosAI` entry and an empty model.
    Leave `name`, `vendor`, `apiKey`, and `apiType` as VS Code wrote them: `apiKey` refers to
    the key you entered, which VS Code keeps in secret storage. Replace the empty model under
    `models` with the entry below and save the file.

    The entry below uses `moonshotai/Kimi-K3-fast` as an example.

    <Accordion title="VS Code model entry">
      ```json theme={null}
      {
        "id": "moonshotai/Kimi-K3-fast",
        "name": "moonshotai/Kimi-K3-fast",
        "url": "https://api.lithosai.cloud/v1/chat/completions",
        "toolCalling": true,
        "vision": false,
        "maxInputTokens": 1015808,
        "maxOutputTokens": 32768,
        "thinking": true,
        "supportsReasoningEffort": ["low", "high", "max"],
        "reasoningEffortFormat": "chat-completions"
      }
      ```
    </Accordion>

    Set `url` to the full Chat Completions endpoint, not the base URL. VS Code treats
    `maxInputTokens` plus `maxOutputTokens` as the context window, so set `maxInputTokens`
    to the model's context window minus `maxOutputTokens`.

    To add another model or tier, copy the entry under `models` and update its `id`, `name`,
    and token limits using the [model catalog](https://console.lithosai.cloud/models).
  </Step>

  <Step title="Start a conversation">
    In the Chat view, select **New Chat** (`+`), set **Session Target** to **Local**, and choose
    your LithosAI model in the model picker. Select **Agent** in the agent picker to let the model
    edit files and run tools.
  </Step>
</Steps>

## Model and reasoning effort

* **Model and tier:** Use the model picker in the Chat view.
* **Reasoning effort:** In the model picker, select **>** next to your LithosAI model to open
  **Thinking Effort**, then select **low**, **high**, or **max**. VS Code remembers the level for
  each session.

## Use VS Code without a GitHub account

Chat and Agent sessions with a LithosAI model work without a GitHub sign-in or a Copilot plan.
Without a sign-in, VS Code has no model for background tasks such as chat titles and
commit messages, and it shows **Set BYOK utility models** in the Chat view. Setting utility models
is optional. To enable those tasks, open Settings and select your LithosAI model for
`chat.utilityModel` and `chat.utilitySmallModel`. VS Code recommends a fast, inexpensive model
for `chat.utilitySmallModel`. Each background task is a separate LithosAI request.

Inline suggestions (code completions) and semantic search still require a GitHub account.

## Limitations

* The **Copilot** session target and the **Agents** window don't list LithosAI models by
  default. To use them there, enable `chat.agentHost.byokModels.enabled`, which VS Code
  marks as experimental.
* On Copilot Business or Enterprise, your administrator can disable the
  **Bring Your Own Language Model Key in VS Code** policy. You then can't add LithosAI models.

Issues common to every agent are listed under [Common issues](/agent-integrations#common-issues).

## Resources

* [VS Code language models](https://code.visualstudio.com/docs/agent-customization/language-models)
* [VS Code agent harnesses](https://code.visualstudio.com/docs/agents/run/agent-harnesses)
* [LithosAI models](https://console.lithosai.cloud/models)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.