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

如何自定义词汇? #1

Open
YahuiWong opened this issue Apr 10, 2024 · 1 comment
Open

如何自定义词汇? #1

YahuiWong opened this issue Apr 10, 2024 · 1 comment

Comments

@YahuiWong
Copy link

您好 如何自定义分词的词汇?
我试着在jieba的文件夹下定义词汇,但是没有生效,自定义分词如何使用?

@dudylan
Copy link
Owner

dudylan commented Apr 11, 2024

您好 在simple 的文档中有介绍

jieba_query() 实现jieba分词的效果,在索引不变的情况下,可以实现更精准的匹配。可以通过 -DSIMPLE_WITH_JIEBA=OFF 关掉结巴分词的功能 wangfenjin/simple#35
jieba_dict() 指定 dict 的目录,只需要调用一次,需要在调用 jieba_query() 之前指定。

这个说明 你需要用jieba_dict 指定文件 再用jieba_query 来实现自定义分词的检索

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