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

How to customize the tokenizer default behavior? #1

Open
sincebyte opened this issue Jun 7, 2024 · 1 comment
Open

How to customize the tokenizer default behavior? #1

sincebyte opened this issue Jun 7, 2024 · 1 comment

Comments

@sincebyte
Copy link

Excellent work!
It seems that NLTokenizer split text but ignored the sign char .
example:emt-lib-path,the out put is emt, -lib ,-path
but expect is emt ,-,lib,-,path
Did there have any method to change the default behavior?

@roife
Copy link
Owner

roife commented Jun 7, 2024

It seems that NLTokenizer does not provide the related functionality (See https://developer.apple.com/documentation/naturallanguage/nltokenizer), so we need to handle it manually.

Actually, for English characters (or more precisely, ASCII characters), emt will call Emacs' own forward-word/backward-word.

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

No branches or pull requests

2 participants