Text Classification
Transformers
PyTorch
Safetensors
English
bert
feature-extraction
Eval Results (legacy)
text-embeddings-inference
Instructions to use shhossain/bert-tiny-book-text-classifier with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use shhossain/bert-tiny-book-text-classifier with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="shhossain/bert-tiny-book-text-classifier")# Load model directly from transformers import AutoTokenizer, AutoModel tokenizer = AutoTokenizer.from_pretrained("shhossain/bert-tiny-book-text-classifier") model = AutoModel.from_pretrained("shhossain/bert-tiny-book-text-classifier") - Notebooks
- Google Colab
- Kaggle
Update README.md
Browse files
README.md
CHANGED
|
@@ -56,9 +56,7 @@ tokenizer = AutoTokenizer.from_pretrained('prajjwal1/bert-tiny')
|
|
| 56 |
|
| 57 |
pipe = pipeline('text-classification', model='shhossain/bert-tiny-book-text-classifier')
|
| 58 |
|
| 59 |
-
book_text = """
|
| 60 |
-
|
| 61 |
-
“Where’s the truck?” she asked, raising her voice slightly so that Ultron could hear her over the wind. It was a little demeaning to be cradled in the arms of one of his units like a child but it made flying possible, and that was a lot faster than any of the other possible modes of transportation."""
|
| 62 |
|
| 63 |
pipe(book_text) # LABEL_1
|
| 64 |
>> [{'label': 'LABEL_1', 'score': 0.9998537302017212}]
|
|
|
|
| 56 |
|
| 57 |
pipe = pipeline('text-classification', model='shhossain/bert-tiny-book-text-classifier')
|
| 58 |
|
| 59 |
+
book_text = """Shen Yuanye didn’t expect to go back to Huang Ni’s matter again, this matter of being killed without finding the murderer, who else could be beside her."""
|
|
|
|
|
|
|
| 60 |
|
| 61 |
pipe(book_text) # LABEL_1
|
| 62 |
>> [{'label': 'LABEL_1', 'score': 0.9998537302017212}]
|