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

Simplify top-level schema declaration in FunctionDeclaration #117

Conversation

andrewheard
Copy link
Collaborator

Updated the constructor for FunctionDeclaration to take parameters: [String: Schema]?, requiredParameters: [String]? instead of parameters: Schema?. This prevents a non-object top-level schema from being provided, e.g., Schema(type: .number, format: "int64", description: "My Int parameter") which isn't supported.

Copy link
Collaborator

@paulb777 paulb777 left a comment

Choose a reason for hiding this comment

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

Nice simplification

@andrewheard andrewheard marked this pull request as ready for review March 14, 2024 16:13
@andrewheard andrewheard merged commit ae60f57 into ah/function-calling-prototype Mar 14, 2024
10 checks passed
@andrewheard andrewheard deleted the ah/function-calling-prototype-properties branch March 14, 2024 16:13
@github-actions github-actions bot added component:swift sdk Issue/PR related to Swift SDK status:awaiting review PR awaiting review from a maintainer and removed status:awaiting review PR awaiting review from a maintainer labels Mar 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component:swift sdk Issue/PR related to Swift SDK
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants