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

Issue with handling numbers, decimals, percentges in text #53

Open
p4u1d34n opened this issue Jan 30, 2019 · 1 comment
Open

Issue with handling numbers, decimals, percentges in text #53

p4u1d34n opened this issue Jan 30, 2019 · 1 comment

Comments

@p4u1d34n
Copy link

see image

https://imgur.com/jamohRG

when using the tool to segment content which contains decimal numbers, the number is split at the decimal, also, if a percentage is used, the symbol is stripped out. Is there a way to preserve these items?

@p4u1d34n
Copy link
Author

i managed to work round this by adapting the cut method in Posseg.php

$re_punctuation_pattern = '([\x{ff5e}\x{ff01}\x{ff08}\x{ff09}\x{300e}'.
'\x{300c}\x{300d}\x{300f}\x{3001}\x{ff1a}\x{ff1b}'.
'\x{ff0c}\x{ff1f}\x{3002}\x{0025}\x{002E}]+)';

https://imgur.com/a/dLuNNHm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants