Environment Variables
Shannon reads configuration from environment variables (which always take precedence over saved config files). Set them in your shell with export, or in a .env file in source-build mode.
Model and provider
Section titled “Model and provider”| Variable | Description |
|---|---|
SHANNON_AI_MODEL | The provider and model for the whole scan, as <provider>:<model-id>. Default: anthropic:claude-sonnet-4-6. |
SHANNON_AI_API_KEY | Key for the provider that SHANNON_AI_MODEL names, or the gateway’s key when a base URL is set. |
SHANNON_AI_BASE_URL | Optional proxy or LLM gateway endpoint. It changes only where requests go. |
ANTHROPIC_API_KEY, OPENAI_API_KEY, XAI_API_KEY | Native alternatives. When the selected provider’s variable is set, it is used instead of SHANNON_AI_API_KEY. |
CLAUDE_CODE_OAUTH_TOKEN | OAuth token accepted by the Anthropic provider. |
A model the catalogue does not carry, including a local one, is described in a file passed with the --models-config flag rather than through an environment variable. See Custom model configuration.
AWS Bedrock
Section titled “AWS Bedrock”Select Bedrock with SHANNON_AI_MODEL=amazon-bedrock:<model-id>. Bedrock uses bearer-token authentication only.
| Variable | Description |
|---|---|
AWS_REGION | AWS region, e.g. us-east-1. |
AWS_BEARER_TOKEN_BEDROCK | Bedrock bearer token. |
Subscriptions
Section titled “Subscriptions”| Variable | Description |
|---|---|
SHANNON_USE_PI_AUTH | Set to 1 to reuse a Pi login for a ChatGPT Plus or Pro (Codex) or xAI (Grok) subscription. |
Networking
Section titled “Networking”| Variable | Description |
|---|---|
SHANNON_FORWARD_HOSTS | Set to false to disable forwarding /etc/hosts custom hostnames into the worker. |
Removed variables
Section titled “Removed variables”These no longer do anything. See Upgrading from earlier versions.
| Removed | Replacement |
|---|---|
SHANNON_AI_OPENAI_FORMAT (removed in 3.1) | None. An openai: model with a base URL always speaks OpenAI Responses. |
ANTHROPIC_SMALL_MODEL, ANTHROPIC_MEDIUM_MODEL, ANTHROPIC_LARGE_MODEL | A single SHANNON_AI_MODEL. |
CLAUDE_CODE_USE_BEDROCK | SHANNON_AI_MODEL=amazon-bedrock:<model-id>. |
ANTHROPIC_BASE_URL, ANTHROPIC_AUTH_TOKEN | SHANNON_AI_BASE_URL. |
CLAUDE_CODE_USE_VERTEX, CLOUD_ML_REGION, ANTHROPIC_VERTEX_PROJECT, GOOGLE_APPLICATION_CREDENTIALS | None. Vertex AI is no longer supported; use Anthropic, Bedrock, or a custom base URL. |
CLAUDE_CODE_MAX_OUTPUT_TOKENS, CLAUDE_ADAPTIVE_THINKING | None. |
See AI Providers for full setup sequences and Platforms & Networking for networking details.