semantic-kernel icon indicating copy to clipboard operation
semantic-kernel copied to clipboard

Python: Filters for FunctionCallBehavior.EnableFunctions should be optional

Open madsbolaris opened this issue 1 year ago • 1 comments

Today, the filters property is required, even if its empty (see below)

execution_settings.function_call_behavior = FunctionCallBehavior.EnableFunctions(auto_invoke=True, filters={})

I should be able to just write...

execution_settings.function_call_behavior = FunctionCallBehavior.EnableFunctions(auto_invoke=True)

madsbolaris avatar Jun 24 '24 15:06 madsbolaris

We're moving to support FunctionChoiceBehavior (#6910) where the filters for each class method are optional. However, for existing functionality, and for those users who haven't migrated from FunctionCallBehavior -> FunctionChoiceBehavior we can make the update to make the default filters, if not passed, as an empty dict.

moonbox3 avatar Jun 24 '24 16:06 moonbox3

Closed as of #6910.

moonbox3 avatar Jul 03 '24 15:07 moonbox3