-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
Java: Update ToolCallBehavior #5058
Conversation
...tickernel-api/src/main/java/com/microsoft/semantickernel/orchestration/ToolCallBehavior.java
Outdated
Show resolved
Hide resolved
...tickernel-api/src/main/java/com/microsoft/semantickernel/orchestration/ToolCallBehavior.java
Outdated
Show resolved
Hide resolved
...tickernel-api/src/main/java/com/microsoft/semantickernel/orchestration/ToolCallBehavior.java
Outdated
Show resolved
Hide resolved
...tickernel-api/src/main/java/com/microsoft/semantickernel/orchestration/ToolCallBehavior.java
Outdated
Show resolved
Hide resolved
...tickernel-api/src/main/java/com/microsoft/semantickernel/orchestration/ToolCallBehavior.java
Outdated
Show resolved
Hide resolved
throw new SKException( | ||
"The maximum auto-invoke attempts should be greater than or equal to zero."); | ||
} | ||
if (requiredFunction == null) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why does 'requiredFunction' get special treatment here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If the required function is set, there is no need to send all of the other enabled functions from the kernel as the model will try to call only that function.
...tickernel-api/src/main/java/com/microsoft/semantickernel/orchestration/ToolCallBehavior.java
Outdated
Show resolved
Hide resolved
...tickernel-api/src/main/java/com/microsoft/semantickernel/orchestration/ToolCallBehavior.java
Outdated
Show resolved
Hide resolved
### Motivation and Context <!-- Thank you for your contribution to the semantic-kernel repo! Please help reviewers and future users, providing the following information: 1. Why is this change required? 2. What problem does it solve? 3. What scenario does it contribute to? 4. If it fixes an open issue, please link to the issue here. --> ### Description <!-- Describe your changes, the overall approach, the underlying design. These notes will help understanding how your code works. Thanks! --> ### Contribution Checklist <!-- Before submitting this PR, please make sure: --> - [ ] The code builds clean without any errors or warnings - [ ] The PR follows the [SK Contribution Guidelines](https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md) and the [pre-submission formatting script](https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md#development-scripts) raises no violations - [ ] All unit tests pass, and I have added new tests where possible - [ ] I didn't break anyone 😄 --------- Co-authored-by: David Grieve <dsgrieve@yahoo.com>
### Motivation and Context <!-- Thank you for your contribution to the semantic-kernel repo! Please help reviewers and future users, providing the following information: 1. Why is this change required? 2. What problem does it solve? 3. What scenario does it contribute to? 4. If it fixes an open issue, please link to the issue here. --> ### Description <!-- Describe your changes, the overall approach, the underlying design. These notes will help understanding how your code works. Thanks! --> ### Contribution Checklist <!-- Before submitting this PR, please make sure: --> - [ ] The code builds clean without any errors or warnings - [ ] The PR follows the [SK Contribution Guidelines](https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md) and the [pre-submission formatting script](https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md#development-scripts) raises no violations - [ ] All unit tests pass, and I have added new tests where possible - [ ] I didn't break anyone 😄 --------- Co-authored-by: David Grieve <dsgrieve@yahoo.com>
### Motivation and Context <!-- Thank you for your contribution to the semantic-kernel repo! Please help reviewers and future users, providing the following information: 1. Why is this change required? 2. What problem does it solve? 3. What scenario does it contribute to? 4. If it fixes an open issue, please link to the issue here. --> ### Description <!-- Describe your changes, the overall approach, the underlying design. These notes will help understanding how your code works. Thanks! --> ### Contribution Checklist <!-- Before submitting this PR, please make sure: --> - [ ] The code builds clean without any errors or warnings - [ ] The PR follows the [SK Contribution Guidelines](https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md) and the [pre-submission formatting script](https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md#development-scripts) raises no violations - [ ] All unit tests pass, and I have added new tests where possible - [ ] I didn't break anyone 😄 --------- Co-authored-by: David Grieve <dsgrieve@yahoo.com>
Motivation and Context
Description
Contribution Checklist