|
Download README.md from Recallic/recallic-reader: direct link, hf CLI and curl.
- Browser
- Download file 2.6 kB
-
https://huggingface.co/Recallic/recallic-reader/resolve/main/README.md
- Command line
-
hf download hf://Recallic/recallic-reader/README.md
-
curl -L -o README.md https://huggingface.co/Recallic/recallic-reader/resolve/main/README.md
2.6 kB
| license: cc-by-4.0 | |
| language: | |
| - en | |
| base_model: deepset/roberta-base-squad2 | |
| datasets: | |
| - rajpurkar/squad_v2 | |
| pipeline_tag: question-answering | |
| tags: | |
| - extractive-qa | |
| - squad2 | |
| - memory | |
| - recallic | |
| # Recallic reader (case-augmented roberta-base-squad2) | |
| The extractive question-answering model that [Recallic](https://github.com/Recallic/Recallic) uses to read recalled | |
| memories, find the answer span, and decline when no memory answers the question. | |
| It is [deepset/roberta-base-squad2](https://huggingface.co/deepset/roberta-base-squad2) trained for one more pass | |
| on SQuAD 2.0 data shaped like chat messages: | |
| * 40,000 SQuAD 2.0 training examples and 39,975 lowercased copies; | |
| * 30,001 sentence-level examples: the single sentence that holds the answer (answerable), and another sentence of | |
| the same paragraph that does not (unanswerable, same topic), plus 29,995 lowercased copies. | |
| People text an assistant in short, often lowercase messages; the base model was trained on edited Wikipedia | |
| paragraphs. One epoch, learning rate 1e-5, batch 16, on a Kaggle T4 (42 minutes). Training script: | |
| [training/reader/train_case_aug.py](https://github.com/Recallic/Recallic/tree/main/training/reader). | |
| ## Results (Recallic end to end, decline threshold -2.721 on the null-answer margin) | |
| Against the base model in the same system and threshold: | |
| | | base model | this model | | |
| |---|---|---| | |
| | LoCoMo test, trick questions declined | 66 / 209 | **121 / 209** | | |
| | LoCoMo test, real questions declined | 70 / 778 | 114 / 778 | | |
| | LoCoMo test, answer token F1 | 0.3449 | **0.3567** | | |
| | Fact-update scenarios (120, texting style), correct / wrong | 76 / 8 | **92** / 9 | | |
| It answers fewer trick questions and gives better answers, at the cost of declining more real questions. All | |
| figures and how they were produced: `eval/results/reader_case_aug_v2/` in the Recallic repository. | |
| ## Use | |
| ```python | |
| from transformers import pipeline | |
| qa = pipeline("question-answering", model="Recallic/recallic-reader") | |
| qa(question="where do i work now?", context="moved to infosys last month, left tcs finally", | |
| handle_impossible_answer=True) | |
| ``` | |
| ## Limitations | |
| Trained on English Wikipedia question answering only. Within Recallic it can still pick a value about someone else | |
| when the message says whose it is only implicitly (an extra wrong answer of this kind appeared on the fact-update | |
| scenarios). Thresholds should be checked on the deployment's own data. | |
| ## Licence and attribution | |
| CC BY 4.0, as the base model. Base model by deepset (CC BY 4.0); training data from SQuAD 2.0 by Rajpurkar et al. | |
| (CC BY-SA 4.0). | |