Skip to content

Commit b031a08

Browse files
authored
Bump anthropic to 0.75.0 (home-assistant#157491)
1 parent a113219 commit b031a08

File tree

6 files changed

+17
-5
lines changed

6 files changed

+17
-5
lines changed

homeassistant/components/anthropic/config_flow.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -421,6 +421,8 @@ async def _get_model_list(self) -> list[SelectOptionDict]:
421421
)
422422
if short_form.search(model_alias):
423423
model_alias += "-0"
424+
if model_alias.endswith(("haiku", "opus", "sonnet")):
425+
model_alias += "-latest"
424426
model_options.append(
425427
SelectOptionDict(
426428
label=model_info.display_name,

homeassistant/components/anthropic/manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,5 @@
88
"documentation": "https://www.home-assistant.io/integrations/anthropic",
99
"integration_type": "service",
1010
"iot_class": "cloud_polling",
11-
"requirements": ["anthropic==0.73.0"]
11+
"requirements": ["anthropic==0.75.0"]
1212
}

requirements_all.txt

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

requirements_test_all.txt

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

tests/components/anthropic/conftest.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,12 @@ async def mock_init_component(
128128
"""Initialize integration."""
129129
model_list = AsyncPage(
130130
data=[
131+
ModelInfo(
132+
id="claude-opus-4-5-20251101",
133+
created_at=datetime.datetime(2025, 11, 1, 0, 0, tzinfo=datetime.UTC),
134+
display_name="Claude Opus 4.5",
135+
type="model",
136+
),
131137
ModelInfo(
132138
id="claude-haiku-4-5-20251001",
133139
created_at=datetime.datetime(2025, 10, 15, 0, 0, tzinfo=datetime.UTC),

tests/components/anthropic/test_config_flow.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -357,6 +357,10 @@ async def test_model_list(
357357
assert options["type"] == FlowResultType.FORM
358358
assert options["step_id"] == "advanced"
359359
assert options["data_schema"].schema["chat_model"].config["options"] == [
360+
{
361+
"label": "Claude Opus 4.5",
362+
"value": "claude-opus-4-5",
363+
},
360364
{
361365
"label": "Claude Haiku 4.5",
362366
"value": "claude-haiku-4-5",
@@ -379,11 +383,11 @@ async def test_model_list(
379383
},
380384
{
381385
"label": "Claude Sonnet 3.7",
382-
"value": "claude-3-7-sonnet",
386+
"value": "claude-3-7-sonnet-latest",
383387
},
384388
{
385389
"label": "Claude Haiku 3.5",
386-
"value": "claude-3-5-haiku",
390+
"value": "claude-3-5-haiku-latest",
387391
},
388392
{
389393
"label": "Claude Haiku 3",

0 commit comments

Comments
 (0)