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

Contractions don't remove dots #41

Open
sheerun opened this issue Mar 18, 2019 · 0 comments
Open

Contractions don't remove dots #41

sheerun opened this issue Mar 18, 2019 · 0 comments

Comments

@sheerun
Copy link

sheerun commented Mar 18, 2019

tokenizer =PragmaticTokenizer::Tokenizer.new({
  language: :pl,
  numbers: :all,
  downcase: false,
  contractions: { "os" => "osiedle", "os." => "osiedle" },
  expand_contractions: true
})

puts tokenizer.tokenize("Na os.Piłsudskiego")

The proper tokenization should be

  • ["Na", "osiedle", "Piłsudskiego"]
    while tokenizer returns
  • ["Na", "Osiedle", ".", "Piłsudskiego"]
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

1 participant