Coder Social home page Coder Social logo

rivercold / lstm-er Goto Github PK

View Code? Open in Web Editor NEW

This project forked from tticoin/lstm-er

0.0 1.0 0.0 38.52 MB

Implementation of End-to-End Relation Extraction using LSTMs on Sequences and Tree Structures in ACL2016.

License: Apache License 2.0

CMake 0.56% Python 8.65% Shell 2.59% Perl 3.03% C++ 85.17%

lstm-er's Introduction

LSTM-ER

Implementation of End-to-End Relation Extraction using LSTMs on Sequences and Tree Structures.

Requirements

  • Fedora Core 22
  • clang++ 3.4
  • boost 1.57
  • yaml-cpp 0.5.1
  • ICU4C 54.1

This code may work on other linux environments, but we have not tried them. For convenience, this package includes snapshot versions of clab/cnn (https://github.com/clab/cnn) and eigen (http://eigen.tuxfamily.org/). These follow the original license.

Usage

Compilation

tar xzf cnn.tar.gz
tar xzf eigen.tar.gz
mkdir build
cd build
cmake .. -DEIGEN3_INCLUDE_DIR=eigen -DCMAKE_CXX_COMPILER=/usr/bin/clang++
make
cd ..

Creation of directories

mkdir dict models

Preparation of the pretrained embeddings

cd dict/
wget http://tti-coin.jp/data/wikipedia200.bin
cd ..

Preparation of the data sets

see data/README.md

Obtaining pretrained models

ACE 2005 (Relation extraction)

cd models/
wget http://tti-coin.jp/data/ace2005-test.txt.gz
gunzip ace2005-test.txt.gz
cd ..

SemEval 2010 Task 8 (Relation classification)

cd models/
wget http://tti-coin.jp/data/semeval-test.txt.gz
gunzip semeval-test.txt.gz
cd ..

Testing models

Prediction results will be written as *.pred.ann in the test corpus directory.

ACE 2005 (Relation extraction)

build/relation/RelationExtraction --test -y yaml/parameter-ace2005.yaml

SemEval 2010 Task 8 (Relation classification)

build/relation/RelationExtraction --test -y yaml/parameter-semeval-2010.yaml

Training models

ACE 2005 (Relation extraction)

build/relation/RelationExtraction --train -y yaml/parameter-ace2005.yaml

SemEval 2010 Task 8 (Relation classification)

build/relation/RelationExtraction --train -y yaml/parameter-semeval-2010.yaml

Notes

YAML files for ACE2004 are not included. Please modify yaml/parameter-ace2005.yaml.

Scores may not be consistent with those in our paper due to the differences in the environments.

Please cite our ACL paper when using this software.

lstm-er's People

Contributors

mmiwa avatar

Watchers

 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.