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 enable discardPunctuation in Kuromoji Java #134

Open
yanghanxy opened this issue May 20, 2021 · 0 comments
Open

How to enable discardPunctuation in Kuromoji Java #134

yanghanxy opened this issue May 20, 2021 · 0 comments

Comments

@yanghanxy
Copy link

yanghanxy commented May 20, 2021

Hi,

I can remove the punctuations in Kuromoji-ES plugin by setting "discard_punctuation": "true"

I'm wondering how can I get the same result with Kuromoji-Java?

For example, in Kuromoji-ES, 「浅草」駅 will be tokenized as

{
  "tokens" : [
    {
      "token" : "浅草",
      "start_offset" : 1,
      "end_offset" : 3,
      "type" : "word",
      "position" : 0
    },
    {
      "token" : "駅",
      "start_offset" : 4,
      "end_offset" : 5,
      "type" : "word",
      "position" : 1
    }
  ]
}

Is there a same function with Kuromoji-Java to do so?

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