Instructions to use Den4ikAI/ruBert-tiny-replicas-classifier with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Den4ikAI/ruBert-tiny-replicas-classifier with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="Den4ikAI/ruBert-tiny-replicas-classifier")# Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("Den4ikAI/ruBert-tiny-replicas-classifier") model = AutoModelForSequenceClassification.from_pretrained("Den4ikAI/ruBert-tiny-replicas-classifier") - Notebooks
- Google Colab
- Kaggle
Update README.md
Browse files
README.md
CHANGED
|
@@ -41,7 +41,7 @@ model = AutoModelForSequenceClassification.from_pretrained('Den4ikAI/ruBert-tiny
|
|
| 41 |
model.to(device)
|
| 42 |
model.eval()
|
| 43 |
|
| 44 |
-
classes = ['
|
| 45 |
|
| 46 |
|
| 47 |
def get_sentence_type(text):
|
|
@@ -54,4 +54,5 @@ def get_sentence_type(text):
|
|
| 54 |
|
| 55 |
while 1:
|
| 56 |
print(get_sentence_type(input(":> ")))
|
|
|
|
| 57 |
```
|
|
|
|
| 41 |
model.to(device)
|
| 42 |
model.eval()
|
| 43 |
|
| 44 |
+
classes = ['instruct', 'question', 'dialogue', 'problem', 'about_system', 'about_user']
|
| 45 |
|
| 46 |
|
| 47 |
def get_sentence_type(text):
|
|
|
|
| 54 |
|
| 55 |
while 1:
|
| 56 |
print(get_sentence_type(input(":> ")))
|
| 57 |
+
|
| 58 |
```
|