m3hrdadfi / typo-detector-distilbert-en

huggingface.co
Total runs: 122
24-hour runs: -2
7-day runs: -8
30-day runs: 0
Model's Last Updated: June 17 2021
token-classification

Introduction of typo-detector-distilbert-en

Model Details of typo-detector-distilbert-en

Typo Detector

Dataset Information

For this specific task, I used NeuSpell corpus as my raw data.

Evaluation

The following tables summarize the scores obtained by model overall and per each class.

# precision recall f1-score support
TYPO 0.992332 0.985997 0.989154 416054.0
micro avg 0.992332 0.985997 0.989154 416054.0
macro avg 0.992332 0.985997 0.989154 416054.0
weighted avg 0.992332 0.985997 0.989154 416054.0
How to use

You use this model with Transformers pipeline for NER (token-classification).

Installing requirements
pip install transformers
Prediction using pipeline
import torch
from transformers import AutoConfig, AutoTokenizer, AutoModelForTokenClassification
from transformers import pipeline


model_name_or_path = "m3hrdadfi/typo-detector-distilbert-en"
config = AutoConfig.from_pretrained(model_name_or_path)
tokenizer = AutoTokenizer.from_pretrained(model_name_or_path)
model = AutoModelForTokenClassification.from_pretrained(model_name_or_path, config=config)
nlp = pipeline('token-classification', model=model, tokenizer=tokenizer, aggregation_strategy="average")
sentences = [
 "He had also stgruggled with addiction during his time in Congress .",
 "The review thoroughla assessed all aspects of JLENS SuR and CPG esign maturit and confidence .",
 "Letterma also apologized two his staff for the satyation .",
 "Vincent Jay had earlier won France 's first gold in gthe 10km biathlon sprint .",
 "It is left to the directors to figure out hpw to bring the stry across to tye audience .",
]

for sentence in sentences:
    typos = [sentence[r["start"]: r["end"]] for r in nlp(sentence)]

    detected = sentence
    for typo in typos:
        detected = detected.replace(typo, f'<i>{typo}</i>')

    print("   [Input]: ", sentence)
    print("[Detected]: ", detected)
    print("-" * 130)
Output: ```text [Input]: He had also stgruggled with addiction during his time in Congress . [Detected]: He had also stgruggled with addiction during his time in Congress .
[Input]: The review thoroughla assessed all aspects of JLENS SuR and CPG esign maturit and confidence . [Detected]: The review thoroughla assessed all aspects of JLENS SuR and CPG esign maturit and confidence .
[Input]: Letterma also apologized two his staff for the satyation . [Detected]: Letterma also apologized two his staff for the satyation .
[Input]: Vincent Jay had earlier won France 's first gold in gthe 10km biathlon sprint . [Detected]: Vincent Jay had earlier won France 's first gold in gthe 10km biathlon sprint .
[Input]: It is left to the directors to figure out hpw to bring the stry across to tye audience . [Detected]: It is left to the directors to figure out hpw to bring the stry across to tye audience .

## Questions?
Post a Github issue on the [TypoDetector Issues](https://github.com/m3hrdadfi/typo-detector/issues) repo.

Runs of m3hrdadfi typo-detector-distilbert-en on huggingface.co

122
Total runs
-2
24-hour runs
-7
3-day runs
-8
7-day runs
0
30-day runs

More Information About typo-detector-distilbert-en huggingface.co Model

typo-detector-distilbert-en huggingface.co

typo-detector-distilbert-en huggingface.co is an AI model on huggingface.co that provides typo-detector-distilbert-en's model effect (), which can be used instantly with this m3hrdadfi typo-detector-distilbert-en model. huggingface.co supports a free trial of the typo-detector-distilbert-en model, and also provides paid use of the typo-detector-distilbert-en. Support call typo-detector-distilbert-en model through api, including Node.js, Python, http.

typo-detector-distilbert-en huggingface.co Url

https://huggingface.co/m3hrdadfi/typo-detector-distilbert-en

m3hrdadfi typo-detector-distilbert-en online free

typo-detector-distilbert-en huggingface.co is an online trial and call api platform, which integrates typo-detector-distilbert-en's modeling effects, including api services, and provides a free online trial of typo-detector-distilbert-en, you can try typo-detector-distilbert-en online for free by clicking the link below.

m3hrdadfi typo-detector-distilbert-en online free url in huggingface.co:

https://huggingface.co/m3hrdadfi/typo-detector-distilbert-en

typo-detector-distilbert-en install

typo-detector-distilbert-en is an open source model from GitHub that offers a free installation service, and any user can find typo-detector-distilbert-en on GitHub to install. At the same time, huggingface.co provides the effect of typo-detector-distilbert-en install, users can directly use typo-detector-distilbert-en installed effect in huggingface.co for debugging and trial. It also supports api for free installation.

typo-detector-distilbert-en install url in huggingface.co:

https://huggingface.co/m3hrdadfi/typo-detector-distilbert-en

Url of typo-detector-distilbert-en

typo-detector-distilbert-en huggingface.co Url

Provider of typo-detector-distilbert-en huggingface.co

m3hrdadfi
ORGANIZATIONS

Other API from m3hrdadfi

huggingface.co

Total runs: 26
Run Growth: 17
Growth Rate: 65.38%
Updated:August 11 2021
huggingface.co

Total runs: 2
Run Growth: -8
Growth Rate: -400.00%
Updated:April 03 2024