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

Fix #29 #30

Merged
merged 3 commits into from
Oct 31, 2024
Merged

Fix #29 #30

merged 3 commits into from
Oct 31, 2024

Conversation

DoodleBears
Copy link
Owner

Summary

Now, when

merge_across_punctuation = True and merge_across_digit= False

merge_across_punctuation will [A, B, C]
if A is punctuation, it connect to B
if B is punctuation, it connect to A
if C is punctuation, it connect to B

text = "(2.2)术语和定义 (2.2)Terms and Definitions"

0|digit:(2.2)
1|zh:术语和定义 (
2|digit:2.2)
3|en:Terms and Definitions

merge_across_punctuation = False and merge_across_digit= True

merge_across_digit will [A, B, C]
if one of A or B is digit, it connect together

text = "(2.2)术语和定义 (2.2)Terms and Definitions"

0|zh:(2.2)术语和定义
1|en:(2.2)Terms and Definitions

merge_across_punctuation = True and merge_across_digit= True

text = "(2.2)术语和定义 (2.2)Terms and Definitions"

0|zh:(2.2)术语和定义
1|en:(2.2)Terms and Definitions

@DoodleBears DoodleBears merged commit 7eb23ac into main Oct 31, 2024
@DoodleBears DoodleBears deleted the 29-fix/punctuation-digit-appear-together branch October 31, 2024 15:34
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.

wrong split result when punctuations and digits are near each other
1 participant