Skip to content

Commit 8425c8d

Browse files
authored
Merge pull request #26 from UiPath/fix/runnable_config
feat: configurable recursion_limit and max_concurrency
2 parents ec6f774 + cde0579 commit 8425c8d

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/uipath_langchain/_cli/_runtime/_runtime.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,14 @@ async def execute(self) -> Optional[UiPathRuntimeResult]:
9494
"callbacks": callbacks,
9595
}
9696

97+
recursion_limit = os.environ.get("LANGCHAIN_RECURSION_LIMIT", None)
98+
max_concurrency = os.environ.get("LANGCHAIN_MAX_CONCURRENCY", None)
99+
100+
if recursion_limit is not None:
101+
graph_config["recursion_limit"] = int(recursion_limit)
102+
if max_concurrency is not None:
103+
graph_config["max_concurrency"] = int(max_concurrency)
104+
97105
# Stream the output at debug time
98106
if self.context.job_id is None:
99107
# Get final chunk while streaming

0 commit comments

Comments
 (0)