The list below is verified against the source. Variables Lime stores under
~/.lime/ (via lime login) override the corresponding environment
variables when present.
Provider credentials
Variable
Purpose
OPENAI_API_KEY
OpenAI key. Also used for any OpenAI-compatible service that doesn’t have a dedicated env var.
OPENAI_BASE_URL
Custom OpenAI base URL — proxies, Azure, or any OpenAI-compatible server.
ANTHROPIC_API_KEY
Anthropic key.
GEMINI_API_KEY
Google Gemini key. Takes priority over GOOGLE_API_KEY when both are set.
GOOGLE_API_KEY
Google Gemini key (fallback).
GROQ_API_KEY
Groq key (OpenAI-compat preset).
OPENROUTER_API_KEY
OpenRouter key (OpenAI-compat preset).
TOGETHER_API_KEY
Together AI key (OpenAI-compat preset).
MISTRAL_API_KEY
Mistral key (OpenAI-compat preset).
DEEPINFRA_API_KEY
DeepInfra key (OpenAI-compat preset).
CEREBRAS_API_KEY
Cerebras key (OpenAI-compat preset).
XAI_API_KEY
xAI key (OpenAI-compat preset).
PERPLEXITY_API_KEY
Perplexity key (OpenAI-compat preset).
COHERE_API_KEY
Cohere key (OpenAI-compat preset).
NVIDIA_API_KEY
NVIDIA NIM key (OpenAI-compat preset).
For Ollama (local), no key is required.
Lime runtime knobs
Variable
Purpose
LIME_CONFIG_HOME
Override the config search root (default ~/.lime).
LIME_MODEL
Override the active model slug.
LIME_MODELS_FILE
Override the path to the user models.json (primarily for testing).
LIME_MAX_RETRIES
Per-provider retry budget. Default 6.
LIME_CODE_AUTO_COMPACT_INPUT_TOKENS
Force a specific token threshold for auto-compaction across all models.
LIME_AUTOCOMPACT_PCT_OVERRIDE
Override the auto-compact percentage of the model’s context window.
LIME_TIME_BASED_MICROCOMPACT_MIN
Idle gap (minutes) before a time-based microcompact runs. Default 60. Set 0 to disable.
LIME_AUTO_MEMORY_DISABLED
When set, disables automatic memory extraction at session end.
LIME_DEBUG_COMPACTION_THRESHOLD
Diagnostic knob that lowers the compaction threshold for testing.
LIME_MANAGED_SETTINGS
Path to a managed-settings file (enterprise/policy layer).
Override the runtime data root (~/.lime). Affects bridge state, agent files, device pairing, web-push state, IDE adapters, and LIME_CONFIG_HOME fallback.
LIME_SESSION_ID
Set by the runtime when invoking AI tools — read by skill content for ${LIME_SESSION_ID} substitution. Don’t set this by hand.
LIME_TASK_DIR
Override the directory where the task store persists in-flight task lists (default: under ~/.lime/). Used in tests and headless runs.
LIME_WEB_SEARCH_BASE_URL
Custom base URL for the built-in web_search tool. Useful when fronting search behind a proxy.
LIME_BRIDGE_ALLOWED_ORIGINS
Comma-separated list of additional Origin headers the bridge WebSocket will accept. Local origins are always allowed.
LIME_WORKER_STALL_TIMEOUT_SECS
Override the worker stall-detection timeout in seconds. Set high for long-running tools; default is conservative.
LIME_CODE_AUTO_COMPACT_WINDOW
Set the auto-compact threshold by fraction of the model’s context window (e.g. 0.85). Replaces the legacy LIME_CODE_AUTO_COMPACT_INPUT_TOKENS.
MCP runtime knobs
Variable
Purpose
LIME_MAX_MCP_OUTPUT_TOKENS
Cap on tokens returned per MCP tool call.
LIME_MCP_IO_THREADS
Worker thread count for the MCP runtime pool.
LIME_MCP_CONNECT_TIMEOUT_MS
Connect timeout for new MCP transports.
LIME_MCP_CONNECTION_BATCH_SIZE
Concurrency cap for the eager-startup connect wave.
LIME_MCP_REMOTE_CONNECTION_BATCH_SIZE
Concurrency cap for the remote-transport connect wave.
Build-time
Variable
Purpose
GIT_SHA
Embed a short commit hash in lime --version. Set at build time: