aikit is a Rust TUI for managing local AI provider settings and switching the active provider, API key, and model used by AI coding tools.
It is built with Ratatui and currently targets OpenAI-compatible providers.
- Manage multiple AI providers with
base_urland multiple API keys. - Cache provider model lists locally, refresh them only on demand, and add manual models for proxy services.
- Select a global provider + API key + model combination.
- Apply the active selection to Claude Code, Codex CLI, and Gemini CLI configs.
- Back up existing target config files before writing.
- For Claude Code: pin every model slot (main, small/fast, and the Haiku/Sonnet/Opus defaults) to the selected model, and optionally enable a 1M context window that appends a
[1m]model-name suffix and setsCLAUDE_CODE_AUTO_COMPACT_WINDOW. Both default on and can be toggled off in the Apply To pane.
macOS/Linux (Recommended):
curl -fsSL https://github.com/millylee/aikit/releases/latest/download/install.sh | bashWindows (Recommended):
irm https://github.com/millylee/aikit/releases/latest/download/install.ps1 | iexStart the TUI:
aikitPrint the installed version:
aikit --versionIf the installer just added aikit to your PATH, restart the terminal or run the PATH command printed by the installer before using aikit.
Installers place the aikit binary in ~/.local/bin by default. Set AIKIT_BIN_DIR before running an installer to choose another directory.
The TUI manages providers and API keys directly in ~/.aikit/config.toml.
Default config location on all platforms:
~/.aikit/config.toml
Runtime state is kept outside the main config:
~/.aikit/state.toml: import prompt state.~/.aikit/cache/models.json: provider model cache.~/.aikit/backups/<target>/: centralized backups foraikit, Claude Code, Codex CLI, and Gemini CLI configs.~/.aikit/logs/backups.jsonl: append-only backup index.
Provider management keys in the main TUI:
a: add provider.e: edit selected provider.d: delete selected provider, API key, or manual model (with confirmation).+: add API key to selected provider. The form accepts an optional display name and a required key value;aikitgenerates the internal key id.m: manually add a model to the selected provider.
Import keys and behavior:
i: scan and import provider candidates.- On startup, if no providers are configured,
aikitscans environment variables plus Claude Code, Codex CLI, and Gemini CLI config files for import candidates. - If import candidates are found,
aikitshows an import prompt before changing config. - In the prompt, you can import all, skip, or open the selectable candidate list.
- Missing or unparseable config files are soft-failed and shown as warnings; other import sources continue.
Supported environment variables for import:
- OpenAI:
OPENAI_API_KEY,OPENAI_BASE_URL,OPENAI_MODEL - Anthropic:
ANTHROPIC_API_KEY,ANTHROPIC_BASE_URL,ANTHROPIC_MODEL - Gemini:
GEMINI_API_KEY,GEMINI_BASE_URL,GEMINI_MODEL
Security note: imported API keys are saved in local TOML as plain text. Keep your machine and config directory protected.
TaborRight/l: switch to the next pane.Left/h: switch to the previous pane.Up/Downork/j: move selection in the focused pane.g/G: jump to the first or last item in the focused pane.Enter/Space: activate the selected provider, API key, model, toggle the selected target, or toggle a Claude Code option (Pin all models / 1M context).e: edit the current provider in Providers, edit the current key/model in Selection, and show a hint in Apply To.r: refresh models for the selected provider using the selected API key.m: add a manual model for the selected provider.?: show shortcuts.u: check GitHub Releases for updates.Ctrl+s: apply the active provider + API key + model to enabled targets.q/Esc: quit.
The footer shows the current aikit version plus shortcut hints.
Modal form keys:
Tab/Shift+Tab/Up/Down: switch input fields.Left/Right: move within the current input.Home/End: jump to the start or end of the current input.Backspace/Delete: delete before or at the current input position.Ctrl+U: clear the current input.Enter: save the form.Esc: cancel the form.
cargo fmt --check
cargo clippy --workspace --all-targets -- -D warnings
cargo test --workspaceRun the TUI locally:
cargo run -p aikit-tuiBump the workspace version, create a release commit, and tag it:
pwsh scripts/version.ps1 patchPush the current branch and tag:
pwsh scripts/version.ps1 patch -PushUse minor, major, or an explicit version when needed:
pwsh scripts/version.ps1 minor
pwsh scripts/version.ps1 -Version 0.2.0BSD-2-Clause