Giter VIP home page Giter VIP logo

event_process_typing's Introduction

Semantic Typing of Event Processes

This is the repository for the resources in CoNLL 2020 Paper "What Are You Trying Todo? Semantic Typing of Event Processes". This repository contains the source code and links to some datasets used in our paper.

Abstract

This paper studies a new (cognitively motivated) semantic typing task, multi-axis event process typing, that, given an event process, attempts to infer free-form type labels describing (i) the type of action made by the process and (ii) the type of object the process seeks to affect. This task is inspired by computational and cognitive studies of event understanding, which suggest that understanding processes of events is often directed by recognizing the goals, plans or intentions of the protagonist(s). We develop a large dataset containing over 60k event processes, featuring ultra fine-grained typing on both the action and object type axes with very large (10^3โˆผ10^4) label vocabularies. We then propose a hybrid learning framework, P2GT, which addresses the challenging typing problem with indirect supervision from glosses1and a joint learning-to-rank framework. As our experiments indicate, P2GT supports identifying the intent of processes, as well as the fine semantic type of the affected object. It also demonstrates the capability of handling few-shot cases, and strong generalizability on out-of-domain processes

Fig1 in paper

Environment

python 3.6
Transformers (Huggingface) version 2.11.0 (Important)
PyTorch with CUDA support
nltk 3.4.5
AllenNLP 1.0

Dataset

./data contains the wikiHow Event Process Typing dataset contributed in this work. The same folder also contains verb and noun glosses from WordNet, and the SemCor dataset used for WSD.
The raw file of wikiHow Event Process Typing dataset is given as data_seq.tsv, where each row records the content and types labels of a process. Specifically, each tab separated row contains a sequence of subevent contents, and the last two cell are the action and object labels.
The binary file is a saved instance of the data.py object in utils, which has already read the process data and label glosses, and provided necessary indexing information to split (random state=777 should always give the same split), train and test.
./process archives several programs for dataset proprocessing.

Run the experiment

The program ./run_joint/jointSSmrl_roberta_bias.py runs the experiment for training and testing with excluded 10% test split. It should execute with the following pattern

python jointSSmrl_roberta_bias.py <skip_training> <alpha> <margin_1> <margin_2>  

For example:

CUDA_VISIBLE_DEVICES=4 python jointSSmrl_roberta_bias.py 0 1. 0.1 0.1

Console demo application

./run_joint/console_roberta_bias.py is a console application where the user can type in event processes and obtain the multi-axis type information on-the-fly. Simple run this program, wait until it loads a pre-trained model, and type in an event process where subevents are separated by '@'. For example, the following input

read papers@attend conferences@go to seminars@write a thesis

would receive type information such as

[('get', 0.6021211743354797), ('retain', 0.6217673718929291), ('absorb', 0.6397878527641296), ('pass', 0.6577234268188477), ('submit', 0.6673179864883423), ('present', 0.6688072383403778)] 
[('doctorate', 0.5141586363315582), ('psychology', 0.5413682460784912), ('genetic', 0.5501004457473755), ('science', 0.5507515966892242), ('determinism', 0.5621879994869232), ('grade', 0.5723227560520172)]

Link to the pre-trained full models for console demo: https://drive.google.com/drive/folders/1b8peVVRNANL7r_Wnyyt4pPsyNROIlOfT?usp=sharing
Users can also train the model on the full wikiHow event process dataset by running ./runjoint/train_full_roberta_bias.py

Web demo

A Web demo should be running at https://cogcomp.seas.upenn.edu/page/demo_view/STEP
Demo screenshot

Reference

Bibtex:

@inproceedings{chen-etal-2020-what,
  title = {``{W}hat {A}re {Y}ou {T}rying {T}o {D}o?'' {S}emantic {T}yping of {E}vent {P}rocesses},
  author = "Chen, Muhao and Zhang, Hongming and Wang, Haoyu and Roth, Dan",
  booktitle = "Proceedings of the 24th Conference on Computational Natural Language Learning (CoNLL)",
  year = "2020",
  publisher = "Association for Computational Linguistics"
}

event_process_typing's People

Contributors

heglertissot avatar muhaochen avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

event_process_typing's Issues

Problem in reproducing the paper results

Hello, I have read your paper and i run the command you say in the README file to train model but I don't get the same results as you. Is there anything specific I need to do to get the same results you show in the paper?
Thanks

These are the results I get when I run your command:
my_res

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.