eg, toolA, toolB, toolC , when execute toolA, then use toolA result as parameter to execute toolB, use toolB result as parameter to execute toolC.

Comment From: ilayaperumalg

@zhankun Could you elaborate your use case? While LLM chooses the tool to execute based on the context, the client still holds the control over the tool definition and how the tool gets executed. But, the LLM may not decide the chaining in the way we expect.

If you want a specific sequence of execution, then, you can very well define your tool in such a way that the toolA's result gets fed into another operation which the client controls. But, this may not be another toolB invoked by the LLM.

Did you try to explore prompt chaining instead? In this case, you can feed the response from the LLM into the next prompt that gets sent to the LLM. Please see this example for chain workflow agentic pattern.

Comment From: zhankun

@zhankun Could you elaborate your use case? While LLM chooses the tool to execute based on the context, the client still holds the control over the tool definition and how the tool gets executed. But, the LLM may not decide the chaining in the way we expect.

If you want a specific sequence of execution, then, you can very well define your tool in such a way that the toolA's result gets fed into another operation which the client controls. But, this may not be another toolB invoked by the LLM.

Did you try to explore prompt chaining instead? In this case, you can feed the response from the LLM into the next prompt that gets sent to the LLM. Please see this example for chain workflow agentic pattern.

Thank you very much, I have learned according to your sharing.