Skip to content

Commit b419f66

Browse files
cronoik-inceptionaihuydhn
authored andcommitted
Documentation update tool_calling: mapping back to function from response (vllm-project#20373)
1 parent d638b9e commit b419f66

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/features/tool_calling.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ Next, make a request to the model that should result in it using the available t
5353
tool_call = response.choices[0].message.tool_calls[0].function
5454
print(f"Function called: {tool_call.name}")
5555
print(f"Arguments: {tool_call.arguments}")
56-
print(f"Result: {get_weather(**json.loads(tool_call.arguments))}")
56+
print(f"Result: {tool_functions[tool_call.name](**json.loads(tool_call.arguments))}")
5757
```
5858

5959
Example output:

0 commit comments

Comments
 (0)