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

Python: Fix kernel parameter metadata input type arg to call type_ #10603

Merged
merged 3 commits into from
Feb 19, 2025

Conversation

moonbox3
Copy link
Contributor

Motivation and Context

To address a typing issue, we updated the kernel parameter metadata so that the input type argument now calls type (configured as an alias) rather than the model’s parameter type_. Previously, setting the alias did not update the underlying type_ attribute, leaving it as None. As a result, when generating the JSON schema, the parameter_type was omitted, causing some customers who sent KernelFunctionMetadata to the OpenAI model to receive a 400 error due to a malformed schema.

Description

Revert the change and add a unit test to make sure we check for the expected schema.

Contribution Checklist

@moonbox3 moonbox3 requested a review from a team as a code owner February 19, 2025 04:33
@moonbox3 moonbox3 requested a review from Copilot February 19, 2025 04:33

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

@moonbox3 moonbox3 enabled auto-merge February 19, 2025 04:43
@moonbox3 moonbox3 added this pull request to the merge queue Feb 19, 2025
Merged via the queue into microsoft:main with commit 68448b1 Feb 19, 2025
28 checks passed
@moonbox3 moonbox3 deleted the fix-param-metadata-type-arg branch February 19, 2025 10:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Sprint: Done
Development

Successfully merging this pull request may close these issues.

3 participants