Kilo CLI
Run the Kilo CLI terminal agent on Nebul models with an OpenAI-compatible custom provider.
Kilo CLI is Kilo Code's terminal agent: a fork of OpenCode that shares its configuration format, with agent modes, skills, session management, and CI-friendly automation. Because it speaks the OpenAI API format, it runs directly on your Nebul project's models.
Prerequisites
- A Nebul AI Studio account with API access
- An API key for your active project
- A model ID from the Model Catalog
Installation
npm install -g @kilocode/cliVerify it runs, then start it in your project directory:
kilo --version
cd /to/your/project
kiloConnect it to Nebul
Kilo CLI stores provider credentials separately from provider configuration, so setup has two steps.
1. Store your API key
Inside the kilo TUI, run:
/connectScroll to Other, enter a provider ID such as nebul, and paste your Nebul API key when prompted. The provider ID must match the key you use in the config file in the next step.
2. Register the provider
Kilo CLI reads the same config format as OpenCode. Create or edit kilo.jsonc in your project root, or ~/.config/kilo/kilo.jsonc for a global setup:
{
"$schema": "https://opencode.ai/config.json",
"model": "nebul/zai-org/GLM-5.3",
"provider": {
"nebul": {
"npm": "@ai-sdk/openai-compatible",
"name": "Nebul Inference API",
"options": {
"baseURL": "https://api.inference.nebul.io/v1"
},
"models": {
"zai-org/GLM-5.3": {
"name": "GLM 5.3",
"limit": {
"context": 1048576,
"output": 16384
}
}
}
}
}
}Notes on the fields:
modelis written asprovider_id/model_id, sonebul/zai-org/GLM-5.3here.- The key under
modelsmust exactly match a catalog model ID. limit.contextandlimit.outputshape how Kilo manages context and compaction. Takecontextfrom/v1/model/info; a conservative output cap like the one above is fine.
3. Select the model
Run /models inside Kilo, pick the Nebul model, and start coding. kilo models nebul from your shell lists the models registered on the provider.
Upgrading from opencode
Kilo no longer reads config from .opencode directories. Move your global config into ~/.config/kilo/ and any project config into ./kilo.jsonc or ./.kilo/.
Automation
For CI and scripts, Kilo runs without interaction:
kilo run "Explain what this repo does" --autoIn autonomous mode, operations that are not auto-approved are rejected rather than prompted, so review your permission config first. Resume your last session with kilo --continue.
Troubleshooting
- Provider not listed after
/connect: the provider ID you entered must match the key underproviderin the config file. 404on requests: the base URL must behttps://api.inference.nebul.io/v1, with the/v1suffix.- Model not found: the model key in config must exactly match a catalog ID, including vendor prefix and casing.
- Config edits not picked up: restart the CLI after editing
kilo.jsonc, or run/reloadinside a session.
Data and telemetry
Kilo's telemetry is on by default and can be disabled in ~/.config/kilo/kilo.jsonc:
{
"experimental": {
"openTelemetry": false
}
}If you want telemetry routed to your own observability stack instead, leave it on and set OTEL_EXPORTER_OTLP_ENDPOINT to your collector.
Requests to Nebul are covered by Privacy & Security.