GithubHelp home page GithubHelp logo

ccks-2021-task2-baseline-1's Introduction

ccks-2021-task2-baseline 90+

provide a baseline for ccks-2021-task2(address parsing)

Simple way to run for ccks2021 task2

  1. prepare bert_pretrained model and revised '--model_name_or_path'

  2. prepare bigram and char embedding and revised pretrain_unigram_path,pretrain_bigram_path

  3. prepare dataset and revised '--data_dir'

  4. run on colab (main.ipynb). turn debug on False before run main.

  5. run on local device(main.py). turn debug on False before run main.

Stucture

The main module contains the follow files:

  • The load_data.py Text process -> read a file and convert it to a format for model (fastNLP package).

  • model.py Build Model -> char,bigram and bert embedding + Bi-LSTM + CRF model and other model can be added.

  • pipeline.py contain two classes. Trainer is for training process. Tester is for testing process which contains model predict and evaluation.

  • main.py main file to run on local device.

  • config.py

  • data folder contains files(train.conll,dev.conll,test.conll).

Other

  • 1.one can add some trick to import prediction performance. For example model average,Pseudo label,model stacking. Details can be seenBDCI top1 scheme.
  • 2.model_name_or_path contains pretrained bert model files (.bin,.json,.txt) which can be downloaded Chinese-BERT-wwm for chinese text (also support other language).
  • 3.char and bigram embedding can be downloaded from Flat
  • 4.Flat model achieves 87.93, cross validate:88.73, pseudo-labelling: 89.73
  • 5.char-bigram-bilstm 86.88
  • 6.biaffine-ner, 81.63
  • 7.our provided model(char-bigram-bert-bilstm-crf) 90+

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.