INK-USC / TriggerNER

TriggerNER: Learning with Entity Triggers as Explanations for Named Entity Recognition (ACL 2020)
https://arxiv.org/abs/2004.07493
173 stars 19 forks source link

if i use my own chinese corpus , how to design and create my own trigger txt? #4

Closed marcusau closed 4 years ago

marcusau commented 4 years ago

Thanks a lot.

your method is amazing.

How to design and create my own trigger txt file if i wanna use my own set of Chinese corpus?

danny911kr commented 4 years ago

Hi, Thank you for your interest.

Please refer to our dataset file. (trigger_turk.txt) and also please refer to #2 .

First, you should split the current corpus into single-entity sentences. For example,

"Paris is the president of USC" -> ['B-PER', 'O', 'O', 'O', 'O', 'O'] -> ['O', 'O', 'O', 'O', 'O', 'B-LOC']

then please annotate triggers on to it.

"Paris is the president of USC" -> ['B-PER', 'T-0', 'T-0', 'T-0', 'O', 'O'] -> ['O', 'O', 'O', 'T-0', 'T-0', 'B-LOC']