Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/uipath_langchain/agent/tools/escalation_tool.py
Original file line number Diff line number Diff line change
Expand Up @@ -170,13 +170,13 @@ async def escalation_tool_fn(**kwargs: Any) -> dict[str, Any]:
serialized_data = input_model.model_validate(kwargs).model_dump(mode="json")

@mockable(
name=tool_name.lower(),
name=resource.name,
description=resource.description,
input_schema=input_model.model_json_schema(),
output_schema=EscalationToolOutput.model_json_schema(),
example_calls=channel.properties.example_calls,
)
async def escalate():
async def escalate(**_tool_kwargs: Any):
@durable_interrupt
async def create_escalation_task():
client = UiPath()
Expand All @@ -200,7 +200,7 @@ async def create_escalation_task():

return await create_escalation_task()

result = await escalate()
result = await escalate(**kwargs)
if isinstance(result, dict):
result = TypeAdapter(EscalationToolOutput).validate_python(result)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ async def batch_transform_tool_fn(**kwargs: Any) -> dict[str, Any]:
output_schema=output_model.model_json_schema(),
example_calls=[], # Examples cannot be provided for internal tools
)
async def invoke_batch_transform():
async def invoke_batch_transform(**_tool_kwargs: Any):
@durable_interrupt
async def create_ephemeral_index():
uipath = UiPath()
Expand Down Expand Up @@ -169,7 +169,7 @@ async def upload_result_attachment():
"MimeType": "text/csv",
}

result_attachment = await invoke_batch_transform()
result_attachment = await invoke_batch_transform(**kwargs)

return {"result": result_attachment}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ async def deeprag_tool_fn(**kwargs: Any) -> dict[str, Any]:
output_schema=output_model.model_json_schema(),
example_calls=[], # Examples cannot be provided for internal tools
)
async def invoke_deeprag():
async def invoke_deeprag(**_tool_kwargs: Any):
@durable_interrupt
async def create_ephemeral_index():
uipath = UiPath()
Expand Down Expand Up @@ -134,7 +134,7 @@ async def create_deeprag():

return await create_deeprag()

return await invoke_deeprag()
return await invoke_deeprag(**kwargs)

# Import here to avoid circular dependency
from uipath_langchain.agent.wrappers import get_job_attachment_wrapper
Expand Down
6 changes: 3 additions & 3 deletions src/uipath_langchain/agent/tools/process_tool.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,13 +44,13 @@ async def process_tool_fn(**kwargs: Any):
input_arguments = input_model.model_validate(kwargs).model_dump(mode="json")

@mockable(
name=tool_name.lower(),
name=resource.name,
description=resource.description,
input_schema=input_model.model_json_schema(),
output_schema=output_model.model_json_schema(),
example_calls=resource.properties.example_calls,
)
async def invoke_process():
async def invoke_process(**_tool_kwargs: Any):
parent_span_id = _span_context.pop("parent_span_id", None)

@durable_interrupt
Expand All @@ -67,7 +67,7 @@ async def start_job():

return await start_job()

return await invoke_process()
return await invoke_process(**kwargs)

job_attachment_wrapper = get_job_attachment_wrapper(output_type=output_model)

Expand Down