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

Feature/autogenstudio UI extra headers #2433

Closed
wants to merge 21 commits into from

Conversation

ronaldpereira
Copy link

Why are these changes needed?

Problem: The autogenstudio library lacked the ability to specify default headers for API requests. This caused issues when APIs required specific headers to be included in every request.

Solution: I've extended autogenstudio to accept an optional default_headers parameter. This parameter allows developers to define a dictionary containing the desired headers, which will be automatically included in all API requests generated by autogenstudio.

For example, when any custom API needed some extra headers to complete the request:
"default_headers": {"X-Requester-Token": "<requester_token>"}
The llm_config parameter already accepts this configuration, but it wasn't possible to pass it via the autogenstudio via model creation.

Checks

Extra info

This MR was done originally in here, but it was needed to create this in the upstream repo for openai tests to run.

@ronaldpereira ronaldpereira self-assigned this Apr 18, 2024
@codecov-commenter
Copy link

codecov-commenter commented May 17, 2024

Codecov Report

Attention: Patch coverage is 50.00000% with 2 lines in your changes are missing coverage. Please review.

Project coverage is 48.53%. Comparing base (372ac1e) to head (36483a7).
Report is 29 commits behind head on main.

Files Patch % Lines
autogen/oai/client.py 50.00% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##             main    #2433       +/-   ##
===========================================
+ Coverage   33.11%   48.53%   +15.41%     
===========================================
  Files          86       87        +1     
  Lines        9108     9340      +232     
  Branches     1938     2140      +202     
===========================================
+ Hits         3016     4533     +1517     
+ Misses       5837     4402     -1435     
- Partials      255      405      +150     
Flag Coverage Δ
unittest 12.70% <25.00%> (?)
unittests 47.78% <50.00%> (+14.66%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@ekzhu ekzhu changed the base branch from main to 0.2 October 2, 2024 18:30
@jackgerrits jackgerrits added the 0.2 Issues which were filed before re-arch to 0.4 label Oct 4, 2024
@rysweet rysweet added the awaiting-op-response Issue or pr has been triaged or responded to and is now awaiting a reply from the original poster label Oct 10, 2024
@rysweet
Copy link
Collaborator

rysweet commented Oct 11, 2024

Hi @ronaldpereira - we rebased this for you but it looks like there are still some conflicts. If you are still interested in bringing this forward please have a look at resolving the conflicts and greening the CI

@ronaldpereira
Copy link
Author

Hello @rysweet,

The recent changes to the autogen studio have affected the database and UI design I've implemented, so adjustments will be needed to make this mergeable. I believe it would be more efficient to create a new branch from scratch using the current codebase, rather than trying to adapt the existing one in this MR.

Therefore, I'll close this MR for now and will open a new one, referencing this, once the new branch is ready.

Thank you for rebasing this MR for me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0.2 Issues which were filed before re-arch to 0.4 awaiting-op-response Issue or pr has been triaged or responded to and is now awaiting a reply from the original poster proj-studio Related to AutoGen Studio.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants