mirror of
https://github.com/microsoft/autogen.git
synced 2025-12-28 07:29:54 +00:00
Fix missing tools in logs (#6532)
Fix for LLMCallEvent failing to log "tools" passed to BaseOpenAIChatCompletionClient in autogen_ext.models.openai._openai_client.BaseOpenAIChatCompletionClient This bug creates problems inspecting why a certain tool was selected/not selected by the LLM as the list of tools available to the LLM is not present in the logs ## Why are these changes needed? Added "tools" to the LLMCallEvent to log tools available to the LLM as these were being missed causing difficulties during debugging LLM tool calls. ## Related issue number [<!-- For example: "Closes #1234" -->](https://github.com/microsoft/autogen/issues/6531) ## Checks - [x] I've included any doc changes needed for <https://microsoft.github.io/autogen/>. See <https://github.com/microsoft/autogen/blob/main/CONTRIBUTING.md> to build and test documentation locally. - [x] I've added tests (if relevant) corresponding to the changes introduced in this PR. - [x] I've made sure all auto checks have passed. --------- Co-authored-by: Eric Zhu <ekzhu@users.noreply.github.com>
This commit is contained in:
parent
9d297318b5
commit
446da624ac
@ -637,6 +637,7 @@ class BaseOpenAIChatCompletionClient(ChatCompletionClient):
|
||||
response=result.model_dump(),
|
||||
prompt_tokens=usage.prompt_tokens,
|
||||
completion_tokens=usage.completion_tokens,
|
||||
tools=create_params.tools,
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user