Unverified Commit b161f1ae authored by moniquebm's avatar moniquebm Committed by GitHub
Browse files

Update README.md (#8820)

parent 649d389d
...@@ -22,6 +22,17 @@ For more details, please see, (https://github.com/SecexSaudeTCU/noticias_ner). ...@@ -22,6 +22,17 @@ For more details, please see, (https://github.com/SecexSaudeTCU/noticias_ner).
#### How to use #### How to use
```python
from transformers import BertForTokenClassification, DistilBertTokenizerFast, pipeline
model = BertForTokenClassification.from_pretrained('monilouise/ner_pt_br')
tokenizer = DistilBertTokenizerFast.from_pretrained('neuralmind/bert-base-portuguese-cased'
, model_max_length=512
, do_lower_case=False
)
nlp = pipeline('ner', model=model, tokenizer=tokenizer, grouped_entities=True)
result = nlp("O Tribunal de Contas da União é localizado em Brasília e foi fundado por Rui Barbosa.")
```
#### Limitations and bias #### Limitations and bias
- The finetunned model was trained on a corpus with around 180 news articles crawled from Google News. The original project's purpose was to recognize named entities in news - The finetunned model was trained on a corpus with around 180 news articles crawled from Google News. The original project's purpose was to recognize named entities in news
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment