Fix after QWen support (#82)
This commit is contained in:
@@ -55,7 +55,8 @@ class DetokenizerManager:
|
||||
first_token = self.tokenizer.convert_ids_to_tokens(
|
||||
int(output_tokens[i][0])
|
||||
)
|
||||
first_token = first_token.decode("utf-8")
|
||||
if not isinstance(first_token, str):
|
||||
first_token = first_token.decode("utf-8")
|
||||
if first_token.startswith("▁"):
|
||||
output_strs[i] = " " + output_strs[i]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user