Closed shethaadit closed 5 days ago
Out of curiosity, are you going to support images as well? (They currently are not working)
@raffaeler, please open an issue and (if you could provide your not working example code would be very helpful) we can investigate this. Thanks!
Description
This PR addresses a bug in
OllamaPromptExecutionSettings
where theFunctionChoiceBehavior
state was not properly restored during the conversion process fromPromptExecutionSettings
. Specifically, the internal state ofFunctionChoiceBehavior
, including its list of associated functions, was lost during serialization and deserialization.Motivation and Context
Why is this change required? The lack of proper state restoration led to missing function definitions in HTTP requests when using the Ollama connector, causing failures in scenarios that rely on function calls.
What problem does it solve? This change ensures that the
FunctionChoiceBehavior
is fully restored when converting execution settings, maintaining the expected behavior for function calls in the Ollama connector.What scenario does it contribute to? This fix enables consistent and reliable function calling with the Ollama connector, ensuring that defined functions are included in requests and operate as expected.
Related Issues This change fixes the issue described in the bug report, improving usability and reliability when working with function behaviors in Semantic Kernel integrations.
Contribution Checklist
Fixes #9682