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

Add BartTokenizer and BART Presets #685

Merged
merged 4 commits into from
Feb 2, 2023

Conversation

abheesht17
Copy link
Collaborator

No description provided.

Copy link
Member

@mattdangerw mattdangerw left a comment

Choose a reason for hiding this comment

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

Just one minor comment. LGTM!

Weights have been uploaded hopefully. Let me know if any of them aren't showing up.

Examples:

Batched inputs.
>>> vocab = {"<s>": 0, "<pad>": 1, "</s>": 2, "reful": 3, "gent": 4}
Copy link
Member

Choose a reason for hiding this comment

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

Can we shrink these vocabs down? They end up distracting from the actual tokenizer, where we want the attention to be. I was playing around with some shorter examples on #653 , e.g. https://github.com/keras-team/keras-nlp/blob/dc62952b023602fde8e5c2373894a449be15265f/keras_nlp/models/roberta/roberta_preprocessor.py#L135-L149

def presets(cls):
return copy.deepcopy(backbone_presets)

@classmethod
Copy link
Member

Choose a reason for hiding this comment

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

Also, we have no done the base class stuff for tokenizer! Though slightly different as there are many tokenizer types. #673

You can remove all this.

Copy link
Member

@mattdangerw mattdangerw left a comment

Choose a reason for hiding this comment

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

Thanks!

@mattdangerw mattdangerw merged commit 30fcbdb into keras-team:master Feb 2, 2023
@abheesht17 abheesht17 mentioned this pull request Feb 7, 2023
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.

2 participants