mirror of
https://github.com/PaddlePaddle/FastDeploy.git
synced 2025-10-05 16:48:03 +08:00
[Feature 2.0.2] support top_k_top_p sampling (#2789)
* support top_k_top_p sampling * fix * add api param * add api para * fix * fix * fix * fix * fix * fix * fix * fix * change func name
This commit is contained in:
@@ -1021,8 +1021,8 @@ class LLMEngine(object):
|
||||
py_script = os.path.join(current_dir_path, worker_path)
|
||||
|
||||
ori_vocab_size = (
|
||||
len(self.data_processor.tokenizer.sp_model)
|
||||
if hasattr(self.data_processor.tokenizer, 'sp_model')
|
||||
len(self.data_processor.tokenizer.sp_model)
|
||||
if hasattr(self.data_processor.tokenizer, 'sp_model')
|
||||
else len(self.data_processor.tokenizer.vocab)
|
||||
)
|
||||
|
||||
|
Reference in New Issue
Block a user