Update README.md
Browse files
README.md
CHANGED
|
@@ -6,4 +6,61 @@ base_model:
|
|
| 6 |
- lyeonii/bert-tiny
|
| 7 |
pipeline_tag: text-classification
|
| 8 |
---
|
| 9 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 6 |
- lyeonii/bert-tiny
|
| 7 |
pipeline_tag: text-classification
|
| 8 |
---
|
| 9 |
+
|
| 10 |
+
# is_pay
|
| 11 |
+
|
| 12 |
+
`is_pay` is a fine-tuned, lightweight sequence classification model used to predict whether a given text string contains wage or salary information. It was fine-tuned from `lyeonii/bert-tiny`, making it highly efficient for high-throughput filtering pipelines.
|
| 13 |
+
|
| 14 |
+
## Basic Usage
|
| 15 |
+
|
| 16 |
+
You can deploy this model using the standard Hugging Face `text-classification` pipeline.
|
| 17 |
+
|
| 18 |
+
```python
|
| 19 |
+
from transformers import pipeline, AutoModelForSequenceClassification, AutoTokenizer
|
| 20 |
+
|
| 21 |
+
model_name = "loyoladatamining/is_pay"
|
| 22 |
+
model = AutoModelForSequenceClassification.from_pretrained(model_name)
|
| 23 |
+
tokenizer = AutoTokenizer.from_pretrained(model_name, max_length=64, truncation=True)
|
| 24 |
+
|
| 25 |
+
# Create text classification pipeline
|
| 26 |
+
nlp = pipeline(
|
| 27 |
+
"text-classification",
|
| 28 |
+
model=model,
|
| 29 |
+
tokenizer=tokenizer,
|
| 30 |
+
max_length=64,
|
| 31 |
+
truncation=True
|
| 32 |
+
)
|
| 33 |
+
|
| 34 |
+
# Inference
|
| 35 |
+
text = "The starting salary for this position is $75,000 per year."
|
| 36 |
+
result = nlp(text)
|
| 37 |
+
print(result)
|
| 38 |
+
```
|
| 39 |
+
|
| 40 |
+
## Output Format
|
| 41 |
+
|
| 42 |
+
The model returns a list containing a dictionary with the predicted binary class label and its corresponding confidence score:
|
| 43 |
+
|
| 44 |
+
```json
|
| 45 |
+
[
|
| 46 |
+
{
|
| 47 |
+
"label": "LABEL_1",
|
| 48 |
+
"score": 0.9942
|
| 49 |
+
}
|
| 50 |
+
]
|
| 51 |
+
```
|
| 52 |
+
|
| 53 |
+
### Label Mapping
|
| 54 |
+
- `LABEL_0`: The text does not contain wage or salary information.
|
| 55 |
+
- `LABEL_1`: The text contains wage or salary information.
|
| 56 |
+
|
| 57 |
+
## Citation
|
| 58 |
+
If you find `is_pay` useful in your work, please consider citing:
|
| 59 |
+
|
| 60 |
+
```
|
| 61 |
+
@article{meisenbacher2025extracting,
|
| 62 |
+
title={Extracting O* NET Features from the NLx Corpus to Build Public Use Aggregate Labor Market Data},
|
| 63 |
+
author={Meisenbacher, Stephen and Nestorov, Svetlozar and Norlander, Peter},
|
| 64 |
+
year={2025}
|
| 65 |
+
}
|
| 66 |
+
```
|