CaIon
0359dfb8c3
🐛 fix: correct validation logic for redemption name input in EditRedemption component
2025-07-02 10:28:57 +08:00
CaIon
c7b3b8d0b1
✨ feat: increase Node.js memory limit in macOS release workflow
2025-07-01 13:23:29 +08:00
CaIon
41d20484f9
Merge branch 'main' into alpha
2025-07-01 13:15:47 +08:00
CaIon
0d336793bb
Merge remote-tracking branch 'origin/alpha' into alpha
2025-07-01 13:14:40 +08:00
CaIon
cfc8dcf7af
✨ feat: enhance JWT exchange process with proxy support. ( close #1087 )
2025-07-01 13:14:24 +08:00
CaIon
2f04ab0daf
✨ feat: enhance environment configuration and resource initialization
2025-07-01 13:13:30 +08:00
CaIon
e2c34bdeb9
🐛 fix: refactor JSON unmarshalling across multiple handlers to use UnmarshalJson and UnmarshalJsonStr for consistency
...
This update replaces instances of DecodeJson and DecodeJsonStr with UnmarshalJson and UnmarshalJsonStr in various relay handlers, enhancing code consistency and clarity in JSON processing. The changes improve maintainability and align with recent refactoring efforts in the codebase.
2025-06-28 00:02:07 +08:00
CaIon
aae9e81c20
🐛 fix: refactor response body handling in multiple relay handlers to utilize IOCopyBytesGracefully
2025-06-27 23:35:56 +08:00
CaIon
defc18dea8
🐛 fix: refactor JSON encoding and decoding in OpenAI handlers for improved consistency
2025-06-27 22:45:36 +08:00
CaIon
452cf0dcc4
🐛 fix: refactor OaiStreamHandler to improve last response handling and streamline response body closure
2025-06-27 22:44:20 +08:00
CaIon
b7776bec62
🐛 fix: update hardcoded completion model ratio for gemini-2.5-flash-lite
2025-06-27 22:36:23 +08:00
CaIon
5178e563be
✨ feat: introduce IOCopyBytesGracefully function for streamlined response body handling
...
This update adds the IOCopyBytesGracefully function to the common package, which simplifies the process of copying response bodies in the OpenAI handlers. It enhances error handling and ensures proper resource management by encapsulating the logic for setting headers and writing response data. The OpenAI handlers have been refactored to utilize this new function, improving code clarity and maintainability.
2025-06-27 22:36:12 +08:00
CaIon
6db7a84787
🐛 fix: replace direct response body closure with common.CloseResponseBodyGracefully for improved error handling
...
This update standardizes the closure of HTTP response bodies across multiple stream handlers, enhancing error management and resource cleanup. The new method ensures that any errors during closure are handled gracefully, preventing potential request termination issues.
2025-06-27 21:40:36 +08:00
CaIon
ae586e1be9
✨ feat: add CloseResponseBodyGracefully function to handle HTTP response body closure
2025-06-27 21:37:13 +08:00
CaIon
cc08347caf
🐛 fix: handle response body errors more gracefully in OpenAI handler
...
Changes:
- Replaced error returns with logging for response body copy failures to prevent early termination of the request.
- Ensured that the response body is closed properly after writing to the client.
- Added comments to clarify the handling of billing and error reporting after the response has been sent.
This update improves error handling and maintains resource management in the OpenAI handler.
2025-06-27 21:13:21 +08:00
CaIon
e234ad0740
✨ feat: add Function and Container fields to ResponsesToolsCall struct #1305
2025-06-27 16:56:54 +08:00
CaIon
038202b1f6
🔧 fix(xinference): update Document type to 'any' for flexibility
...
- Changed the type of `Document` in `XinRerankResponseDocument` from `string` to `any` to accommodate various data types.
- Updated the `RerankHandler` to handle `Document` as `any`, ensuring proper assignment based on its actual type.
These modifications enhance the handling of document data, allowing for greater versatility in response structures.
2025-06-25 18:04:34 +08:00
CaIon
04d525e317
🚀 feat(auth): support new model API paths in authentication and routing
...
- Updated TokenAuth middleware to handle requests for both `/v1beta/models/` and `/v1/models/`.
- Adjusted distributor middleware to recognize the new model path.
- Enhanced relay mode determination to include the new model path.
- Added route for handling POST requests to `/models/*path`.
These changes ensure compatibility with the new model API structure, improving the overall routing and authentication flow.
2025-06-25 00:19:38 +08:00
CaIon
51086c3ba6
🔧 fix(model_ratio): adjust return values for gemini-2.5-pro and gemini-2.5-flash models
2025-06-24 18:08:42 +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
CaIon
20e233ea8a
Merge remote-tracking branch 'origin/alpha' into alpha
2025-06-22 16:59:22 +08:00
CaIon
9121a593d7
fix: reset channel key in UpdateChannel function
2025-06-22 16:59:06 +08:00
CaIon
d084083e05
fix: update JSON decoding and budget token handling in RequestOpenAI2ClaudeMessage
2025-06-22 01:15:01 +08:00
CaIon
131b62d065
Merge remote-tracking branch 'origin/alpha' into alpha
2025-06-22 00:59:56 +08:00
CaIon
93fb5bab6b
✨ fix(dto): change Created field type in OpenAITextResponse to any. ( close #1131 )
2025-06-22 00:59:39 +08:00
CaIon
7de52a0c0d
✨ feat(gemini): enhance ThinkingAdapter and model handling
...
- Introduced `isNoThinkingRequest` and `trimModelThinking` functions to manage model names and thinking configurations.
- Updated `GeminiHelper` to conditionally adjust the model name based on the thinking budget and request settings.
- Refactored `ThinkingAdaptor` to streamline the integration of thinking capabilities into Gemini requests.
- Cleaned up commented-out code in `FetchUpstreamModels` for clarity.
These changes improve the handling of model configurations and enhance the adaptability of the Gemini relay system.
2025-06-21 21:50:03 +08:00
CaIon
d244915111
✨ feat(relay-gemini): conditionally set ThinkingBudget based on MaxOutputTokens
2025-06-21 17:51:13 +08:00
CaIon
4307065c6c
Merge branch 'main' into alpha
2025-06-21 17:04:29 +08:00
CaIon
2c391a0c6d
Merge branch 'alpha'
2025-06-21 01:26:57 +08:00
CaIon
3164e86278
fix: remove unnecessary error handling in token counting functions
2025-06-21 01:16:54 +08:00
CaIon
2c0fd2915b
fix: improve usage calculation in GeminiTextGenerationStreamHandler
2025-06-21 01:08:15 +08:00
CaIon
16997a695d
refactor: token counter logic
2025-06-21 00:54:40 +08:00
CaIon
8ceaaf7819
fix: update response handling in GeminiTextGenerationStreamHandler
...
- Changed response handling from ObjectData to StringData for improved data processing.
- Ensured proper error logging in case of response handling failure.
2025-06-20 21:55:28 +08:00
CaIon
11c3bff1e2
fix: update payment method handling in topup controller
...
- Refactored payment method validation to check against available methods.
- Changed payment method types from "zfb" to "alipay" and "wx" to "wxpay" for consistency.
- Updated the purchase request to use the validated payment method directly.
2025-06-20 17:48:55 +08:00
CaIon
13277cf838
feat: implement new handlers for audio, image, embedding, and responses processing
...
- Added new handlers: AudioHelper, ImageHelper, EmbeddingHelper, and ResponsesHelper to manage respective requests.
- Updated ModelMappedHelper to accept request parameters for better model mapping.
- Enhanced error handling and validation across new handlers to ensure robust request processing.
- Introduced support for new relay formats in relay_info and updated relevant functions accordingly.
2025-06-20 16:02:23 +08:00
CaIon
da067b7f90
refactor: update error handling in ClaudeHelper and GeminiHelper
2025-06-20 14:53:27 +08:00
CaIon
2b2e0a4777
feat: enhance error handling in GeminiHelper and streamline response processing
...
- Added status code mapping handling in GeminiHelper to reset status codes based on response.
- Removed redundant candidate check in GeminiTextGenerationHandler to simplify response processing.
2025-06-20 01:42:19 +08:00
CaIon
2aae048295
Merge remote-tracking branch 'origin/alpha' into alpha
2025-06-20 01:07:52 +08:00
CaIon
f9a72212e6
Merge branch 'main' into alpha
2025-06-20 01:07:44 +08:00
CaIon
94a1aeb5c7
feat: add data presence check before batch update in utils
2025-06-19 19:34:57 +08:00
CaIon
2cd9fd4c45
refactor: streamline JSON response structure in channel API endpoints
2025-06-19 19:03:35 +08:00
CaIon
05aaf63337
Merge branch 'alpha'
2025-06-19 16:17:56 +08:00
CaIon
e685279207
fix: ratio render
2025-06-19 15:36:06 +08:00
CaIon
fd943659c0
Merge remote-tracking branch 'origin/alpha' into alpha
2025-06-19 14:36:55 +08:00
CaIon
bf30adcde0
Merge branch 'main' into alpha
2025-06-19 14:36:17 +08:00
CaIon
8d05e44f61
Merge remote-tracking branch 'origin/alpha' into alpha
2025-06-18 20:51:06 +08:00
CaIon
17f3832487
feat(relay): add debug logging for Gemini request body and introduce flexible speech configuration
2025-06-18 20:50:13 +08:00
CaIon
36a0d4d7ae
fix(relay): ensure consistent setting of web search context size in TextHelper function
2025-06-18 00:37:22 +08:00
CaIon
d4e20df7a6
fix(relay): refine error message for unsupported MIME types and enhance error handling in OpenAI wrapper
2025-06-17 22:44:57 +08:00
CaIon
8d0b54bf6e
fix(relay): improve error handling for unsupported MIME types by sanitizing URLs
2025-06-17 22:40:41 +08:00
CaIon
5506e4feed
feat(file_decoder): expand MIME type detection to include additional file extensions
2025-06-17 22:20:19 +08:00
CaIon
16bffe05d4
feat(file_decoder): add debug logging for MIME type detection when handling application/octet-stream
2025-06-17 22:18:51 +08:00
CaIon
680ff8e8eb
feat(file_decoder): enhance MIME type detection based on URL and Content-Disposition header
2025-06-17 21:49:13 +08:00
CaIon
4ec7012974
✨ feat: enhance group ratio handling in pricing calculations
2025-06-17 21:05:35 +08:00
CaIon
26c6087d80
✨ feat(GroupRatioSettings): enhance JSON validation for group ratios
2025-06-17 21:05:24 +08:00
CaIon
4238068c65
feat(channel): enhance Claude response handling with new Done flag and improved usage tracking
2025-06-17 20:08:25 +08:00
CaIon
822ed681de
feat(channel): add handling for pre_consume_token_quota_failed error type
2025-06-17 16:46:52 +08:00
CaIon
2a1ed60738
Merge branch 'alpha'
2025-06-17 14:49:13 +08:00
CaIon
28a0eb2a6d
Merge remote-tracking branch 'origin/alpha' into alpha
2025-06-17 00:09:38 +08:00
CaIon
af103dcc7f
🧹 chore(relay): remove unused import in relay-palm.go
2025-06-17 00:09:26 +08:00
CaIon
288f279379
🔧 refactor(relay): replace UUID generation with helper function for response IDs
2025-06-16 21:02:27 +08:00
CaIon
c4e652461e
🔧 refactor(dto): update BudgetTokens handling in Thinking struct
2025-06-16 18:29:49 +08:00
CaIon
c6226f3678
✨ feat(database): implement database migration logic for PostgreSQL and add fast migration fallback
2025-06-14 19:47:44 +08:00
CaIon
49cb5f3fa3
🐛 fix(log): optimize channel ID collection by using a map to prevent duplicates
2025-06-14 18:23:25 +08:00
CaIon
a9ec62eea8
🐛 fix(ability, channel): standardize boolean value handling across database queries
2025-06-14 18:15:45 +08:00
CaIon
4371717c78
fix: Resolving conflicts caused by mixing multiple databases
2025-06-14 17:51:05 +08:00
CaIon
d26ae9aa77
✨ feat(dto): add VlHighResolutionImages parameter to GeneralOpenAIRequest
2025-06-13 17:29:26 +08:00
CaIon
0e97441843
🔧 refactor(LogsTable, render): remove undefined parameters for improved clarity and consistency in function signatures
2025-06-13 01:25:26 +08:00
CaIon
1358a36028
✨ feat(render): introduce getEffectiveRatio helper for improved group ratio handling
2025-06-13 01:16:16 +08:00
CaIon
fa7d18ab7f
🔒 feat(setting): add mutex for GroupGroupRatio to ensure thread safety
2025-06-13 01:08:38 +08:00
CaIon
d62769376b
Merge remote-tracking branch 'origin/alpha' into alpha
2025-06-11 00:18:26 +08:00
CaIon
5511ba3670
🔧 fix(stream_scanner): improve resource management and error handling in StreamScannerHandler
2025-06-11 00:18:16 +08:00
CaIon
ad4d3efd2e
✨ feat(middleware): add HTTP statistics middleware
2025-06-10 19:29:32 +08:00
CaIon
7dc7805c6a
🔧 fix(token_counter): enhance token encoder caching and concurrency handling
2025-06-10 18:55:21 +08:00
CaIon
1abd77c17c
🔧 fix(token_counter): refactor token encoder initialization and retrieval logic
2025-06-10 18:51:26 +08:00
CaIon
88a801af2d
🔧 fix(token_counter): update token encoder implementation and dependencies
2025-06-10 18:04:49 +08:00
CaIon
b23416bbb4
🔧 fix(channel-test): ensure proper state reset to prevent deadlocks
2025-06-10 03:54:18 +08:00
CaIon
92de4d0d04
🔧 fix(api_request): enhance ping keep-alive mechanism with error handling and timeout controls
2025-06-10 03:42:23 +08:00
CaIon
b21e378fee
✨ feat(ChannelsTable): add renderQuotaWithAmount function and clean up imports
2025-06-09 20:50:37 +08:00
CaIon
78b0a82cb8
Merge remote-tracking branch 'origin/alpha' into alpha
2025-06-09 19:24:45 +08:00
CaIon
158c18fe22
✨ feat: add dark mode detection and styling enhancements to PersonalSetting and TopUp components
2025-06-09 19:24:21 +08:00
CaIon
a5baba6b9f
💄 style(LogsTable): remove prefix icons from tags for cleaner UI
2025-06-09 19:00:28 +08:00
CaIon
1de4af1c74
fix(main.go): correct comment formatting for embed directives
2025-06-08 20:26:14 +08:00
CaIon
2fb222b9a4
refactor(dto): change function and encoding fields to use json.RawMessage for improved flexibility
2025-06-08 16:28:47 +08:00
CaIon
2b3e64e8b6
fix(relay-channel): correct condition for mediaMessages initialization in requestOpenAI2Mistral function
2025-06-08 16:25:00 +08:00
CaIon
fcb9647aeb
fix(relay-gemini): remove outdated unsupported models from CovertGemini2OpenAI function
2025-06-08 16:22:39 +08:00
CaIon
7469446a20
fix(relay-gemini): add unsupported models to CovertGemini2OpenAI function
2025-06-08 16:04:31 +08:00
CaIon
e1039c67f7
chore: update CI workflows
2025-06-08 03:37:17 +08:00
CaIon
594636bace
fix: update import statement for vite-plugin-semi to use default import
2025-06-08 03:35:04 +08:00
CaIon
e647163969
chore: update CI workflow to use latest Bun version and adjust build environment variables
2025-06-08 03:28:36 +08:00
CaIon
c3a205e792
chore: update Bun version in CI workflow to 1.2.8
2025-06-08 02:57:44 +08:00
CaIon
e7289297e2
chore: update package.json to replace sse dependency and add trustedDependencies
2025-06-08 02:56:09 +08:00
CaIon
2e04d28483
chore: update CI workflows to use Bun for package management across all platforms
2025-06-08 02:45:18 +08:00
CaIon
4069b3f789
chore: update CI workflows to support manual triggers and rename Docker image workflow
2025-06-08 02:42:27 +08:00
CaIon
2cb067f485
chore: remove deprecated Docker image workflow for amd64
2025-06-08 02:39:53 +08:00
CaIon
550c068994
Merge branch 'alpha'
2025-06-08 02:38:49 +08:00
CaIon
8b55c9b917
Merge remote-tracking branch 'origin/alpha' into alpha
2025-06-08 02:34:22 +08:00
CaIon
e09931558e
chore: update CI workflows to use Bun for package management and build process
2025-06-08 02:34:06 +08:00
CaIon
28a2387dff
Merge remote-tracking branch 'origin/alpha' into alpha
2025-06-08 00:11:28 +08:00