Commit Graph

31 Commits

Author SHA1 Message Date
ryanhex53 b844045d23 Custom model names can include the `@` symbol by itself.
To specify the model's provider, append it after the model name using `@` as before.

This format supports cases like `google vertex ai` with a model name like `claude-3-5-sonnet@20240620`.

For instance, `claude-3-5-sonnet@20240620@vertex-ai` will be split by `split(/@(?!.*@)/)` into:

`[ 'claude-3-5-sonnet@20240620', 'vertex-ai' ]`, where the former is the model name and the latter is the custom provider.
2024-11-05 07:44:12 +00:00
frostime 150fc84b9b feat(model): 增加 sorted 字段,并使用该字段对模型列表进行排序
1. 在 Model 和 Provider 类型中增加 sorted 字段(api.ts)
2. 默认模型在初始化的时候,自动设置默认 sorted 字段,从 1000 开始自增长(constant.ts)
3. 自定义模型更新的时候,自动分配 sorted 字段(model.ts)
2024-08-05 19:43:32 +08:00
frostime b023a00445 🔨 refactor(model): 更改原先的实现方法,在 collect table 函数后面增加额外的 sort 处理 2024-08-05 16:37:22 +08:00
frostime 8a4b8a84d6 feat: 调整模型列表,将自定义模型放在前面显示 2024-08-03 17:16:05 +08:00
Mr. Z c4334d4e5f
Update model.ts 2024-07-25 20:03:54 +08:00
Mr. Z 5c04d3c5ea
Change method 2024-07-25 17:59:15 +08:00
Mr. Z aa4e855012
Compatibility changes 2024-07-22 16:41:11 +08:00
Mr. Z 2fd68bcac3
Fix defaultModel undefined error 2024-07-21 16:42:34 +08:00
lloydzhou 46d3e7884b hotfix: bytedance custom models 2024-07-12 22:53:39 +08:00
lloydzhou 9203870df5 hotfix: using custom models, create custom provider 2024-07-12 20:19:36 +08:00
lloydzhou 5e7254e8dc hotfix: doubao display name 2024-07-11 14:46:12 +08:00
lloydzhou b3023543d6 update 2024-07-09 16:55:33 +08:00
lloydzhou c229d2c3ce merge main 2024-07-09 16:53:15 +08:00
lloydzhou 71af2628eb hotfix: old AZURE_URL config error: "DeploymentNotFound". #4945 #4930 2024-07-09 00:32:18 +08:00
Dogtiti 1caa61f4c0 feat: swap name and displayName for bytedance in custom models 2024-07-06 22:59:20 +08:00
lloydzhou 31d9444264 hotfix 2024-07-04 19:38:26 +08:00
lloydzhou 97aa72ec5b hotfix ts 2024-07-04 08:36:25 +00:00
lloydzhou a68341eae6 include providerId in fullName 2024-07-04 16:11:37 +08:00
lloydzhou aa08183439 hotfix 2024-07-04 16:03:35 +08:00
lloydzhou b9ffd50992 using <modelName>@<providerName> as fullName in modelTable 2024-07-04 15:44:36 +08:00
lloydzhou e7b16bfbc0 add function to check model is available 2024-07-04 15:30:24 +08:00
butterfly b3e856df1d feat: fix 1)the property named 'role' of the first message must be 'user' 2)if default summarize model 'gpt-3.5-turbo' is blocked, use currentModel instead 3)if apiurl&apikey set by location, useCustomConfig would be opened 2024-05-06 19:26:39 +08:00
Wayland Zhan c96e4b7966 feat: Support a way to define default model by adding DEFAULT_MODEL env. 2024-04-19 06:57:15 +00:00
butterfly 79f342439a feat: Solve the problem of using openai interface protocol for user-defined claude model & add some famous webdav endpoints 2024-04-09 20:49:51 +08:00
H0llyW00dzZ e9def2cdc5
Refactor [Model] [LLM Api] Chaining Model
- [+] refactor(model.ts): change forEach loop to arrow function for readability and consistency
- [+] fix(model.ts): mark 'provider' property as optional in modelTable type
- [+] fix(model.ts): use optional chaining when assigning provider property in modelTable
2023-12-25 01:12:44 +07:00
Fred Liang 45798f993d
fix: fix type errors 2023-12-24 02:39:13 +08:00
Fred Liang 778e88cb56
chore: resolve conflict 2023-12-24 02:15:30 +08:00
Yidadaa 45b88ebb2a feat: close #3304 use `=` instead of `:` to map model name in CUSTOM_MODELS 2023-11-19 18:34:39 +08:00
Yidadaa dc7159a450 feat: close #3301 enable or diable default models with -all / +all 2023-11-19 18:32:54 +08:00
Yidadaa a5a1f2e8ad feat: CUSTOM_MODELS support mapper 2023-11-12 00:46:21 +08:00
Yidadaa d93f05f511 feat: close #3187 use CUSTOM_MODELS to control model list 2023-11-09 03:01:29 +08:00