Learn Before
Concept

Mechanism of Tool Invocation and Result Substitution

The process of tool use by an LLM involves generating a specially formatted string, such as {tool: calculator, expression: 10 * 4 * 2}, which acts as a trigger for an external tool like a mathematical interpreter. Once the tool computes the result (e.g., '80'), this output replaces the original tool-invocation string. This substitution updates the model's working context, enabling the result to be directly referenced and utilized in the subsequent token predictions that form the next steps of the reasoning process.

0

1

Updated 2025-10-06

Contributors are:

Who are from:

Tags

Ch.3 Prompting - Foundations of Large Language Models

Foundations of Large Language Models

Foundations of Large Language Models Course

Computing Sciences