Find occurrences of huge list of phrases in text

后端 未结 8 2015
傲寒
傲寒 2021-02-08 05:02

I\'m building a backend and trying to crunch the following problem.

  • The clients submit text to the backend (around 2000 characters on average)
8条回答
  •  一整个雨季
    2021-02-08 05:49

    Maybe you should try flashtext.
    According to the author, it is much more faster than Regex.

    The author even published a paper for this library.

    I've personally tried this library for one of my project, in my opinion its API is quite friendly and usable.

    Hope it helps.

提交回复
热议问题