Configuration
Nilux AI reads settings from a configuration file and environment variables. This page documents all available options.
Configuration File
The main configuration file is located at:
~/.nilux/config.json
If the file does not exist, Nilux AI creates it with defaults on first run.
Available Options
| Option | Type | Default | Description |
|---|---|---|---|
api_key | string | — | Your Nilux API key (sk_live_...) |
model | string | "standard" | Default model ("standard" or "pro") |
theme | string | "dark" | Terminal theme ("dark" or "light") |
Example Configuration
{
"api_key": "sk_live_xxxxxxxxxxxxxxxxxxxxxxxx",
"model": "standard",
"theme": "dark"
}
Environment Variables
You can also configure Nilux AI via environment variables. Environment variables take precedence over the config file.
| Variable | Equivalent Config | Description |
|---|---|---|
NILUX_API_KEY | api_key | Your Nilux API key |
NILUX_MODEL | model | Default model |
Using Environment Variables
export NILUX_API_KEY="sk_live_xxxxxxxxxxxxxxxxxxxxxxxx"
export NILUX_MODEL="pro"
nilux
Tip: Use environment variables in CI/CD pipelines or when you need to temporarily override settings without editing the config file.
Model Selection
You can switch models at any time using the /model slash command within the CLI:
/model pro
Available models are documented on the Models page.
API Key
Your API key authenticates you to the Nilux backend. You can find or rotate your key from the API Keys dashboard page.
Warning: Never commit your
config.jsonor API key to version control. The~/.nilux/directory is outside your project tree by design.
Project-Specific Settings
For project-specific overrides, you can create a .nilux/ directory in your project root. Settings here merge with your global config, with project values taking priority.
your-project/
.nilux/
skills/ # Project-specific skills
agents/ # Project-specific custom agents
This is covered in detail in the Skills and Agents documentation.
Next Steps
- Quickstart — Make your first request
- Models — Choose the right model for your task
- API Keys — Manage your API key