-
Notifications
You must be signed in to change notification settings - Fork 665
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
Fix issue with setPadding and setTruncation overriding configurations… #2741
Conversation
String[] expected = { | ||
"<s>", "▁", "test", "▁sentence", "</s>", "<pad>", "<pad>", "<pad>" | ||
}; | ||
System.out.println(Arrays.toString(tokens)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Clean println in test
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good catch
… set in tokenizer.json
Codecov ReportPatch coverage:
❗ Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more. Additional details and impacted files@@ Coverage Diff @@
## master #2741 +/- ##
============================================
+ Coverage 72.08% 72.15% +0.06%
- Complexity 5126 7029 +1903
============================================
Files 473 698 +225
Lines 21970 31282 +9312
Branches 2351 3228 +877
============================================
+ Hits 15838 22570 +6732
- Misses 4925 7171 +2246
- Partials 1207 1541 +334
☔ View full report in Codecov by Sentry. |
… set in tokenizer.json
Description
This fixes an issue where our implementation of Tokenizer overwrites any padding or truncation configuration set in the
tokenizer.json
file.I have added a fake tokenizer.json here to validate with a unit test.
Fixes #2669