Skip to content

VS Code AI Assistant

GitHub Copilot Chat in Visual Studio Code lets you register custom language models via Manage Language Models. This guide shows how to connect VS Code directly to our Swiss LLMaaS Gateway — chat with our models, generate code, and run agent mode without your data ever leaving Switzerland.


Key Features

  • Native IDE Integration: Chat directly inside VS Code (Ctrl+Alt+I) — no terminal or separate tool required.
  • Tool Calling: The model can read files, apply edits, and execute terminal commands (agent mode).
  • Large Context: Up to 128,000 input tokens — enough for repository-wide conversations.
  • Full Data Sovereignty: All prompts and source code are processed exclusively on our Swiss GPU infrastructure.

Prerequisites

  • VS Code (current version) with the GitHub Copilot Chat extension.
  • A personal API key for the LLMaaS Gateway (format sk-bf-...). If you don't have one yet, request a virtual key through the Cloud Service Portal or our support team.

Handle API keys with care

Never commit your API key to a repository. VS Code stores the key as a secret and references it via a ${input:...} placeholder — keep it that way.


1. Add the Model

  1. Open the command palette: Ctrl+Shift+P
  2. Select Chat: Manage Language Models
  3. Choose Add ModelsCustom Endpoint
  4. Enter your credentials:
    • Group Name: EW
    • API Key: your personal key (sk-bf-...)

2. Configuration

The model is registered as a Chat Completions provider with the following configuration:

[
    {
        "name": "everyware",
        "vendor": "customendpoint",
        "apiKey": "${input:chat.lm.secret.xxxxxx}",
        "apiType": "chat-completions",
        "models": [
            {
                "id": "ew/glm-5.3-flash",
                "name": "GLM 5.3 Flash",
                "url": "https://ai.ewcs.ch/v1/chat/completions",
                "toolCalling": true,
                "vision": false,
                "maxInputTokens": 128000,
                "maxOutputTokens": 16000
            }
        ]
    }
]

Configuration Parameters

Parameter Value Description
name everyware Display name of the provider in VS Code
vendor customendpoint Provider type (OpenAI-compatible endpoint)
apiKey ${input:...} Reference to the secret stored in step 1 — no hardcoded keys
apiType chat-completions Protocol of the endpoint
id ew/glm-5.3-flash Model identifier for the API
url https://ai.ewcs.ch/v1/chat/completions API endpoint
toolCalling true Enables agent features (file access, terminal)
vision false Image input is not supported
maxInputTokens 128000 Maximum context size
maxOutputTokens 16000 Maximum response length

3. Open the Chat

Open the Chat panel with Ctrl+Alt+I, select GLM 5.3 Flash in the model picker — done!


Corporate Proxy

In corporate networks, VS Code typically reaches ai.ewcs.ch through an HTTP proxy. VS Code uses the same network stack as Chrome and picks up the proxy settings from your operating system automatically — if your OS proxy is configured correctly, no extra setup is needed.

To configure the proxy explicitly, either start VS Code with a command-line argument:

code --proxy-server=http://proxy.example.com:8080

or set the proxy in your settings.json:

{
    "http.proxy": "http://proxy.example.com:8080",
    "http.proxySupport": "override"
}

Authenticated proxies (Basic, NTLM, Negotiate) are supported — VS Code shows a login prompt when the proxy requests credentials.

TLS Inspection / Custom Certificates

If your company uses TLS inspection or its own certificate authority, add the CA certificate to your operating system's trust store — VS Code then trusts it automatically:

  • Windows / macOS: Import the certificate via the system certificate manager.
  • Linux: Copy the certificate to /usr/local/share/ca-certificates/ and run sudo update-ca-certificates (Ubuntu/Debian), or place it in /etc/pki/ca-trust/source/anchors/ and run sudo update-ca-trust (RHEL/Fedora).

Never disable certificate checks

Do not work around TLS inspection with the --ignore-certificate-errors flag or by disabling certificate validation — this would expose your API key and prompts to interception. Ask your IT team for the official CA certificate instead.


Typical Prompts and Workflows

  • Code Analysis: "Explain the architecture of this repository and show me where the API calls are made."
  • Refactoring: "Optimize error handling in this module and add unit tests."
  • Agent Mode: "Run the linter and fix all reported syntax errors."

Alternative: OpenCode Agent

Prefer working in the terminal? The OpenCode Agent offers the same LLMaaS integration with multi-agent workflows and intelligent model routing.

Last updated: September 2026