Commit Graph

69 Commits

Author SHA1 Message Date
skynono
221d2b5552 feat: add video channel jimeng 2025-06-27 17:08:20 +08:00
CaIon
8a1e437ce9 🔧 chore: update STREAMING_TIMEOUT default value to 120 seconds in configuration 2025-06-22 18:47:40 +08:00
CaIon
32366d1e1b refactor: streamline price calculation in RelaySwapFace and RelayMidjourneySubmit functions 2025-06-22 17:52:48 +08:00
skynono
d7ed0214ad feat: add video channel kling 2025-06-19 11:53:42 +08:00
RedwindA
09ffc364f2 🔧 refactor(redis): replace direct constant usage with RedisKeyCacheSeconds function for cache duration 2025-06-17 03:24:39 +08:00
Apple\Apple
28c3aef76f 🔒 feat: Add user-configurable IP logging for consume and error logs
- Add IP field to Log model with database index and default empty value
- Implement conditional IP recording based on user setting in RecordConsumeLog and RecordErrorLog
- Add UserSettingRecordIpLog constant and update user settings API to handle record_ip_log field
- Create dedicated "IP记录" tab in personal settings under "其他设置" section
- Add IP column to logs table with help tooltip explaining recording conditions
- Make IP column visible to all users (not admin-only) with proper filtering for consume/error log types
- Restrict display of use_time and retry columns to consume and error log types only
- Update personal settings UI structure: rename "通知设置" to "其他设置" to accommodate new functionality
- Add proper translation support and maintain consistent styling across components

