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

词性分析时调用自定义词典的方法 #85

Open
woaidianqian opened this issue Jun 13, 2021 · 1 comment
Open

词性分析时调用自定义词典的方法 #85

woaidianqian opened this issue Jun 13, 2021 · 1 comment

Comments

@woaidianqian
Copy link

woaidianqian commented Jun 13, 2021

在PosSegmenter的括号里面添加segmenter,这个不看源码应该不知道怎么用吧。。。。

using JiebaNet.Segmenter;
using JiebaNet.Segmenter.PosSeg;
var segmenter = new JiebaSegmenter();
segmenter.LoadUserDict("userdict.txt");
var posSeg = new PosSegmenter(segmenter);
@woaidianqian
Copy link
Author

此外,词库里面每行的词推荐用一个空格隔开。

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