Update README.md
Browse files
README.md
CHANGED
@@ -8,6 +8,20 @@ datasets:
|
|
8 |
|
9 |
## Swahili News Classification with BERT
|
10 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
11 |
|
12 |
```
|
13 |
Eval metrics (10% valid set): {'accuracy': 0.9114740008594757}
|
|
|
8 |
|
9 |
## Swahili News Classification with BERT
|
10 |
|
11 |
+
This model was trained using HuggingFace's Flax framework and is part of the [JAX/Flax Community Week](https://discuss.huggingface.co/t/open-to-the-community-community-week-using-jax-flax-for-nlp-cv/7104) organized by [HuggingFace](https://huggingface.co). All training was done on a TPUv3-8 VM sponsored by the Google Cloud team.
|
12 |
+
|
13 |
+
This [model](https://huggingface.co/flax-community/bert-base-uncased-swahili) was used as the base and fine-tuned for this task.
|
14 |
+
|
15 |
+
## How to use
|
16 |
+
|
17 |
+
```python
|
18 |
+
from transformers import AutoTokenizer, AutoModelForSequenceClassification
|
19 |
+
|
20 |
+
tokenizer = AutoTokenizer.from_pretrained("flax-community/bert-swahili-news-classification")
|
21 |
+
|
22 |
+
model = AutoModelForSequenceClassification.from_pretrained("flax-community/bert-swahili-news-classification")
|
23 |
+
```
|
24 |
+
|
25 |
|
26 |
```
|
27 |
Eval metrics (10% valid set): {'accuracy': 0.9114740008594757}
|