Skip to content

Commit

Permalink
py : suggest hint for missing vocab size
Browse files Browse the repository at this point in the history
  • Loading branch information
ggerganov committed Jan 9, 2024
1 parent 90582b7 commit 7cfcee4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion convert.py
Original file line number Diff line number Diff line change
Expand Up @@ -991,7 +991,7 @@ def check_vocab_size(params: Params, vocab: Vocab, pad_vocab: bool = False) -> N
# Handle special case where the model's vocab size is not set
if params.n_vocab == -1:
raise ValueError(
"The model's vocab size is set to -1 in params.json. Please update it manually."
f"The model's vocab size is set to -1 in params.json. Please update it manually. Maybe {vocab.vocab_size}?"
)

# Check for a vocab size mismatch
Expand Down

0 comments on commit 7cfcee4

Please sign in to comment.