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

# Kilo Code

> Hubungkan Kilo Code dan Kilo CLI ke TokenLab

## Ikhtisar

<Note>
  **Tipe**: agen coding IDE dan CLI

  **Jalur utama**: Chat Completions kompatibel OpenAI

  **Dukungan**: jalur penyedia khusus resmi
</Note>

[Kilo Code](https://kilo.ai/docs/ai-providers/openai-compatible) mendukung penyedia kompatibel OpenAI pada ekstensi VS Code dan CLI.

## Instalasi dan UI

Instal kanal pre-release **Kilo Code** di VS Code atau instal CLI:

```bash theme={null}
npm install -g @kilocode/cli
kilo --version
```

Buka **Settings → Providers → Custom provider**.

| Kolom        | Nilai                        |
| ------------ | ---------------------------- |
| Provider ID  | `tokenlab`                   |
| Display name | `TokenLab`                   |
| Provider API | **OpenAI Compatible**        |
| Base URL     | `https://api.tokenlab.sh/v1` |
| API key      | TokenLab API Key Anda        |
| Model        | `kimi-k3`                    |

Kilo mendeteksi model melalui `/v1/models`. Setelah disimpan, pilih `tokenlab/kimi-k3`.

## Konfigurasi CLI

Simpan Key di variabel lingkungan dan edit berkas global tepercaya `~/.config/kilo/kilo.jsonc`:

```bash theme={null}
export TOKENLAB_API_KEY="sk-your-tokenlab-key"
```

```jsonc theme={null}
{
  "$schema": "https://app.kilo.ai/config.json",
  "model": "openai-compatible/kimi-k3",
  "provider": {
    "openai-compatible": {
      "options": {
        "apiKey": "{env:TOKENLAB_API_KEY}",
        "baseURL": "https://api.tokenlab.sh/v1"
      },
      "models": {
        "kimi-k3": {
          "name": "Kimi K3",
          "tool_call": true,
          "reasoning": true,
          "limit": { "context": 1048576, "output": 131072 }
        }
      }
    }
  }
}
```

Mulai ulang Kilo lalu jalankan `kilo models`. `{env:...}` hanya diresolusi dalam konfigurasi global atau terkelola yang tepercaya. Jangan tulis Key asli di konfigurasi proyek yang mungkin masuk Git.
