Git Product home page Git Product logo

andreabac3 / nlp-named-entity-recognition Goto Github PK

View Code? Open in Web Editor NEW
8.0 2.0 1.0 20.01 MB

Named Entity Recognition with 92.5% of F1-Score, developed in Pytorch using PoS embeddings, Word2Vec

Home Page: https://github.com/SapienzaNLP/nlp2020-hw1

Dockerfile 0.70% Python 96.99% Shell 2.31%
crf conditional-random-field pytorch nlp ner named-entity-recognition spacy word2vec w2v tensorflow

nlp-named-entity-recognition's Introduction

Named Entity Recognition

The experiments on NER field let me to build the following model. The model made use of two input, one the PoS embeddings (calculated starting from the SpaCy tool) and the Word embeddings (Word2Vec 300d from Google research) I also tested the model using the Conditional Random Field, as shown in the table result below, I got a more higher score without it when I started using the PoS embeddings.

ner diagram

Check the Report and the Slide Presentation for more information.

Results

Model Dev F1 (%) Test F1 (%)
Word emb (100d) + BiLSTM 78.02 78.73
Word2Vec + BiLSTM 80.25 81.04
Word2Vec + BiLSTM + CRF 88.12 89.76
Pos Emb + W2v + CRF 92.11 92.37
Pos Emb + W2v 92.20 92.66

Run

test.sh is a simple bash script. To run it:

conda create -n nlp2020-hw1 python=3.7
conda activate nlp2020-hw1
pip install -r requirements.txt
bash test.sh data/dev.tsv

Actually, you can replace data/dev.tsv to point to a different file, as far as the target file has the same format.

nlp-named-entity-recognition's People

Contributors

andreabac3 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

topliftarm

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.