Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pad tiktoken vocab so that additional_special_tokens works #695

Merged
merged 4 commits into from
Oct 26, 2023

Conversation

dakinggg
Copy link
Collaborator

No description provided.

@dakinggg dakinggg marked this pull request as ready for review October 26, 2023 02:23
@samhavens
Copy link
Contributor

This is in lieu of #689, which was a work around for this specific issue

Copy link
Contributor

@samhavens samhavens left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I lean on the side of wanting to add a warning to get_vocab just in case, but I also think it's a very unlikely edge case

llmfoundry/tokenizers/tiktoken.py Show resolved Hide resolved
llmfoundry/tokenizers/tiktoken.py Show resolved Hide resolved
Copy link
Contributor

@samhavens samhavens left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As the person who will probably forget about this and be saved by the warning: thank you. LGTM

@dakinggg dakinggg merged commit 6f59738 into mosaicml:main Oct 26, 2023
12 checks passed
@dakinggg dakinggg deleted the tiktoken-special branch December 11, 2023 23:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants