-
Notifications
You must be signed in to change notification settings - Fork 162
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
Allow PartsRepresentable
to throw errors
#88
Conversation
What's an API example that will break and need to be changed? |
See this file: https://github.com/google/generative-ai-swift/pull/88/files#diff-a61268065794a7fb215fc6d6e84f0127f200a881647fe588e9b06477683d4a9b I left this PR as a draft because I think we should do some more formal API proposal before baking it in. We can discuss in standup tomorrow. |
PartsRepresentable
to throw errors
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.
Some questions around showing how to use the updated APIs, and some remarks around naming.
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.
LGTM, with one final nit: use a consistent name for the autoclosure.
Places using content
:
https://github.com/google/generative-ai-swift/blob/d962763ca1095879b54f2c12a9c0d3e708358aac/Sources/GoogleAI/Chat.swift#L91
https://github.com/google/generative-ai-swift/blob/d962763ca1095879b54f2c12a9c0d3e708358aac/Sources/GoogleAI/Chat.swift#L44
https://github.com/google/generative-ai-swift/blob/d962763ca1095879b54f2c12a9c0d3e708358aac/Sources/GoogleAI/GenerativeModel.swift#L114
https://github.com/google/generative-ai-swift/blob/d962763ca1095879b54f2c12a9c0d3e708358aac/Sources/GoogleAI/GenerativeModel.swift#L259
This is a breaking change. See the internal proposal for more details.