Rename to SIMPLE Score (simple-score)
Browse files- README.md +8 -8
- config.json +1 -1
README.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
| 2 |
license: mit
|
| 3 |
language:
|
| 4 |
- en
|
| 5 |
-
library_name: simple-
|
| 6 |
base_model: microsoft/deberta-v3-base
|
| 7 |
tags:
|
| 8 |
- text-simplification
|
|
@@ -13,7 +13,7 @@ tags:
|
|
| 13 |
|
| 14 |
# SIMPLE-base
|
| 15 |
|
| 16 |
-
**SIMPLE** (SImplicity Metric via Preference LEarning) is a reference-free learned metric
|
| 17 |
for sentence simplification. For a source sentence and a candidate simplification it returns
|
| 18 |
|
| 19 |
- a **score** `mu` in (-1, 1): +1 = highly successful simplification, 0 = verbatim copy of
|
|
@@ -27,13 +27,13 @@ This is the `base` model (microsoft/deberta-v3-base cross-encoder). Sizes: small
|
|
| 27 |
## Usage
|
| 28 |
|
| 29 |
```bash
|
| 30 |
-
pip install simple-
|
| 31 |
```
|
| 32 |
|
| 33 |
```python
|
| 34 |
-
from
|
| 35 |
|
| 36 |
-
metric = SIMPLE.from_pretrained("base") # = "mpapucci/simple-
|
| 37 |
out = metric.score(
|
| 38 |
["The feline perched upon the mat in a state of repose."],
|
| 39 |
["The cat sat on the mat."],
|
|
@@ -41,8 +41,8 @@ out = metric.score(
|
|
| 41 |
print(out.mu, out.sigma)
|
| 42 |
```
|
| 43 |
|
| 44 |
-
From the command line: `simple-
|
| 45 |
-
With Hugging Face `evaluate`: `evaluate.load("mpapucci/simple", "base")`.
|
| 46 |
|
| 47 |
## Results
|
| 48 |
|
|
@@ -84,7 +84,7 @@ A cross-encoder over `[CLS] source [SEP] candidate [SEP]` with two linear heads,
|
|
| 84 |
Hyperparameters: AdamW, learning rate 1e-5, batch 16, 5 epochs over a random half of the
|
| 85 |
pairs per epoch, linear warmup over 6% of steps, max length 512. The training code and a
|
| 86 |
recipe to rebuild the data from the original sources are in the
|
| 87 |
-
[simple-
|
| 88 |
|
| 89 |
## Limitations
|
| 90 |
|
|
|
|
| 2 |
license: mit
|
| 3 |
language:
|
| 4 |
- en
|
| 5 |
+
library_name: simple-score
|
| 6 |
base_model: microsoft/deberta-v3-base
|
| 7 |
tags:
|
| 8 |
- text-simplification
|
|
|
|
| 13 |
|
| 14 |
# SIMPLE-base
|
| 15 |
|
| 16 |
+
**SIMPLE Score** (SImplicity Metric via Preference LEarning) is a reference-free learned metric
|
| 17 |
for sentence simplification. For a source sentence and a candidate simplification it returns
|
| 18 |
|
| 19 |
- a **score** `mu` in (-1, 1): +1 = highly successful simplification, 0 = verbatim copy of
|
|
|
|
| 27 |
## Usage
|
| 28 |
|
| 29 |
```bash
|
| 30 |
+
pip install simple-score
|
| 31 |
```
|
| 32 |
|
| 33 |
```python
|
| 34 |
+
from simple_score import SIMPLE
|
| 35 |
|
| 36 |
+
metric = SIMPLE.from_pretrained("base") # = "mpapucci/simple-score-base"
|
| 37 |
out = metric.score(
|
| 38 |
["The feline perched upon the mat in a state of repose."],
|
| 39 |
["The cat sat on the mat."],
|
|
|
|
| 41 |
print(out.mu, out.sigma)
|
| 42 |
```
|
| 43 |
|
| 44 |
+
From the command line: `simple-score score --model base --sources src.txt --candidates sys.txt`.
|
| 45 |
+
With Hugging Face `evaluate`: `evaluate.load("mpapucci/simple-score", "base")`.
|
| 46 |
|
| 47 |
## Results
|
| 48 |
|
|
|
|
| 84 |
Hyperparameters: AdamW, learning rate 1e-5, batch 16, 5 epochs over a random half of the
|
| 85 |
pairs per epoch, linear warmup over 6% of steps, max length 512. The training code and a
|
| 86 |
recipe to rebuild the data from the original sources are in the
|
| 87 |
+
[simple-score repository](https://github.com/michelepapucci/simple-score).
|
| 88 |
|
| 89 |
## Limitations
|
| 90 |
|
config.json
CHANGED
|
@@ -94,5 +94,5 @@
|
|
| 94 |
"max_length": 512,
|
| 95 |
"model_type": "simple",
|
| 96 |
"sigma_floor": 0.05,
|
| 97 |
-
"
|
| 98 |
}
|
|
|
|
| 94 |
"max_length": 512,
|
| 95 |
"model_type": "simple",
|
| 96 |
"sigma_floor": 0.05,
|
| 97 |
+
"simple_score_version": "0.1.0"
|
| 98 |
}
|