Update README.md
Browse files
README.md
CHANGED
|
@@ -10,197 +10,126 @@ tags:
|
|
| 10 |
- news
|
| 11 |
---
|
| 12 |
|
| 13 |
-
#
|
| 14 |
|
| 15 |
-
|
|
|
|
| 16 |
|
|
|
|
| 17 |
|
|
|
|
| 18 |
|
| 19 |
-
|
| 20 |
-
|
| 21 |
-
|
| 22 |
-
|
| 23 |
-
|
| 24 |
-
|
| 25 |
-
|
| 26 |
-
|
| 27 |
-
- **Developed by:** [More Information Needed]
|
| 28 |
-
- **Funded by [optional]:** [More Information Needed]
|
| 29 |
-
- **Shared by [optional]:** [More Information Needed]
|
| 30 |
-
- **Model type:** [More Information Needed]
|
| 31 |
-
- **Language(s) (NLP):** ['pt']
|
| 32 |
-
- **License:** cc-by-nc-4.0
|
| 33 |
-
- **Finetuned from model [optional]:** [More Information Needed]
|
| 34 |
-
|
| 35 |
-
### Model Sources [optional]
|
| 36 |
-
|
| 37 |
-
<!-- Provide the basic links for the model. -->
|
| 38 |
-
|
| 39 |
-
- **Repository:** [More Information Needed]
|
| 40 |
-
- **Paper [optional]:** [More Information Needed]
|
| 41 |
-
- **Demo [optional]:** [More Information Needed]
|
| 42 |
-
|
| 43 |
-
## Uses
|
| 44 |
-
|
| 45 |
-
<!-- Address questions around how the model is intended to be used, including the foreseeable users of the model and those affected by the model. -->
|
| 46 |
-
|
| 47 |
-
### Direct Use
|
| 48 |
-
|
| 49 |
-
<!-- This section is for the model use without fine-tuning or plugging into a larger ecosystem/app. -->
|
| 50 |
-
|
| 51 |
-
[More Information Needed]
|
| 52 |
-
|
| 53 |
-
### Downstream Use [optional]
|
| 54 |
-
|
| 55 |
-
<!-- This section is for the model use when fine-tuned for a task, or when plugged into a larger ecosystem/app -->
|
| 56 |
-
|
| 57 |
-
[More Information Needed]
|
| 58 |
-
|
| 59 |
-
### Out-of-Scope Use
|
| 60 |
-
|
| 61 |
-
<!-- This section addresses misuse, malicious use, and uses that the model will not work well for. -->
|
| 62 |
-
|
| 63 |
-
[More Information Needed]
|
| 64 |
-
|
| 65 |
-
## Bias, Risks, and Limitations
|
| 66 |
-
|
| 67 |
-
<!-- This section is meant to convey both technical and sociotechnical limitations. -->
|
| 68 |
-
|
| 69 |
-
[More Information Needed]
|
| 70 |
-
|
| 71 |
-
### Recommendations
|
| 72 |
-
|
| 73 |
-
<!-- This section is meant to convey recommendations with respect to the bias, risk, and technical limitations. -->
|
| 74 |
-
|
| 75 |
-
Users (both direct and downstream) should be made aware of the risks, biases and limitations of the model. More information needed for further recommendations.
|
| 76 |
-
|
| 77 |
-
## How to Get Started with the Model
|
| 78 |
-
|
| 79 |
-
Use the code below to get started with the model.
|
| 80 |
-
|
| 81 |
-
[More Information Needed]
|
| 82 |
-
|
| 83 |
-
## Training Details
|
| 84 |
-
|
| 85 |
-
### Training Data
|
| 86 |
-
|
| 87 |
-
<!-- This should link to a Dataset Card, perhaps with a short stub of information on what the training data is all about as well as documentation related to data pre-processing or additional filtering. -->
|
| 88 |
-
|
| 89 |
-
[More Information Needed]
|
| 90 |
-
|
| 91 |
-
### Training Procedure
|
| 92 |
-
|
| 93 |
-
<!-- This relates heavily to the Technical Specifications. Content here should link to that section when it is relevant to the training procedure. -->
|
| 94 |
-
|
| 95 |
-
#### Preprocessing [optional]
|
| 96 |
-
|
| 97 |
-
[More Information Needed]
|
| 98 |
-
|
| 99 |
-
|
| 100 |
-
#### Training Hyperparameters
|
| 101 |
-
|
| 102 |
-
- **Training regime:** [More Information Needed] <!--fp32, fp16 mixed precision, bf16 mixed precision, bf16 non-mixed precision, fp16 non-mixed precision, fp8 mixed precision -->
|
| 103 |
-
|
| 104 |
-
#### Speeds, Sizes, Times [optional]
|
| 105 |
-
|
| 106 |
-
<!-- This section provides information about throughput, start/end time, checkpoint size if relevant, etc. -->
|
| 107 |
-
|
| 108 |
-
[More Information Needed]
|
| 109 |
-
|
| 110 |
-
## Evaluation
|
| 111 |
-
|
| 112 |
-
<!-- This section describes the evaluation protocols and provides the results. -->
|
| 113 |
-
|
| 114 |
-
### Testing Data, Factors & Metrics
|
| 115 |
-
|
| 116 |
-
#### Testing Data
|
| 117 |
-
|
| 118 |
-
<!-- This should link to a Dataset Card if possible. -->
|
| 119 |
-
|
| 120 |
-
[More Information Needed]
|
| 121 |
-
|
| 122 |
-
#### Factors
|
| 123 |
-
|
| 124 |
-
<!-- These are the things the evaluation is disaggregating by, e.g., subpopulations or domains. -->
|
| 125 |
-
|
| 126 |
-
[More Information Needed]
|
| 127 |
-
|
| 128 |
-
#### Metrics
|
| 129 |
-
|
| 130 |
-
<!-- These are the evaluation metrics being used, ideally with a description of why. -->
|
| 131 |
|
| 132 |
-
|
| 133 |
|
| 134 |
-
|
| 135 |
|
| 136 |
-
|
| 137 |
|
| 138 |
-
|
|
|
|
| 139 |
|
|
|
|
|
|
|
| 140 |
|
|
|
|
| 141 |
|
| 142 |
-
##
|
| 143 |
|
| 144 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 145 |
|
| 146 |
-
|
| 147 |
|
| 148 |
-
##
|
| 149 |
|
| 150 |
-
<!-- Total emissions (in grams of CO2eq) and additional considerations, such as electricity usage, go here. Edit the suggested text below accordingly -->
|
| 151 |
|
| 152 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 153 |
|
| 154 |
-
|
| 155 |
-
- **Hours used:** [More Information Needed]
|
| 156 |
-
- **Cloud Provider:** [More Information Needed]
|
| 157 |
-
- **Compute Region:** [More Information Needed]
|
| 158 |
-
- **Carbon Emitted:** [More Information Needed]
|
| 159 |
|
| 160 |
-
##
|
| 161 |
|
| 162 |
-
|
|
|
|
| 163 |
|
| 164 |
-
|
|
|
|
| 165 |
|
| 166 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 167 |
|
| 168 |
-
|
| 169 |
|
| 170 |
-
|
| 171 |
|
| 172 |
-
|
| 173 |
|
| 174 |
-
|
| 175 |
|
| 176 |
-
|
| 177 |
|
| 178 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 179 |
|
| 180 |
-
|
| 181 |
|
| 182 |
-
**BibTeX:**
|
| 183 |
|
| 184 |
-
|
| 185 |
|
| 186 |
-
**APA:**
|
| 187 |
|
| 188 |
-
|
| 189 |
|
| 190 |
-
|
| 191 |
|
| 192 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 193 |
|
| 194 |
-
|
| 195 |
|
| 196 |
-
##
|
| 197 |
|
| 198 |
-
[
|
| 199 |
|
| 200 |
-
|
| 201 |
|
| 202 |
-
[
|
|
|
|
|
|
|
| 203 |
|
| 204 |
-
|
| 205 |
|
| 206 |
-
|
|
|
|
|
|
| 10 |
- news
|
| 11 |
---
|
| 12 |
|
| 13 |
+
# 🇵🇹 BERTimbau fine-tuned on ClaimPT (Claim Detection)
|
| 14 |
|
| 15 |
+
This model is a fine-tuned version of **[neuralmind/bert-base-portuguese-cased](https://huggingface.co/neuralmind/bert-base-portuguese-cased)** on the **ClaimPT** dataset for **claim and non-claim detection** in Portuguese news articles.
|
| 16 |
+
It classifies each token as part of a *Claim* or *Non-Claim* span, following the guidelines described below.
|
| 17 |
|
| 18 |
+
---
|
| 19 |
|
| 20 |
+
## 🧠 Model Details
|
| 21 |
|
| 22 |
+
**Model type:** Transformer-based encoder (BERT)
|
| 23 |
+
**Base model:** [`neuralmind/bert-base-portuguese-cased`](https://huggingface.co/neuralmind/bert-base-portuguese-cased)
|
| 24 |
+
**Fine-tuning objective:** Token classification
|
| 25 |
+
**Task:** Claim Extraction
|
| 26 |
+
**Language:** Portuguese (pt)
|
| 27 |
+
**Framework:** 🤗 Transformers
|
| 28 |
+
**License:** CC BY-NC 4.0 *(non-commercial use)*
|
| 29 |
+
**Authors:** Ricardo Campos, Raquel Sequeira, Sara Nerea, Inês Cantante, Diogo Folques, Luís Filipe Cunha, João Canavilhas, António Branco, Alípio Jorge, Sérgio Nunes, Nuno Guimarães, Purificação Silvano
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 30 |
|
| 31 |
+
**Institution(s):** INESC TEC, University of Beira Interior, University of Porto, University of Lisbon
|
| 32 |
|
| 33 |
+
---
|
| 34 |
|
| 35 |
+
## 📘 Dataset
|
| 36 |
|
| 37 |
+
**Dataset:** [ClaimPT](https://rdm.inesctec.pt/dataset/cs-2025-008)
|
| 38 |
+
**Authors:** Ricardo Campos, Raquel Sequeira, Sara Nerea, Inês Cantante, Diogo Folques, Luís Filipe Cunha, João Canavilhas, António Branco, Alípio Jorge, Sérgio Nunes, Nuno Guimarães, Purificação Silvano
|
| 39 |
|
| 40 |
+
**ClaimPT**, a dataset of European Portuguese news articles annotated for **factual claims**, comprising **1,308 articles** and **6,875 individual annotations**.
|
| 41 |
+
For more information visit our [GitHub repository](https://github.com/LIAAD/ClaimPT)
|
| 42 |
|
| 43 |
+
---
|
| 44 |
|
| 45 |
+
## ⚙️ Training Details
|
| 46 |
|
| 47 |
+
- **Task formulation:** Token classification with labels
|
| 48 |
+
`{B-Claim, I-Claim, B-Non-Claim, I-Non-Claim, O}`
|
| 49 |
+
- **Loss:** Cross-entropy
|
| 50 |
+
- **Optimizer:** AdamW
|
| 51 |
+
- **Learning rate:** 2e-5
|
| 52 |
+
- **Batch size:** 16
|
| 53 |
+
- **Epochs:** 5
|
| 54 |
+
- **Max sequence length:** 512
|
| 55 |
+
- **Truncation strategy:** Sentence-level segmentation
|
| 56 |
|
| 57 |
+
---
|
| 58 |
|
| 59 |
+
## 📊 Evaluation
|
| 60 |
|
|
|
|
| 61 |
|
| 62 |
+
| **Model** | **Label** | **Precision (%)** | **Recall (%)** | **F1 (%)** |
|
| 63 |
+
|------------|------------|-------------------|----------------|-------------|
|
| 64 |
+
| **BERT-Sent (This model)** | Claim | 37.50 | 25.81 | 30.57 |
|
| 65 |
+
| | Non-Claim | 63.35 | 76.42 | 69.27 |
|
| 66 |
+
| | Micro Avg | 61.88 | 71.59 | 66.38 |
|
| 67 |
|
| 68 |
+
---
|
|
|
|
|
|
|
|
|
|
|
|
|
| 69 |
|
| 70 |
+
## 🧩 Usage
|
| 71 |
|
| 72 |
+
```python
|
| 73 |
+
from transformers import AutoTokenizer, AutoModelForTokenClassification
|
| 74 |
|
| 75 |
+
tokenizer = AutoTokenizer.from_pretrained("lfcc/bertimbau-claimpt-sent")
|
| 76 |
+
model = AutoModelForTokenClassification.from_pretrained("lfcc/bertimbau-claimpt-sent")
|
| 77 |
|
| 78 |
+
text = '"O governo vai reduzir o IVA dos alimentos", disse o ministro da economia.'
|
| 79 |
+
inputs = tokenizer(text, return_tensors="pt")
|
| 80 |
+
outputs = model(**inputs)
|
| 81 |
+
logits = outputs.logits
|
| 82 |
+
````
|
| 83 |
|
| 84 |
+
---
|
| 85 |
|
| 86 |
+
## Annotation Guidelines
|
| 87 |
|
| 88 |
+
Detailed annotation instructions, including procedures, quality-control measures, and schema definitions, are available in the document:
|
| 89 |
|
| 90 |
+
📄 [ClaimPT Annotation Manual (PDF)](https://github.com/LIAAD/ClaimPT/blob/main/ClaimPT%20Annotation%20Manual.pdf)
|
| 91 |
|
| 92 |
+
This manual describes:
|
| 93 |
|
| 94 |
+
* The annotation process and methodology
|
| 95 |
+
* The annotation scheme and entity structures
|
| 96 |
+
* The definition of a claim
|
| 97 |
+
* Metadata and label taxonomy
|
| 98 |
+
* Examples and boundary cases
|
| 99 |
|
| 100 |
+
Researchers interested in replicating the annotation or training models should refer to this guide.
|
| 101 |
|
|
|
|
| 102 |
|
| 103 |
+
---
|
| 104 |
|
|
|
|
| 105 |
|
| 106 |
+
## Citation
|
| 107 |
|
| 108 |
+
If you use this dataset, please cite:
|
| 109 |
|
| 110 |
+
```bibtex
|
| 111 |
+
@dataset{claimpt2025,
|
| 112 |
+
author = {Ricardo Campos and Raquel Sequeira and Sara Nerea and Inês Cantante and Diogo Folques and Luís Filipe Cunha and João Canavilhas and António Branco and Alípio Jorge and Sérgio Nunes and Nuno Guimarães and Purificação Silvano},
|
| 113 |
+
title = {ClaimPT: A Portuguese Dataset of Annotated Claims in News Articles},
|
| 114 |
+
year = {2025},
|
| 115 |
+
doi = {https://rdm.inesctec.pt/dataset/cs-2025-008},
|
| 116 |
+
institution = {INESC TEC}
|
| 117 |
+
}
|
| 118 |
+
```
|
| 119 |
|
| 120 |
+
---
|
| 121 |
|
| 122 |
+
## Credits and Acknowledgements
|
| 123 |
|
| 124 |
+
This dataset was developed by **[INESC TEC – Institute for Systems and Computer Engineering, Technology and Science](https://www.inesctec.pt)**, specifically by the **[NLP Group](https://nlp.inesctec.pt/)** within the **[LIAAD – Laboratory of Artificial Intelligence and Decision Support](https://www.inesctec.pt/pt/centros/LIAAD)** research center.
|
| 125 |
|
| 126 |
+
### Affiliated Institutions
|
| 127 |
|
| 128 |
+
* [University of Beira Interior](https://www.ubi.pt/en/)
|
| 129 |
+
* [University of Porto ](https://www.up.pt/portal/en/)
|
| 130 |
+
* [University of Lisbon](https://www.ulisboa.pt/en)
|
| 131 |
|
| 132 |
+
### Acknowledgements
|
| 133 |
|
| 134 |
+
This work was carried out as part of the project *Accelerat.AI* (Ref. C644865762-00000008), financed by IAPMEI and the European Union — Next Generation EU Fund, within the scope of call for proposals no. 02/C05-i01/2022 — submission of final proposals for project development under the Mobilizing Agendas for Business Innovation of the Recovery and Resilience Plan.
|
| 135 |
+
Ricardo Campos, Alípio Jorge, and Nuno Guimarães also acknowledge support from the *StorySense* project (Ref. 2022.09312.PTDC, DOI: [10.54499/2022.09312.PTDC](https://doi.org/10.54499/2022.09312.PTDC)).
|