Remove OpenAI fallback - MiniMax only
This commit is contained in:
@@ -101,26 +101,21 @@ def load_config_from_env() -> OpusConfig:
|
|||||||
"""Load configuration from environment variables.
|
"""Load configuration from environment variables.
|
||||||
|
|
||||||
Reads:
|
Reads:
|
||||||
- MINIMAX_API_KEY or OPENAI_API_KEY for LLM
|
- MINIMAX_API_KEY for LLM
|
||||||
- GITHUB_TOKEN for GitHub operations
|
- GITHUB_TOKEN for GitHub operations
|
||||||
|
|
||||||
Prefers MINIMAX_API_KEY (more cost-effective).
|
Uses MiniMax exclusively.
|
||||||
"""
|
"""
|
||||||
# Load API keys - prefer MiniMax by default
|
# Load MiniMax API key
|
||||||
openai_key = _load_env("OPENAI_API_KEY")
|
|
||||||
minimax_key = _load_env("MINIMAX_API_KEY")
|
minimax_key = _load_env("MINIMAX_API_KEY")
|
||||||
|
|
||||||
# Use MiniMax by default (cost-effective), fall back to OpenAI if needed
|
# Use MiniMax only
|
||||||
if minimax_key:
|
if minimax_key:
|
||||||
provider = "minimax"
|
provider = "minimax"
|
||||||
default_model = "MiniMax/MiniMax-M2.1"
|
default_model = "MiniMax/MiniMax-M2.1"
|
||||||
api_key = minimax_key
|
api_key = minimax_key
|
||||||
elif openai_key:
|
|
||||||
provider = "openai"
|
|
||||||
default_model = "gpt-4o"
|
|
||||||
api_key = openai_key
|
|
||||||
else:
|
else:
|
||||||
provider = "minimax" # Default to minimax
|
provider = "minimax"
|
||||||
default_model = "MiniMax/MiniMax-M2.1"
|
default_model = "MiniMax/MiniMax-M2.1"
|
||||||
api_key = None
|
api_key = None
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user