Butui Hu
6e710f3210
Fix temperature not being set to 0 due to json omitempty
...
The issue was caused by the `omitempty` tag in the Go struct, which prevented the `temperature` field from being included in the JSON output when it was set to 0.
Signed-off-by: Butui Hu <hot123tea123@gmail.com >
2025-01-21 12:54:09 +08:00
CalciumIon
e326679b72
feat: add multi-file type support for Gemini and Claude
...
- Add file data DTO for structured file handling
- Implement file decoder service
- Update Claude and Gemini relay channels to handle various file types
- Reorganize worker service to cf_worker for clarity
- Update token counter and image service for new file types
2024-12-29 00:00:24 +08:00
CalciumIon
464220cdf1
refactor: Update OpenAI request and message handling
...
- Changed the type of ToolCalls in the Message struct from `any` to `json.RawMessage` for better type safety and clarity.
- Introduced ParseToolCalls and SetToolCalls methods to handle ToolCalls more effectively, improving code readability and maintainability.
- Updated the ParseContent method to work with the new MediaContent type instead of MediaMessage, enhancing the structure of content parsing.
- Refactored Gemini relay functions to utilize the new ToolCalls handling methods, streamlining the integration with OpenAI and Gemini systems.
2024-12-22 16:20:30 +08:00
1808837298@qq.com
1307a23f01
feat: realtime
...
(cherry picked from commit d4966246e68dbdcdab45ec5c5141362834d74425)
2024-11-05 19:27:47 +08:00
1808837298@qq.com
9e4133a890
feat: realtime
...
(cherry picked from commit a5529df3e1a4c08a120e8c05203a7d885b0fe8d8)
2024-11-05 19:24:14 +08:00
CalciumIon
52e7230c41
chore: update model ratio
2024-11-05 15:58:22 +08:00
1808837298@qq.com
6e3d8b5572
feat: update claude models
2024-10-24 00:17:23 +08:00
Yan Tau
02e9dd176c
Merge branch 'Calcium-Ion:main' into main
2024-09-11 19:29:50 +08:00
CalciumIon
17c8ba787e
feat: claude response return model name
2024-09-11 19:12:55 +08:00
Yan
94b1fc857c
fix: tool use in claude
2024-09-05 00:53:00 +08:00
CalciumIon
b8664e71e6
feat: support vertex ai #377
2024-08-27 20:19:51 +08:00
CalciumIon
e059909a29
feat: format claude messages when first role is not user
2024-08-24 17:15:55 +08:00
CalciumIon
a79a68c379
feat: update claude tools calling
2024-08-13 17:54:24 +08:00
CalciumIon
d06018cd3f
chore: gopool
2024-07-19 01:07:37 +08:00
CalciumIon
dc58ff0434
feat: support claude tool calling
2024-07-18 00:36:05 +08:00
CalciumIon
ee0e1c9736
refactor: audio relay
2024-07-16 22:07:10 +08:00
CalciumIon
7b20b4ed3d
fix: azure stream options
2024-07-15 16:05:30 +08:00
CalciumIon
1086340e14
feat: support claude stop_sequences
2024-07-11 18:44:45 +08:00
CalciumIon
f2a251025d
feat: 完善stream_options
2024-07-08 02:00:39 +08:00
CalciumIon
b93fd8e349
feat: support aws stream_options
2024-07-08 01:52:40 +08:00
CalciumIon
876bed4600
feat: support claude stream_options
2024-07-08 01:45:43 +08:00
CalciumIon
c7ba4a245b
feat: support cohere rerank
2024-07-06 17:09:22 +08:00
CalciumIon
fce31dd1de
feat: 支持设置流模式超时时间(gemini, claude)
2024-06-27 17:24:48 +08:00
CalciumIon
a1d4012efb
feat: first response time support gemini and claude
2024-06-27 00:16:39 +08:00
Mageia
4b08066f65
chore: Add Anthropic claude-3-5-sonnet-20240620 to model list
2024-06-25 10:04:17 +08:00
1808837298@qq.com
31f7946866
fix: claude usage
2024-06-15 01:30:51 +08:00
1808837298@qq.com
893dafb89f
feat: 支持设置worker访问请求中的图片地址
2024-05-28 17:59:53 +08:00
1808837298@qq.com
313c16f360
refactor: 重构敏感词
2024-05-23 23:59:55 +08:00
CaIon
c5a9fa97ef
fix: aws claude
2024-04-28 20:45:34 +08:00
CaIon
8e3c527640
fix: 规范claude返回格式
2024-04-26 02:56:35 +08:00
CaIon
483e1c46d2
fix: 规范claude返回格式
2024-04-25 23:57:39 +08:00
CaIon
362c55d6cc
fix: claude流模式缺失role
2024-04-25 22:57:11 +08:00
CaIon
6ead87c057
fix: claude
2024-04-25 20:37:50 +08:00
1808837298@qq.com
8132493dbd
feat: claude 整理prompt
2024-04-25 16:04:53 +08:00
CaIon
cae9dbe141
feat: support cohere ( close #195 )
2024-04-24 18:49:56 +08:00
CaIon
b1bfcbb02a
feat: 自动整理claude不规范prompt
2024-04-23 13:08:37 +08:00
CaIon
dc818a92f6
fix: claude max_tokens
2024-04-23 12:19:23 +08:00
CaIon
3721ed796c
feat: support aws claude
2024-04-23 11:44:40 +08:00
Maple Gao
dad51bda73
feat: add Claude TopK
2024-04-01 14:33:58 +08:00
CaIon
54c18dc89e
fix: remove sensitive check on completion ( close #157 )
2024-03-29 22:20:14 +08:00
CaIon
5d694efda7
fix: claude panic
2024-03-20 21:32:33 +08:00
CaIon
b01d59704d
fix: claude panic
2024-03-20 21:28:45 +08:00
CaIon
5aad98d736
feat: 统一错误提示
2024-03-20 20:36:55 +08:00
CaIon
580f2894ac
feat: 初步兼容生成内容检查
2024-03-20 19:00:51 +08:00
CaIon
14892a6582
feat: 初步兼容敏感词过滤
2024-03-20 17:07:42 +08:00
CaIon
232928f455
feat: support Anthropic Claude 3.0 Haiku ( close #116 )
2024-03-14 14:28:21 +08:00
CaIon
db024636bc
fix: 修复claude渠道流模式计费可能异常
2024-03-09 13:25:47 +08:00
CaIon
d007f84c5e
fix: fix claude channel test
2024-03-08 21:38:43 +08:00
CaIon
22f1c13a8b
feat: update claude default model ratio
2024-03-08 21:17:32 +08:00
CaIon
a1d8626ad6
fix: fix claude 3 request missing the 'max_token' field
2024-03-08 21:16:12 +08:00