Skip to content

Commit fda2293

Browse files
committed
feat(langgraph): upgrade langgraph
1 parent c58ecc5 commit fda2293

File tree

9 files changed

+90
-492
lines changed

9 files changed

+90
-492
lines changed

pyproject.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@ name = "uipath-langchain"
33
version = "0.0.143"
44
description = "UiPath Langchain"
55
readme = { file = "README.md", content-type = "text/markdown" }
6-
requires-python = ">=3.10"
6+
requires-python = ">=3.11"
77
dependencies = [
88
"uipath>=2.1.103, <2.2.0",
9-
"langgraph>=0.5.0, <0.7.0",
10-
"langchain-core>=0.3.34",
9+
"langgraph>=1.0.1, <1.1.0",
10+
"langchain-core>=1.0.0, <1.1.0",
1111
"langgraph-checkpoint-sqlite>=2.0.3",
1212
"langchain-community>=0.3.21",
1313
"langchain-openai>=0.3.3",

testcases/common/trace_assert.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,13 +117,18 @@ def assert_traces(traces_file: str, expected_file: str) -> None:
117117
print(f"✗ Missing span: {expected['name']}")
118118

119119
if missing_spans:
120+
120121
raise AssertionError(
121122
f"Missing expected spans: {', '.join(missing_spans)}\n"
122123
f"Expected {len(expected_spans)} spans, found {len(expected_spans) - len(missing_spans)}"
123124
)
124125

125126
print(f"\n✓ All {len(expected_spans)} expected spans found!")
126127

128+
print("Traces file content:")
129+
with open(traces_file, 'r', encoding='utf-8') as f:
130+
print(f.read())
131+
127132

128133
if __name__ == "__main__":
129134
# Example usage

testcases/company-research-agent/pyproject.toml

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,13 @@ version = "0.0.1"
44
description = "Company research agent with Tavily web search"
55
authors = [{ name = "John Doe", email = "john.doe@myemail.com" }]
66

7-
requires-python = ">=3.10"
7+
requires-python = ">=3.11"
88
dependencies = [
9-
"langgraph>=0.2.55",
10-
"langchain-anthropic>=0.3.8",
11-
"tavily-python>=0.5.0",
129
"uipath-langchain",
13-
"duckduckgo-search>=8.1.1",
10+
"langgraph>=1.0.1",
11+
"tavily-python>=0.5.0",
1412
"langchain-community>=0.3.21",
15-
"debugpy>=1.8.15",
13+
"ddgs>=9.6.1",
1614
]
1715

1816
[project.optional-dependencies]

testcases/company-research-agent/src/graph.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,11 @@
1010
from uipath_langchain.chat import UiPathAzureChatOpenAI, UiPathChat
1111

1212
# Configuration constants
13-
MAX_SEARCH_RESULTS = 5
1413
DEFAULT_MODEL = "gpt-4o-2024-08-06"
15-
ALTERNATIVE_MODEL = "claude-3-5-sonnet-latest"
1614

1715

1816
def get_search_tool() -> Union[TavilySearchResults, DuckDuckGoSearchResults]:
1917
"""Get the appropriate search tool based on available API keys."""
20-
if os.getenv("TAVILY_API_KEY"):
21-
return TavilySearchResults(max_results=MAX_SEARCH_RESULTS)
2218
return DuckDuckGoSearchResults()
2319

2420

@@ -73,7 +69,7 @@ class GraphOutput(BaseModel):
7369

7470
def create_user_message(company_name: str) -> str:
7571
"""Create a formatted user message for company research."""
76-
return f"""Please provide a comprehensive analysis and outreach strategy for the company: {company_name}. Use the TavilySearchResults tool to gather information. Include detailed research on the company's background, organizational structure, key decision-makers, and a tailored outreach strategy. Format your response using the following section headers:
72+
return f"""Please provide a comprehensive analysis and outreach strategy for the company: {company_name}. Use the DuckDuckGoSearchResults tool to gather information. Include detailed research on the company's background, organizational structure, key decision-makers, and a tailored outreach strategy. Format your response using the following section headers:
7773
7874
1. Company Overview
7975
2. Organizational Structure

testcases/init-flow/pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ dependencies = [
77
"langchain-anthropic>=0.3.8",
88
"uipath-langchain",
99
]
10-
requires-python = ">=3.10"
10+
requires-python = ">=3.11"
1111

1212
[tool.uv.sources]
1313
uipath-langchain = { path = "../../", editable = true }

testcases/simple-local-mcp/input.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"messages": [
33
{
44
"type": "system",
5-
"content": "You are a calculator assistant, you only use the provided tools to do math. DO NOT make up any answers on your own."
5+
"content": "You are a calculator assistant, you only use the provided tools to do math. VERY IMPORTANT: DO NOT make up any answers on your own use the provided tools to make calculations."
66
},
77
{
88
"type": "human",

testcases/simple-local-mcp/pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ dependencies = [
1717
"ipython>=8.32.0",
1818
"mcp>=1.4.1",
1919
]
20-
requires-python = ">=3.10"
20+
requires-python = ">=3.11"
2121

2222
[tool.uv.sources]
2323
uipath-langchain = { path = "../../", editable = true }

testcases/ticket-classification/pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ dependencies = [
1515
"typing-extensions>=4.12.2",
1616
"ipython>=8.32.0",
1717
]
18-
requires-python = ">=3.10"
18+
requires-python = ">=3.11"
1919

2020
[tool.uv.sources]
2121
uipath-langchain = { path = "../../", editable = true }

uv.lock

Lines changed: 73 additions & 474 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)