Skip to content

Commit 163fe7d

Browse files
cosminachoclaude
andcommitted
Re-export is_anthropic_model_name from langchain utils
Expose the helper via uipath_langchain_client.utils alongside other re-exported core utilities (exceptions, RetryConfig). Internal callers now import from the package-local utils module instead of reaching across to uipath.llm_client.utils.model_family directly. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent e717775 commit 163fe7d

3 files changed

Lines changed: 8 additions & 2 deletions

File tree

packages/uipath_langchain_client/src/uipath_langchain_client/clients/normalized/chat_models.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,9 +64,9 @@
6464
from langchain_core.utils.pydantic import is_basemodel_subclass
6565
from pydantic import AliasChoices, BaseModel, Field
6666

67-
from uipath.llm_client.utils.model_family import is_anthropic_model_name
6867
from uipath_langchain_client.base_client import UiPathBaseChatModel
6968
from uipath_langchain_client.settings import ApiType, RoutingMode, UiPathAPIConfig
69+
from uipath_langchain_client.utils import is_anthropic_model_name
7070

7171
_DictOrPydanticClass = Union[dict[str, Any], type[BaseModel], type]
7272
_DictOrPydantic = Union[dict[str, Any], BaseModel]

packages/uipath_langchain_client/src/uipath_langchain_client/factory.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@
2222

2323
from typing import Any
2424

25-
from uipath.llm_client.utils.model_family import is_anthropic_model_name
2625
from uipath_langchain_client.base_client import (
2726
UiPathBaseChatModel,
2827
UiPathBaseEmbeddings,
@@ -37,6 +36,7 @@
3736
VendorType,
3837
get_default_client_settings,
3938
)
39+
from uipath_langchain_client.utils import is_anthropic_model_name
4040

4141

4242
def get_chat_model(

packages/uipath_langchain_client/src/uipath_langchain_client/utils.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,10 @@
1313
UiPathTooManyRequestsError,
1414
UiPathUnprocessableEntityError,
1515
)
16+
from uipath.llm_client.utils.model_family import (
17+
ANTHROPIC_MODEL_NAME_KEYWORDS,
18+
is_anthropic_model_name,
19+
)
1620
from uipath.llm_client.utils.retry import RetryConfig
1721

1822
__all__ = [
@@ -30,4 +34,6 @@
3034
"UiPathServiceUnavailableError",
3135
"UiPathGatewayTimeoutError",
3236
"UiPathTooManyRequestsError",
37+
"ANTHROPIC_MODEL_NAME_KEYWORDS",
38+
"is_anthropic_model_name",
3339
]

0 commit comments

Comments
 (0)