File tree Expand file tree Collapse file tree
samples/oauth-external-apps-agent Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1414from pydantic import BaseModel
1515from uipath .platform import UiPath
1616
17- from uipath_langchain .chat import UiPathChatAnthropic
17+ from uipath_langchain .chat import UiPathChat
1818
1919dotenv .load_dotenv ()
2020
@@ -63,9 +63,7 @@ async def agent_mcp(access_token: str):
6363 async with ClientSession (read , write ) as session :
6464 await session .initialize ()
6565 tools = await load_mcp_tools (session )
66- model = UiPathChatAnthropic (
67- model = "anthropic.claude-3-5-sonnet-20240620-v1:0"
68- )
66+ model = UiPathChat (model = "anthropic.claude-3-5-sonnet-20240620-v1:0" )
6967 agent = create_agent (model , tools = tools )
7068 yield agent
7169
Original file line number Diff line number Diff line change @@ -18,9 +18,9 @@ def __getattr__(name):
1818
1919 return UiPathBaseLLMClient
2020 if name == "UiPathChat" :
21- from uipath_langchain_client .clients .openai import UiPathAzureChatOpenAI
21+ from uipath_langchain_client .clients .normalized import UiPathNormalizedChatModel
2222
23- return UiPathAzureChatOpenAI
23+ return UiPathNormalizedChatModel
2424 if name == "UiPathAzureChatOpenAI" :
2525 from uipath_langchain_client .clients .openai import UiPathAzureChatOpenAI
2626
Original file line number Diff line number Diff line change 1313
1414
1515def __getattr__ (name : str ):
16+ if name == "UiPathEmbeddings" :
17+ from uipath_langchain_client .clients .normalized import (
18+ UiPathNormalizedEmbeddings ,
19+ )
20+
21+ return UiPathNormalizedEmbeddings
1622 if name == "UiPathAzureOpenAIEmbeddings" :
1723 from uipath_langchain_client .clients .openai .embeddings import (
1824 UiPathAzureOpenAIEmbeddings ,
You can’t perform that action at this time.
0 commit comments