Laisky.Cai
2989686ace
fix: Refactor: Migrate Distributor logging to ratio metrics
...
- Log a ratio for each channel in the context
- Initialize `minimalRatio` to -1 instead of 0
2024-03-01 13:55:21 +00:00
Laisky.Cai
dbe3930a8c
fix: Switch to channel-ratio
...
- Use channel ratios instead of group ratios in all applicable places
- Start using the lowest channel ratio of the specified channel's groups
2024-03-01 13:49:23 +00:00
Laisky.Cai
a94a3f5b36
Merge remote-tracking branch 'origin/upstream/main'
2024-02-27 01:09:14 +00:00
JustSong
565ea58e68
feat: built in retry supported ( close #1036 , close #770 )
2024-02-25 19:01:49 +08:00
Laisky.Cai
29eab22762
Merge remote-tracking branch 'origin/upstream/main'
2024-02-19 07:23:30 +00:00
JustSong
de9a58ca0b
refactor: use config field to save config
2024-02-18 02:22:50 +08:00
Laisky.Cai
10cbe63c0d
Merge remote-tracking branch 'origin/upstream/main'
2024-01-28 13:44:16 +00:00
JustSong
2cd1a78203
chore: update module name
2024-01-28 19:38:58 +08:00
JustSong
2d760d4a01
refactor: refactor relay part ( #957 )
...
* refactor: refactor relay part
* refactor: refactor config part
2024-01-21 23:21:42 +08:00
Laisky.Cai
00eca28a76
Merge remote-tracking branch 'origin/upstream/main'
2023-12-27 02:14:34 +00:00
JustSong
1c8922153d
feat: support gemini-vision-pro
2023-12-24 18:54:32 +08:00
Laisky.Cai
a889d9dcc9
Merge remote-tracking branch 'origin/upstream/main'
2023-12-18 02:10:13 +00:00
David Zhuang
5cf23d8698
feat: add Google Gemini Pro support ( #826 )
...
* fest: Add Google Gemini Pro, fix #810
* fest: Add tooling to Gemini; Add OpenAI-like system prompt to Gemini
* refactor: removing unused if statement
* fest: Add dummy model message for system message in gemini model
* chore: update implementation
---------
Co-authored-by: JustSong <songquanpeng@foxmail.com>
2023-12-17 12:48:32 +08:00
Laisky.Cai
7239b3386a
Merge remote-tracking branch 'origin/upstream/main'
2023-12-12 06:00:29 +00:00
JustSong
2a70744dbf
feat: add panic recover middleware
2023-12-10 19:53:33 +08:00
JustSong
379074f7d0
feat: support plugin for ali channel ( close #797 )
2023-12-10 17:22:52 +08:00
igophper
d85e356b6e
refactor: remove consumeQuota related logic ( #738 )
...
* feat: 删除relay-text中的consumeQuota变量
该变量始终为true,可以删除
* chore: remove useless code
---------
Co-authored-by: JustSong <songquanpeng@foxmail.com>
2023-11-24 20:42:29 +08:00
ckt1031
ddcaf95f5f
feat: support tts model ( #713 )
...
* Added support for Text-to-Speech models and
endpoints
* chore: update impl
---------
Co-authored-by: JustSong <songquanpeng@foxmail.com>
2023-11-17 21:18:51 +08:00
Laisky.Cai
3ae5063626
Merge remote-tracking branch 'upstream/main'
2023-10-19 09:10:23 +00:00
Laisky.Cai
b3ebf069e2
feat: change default token prefix to laisky-
...
- Remove prefix "laisky-" from the variable "key" in [middleware/auth.go]
- Modify error message from "用户已被封禁" to "用户已被禁用" in [middleware/auth.go]
- Remove check for "consumeQuota" when request URL starts with "/v1/models" in [middleware/auth.go]
- Add ability for admin users to set "channelId" in context in [middleware/auth.go]
- Update URL and key for `ama` and `opencat` links, and key format for `url` in links in [web/src/components/TokensTable.js]
- Update URL for `nextUrl` in [web/src/components/TokensTable.js]
- Change variable names and improve search function for token names in [web/src/components/TokensTable.js]
- Add delete confirmation popup, copy and open link buttons, sorting functionality for column header, and loading state in [web/src/components/TokensTable.js]
- Update pagination to load more data in [web/src/components/TokensTable.js]
- Update rendering of token information, including quota and timestamp in [web/src/components/TokensTable.js]
2023-10-19 09:01:03 +00:00
JustSong
b4b4acc288
feat: support Tencent's model ( close #519 )
2023-10-03 14:19:03 +08:00
JustSong
f9b748c2ca
chore: add MEMORY_CACHE_ENABLED env variable
2023-09-29 11:38:27 +08:00
JustSong
159b9e3369
fix: fix unable to set zero value for base url & model mapping
2023-09-18 22:07:17 +08:00
JustSong
42451d9d02
refactor: update logging related logic
2023-09-17 15:39:46 +08:00
JustSong
621eb91b46
chore: pass through error out
2023-09-03 21:31:58 +08:00
JustSong
04acdb1ccb
feat: support aiproxy's library
2023-09-03 12:51:59 +08:00
JustSong
d09d317459
feat: supper whisper now ( close #197 )
2023-08-27 15:28:23 +08:00
滔哥
7e058bfb9b
feat: support xunfei's v2 api ( #442 , close #440 )
...
* 兼容讯飞v2接口
* Revert "兼容讯飞v2接口"
This reverts commit 21f05d1294
.
* fix: fix implementation
---------
Co-authored-by: JustSong <songquanpeng@foxmail.com>
Co-authored-by: JustSong <39998050+songquanpeng@users.noreply.github.com>
2023-08-19 17:50:34 +08:00
JustSong
c87e05bfc2
chore: add more context in error message
2023-07-23 09:49:46 +08:00
ckt
b520b54625
feat: initial support of Dall-E ( #148 , #266 )
...
* feat: initial support of Dall-E
* fix: fix N not timed
---------
Co-authored-by: JustSong <songquanpeng@foxmail.com>
Co-authored-by: JustSong <39998050+songquanpeng@users.noreply.github.com>
2023-07-15 12:30:06 +08:00
玩牛牛
81c5901123
feat: add support for /v1/engines/text-embedding-ada-002/embeddings ( #224 , close #222 )
2023-07-15 12:03:23 +08:00
JustSong
aabc546691
fix: fix the wrong message when channel is deleted
2023-06-29 11:27:34 +08:00
JustSong
0941e294bf
feat: support model remap now
2023-06-27 13:42:45 +08:00
JustSong
8a4cd403fd
fix: fix http status code ( close #193 )
2023-06-23 22:59:44 +08:00
JustSong
6d961064d2
feat: do not access database before response return ( close #158 )
2023-06-21 17:26:26 +08:00
JustSong
634099e592
fix: cors allow all headers
2023-06-20 22:04:01 +08:00
JustSong
3d76a974d1
feat: use cache to avoid database access ( #158 )
2023-06-20 19:09:49 +08:00
JustSong
6855d0dc39
chore: add x-requested-with header in CORS setting
2023-06-17 15:30:14 +08:00
Miniers
46c43396d8
feat: add token name to log ( #172 )
...
* add token name to log
* chore: update expression
---------
Co-authored-by: JustSong <songquanpeng@foxmail.com>
2023-06-17 14:56:03 +08:00
JustSong
596446dba4
feat: able to set group ratio now ( close #62 , close #142 )
2023-06-11 11:08:16 +08:00
JustSong
4339f45f74
feat: support /v1/moderations now ( close #117 )
2023-06-11 09:37:36 +08:00
JustSong
8901f03864
feat: support set proxy for channel OpenAI ( close #139 )
2023-06-09 18:30:01 +08:00
JustSong
2ad22e1425
feat: support group now ( close #17 , close #72 , close #85 , close #104 , close #136 )
...
Co-authored-by: quzard <1191890118@qq.com>
2023-06-07 23:26:00 +08:00
JustSong
8b43e0dd3f
fix: add no-cache for index.html
2023-05-22 00:54:53 +08:00
JustSong
73d5e0f283
feat: support dummy sk- prefix for token ( #82 )
2023-05-17 17:04:06 +08:00
JustSong
8afdc56b11
fix: fix quota not consuming
2023-05-16 13:29:22 +08:00
JustSong
a1f61384c5
feat: automatically disable channel when error occurred ( #59 )
2023-05-15 17:34:09 +08:00
JustSong
bffee4e91d
fix: fix /v1/models not working ( close #66 )
2023-05-15 15:33:34 +08:00
JustSong
4a0e81fe83
fix: fix quota not consumed
2023-05-14 20:36:28 +08:00
JustSong
83e86b9f8a
feat: support specific default api version now ( #57 )
2023-05-13 12:53:57 +08:00