kellywong
commited on
Commit
路
e7787d9
1
Parent(s):
be0358f
update README.md
Browse files
README.md
CHANGED
@@ -1,3 +1,132 @@
|
|
1 |
---
|
|
|
2 |
license: mit
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3 |
---
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
---
|
2 |
+
language: en
|
3 |
license: mit
|
4 |
+
datasets:
|
5 |
+
- RECCON
|
6 |
+
tags:
|
7 |
+
- conversational
|
8 |
+
inference: false
|
9 |
+
model-index:
|
10 |
+
- name: Span Extraction
|
11 |
+
results:
|
12 |
+
- task:
|
13 |
+
type: conversational
|
14 |
+
name: Span-Extraction
|
15 |
+
dataset:
|
16 |
+
name: RECCON dataset (on development set)
|
17 |
+
type: train and evaluation dataset
|
18 |
+
metrics:
|
19 |
+
- name: EMPos
|
20 |
+
type: EMPos
|
21 |
+
value: 0.3437
|
22 |
+
- task:
|
23 |
+
type: conversational
|
24 |
+
name: Span-Extraction
|
25 |
+
dataset:
|
26 |
+
name: RECCON dataset (on development set)
|
27 |
+
type: train and evaluation dataset
|
28 |
+
metrics:
|
29 |
+
- name: F1Pos
|
30 |
+
type: F1Pos
|
31 |
+
value: 0.6062
|
32 |
+
- task:
|
33 |
+
type: conversational
|
34 |
+
name: Span-Extraction
|
35 |
+
dataset:
|
36 |
+
name: RECCON dataset (on development set)
|
37 |
+
type: train and evaluation dataset
|
38 |
+
metrics:
|
39 |
+
- name: F1Neg
|
40 |
+
type: F1Neg
|
41 |
+
value: 0.8318
|
42 |
+
- task:
|
43 |
+
type: conversational
|
44 |
+
name: Span-Extraction
|
45 |
+
dataset:
|
46 |
+
name: RECCON dataset (reported by authors in paper on development set)
|
47 |
+
type: train and evaluation dataset
|
48 |
+
metrics:
|
49 |
+
- name: EMPos
|
50 |
+
type: EMPos
|
51 |
+
value: 0.3464
|
52 |
+
- task:
|
53 |
+
type: conversational
|
54 |
+
name: Span-Extraction
|
55 |
+
dataset:
|
56 |
+
name: RECCON dataset (reported by authors in paper on development set)
|
57 |
+
type: train and evaluation dataset
|
58 |
+
metrics:
|
59 |
+
- name: F1Pos
|
60 |
+
type: F1Pos
|
61 |
+
value: 0.6000
|
62 |
+
- task:
|
63 |
+
type: conversational
|
64 |
+
name: Span-Extraction
|
65 |
+
dataset:
|
66 |
+
name: RECCON dataset (reported by authors in paper on development set)
|
67 |
+
type: train and evaluation dataset
|
68 |
+
metrics:
|
69 |
+
- name: F1Neg
|
70 |
+
type: F1Neg
|
71 |
+
value: 0.8602
|
72 |
+
- task:
|
73 |
+
type: conversational
|
74 |
+
name: Span-Extraction
|
75 |
+
dataset:
|
76 |
+
name: RECCON dataset (reported by authors in paper on development set)
|
77 |
+
type: train and evaluation dataset
|
78 |
+
metrics:
|
79 |
+
- name: F1
|
80 |
+
type: F1
|
81 |
+
value: 0.7571
|
82 |
---
|
83 |
+
|
84 |
+
# Causal Span Detection
|
85 |
+
You can **test the model** at [SGNLP-Demo](https://sgnlp.aisingapore.net/span-extraction).<br />
|
86 |
+
If you want to find out more information, please contact us at [email protected].
|
87 |
+
|
88 |
+
## Table of Contents
|
89 |
+
- [Model Details](#model-details)
|
90 |
+
- [How to Get Started With the Model](#how-to-get-started-with-the-model)
|
91 |
+
- [Training](#training)
|
92 |
+
- [Model Parameters](#parameters)
|
93 |
+
- [Other Information](#other-information)
|
94 |
+
|
95 |
+
## Model Details
|
96 |
+
**Model Name:** SGNLP-Demo
|
97 |
+
- **Description:** This is a causal span extraction model based on SPANBert which recognises that causes of emotions in conversations. Given 4 sets of inputs: target utterance, target utterance's emotion, evidence utterance and conversational history, it returns arrays of start and end logits which can be postprocessed to obtain the span which caused the emotion in the target utterance.
|
98 |
+
- **Paper:** Recognizing emotion cause in conversations. arXiv preprint arXiv:2012.11820., Dec 2020.
|
99 |
+
- **Author(s):** Poria, S., Majumder, N., Hazarika, D., Ghosal, D., Bhardwaj, R., Jian, S.Y.B., Hong, P., Ghosh, R., Roy, A., Chhaya, N., Gelbukh, A. and Mihalcea, R. (2020).
|
100 |
+
- **URL:** https://arxiv.org/abs/2012.11820/
|
101 |
+
|
102 |
+
|
103 |
+
# How to Get Started With the Model
|
104 |
+
|
105 |
+
## Install Python package
|
106 |
+
SGnlp is an initiative by AI Singapore's NLP Hub. They aim to bridge the gap between research and industry, promote translational research, and encourage adoption of NLP techniques in the industry. <br><br> Various NLP models, other than aspect sentiment analysis are available in the python package. You can try them out at [SGNLP-Demo](https://sgnlp.aisingapore.net/) | [SGNLP-Github](https://github.com/aisingapore/sgnlp).
|
107 |
+
|
108 |
+
```python
|
109 |
+
pip install sgnlp
|
110 |
+
|
111 |
+
```
|
112 |
+
|
113 |
+
## Examples
|
114 |
+
For more full code (such as Causal Span Detection), please refer to this [SGNLP-Github](https://github.com/aisingapore/sgnlp). <br> Alternatively, you can also try out the [SGNLP-Demo](https://sgnlp.aisingapore.net/span-extraction) for Causal-Span-Detection.
|
115 |
+
|
116 |
+
# Training
|
117 |
+
The train and evaluation datasets were derived from the RECCON dataset. The full dataset can be downloaded from the author's [github repository](https://github.com/declare-lab/RECCON/tree/main/data).
|
118 |
+
|
119 |
+
#### Training Results
|
120 |
+
- **Training Time:** ~3 hours for 12 epochs on a single V100 GPU.
|
121 |
+
|
122 |
+
# Model Parameters
|
123 |
+
- **Model Weights:** [link](https://storage.googleapis.com/sgnlp/models/reccon_span_extraction/pytorch_model.bin)
|
124 |
+
- **Model Config:** [link](https://storage.googleapis.com/sgnlp/models/reccon_span_extraction/config.json)
|
125 |
+
- **Model Inputs:** Target utterance, emotion in target utterance, evidence utterance and conversational history.
|
126 |
+
- **Model Outputs:** Array of start logits and array of end logits. These 2 arrays can be post processed to detemine the start and end of the causal span.
|
127 |
+
- **Model Size:** ~411MB
|
128 |
+
- **Model Inference Info:** ~ 2 sec on Intel(R) Core(TM) i7-8750H CPU @ 2.20GHz.
|
129 |
+
- **Usage Scenarios:** Recognizing emotion cause for phone support satisfaction.
|
130 |
+
|
131 |
+
# Other Information
|
132 |
+
- **Original Code:** [link](https://github.com/declare-lab/RECCON)
|