Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Update SKChatCompletionAdapter message conversion #5749

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

lspinheiro
Copy link
Collaborator

@lspinheiro lspinheiro commented Feb 28, 2025

Why are these changes needed?

The PR introduces two changes.

The first change is adding a name attribute to FunctionExecutionResult. The motivation is that semantic kernel requires it for their function result interface and it seemed like a easy modification as FunctionExecutionResult is always created in the context of a FunctionCall which will contain the name. I'm unsure if there was a motivation to keep it out but this change makes it easier to trace which tool the result refers to and also increases api compatibility with SK.

The second change is an update to how messages are mapped from autogen to semantic kernel, which includes an update/fix in the processing of function results.

Related issue number

Related to #5675 but wont fix the underlying issue of anthropic requiring tools during AssistantAgent reflection.

Checks

@lspinheiro lspinheiro changed the title Fix 5675 update sk message conversion fix: Update SKChatCompletionAdapter message conversion Feb 28, 2025
Copy link

codecov bot commented Feb 28, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 75.04%. Comparing base (dd0781a) to head (9f33936).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #5749      +/-   ##
==========================================
+ Coverage   74.96%   75.04%   +0.08%     
==========================================
  Files         175      176       +1     
  Lines       11158    11166       +8     
==========================================
+ Hits         8365     8380      +15     
+ Misses       2793     2786       -7     
Flag Coverage Δ
unittests 75.04% <100.00%> (+0.08%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants