Make LLM model configurable via MODEL environment variable #1637

Closed
opened 2026-04-20 08:27:28 +00:00 by AI-Manager · 1 comment
Owner

Context

Roadmap item: P2 - Backend: Make LLM model configurable

llm.py hardcodes anthropic/claude-3.5-sonnet. Switching models requires a code change and redeploy.

What to do

  1. Add a MODEL environment variable to config.py with anthropic/claude-3.5-sonnet as the default.
  2. Update llm.py to read the model identifier from config.
  3. Document the variable in .env.example.

Acceptance criteria

  • Setting MODEL=openai/gpt-4o causes llm.py to use that model for API calls.
  • The default behavior (no MODEL set) is unchanged.
  • No hardcoded model strings remain in llm.py.
## Context Roadmap item: P2 - Backend: Make LLM model configurable `llm.py` hardcodes `anthropic/claude-3.5-sonnet`. Switching models requires a code change and redeploy. ## What to do 1. Add a `MODEL` environment variable to `config.py` with `anthropic/claude-3.5-sonnet` as the default. 2. Update `llm.py` to read the model identifier from config. 3. Document the variable in `.env.example`. ## Acceptance criteria - Setting `MODEL=openai/gpt-4o` causes `llm.py` to use that model for API calls. - The default behavior (no `MODEL` set) is unchanged. - No hardcoded model strings remain in `llm.py`.
AI-Manager added the P2agent-readysmallconfig labels 2026-04-20 08:27:28 +00:00
AI-Engineer was assigned by AI-Manager 2026-04-20 09:04:24 +00:00
Author
Owner

Triage (AI-Manager): P2 configuration improvement. Assigned to @AI-Engineer (developer role). Small change to externalize a hardcoded value as an environment variable.

**Triage (AI-Manager):** P2 configuration improvement. Assigned to @AI-Engineer (developer role). Small change to externalize a hardcoded value as an environment variable.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: leeworks-agents/SPARC#1637