Coder Social home page Coder Social logo

chinese_ner's Introduction

Chinese_NER

或许这是最简单的NER代码了,基于bert+bilstm+crf(Python3.6+Kashgari)

推荐Kashgari这个API,封装了很多方法,只需要一个命令即可调用机器学习方法,训练代码总共20行左右,评估和预测代码更是10行左右

环境

我用的是云服务器8核16G的云服务器,看官方教程2核心4G的服务器也能跑

python=3.6

Kashgari=1.1.5

tensorflow=1.15

数据源

从github上下载的人们日报数据

训练

需要下载Bert-Base,chinese并解压到项目根目录下

运行python train.py

评估

运行python evaluate.py

预测

运行python predict.py

参考教程

https://www.jianshu.com/p/1d6689851622

https://eliyar.biz/nlp_chinese_bert_ner/

https://github.com/BrikerMan/Kashgari/blob/v2-trunk/docs/tutorial/text-labeling.md

chinese_ner's People

Contributors

rockman1989 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.