File size: 1,626 Bytes
85e238c
 
aae1bd0
 
 
 
 
 
 
 
85e238c
aae1bd0
7f1500c
aae1bd0
 
 
 
 
 
7f1500c
aae1bd0
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
7f1500c
aae1bd0
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
---
license: mit
datasets:
- mrqa
language:
- en
metrics:
- squad
library_name: adapter-transformers
pipeline_tag: question-answering
---

# Description
This is the MADE Adapter for the HotpotQA partition of the MRQA 2019 Shared Task dataset. The adapter was created by Friedman et al. (2021) and should be used with this encoder: https://huggingface.co/UKP-SQuARE/MADE_Encoder



The UKP-SQuARE team created this model repository to simplify the deployment of this model on the UKP-SQuARE platform. The GitHub repository of the original authors is https://github.com/princeton-nlp/MADE

# Usage
This model contains the same weights as https://huggingface.co/princeton-nlp/MADE/resolve/main/made_tuned_adapters/HotpotQA/model.pt. The only difference is that our repository follows the standard format of AdapterHub. Therefore, you could load this model as follows:

```
from transformers import RobertaForQuestionAnswering, RobertaTokenizerFast

model = RobertaForQuestionAnswering.from_pretrained("UKP-SQuARE/MADE_Encoder")
model.load_adapter("UKP-SQuARE/MADE_HotpotQA_Adapter",  source="hf")
model.set_active_adapters("HotpotQA")

tokenizer = RobertaTokenizerFast.from_pretrained('UKP-SQuARE/MADE_Encoder')

pipe = pipeline("question-answering", model=model, tokenizer=tokenizer)
pipe({"question": "What is the capital of Germany?",  "context": "The capital of Germany is Berlin."})
```

Note you need the adapter-transformers library https://adapterhub.ml


Please refer to the original publication for more information.

# Citation 
Single-dataset Experts for Multi-dataset Question Answering (Friedman et al., EMNLP 2021)