forked from XiaoMo/ChatGPT-Next-Web
fix: #528 wont send max_tokens
This commit is contained in:
parent
637cda5b4c
commit
45c8de42b9
@ -126,7 +126,7 @@ const cn = {
|
||||
Model: "模型 (model)",
|
||||
Temperature: {
|
||||
Title: "随机性 (temperature)",
|
||||
SubTitle: "值越大,回复越随机",
|
||||
SubTitle: "值越大,回复越随机,大于 1 的值可能会导致乱码",
|
||||
},
|
||||
MaxTokens: {
|
||||
Title: "单次回复限制 (max_tokens)",
|
||||
|
@ -20,7 +20,11 @@ const makeRequestParam = (
|
||||
sendMessages = sendMessages.filter((m) => m.role !== "assistant");
|
||||
}
|
||||
|
||||
const modelConfig = useChatStore.getState().config.modelConfig;
|
||||
const modelConfig = { ...useChatStore.getState().config.modelConfig };
|
||||
|
||||
// @yidadaa: wont send max_tokens, because it is nonsense for Muggles
|
||||
// @ts-expect-error
|
||||
delete modelConfig.max_tokens;
|
||||
|
||||
return {
|
||||
messages: sendMessages,
|
||||
|
Loading…
Reference in New Issue
Block a user