1、分词方法
- HMM
- CRF
- BERT-BiLSTM-CRF
常有分词器
中科院计算所NLPIR http://ictclas.nlpir.org/nlpir/
ansj分词器 https://github.com/NLPchina/ansj_seg
哈工大的LTP https://github.com/HIT-SCIR/ltp
清华大学THULAC https://github.com/thunlp/THULAC
斯坦福分词器 https://nlp.stanford.edu/software/segmenter.shtml
Hanlp分词器 https://github.com/hankcs/HanLP
结巴分词 https://github.com/yanyiwu/cppjieba
KCWS分词器(字嵌入+Bi-LSTM+CRF) https://github.com/koth/kcws
ZPar https://github.com/frcchang/zpar/releases
IKAnalyzer https://github.com/wks/ik-analyzer
2、文本相似度
- 编辑距离
- 两句子词向量的余弦相似性
- BLEU
- ROUGE
3、最长公共子序列LCS
动态规划:https://blog.csdn.net/hrn1216/article/details/51534607
4、有1w个敏感词,怎么过滤
前缀树:https://blog.csdn.net/weixin_39778570/article/details/81990417
5、有一个8升装满水的杯子,还有一个3升和5升的空杯子,怎么倒出一个4升水。
索引|杯子 | 8 | 5 | 3 |
---|---|---|---|
初始化 | 8 | 0 | 0 |
1 | 3 | 5 | 0 |
2 | 3 | 2 | 3 |
3 | 6 | 2 | 0 |
4 | 6 | 0 | 2 |
5 | 1 | 5 | 2 |
6 | 1 | 4 | 3 |