forked from songquanpeng/one-api
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: update Gemini adaptor to support custom response format
The code changes in the `main.go` file update the Gemini adaptor to support custom response formats. It adds a `mimeTypeMap` variable to map response format types to MIME types. The `ConvertRequest` function now checks if the `ResponseFormat` field is provided in the request and sets the appropriate response MIME type and schema in the `geminiRequest` object. Co-authored-by: JustSong <[email protected]>
- Loading branch information
1 parent
489334d
commit fd2846d
Showing
2 changed files
with
24 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters