Commit Graph

25 Commits

Author SHA1 Message Date
Laisky.Cai
080b6036fb feat: enhance Gemini API to support image response modalities and update model ratios 2025-03-17 01:22:33 +00:00
Laisky.Cai
cdacfb6787 Merge branch 'feature/gemini-2.0-flash' 2025-02-06 03:11:49 +00:00
Laisky.Cai
d70335ecea feat: support gemini-2.0-flash
- Enhance model support by adding new entries and refining checks for system instruction compatibility.
- Update logging display behavior and adjust default quotas for better user experience.
- Revamp pricing structures in the billing system to reflect current model values and deprecate outdated entries.
- Streamline code by replacing hardcoded values with configurations for maintainability.
2025-02-06 03:08:41 +00:00
Laisky.Cai
3e4708b77e feat: support gemini-2.0-flash 2025-02-06 02:34:41 +00:00
Laisky.Cai
ddcd1295ff
Merge pull request #20 from mxdlzg/system_instruction_feature
System instruction feature
2025-01-06 16:12:26 +08:00
mxdlzg
ad56898d5a feat: use SystemInstructions and remove gemini dummy message 2024-12-23 14:44:39 +08:00
mxdlzg
ba50a137ea feat: add tool choice configuration and update steam handling in Gemini
update ToolConfig to use pointer type in ChatRequest
2024-12-23 14:44:25 +08:00
Wei Tingjiang
49ffb1c60d
feat: enhance response handling to support gemini-2.0-thinking (#1995) 2024-12-22 18:25:44 +08:00
Jinjun Liu
c4afcc8337 feat: add support for gemini-2.0-flash-thinking-exp model 2024-12-21 19:46:35 -06:00
Laisky.Cai
2e5e6faad7 Merge remote-tracking branch 'origin/upstream/main' 2024-10-29 01:15:54 +00:00
Wei Tingjiang
6f13a3bb3c
feat: update Gemini adaptor to support custom response format (#1892) 2024-10-27 17:10:50 +08:00
Laisky.Cai
c20f27ec45 Merge remote-tracking branch 'origin/upstream/main' 2024-07-01 03:09:33 +00:00
zijiren
b21b3b5b46
refactor: abusing goroutines and channel (#1561)
* refactor: abusing goroutines

* fix: trim data prefix

* refactor: move functions to render package

* refactor: add back trim & flush

---------

Co-authored-by: JustSong <quanpengsong@gmail.com>
2024-06-30 18:36:33 +08:00
Laisky.Cai
115287b8cf Merge remote-tracking branch 'origin/upstream/main' 2024-06-17 03:16:36 +00:00
Wei Tingjiang
b1520b308b
Try to fix Gemini streaming return being truncated by FinishReason. (#1477)
1
2024-06-14 00:30:47 +08:00
Laisky.Cai
c524e60d9f Merge remote-tracking branch 'origin/upstream/main' 2024-05-29 06:12:37 +00:00
Wei Tingjiang
9321427c6e
feat: support gemini embeddings (text-embedding-004,embedding-001) (#1475)
* Refactor Gemini Adaptor to Support Embeddings

* Add new models to ModelList
2024-05-29 01:17:32 +08:00
Laisky.Cai
ca23dd9a97 Merge commit '1c2654320e5b6268b13b6efca40ce37a523d032b' 2024-04-28 01:53:31 +00:00
JustSong
04b49aa0ec chore: use StringContent() to convert response to text 2024-04-27 15:41:02 +08:00
Wei Tingjiang
ef88497f25
fix: refactor Gemini adaptor to support streaming content generation (#1382) 2024-04-27 15:39:59 +08:00
Laisky.Cai
a516d5eadd Merge commit 'da0842272ced7bee05a8f43c40a7a8c01b14d09a' 2024-04-25 03:04:12 +00:00
Wei Tingjiang
779b747e9e
feat: add function and tools support for Gemini (#1358)
* Update model.go

* Support Gemini tool_calls.

* Fix gemini tool calls (also keep support functions).

* Fixed the problem of arguments not being stringified.

Fix panic: candidate.Content.Parts out of range
2024-04-24 21:26:45 +08:00
Laisky.Cai
c735b9b4d3 Merge commit '2369025842b828ac38f4427fd1ebab8d03b1fe7f' 2024-04-20 01:07:29 +00:00
Laisky.Cai
50bab08496 Refactor codebase, introduce relaymode package, update constants and improve consistency
- Refactor constant definitions and organization
- Clean up package level variables and functions
- Introduce new `relaymode` and `apitype` packages for constant definitions
- Refactor and simplify code in several packages including `openai`, `relay/channel/baidu`, `relay/util`, `relay/controller`, `relay/channeltype`
- Add helper functions in `relay/channeltype` package to convert channel type constants to corresponding API type constants
- Remove deprecated functions such as `ResponseText2Usage` from `relay/channel/openai/helper.go`
- Modify code in `relay/util/validation.go` and related files to use new `validator.ValidateTextRequest` function
- Rename `util` package to `relaymode` and update related imports in several packages
2024-04-06 05:18:04 +00:00
JustSong
24ed170e7b chore: reorganize adaptor related package 2024-04-06 01:36:48 +08:00