Move caller dialog to Sonnet 4.6, add SearXNG for Devon, and fix stale model ids

Working-tree changes that had accumulated without being committed. The test
updates matter most: tests/test_caller_gen.py was left behind when caller_gen
started requiring voice and age in regulars_included, so the committed tree had
a failing suite that only passed locally.

- Caller dialog moves from Haiku 4.5 to Sonnet 4.6 (~$1/show to ~$3-4/show)
- Grok pinned to x-ai/grok-4.3; grok-4, grok-4-fast and grok-4.1-fast were
  retired from OpenRouter, and llm.py swallows the 404 and returns empty text,
  so a retired id makes callers go silent with nothing in the logs
- Devon's web_search now runs against SearXNG on the NAS
- Assorted TTS, audio, news, cost tracker and control-panel changes
- CLAUDE.md updated to match

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
2026-08-14 04:21:55 -05:00
co-authored by Claude Opus 5
parent 2901e5f4fb
commit 44ef13336e
21 changed files with 731 additions and 186 deletions
+6 -2
View File
@@ -27,6 +27,10 @@ class Settings(BaseSettings):
submissions_imap_user: str = os.getenv("SUBMISSIONS_IMAP_USER", "")
submissions_imap_pass: str = os.getenv("SUBMISSIONS_IMAP_PASS", "")
# SearXNG (Devon's web search + caller news grounding) — runs on the NAS.
# Override with SEARXNG_URL in .env (e.g. http://localhost:8888 for a local container).
searxng_url: str = os.getenv("SEARXNG_URL", "http://mmgnas:8888")
# LLM Settings
llm_provider: str = "openrouter" # "openrouter" or "ollama"
openrouter_model: str = "anthropic/claude-sonnet-4.6" # primary/default model
@@ -35,8 +39,8 @@ class Settings(BaseSettings):
# Per-category model routing
category_models: dict = {
"caller_dialog": "anthropic/claude-haiku-4.5", # live caller dialog ($0.80/$4)
"devon_ask": "x-ai/grok-4.1-fast", # Devon matches show energy, cheap ($0.20/$0.50)
"caller_dialog": "anthropic/claude-sonnet-4.6", # live caller dialog — quality matters ($3/$15)
"devon_ask": "x-ai/grok-4.3", # Devon matches show energy (grok-4.1-fast deprecated 2026-05)
"devon_monitor": "google/gemini-2.5-flash", # just yes/no decisions, keep cheap ($0.15/$0.60)
"background_gen": "anthropic/claude-sonnet-4.6", # backgrounds drive the whole call — worth the quality ($3/$15, ~$0.30/show)
"call_summary": "google/gemini-2.5-flash", # post-call, no personality needed ($0.15/$0.60)