Text Classification
Transformers
ONNX
Safetensors
English
bert
political-discourse
media-bias
wording
contextual-review
text-embeddings-inference
Instructions to use Giuliocc/doxa-wording-encoder with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Giuliocc/doxa-wording-encoder with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="Giuliocc/doxa-wording-encoder")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("Giuliocc/doxa-wording-encoder") model = AutoModelForSequenceClassification.from_pretrained("Giuliocc/doxa-wording-encoder", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Download calibration.json from Giuliocc/doxa-wording-encoder: direct link, hf CLI and curl.
- Browser
- Download file 1.33 kB
-
https://huggingface.co/Giuliocc/doxa-wording-encoder/resolve/main/calibration.json
- Command line
-
hf download hf://Giuliocc/doxa-wording-encoder/calibration.json
-
curl -L -o calibration.json https://huggingface.co/Giuliocc/doxa-wording-encoder/resolve/main/calibration.json
1.33 kB
| { | |
| "temperature": 1.0, | |
| "threshold": 0.7, | |
| "validation": { | |
| "rows": 305, | |
| "macro_f1": 0.8229336888277285, | |
| "accuracy": 0.8229508196721311, | |
| "per_class_f1": { | |
| "no_biased_wording": 0.8211920529801324, | |
| "biased_wording": 0.8246753246753247 | |
| }, | |
| "brier": 0.13717932768405094, | |
| "negative_log_likelihood": 0.4269832933515886, | |
| "ece_10_bins": 0.07166403453858174 | |
| }, | |
| "validation_tradeoffs": [ | |
| { | |
| "threshold": 0.55, | |
| "coverage": 0.9508196721311475, | |
| "resolved_macro_f1": 0.8275862068965517 | |
| }, | |
| { | |
| "threshold": 0.6, | |
| "coverage": 0.9016393442622951, | |
| "resolved_macro_f1": 0.8290818687930601 | |
| }, | |
| { | |
| "threshold": 0.65, | |
| "coverage": 0.8590163934426229, | |
| "resolved_macro_f1": 0.8358563415167188 | |
| }, | |
| { | |
| "threshold": 0.7, | |
| "coverage": 0.7672131147540984, | |
| "resolved_macro_f1": 0.8674608539949937 | |
| }, | |
| { | |
| "threshold": 0.75, | |
| "coverage": 0.7344262295081967, | |
| "resolved_macro_f1": 0.8703263798782314 | |
| }, | |
| { | |
| "threshold": 0.8, | |
| "coverage": 0.6754098360655738, | |
| "resolved_macro_f1": 0.8879030922469066 | |
| }, | |
| { | |
| "threshold": 0.85, | |
| "coverage": 0.5901639344262295, | |
| "resolved_macro_f1": 0.9164578111946533 | |
| } | |
| ], | |
| "method": "temperature_scaled_on_validation" | |
| } | |