ivabojic commited on
Commit
200f8f5
·
verified ·
1 Parent(s): 420e3e0

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +74 -3
README.md CHANGED
@@ -1,3 +1,74 @@
1
- ---
2
- license: mit
3
- ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: mit
3
+ datasets:
4
+ - MultiSpanQA
5
+ language:
6
+ - en
7
+ metrics:
8
+ - exact_match
9
+ - f1
10
+ base_model:
11
+ - microsoft/deberta-v3-base
12
+ ---
13
+
14
+ # DeBERTa-v3-base MultiSpanQA (SpanQualifier Fine-Tuning)
15
+
16
+ ### Model Description
17
+ This repository contains **fine-tuned weights** (`pytorch_model.bin`) for `microsoft/deberta-v3-base`, optimized for **multi-span question answering** using the [SpanQualifier](https://github.com/nju-websoft/SpanQualifier) framework.
18
+ The model is trained on the **MultiSpanQA** dataset and is able to predict **multiple non-contiguous answer spans** from a single context.
19
+
20
+ > ⚠️ **Important:** Only the model weights are provided.
21
+ > To use this model, load the tokenizer and configuration from `microsoft/deberta-v3-base`.
22
+
23
+ ---
24
+
25
+ ### Intended Uses
26
+ - **Use case:** Extractive multi-span question answering (e.g., extracting multiple symptoms, medications, goals from text).
27
+ - **Not for:** Free-form text generation or reasoning beyond the given context.
28
+
29
+ ---
30
+
31
+ ### Training Setup
32
+ | Setting | Value |
33
+ |--------|------|
34
+ | Base Model | `microsoft/deberta-v3-base` |
35
+ | Framework | [SpanQualifier](https://github.com/nju-websoft/SpanQualifier) |
36
+ | Dataset | MultiSpanQA (`train.json`, `valid.json`) |
37
+ | Max Seq Length | 512 |
38
+ | Learning Rate | 3e-5 |
39
+ | Batch Size | 32 (gradient accumulation 4) |
40
+ | Epochs | 20 |
41
+ | Seed | 30 |
42
+
43
+ ---
44
+
45
+ ### Evaluation Results (MultiSpanQA)
46
+ | Metric | Precision | Recall | F1 |
47
+ |-------|-----------|--------|----|
48
+ | **Exact Match (EM)** | **76.56** | 73.31 | **74.90** |
49
+ | **Partial Match (PM)** | 88.49 | 83.37 | 85.86 |
50
+
51
+ > EM = strict span match. PM = overlap-based F1 (gives partial credit).
52
+
53
+ ---
54
+
55
+ ### Example
56
+
57
+ You can run inference with the provided `inference_spanqualifier_hf.py` script.
58
+
59
+ ```python
60
+ question = "Who sang it's my party and i'll cry if i want to in the eighties?"
61
+ context = (
62
+ "In 1981, a remake by British artists Dave Stewart and Barbara Gaskin "
63
+ "was a UK number one hit single for four weeks and was also a major hit "
64
+ "in Austria (#3), Germany (#3), the Netherlands (#20), New Zealand (#1), "
65
+ "South Africa (#3) and Switzerland (#6). The track reached #72 in the US. "
66
+ "This was the first version of the song to reach #1 in the UK. The video "
67
+ "for the Stewart/Gaskin version contained a cameo by Thomas Dolby as Johnny, "
68
+ "Judy being played by Gaskin in a blond wig."
69
+ )
70
+ ```
71
+
72
+ Expected model output:
73
+ 1. Dave Stewart
74
+ 2. Barbara Gaskin