-
-
Notifications
You must be signed in to change notification settings - Fork 54
[Platform][Anthropic] Allow beta feature flags to be passed into platform invocations #274
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
Conversation
I am fine using the Can you please add a test case? Thanks |
Sure thing. |
@OskarStark Done. |
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.
Good catch, those specific things slip easily through, thanks!
minor comments from my end
Will address these issues on Monday. |
It's done now. My apologies for the delay, I had some higher priority work to attend to. |
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.
It's done now. My apologies for the delay, I had some higher priority work to attend to.
No need to apologize - we all have a day job to make the living :D
Looks good to me know, thanks!
Thank you @TomLisankie. |
Anthropic supports passing flags for beta features via beta headers in requests to its API. This PR allows for passing in the desired beta features via the
$options
parameter in theinvoke
function like so:If the beta features option is set and contains at least one element, the beta header is constructed inside the model client and then the option is removed from
$options
before the request is built and sent to Anthropic.If we want to support beta feature flags for other providers in the future, we should perhaps add another parameter to the
invoke
function for platforms and therequest
function for model clients in order to not pollute$options
(after all,$options
is meant to hold model options not platform options).