Skip to content

Commit

Permalink
legacy to init the slow tokenizer when converting from slow was wrong (
Browse files Browse the repository at this point in the history
  • Loading branch information
ArthurZucker committed May 22, 2024
1 parent 1432f64 commit 1d568df
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/transformers/models/llama/tokenization_llama_fast.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,9 +151,6 @@ def __init__(
self.legacy = legacy

if add_prefix_space is not None:
logger.warning_once(
"You set `add_prefix_space`. The tokenizer needs to be converted from the slow tokenizers"
)
kwargs["from_slow"] = True

super().__init__(
Expand All @@ -166,6 +163,7 @@ def __init__(
add_bos_token=add_bos_token,
add_eos_token=add_eos_token,
use_default_system_prompt=use_default_system_prompt,
legacy=legacy,
**kwargs,
)
self._add_bos_token = add_bos_token
Expand Down

0 comments on commit 1d568df

Please sign in to comment.