Skip to content
/ MLMAN Public

ACL 2019 paper:Multi-Level Matching and Aggregation Network for Few-Shot Relation Classification

Notifications You must be signed in to change notification settings

ZhixiuYe/MLMAN

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

Multi-Level Matching and Aggregation Network

Dependencies

The code is written in Python 3.6 and pytorch 1.0.0.

Evaluation Results

Model 5 Way 1 Shot 5 Way 5 Shot 10 Way 1 Shot 10 Way 5 Shot
MLMAN 82.98 ± 0.20 92.66 ± 0.09 75.59 ± 0.27 87.29 ± 0.15

Usage

  1. download train.json and val.json from here

  2. download glove.6B.50d.json from here

  3. make data folder in the following structure

MLMAN
|-- data
    |-- glove.6B.50d.json
    |-- train.json
    |-- val.json
|-- models
    |-- data_loader.py
    |-- embedding.py
    |-- framework.py
    |-- MLMAN.py
    |-- utils.py
|-- README.md
|-- train_demo.py
  1. train model
CUDA_VISIBLE_DEVICES=0 python train_demo.py --N_for_train 20 --N_for_test 5 --K 1 --Q 5 --batch 1

Cite

If you use the code, please cite the following paper: "Multi-Level Matching and Aggregation Network for Few-Shot Relation Classification" Zhi-Xiu Ye, Zhen-Hua Ling. ACL (2019)

@inproceedings{ye-ling-2019-multi,
    title = "Multi-Level Matching and Aggregation Network for Few-Shot Relation Classification",
    author = "Ye, Zhi-Xiu  and
      Ling, Zhen-Hua",
    booktitle = "Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics",
    month = jul,
    year = "2019",
    address = "Florence, Italy",
    publisher = "Association for Computational Linguistics",
    url = "https://www.aclweb.org/anthology/P19-1277",
    pages = "2872--2881",
}

About

ACL 2019 paper:Multi-Level Matching and Aggregation Network for Few-Shot Relation Classification

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages