简介
Stanza is a collection of accurate and efficient tools for many human languages in one place. Starting from raw text to syntactic analysis and entity recognition, Stanza brings state-of-the-art NLP models to languages of your choosing.
重点在于使用pytorch框架构建的深度学习模型解决了本质是序列标注的一系列问题,如NER,词性标注等
2020年的Stanford团队推出的,就是做Stanford CoreNLP的那个
项目资源
Pre-trained Models
使用
pip install stanza
通过提取token,里面包含各项属性,比如实体类别
import stanza
# 使用前需要download
clinical_ner_model = stanza.Pipeline('en', package='mimic', processors={
'ner': 'i2b2'}, verbose=False)
disease_ner_model = stanza.Pipeline('en', package='mimic', processors={
'ner': 'ncbi_disease'}, verbose=False