-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Adding extra_headers parameters to ModelSettings #550
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
@rm-openai It doesn't look like I have the ability to request reviews. Is there a process I should follow? |
0e46448
to
025d58e
Compare
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.
Thanks @jonnyk20, looks good. Two change requests:
- Can you please add tests? e.g. ensuring that
extra_headers
is passed on to the model if set. - Can you also add this to the litellm model?
Thanks1
e102319
to
f4ac7ed
Compare
@rm-openai no problem - done! I wasn't able to create a
Which resulted in the following:
Any suggestions for how to fix it? |
@jonnyk20 PR looks good, would you mind fixing lint and I can merge? |
f4ac7ed
to
3dfcfc7
Compare
@rm-openai, sure done. Thanks for the review! |
* upstream/main: Examples: Fix financial_research_agent instructions (openai#573) Adding extra_headers parameters to ModelSettings (openai#550) v0.0.12 (openai#564) Pass through organization/project headers to tracing backend, fix speech_group enum (openai#562) Docs and tests for litellm (openai#561) RFC: automatically use litellm if possible (openai#534) Fix visualize graph filename to without extension. (openai#554) Start and finish streaming trace in impl metod (openai#540) Enable non-strict output types (openai#539) Examples for image inputs (openai#553)
Added the possibility to pass
extra_headers
when sending a request.I used the same implementation as was recently used for
extra_body
andextra_query
in #500In this implementation I added the attributes to ModelSettings as suggested here
https://github.com/openai/openai-agents-python/issues/487 .
I'll be happy to add some tests if you have any suggestions.