mirror of
https://github.com/HIllya51/LunaTranslator.git
synced 2024-12-29 00:24:13 +08:00
Fix max_tokens setting not working for TextGenWebui translator (#828)
* Fix max_tokens setting not working for TextGenWebui translator Added "max_tokens": self.config["max_tokens"]. * Update translatorsetting.json
This commit is contained in:
parent
cb00a8f2b0
commit
1f410e4714
@ -89,6 +89,7 @@ class TS(basetrans):
|
||||
"top_p": self.config["top_p"],
|
||||
"min_p": self.config["min_p"],
|
||||
"top_k": self.config["top_k"],
|
||||
"max_tokens": self.config["max_tokens"],
|
||||
"num_beams": self.config["num_beams"],
|
||||
"repetition_penalty": self.config["repetition_penalty"],
|
||||
"repetition_penalty_range": self.config["repetition_penalty_range"],
|
||||
@ -132,6 +133,7 @@ class TS(basetrans):
|
||||
"top_p": self.config["top_p"],
|
||||
"min_p": self.config["min_p"],
|
||||
"top_k": self.config["top_k"],
|
||||
"max_tokens": self.config["max_tokens"],
|
||||
"num_beams": self.config["num_beams"],
|
||||
"repetition_penalty": self.config["repetition_penalty"],
|
||||
"repetition_penalty_range": self.config["repetition_penalty_range"],
|
||||
|
@ -718,7 +718,7 @@
|
||||
"prompt(文本起始)": "将这段文本直接翻译成中文,不要进行任何额外的格式修改,这里是你需要翻译的文本:",
|
||||
"negative_prompt(不懂可以不写)": "",
|
||||
"stop(自定义停止符,多个用逗号隔开)": "",
|
||||
"max_tokens(单次生成上限)": 200,
|
||||
"max_tokens": 200,
|
||||
"instruction_template(需要按照模型模板选择)": "",
|
||||
"mode": "instruct",
|
||||
"temperature": 0.6,
|
||||
@ -762,7 +762,7 @@
|
||||
"max": 32,
|
||||
"step": 1
|
||||
},
|
||||
"max_tokens(单次生成上限)": {
|
||||
"max_tokens": {
|
||||
"type": "intspin",
|
||||
"min": 1,
|
||||
"max": 2048,
|
||||
@ -879,4 +879,4 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user