mirror of
https://github.com/ChatGPTNextWeb/ChatGPT-Next-Web.git
synced 2025-10-02 16:16:39 +08:00
hotfix: bytedance custom models
This commit is contained in:
parent
7102bed959
commit
065f91d8dd
@ -72,10 +72,14 @@ export function collectModelTable(
|
||||
}
|
||||
// 2. if model not exists, create new model with available value
|
||||
if (count === 0) {
|
||||
const [customModelName, customProviderName] = name.split("@");
|
||||
let [customModelName, customProviderName] = name.split("@");
|
||||
const provider = customProvider(
|
||||
customProviderName || customModelName,
|
||||
);
|
||||
// swap name and displayName for bytedance
|
||||
if (displayName && provider.providerName == "ByteDance") {
|
||||
[customModelName, displayName] = [displayName, customModelName];
|
||||
}
|
||||
modelTable[`${customModelName}@${provider?.id}`] = {
|
||||
name: customModelName,
|
||||
displayName: displayName || customModelName,
|
||||
|
Loading…
Reference in New Issue
Block a user