fix(core): include effort in AnthropicModelSettings returned by _to_model_settings() (#9543)

LlmConfig._to_model_settings() for Anthropic built an AnthropicModelSettings
object without passing effort=self.effort, so GET /agents/{id} never returned
the effort field in model_settings even when it was stored on the agent.

The Letta Code CLI derives the reasoning tier displayed in the status bar
from model_settings.effort (canonical source), so the footer always showed
e.g. "Sonnet 4.6" instead of "Sonnet 4.6 (high)" after a model switch.

👾 Generated with [Letta Code](https://letta.com)

Co-authored-by: Letta <noreply@letta.com>
This commit is contained in:
Charles Packer
2026-02-18 20:13:19 -08:00
committed by Caren Thomas
parent e65795b5f1
commit 044241daec

View File

@@ -360,6 +360,7 @@ class LLMConfig(BaseModel):
thinking=AnthropicThinking(type=thinking_type, budget_tokens=self.max_reasoning_tokens or 1024),
verbosity=self.verbosity,
strict=self.strict,
effort=self.effort,
)
elif self.model_endpoint_type == "google_ai":
return GoogleAIModelSettings(