The IP logging feature is disabled by default and only records client IP addresses
for consume (type 2) and error (type 5) logs when explicitly enabled by users
in their personal settings.
2025-06-13 01:34:01 +08:00
creamlike1024
b843c356c1 feat: change azure default api version to 2025-04-01-preview 2025-05-09 18:11:37 +08:00
CaIon
66cda24386 feat: add AzureNoRemoveDotTime constant and update channel handling #1044
- Introduced a new constant `AzureNoRemoveDotTime` in `constant/azure.go` to manage model name formatting for channels created after May 10, 2025.
- Updated `distributor.go` to set `channel_create_time` in the context.
- Modified `adaptor.go` to conditionally remove dots from model names based on the channel creation time.
- Enhanced `relay_info.go` to include `ChannelCreateTime` in the `RelayInfo` struct.
- Updated English localization files to reflect changes in model name handling for new channels.
2025-05-08 23:19:40 +08:00
CaIon
f5c2fda22a feat: enable error logging configuration in docker-compose and application 2025-04-29 16:26:55 +08:00
wkxu
54c5c3118b refactor: 把common/instants.go里的从Getenv获取的参数,放到init.go的LoadEnv函数里获取
把constant/env.go里的从Getenv获取的参数,放到env.go的InitEnv函数里获取。以避免.env文件配置参数不起作用的情况
2025-04-10 09:02:19 +08:00
CaIon
f33ebc8e2c feat: Implement system setup functionality 2025-04-03 18:57:15 +08:00
CaIon
f0925dc105 feat: Enhance user settings and notification options 2025-04-03 17:32:48 +08:00
1808837298@qq.com
8a30d64a75 feat: Add Gemini version settings configuration support (close #568) 2025-02-26 18:19:09 +08:00
1808837298@qq.com
d04d78a116 refactor: Enhance user context and quota management
- Add new context keys for user-related information
- Modify user cache and authentication middleware to populate context
- Refactor quota and notification services to use context-based user data
- Remove redundant database queries by leveraging context information
- Update various components to use new context-based user retrieval methods
2025-02-25 20:56:16 +08:00
1808837298@qq.com
4597816a14 feat: Add thinking-to-content conversion for stream responses 2025-02-23 17:05:57 +08:00
1808837298@qq.com
8a34d61654 chore: update env name and README 2025-02-19 15:54:33 +08:00
1808837298@qq.com
9a41c04416 feat: Implement notification rate limiting mechanism
- Add in-memory and Redis-based notification rate limiting
- Create configurable hourly notification limits
- Implement notification limit checking for user notifications
- Add environment variables for customizing notification limits
2025-02-18 15:30:43 +08:00
1808837298@qq.com
0fcd243f56 feat: Add user notification settings with quota warning and multiple notification methods
- Implement user notification settings with email and webhook options
- Add new user settings for quota warning threshold and notification preferences
- Create backend API and database support for user notification configuration
- Enhance frontend personal settings with notification configuration UI
- Support custom notification email and webhook URL
- Add service layer for sending user notifications
2025-02-18 14:54:21 +08:00
1808837298@qq.com
80f60109cf feat: add Azure default API version configuration
- Introduce `AZURE_DEFAULT_API_VERSION` environment variable
- Set default Azure API version to `2024-12-01-preview`
- Update README documentation for new environment configuration
- Modify Azure channel relay to use default API version when not specified
2025-02-03 22:38:23 +08:00
1808837298@qq.com
5c8af189eb feat: support channel request proxy 2025-02-02 22:15:06 +08:00
CalciumIon
aefd53b683 refactor: token cache logic 2024-12-30 17:10:48 +08:00
CalciumIon
966cdc1f7f refactor: user cache logic 2024-12-29 16:50:26 +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
Yan
411d3a6251 fix: gemini func call 2024-12-24 20:46:02 +08:00
CalciumIon
72be58523c feat: Add request start time context key and update middleware
- Introduced a new constant `ContextKeyRequestStartTime` to store the request start time in the context, enhancing request tracking.
- Updated the `Distribute` middleware to set the request start time in the context using the new constant.
- Modified the `GenRelayInfo` function to retrieve the request start time from the context, ensuring accurate timing information is used in relay operations.
2024-12-23 20:48:10 +08:00
CalciumIon
69c590d439 feat: Introduce settings package and refactor constants
- Added a new `setting` package to replace the `constant` package for configuration management, improving code organization and clarity.
- Moved various configuration variables such as `ServerAddress`, `PayAddress`, and `SensitiveWords` to the new `setting` package.
- Updated references throughout the codebase to use the new `setting` package, ensuring consistent access to configuration values.
- Introduced new files for managing chat settings and midjourney settings, enhancing modularity and maintainability of the code.
2024-12-22 17:24:29 +08:00
CalciumIon
0725c8aac9 feat: Add GEMINI_VISION_MAX_IMAGE_NUM configuration
- Introduced `GEMINI_VISION_MAX_IMAGE_NUM` to README files for better user guidance.
- Updated `env.go` to retrieve the maximum image number from environment variables, defaulting to 16.
- Modified image handling logic in `relay-gemini.go` to respect the new configuration, allowing disabling of the limit by setting it to -1.
- Removed hardcoded constant for maximum image number in `constant.go` to streamline configuration management.
2024-12-20 21:36:23 +08:00
CalciumIon
0ad03de153 feat: implement channel settings configuration
fix #620
2024-12-15 15:52:41 +08:00
CalciumIon
246c3fa451 feat: add gemini tool_calls finish reason 2024-12-06 14:31:27 +08:00
CalciumIon
21d71a2a31 chore: update default STREAMING_TIMEOUT 2024-11-28 23:59:10 +08:00
HowieWood
4e531938ee Modify the default gemini API to v1beta 2024-11-16 12:21:50 +00:00
1808837298@qq.com
7cd507f13b fix: 修复自定义聊天bug
(cherry picked from commit 8d41c17ccf19cb29100dbe506d3d42a6be822ff9)
2024-10-13 00:21:52 +08:00
1808837298@qq.com
53ff1547cf feat: 弃用旧的聊天配置 2024-10-12 21:09:59 +08:00
GuoRuqiang
f4dcb4e2be Merge branch 'Calcium-Ion:main' into main 2024-09-14 19:00:03 +08:00
Yan
39f10c8305 add gemini exp 2024-09-11 19:37:03 +08:00
Jin Weihan
a3ad4f528d 增加环境变量GENERATE_DEFAULT_TOKEN 设置之后将生成初始令牌,默认关闭。 2024-08-24 18:44:37 +00:00
CalciumIon
fda2fd2e53 feat: 优化Gemini模型版本获取逻辑 2024-08-02 17:23:59 +08:00
kakingone
442a2f0f4d addupload 2024-07-31 15:48:51 +08:00
CalciumIon
e6de0c0bae feat: add UPDATE_TASK env 2024-07-18 17:26:21 +08:00
CalciumIon
34c356b041 feat: 媒体请求计费选项 2024-07-18 17:04:19 +08:00
CalciumIon
976e1f0921 fix: stream options 2024-07-08 21:54:32 +08:00
CalciumIon
1852fe04a1 feat: update FORCE_STREAM_OPTION default value 2024-07-08 21:41:52 +08:00
CalciumIon
a7351b72b1 feat: 允许设置是否检测mj任务已完成才可进行action操作 (close #349) 2024-07-08 16:48:10 +08:00
CalciumIon
22bc0bf773 feat: support stream_options 2024-07-08 01:27:57 +08:00
CalciumIon
2e45163f93 feat: add env DIFY_DEBUG 2024-07-07 02:24:51 +08:00
CalciumIon
eca52104cc chore: 重构 2024-06-27 19:30:17 +08:00
CalciumIon
e7a4aa0595 feat: 支持设置流模式超时时间 2024-06-27 17:17:23 +08:00
Calcium-Ion
7378c3827b Merge pull request #310 from Calcium-Ion/feat/suno-api
Feat/suno api
2024-06-21 14:59:59 +08:00
1808837298@qq.com
3085e512cd feat: 记录自动禁用原因 (close #300) 2024-06-15 01:11:03 +08:00
Xiangyuan Liu
05a4646b44 feat: suno api 支持
feat: 调试 suno

feat: 补充suno 文档
2024-06-13 10:35:48 +08:00