Downloads · 30 days
0
HURIDOCS/spanish-truecasing
spanish-truecasing is a machine learning model from HURIDOCS. Use it for the machine learning task on the model card, and read the license before you ship it in a product. The card lists the license as mit.
Downloads · 30 days
0
Access
Public
Updated Nov 15, 2022
Repo size
273 MB
Likes
0
Public
Click a slice to open those files.
.dist273 MB · 100%
From the Hugging Face model README
.
This is a Spanish truecasing-model that works with the <b>Dalton Fury</b> Python project:
https://github.com/daltonfury42/truecase
You can install it here:
https://pypi.org/project/truecase/
To use the Spanish model use the TrueCase.py file uploaded to this repository
https://huggingface.co/HURIDOCS/spanish_truecasing/blob/main/TrueCaser.py
Install the requirements:
pip install nltk
And ready to work:
from TrueCaser import TrueCaser
model_path = "spanish.dist"
spanish_truecasing = TrueCaser(model_path)
text = 'informe no.78/08. petición 785-05 admisibilidad. vicente arturo villanueva ortega y otros.'
print(spanish_truecasing.get_true_case(text))
The model was trained with the Europarl dataset that contains transcriptions of the European Parliament discusions:
https://www.statmt.org/europarl/ Europarl: A Parallel Corpus for Statistical Machine Translation, Philipp Koehn, MT Summit 2005
Using huggingface load_dataset:
europarl = load_dataset('large_spanish_corpus', name='Europarl')