KarimGhon commited on
Commit
c56f17c
1 Parent(s): 3c99ff4

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +29 -9
README.md CHANGED
@@ -26,6 +26,25 @@ This model is designed to:
26
 
27
  - Extract atomic claims from summaries.
28
  - Serve as a component in pipelines for factuality evaluation of summaries.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
29
 
30
  ### Training
31
  For details regarding the training process, please checkout our [paper](https://aclanthology.org/2024.findings-acl.841.pdf) (section 4.1).
@@ -41,14 +60,11 @@ For details regarding the training process, please checkout our [paper](https://
41
 
42
  Further details on the model's performance and the metrics used can be found in the [paper](https://aclanthology.org/2024.findings-acl.841.pdf) (section 4.1).
43
 
44
- ### Limitations
45
 
46
- - The model is specifically designed for extracting claims from summaries and may not perform well on other types of texts.
47
- - The model is currently available only in English and may not generalize well to other languages.
48
-
49
- ### Ethical Considerations
50
 
51
- Users should be aware that while this model extracts claims that can be evaluated for factuality, it does not determine the truthfulness of those claims. Therefore, it should be used in conjunction with other tools or human judgment when evaluating the reliability of summaries.
 
52
 
53
  ### Citation
54
 
@@ -70,11 +86,15 @@ If you use this model in your work, please cite the following paper:
70
  }
71
  ```
72
 
 
73
 
74
- ### Main Repository
 
 
 
 
 
75
 
76
- For more details about FENICE, check out the GitHub repository:
77
- [Babelscape/FENICE](https://github.com/Babelscape/FENICE)
78
 
79
  ### Acknowledgments
80
 
 
26
 
27
  - Extract atomic claims from summaries.
28
  - Serve as a component in pipelines for factuality evaluation of summaries.
29
+
30
+ ## Example Code
31
+
32
+ You can use the following code to perform operations such as getting distinct elements from a list or splitting text into sentences.
33
+
34
+ ```python
35
+ from transformers import T5ForConditionalGeneration, T5Tokenizer
36
+
37
+ tokenizer = T5Tokenizer.from_pretrained("Babelscape/t5-base-summarization-claim-extractor")
38
+ model = T5ForConditionalGeneration.from_pretrained("Babelscape/t5-base-summarization-claim-extractor").to("cuda:0")
39
+ device = "cuda:0"
40
+ summary = 'Simone Biles made a triumphant return to the Olympic stage at the Paris 2024 Games, competing in the women’s gymnastics qualifications. Overcoming a previous struggle with the “twisties” that led to her withdrawal from events at the Tokyo 2020 Olympics, Biles dazzled with strong performances on all apparatus, helping the U.S. team secure a commanding lead in the qualifications. Her routines showcased her resilience and skill, drawing enthusiastic support from a star-studded audience'
41
+
42
+ tok_input = tokenizer.batch_encode_plus([summary], return_tensors="pt", padding=True).to(device)
43
+ claims = model.generate(**tok_input)
44
+ claims = tokenizer.batch_decode(claims, skip_special_tokens=True)
45
+
46
+ ```
47
+
48
 
49
  ### Training
50
  For details regarding the training process, please checkout our [paper](https://aclanthology.org/2024.findings-acl.841.pdf) (section 4.1).
 
60
 
61
  Further details on the model's performance and the metrics used can be found in the [paper](https://aclanthology.org/2024.findings-acl.841.pdf) (section 4.1).
62
 
 
63
 
64
+ ### Main Repository
 
 
 
65
 
66
+ For more details about FENICE, check out the GitHub repository:
67
+ [Babelscape/FENICE](https://github.com/Babelscape/FENICE)
68
 
69
  ### Citation
70
 
 
86
  }
87
  ```
88
 
89
+ ### Limitations
90
 
91
+ - The model is specifically designed for extracting claims from summaries and may not perform well on other types of texts.
92
+ - The model is currently available only in English and may not generalize well to other languages.
93
+
94
+ ### Ethical Considerations
95
+
96
+ Users should be aware that while this model extracts claims that can be evaluated for factuality, it does not determine the truthfulness of those claims. Therefore, it should be used in conjunction with other tools or human judgment when evaluating the reliability of summaries.
97
 
 
 
98
 
99
  ### Acknowledgments
100