Update README.md
Browse files
README.md
CHANGED
@@ -10,27 +10,51 @@ model-index:
|
|
10 |
datasets:
|
11 |
- agentlans/text-quality-v3
|
12 |
---
|
|
|
13 |
|
14 |
# deberta-v3-base-zyda-2-v2-text-quality-v3
|
15 |
|
16 |
-
|
17 |
-
It achieves the following results on the evaluation set:
|
18 |
-
- Loss: 0.1408
|
19 |
-
- Mse: 0.1408
|
20 |
-
- Combined Score: 0.1408
|
21 |
-
- Num Input Tokens Seen: 102398720
|
22 |
|
23 |
-
|
24 |
|
25 |
-
|
26 |
|
27 |
-
##
|
28 |
|
29 |
-
|
|
|
|
|
|
|
|
|
30 |
|
31 |
-
##
|
32 |
|
33 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
34 |
|
35 |
## Training procedure
|
36 |
|
|
|
10 |
datasets:
|
11 |
- agentlans/text-quality-v3
|
12 |
---
|
13 |
+
Sure! Here’s a more concise and natural revision of your model card:
|
14 |
|
15 |
# deberta-v3-base-zyda-2-v2-text-quality-v3
|
16 |
|
17 |
+
## Overview
|
|
|
|
|
|
|
|
|
|
|
18 |
|
19 |
+
This model rates the **quality of English text** for AI learning. Input a text string, and it outputs a numeric quality score reflecting overall readability, informativeness, and usefulness.
|
20 |
|
21 |
+
It’s fine-tuned from [agentlans/deberta-v3-base-zyda-2-v2](https://huggingface.co/agentlans/deberta-v3-base-zyda-2-v2) using the same dataset.
|
22 |
|
23 |
+
## Performance
|
24 |
|
25 |
+
On the evaluation set, it achieved:
|
26 |
+
- Loss: 0.1408
|
27 |
+
- MSE: 0.1408
|
28 |
+
- Combined Score: 0.1408
|
29 |
+
- Tokens processed during training: 102,398,720
|
30 |
|
31 |
+
## Usage Example
|
32 |
|
33 |
+
```python
|
34 |
+
from transformers import AutoTokenizer, AutoModelForSequenceClassification
|
35 |
+
import torch
|
36 |
+
|
37 |
+
model_name = "agentlans/deberta-v3-base-quality-v3"
|
38 |
+
tokenizer = AutoTokenizer.from_pretrained(model_name)
|
39 |
+
model = AutoModelForSequenceClassification.from_pretrained(model_name).to("cuda" if torch.cuda.is_available() else "cpu")
|
40 |
+
|
41 |
+
# Higher scores indicate higher text quality.
|
42 |
+
# The sign of the score has no particular meaning. For example, score < 0 doesn't mean that the text is low quality.
|
43 |
+
def quality(text):
|
44 |
+
inputs = tokenizer(text, return_tensors="pt", truncation=True, padding=True).to(model.device)
|
45 |
+
with torch.no_grad():
|
46 |
+
score = model(**inputs).logits.squeeze().cpu().item()
|
47 |
+
return score
|
48 |
+
|
49 |
+
print(quality("Your text here."))
|
50 |
+
```
|
51 |
+
|
52 |
+
## Limitations
|
53 |
+
|
54 |
+
- Works best on non-fiction and general-purpose texts.
|
55 |
+
- Scores give an overall quality estimate but don’t explain why.
|
56 |
+
- The model is large and slow; for faster results with similar accuracy, try `MyOtherModel`.
|
57 |
+
- Check for biases and suitability before use.
|
58 |
|
59 |
## Training procedure
|
60 |
|