🚀 Universal NER for Italian (Zero-Shot)
This is a universal model for Italian Named Entity Recognition (NER) using zero-shot learning, applicable across all domains.
🚀 Quick Start
It's crucial to understand that this model is universal and works across all domains. If you're aiming for an F1 score close to 90/99% for a specific domain, feel free to contact Michele Montebovi via email at montebovi.michele@gmail.com. This way, the model can be customized to better meet your Italian entity recognition needs.
You can try the model here: https://huggingface.co/spaces/DeepMount00/universal_ner_ita
✨ Features
- Universal Applicability: This model is designed to operate across all domains, providing flexibility for various entity recognition tasks in Italian.
- Zero-Shot Learning: It uses a zero-shot learning approach, which allows it to identify a wide range of entities without specific training on those entities.
📦 Installation
To use this model, you need to download the GLiNER project:
!pip install gliner
💻 Usage Examples
Basic Usage
from gliner import GLiNER
model = GLiNER.from_pretrained("DeepMount00/universal_ner_ita")
text = """
Il comune di Castelrosso, con codice fiscale 80012345678, ha approvato il finanziamento di 15.000€ destinati alla ristrutturazione del parco giochi cittadino, affidando l'incarico alla società 'Verde Vivo Società Cooperativa', con sede legale in Corso della Libertà 45, Verona, da completarsi entro il 30/09/2024.
"""
labels = ["comune", "codice fiscale", "importo", "società", "indirizzo", "data di completamento"]
entities = model.predict_entities(text, labels)
max_length = max(len(entity["text"]) for entity in entities)
for entity in entities:
padded_text = entity["text"].ljust(max_length)
print(f"{padded_text} => {entity['label']}")
📚 Documentation
Model Description
This model is intended for Named Entity Recognition (NER) tasks, specifically for the Italian language. It adopts a zero-shot learning approach, enabling it to recognize a wide variety of entities without the need for specific training on those entities. This makes it highly adaptable for various applications that require entity extraction from Italian text.
Model Performance
- Inference Time: The model runs on CPUs, and it has an inference time of 0.01 seconds on a GPU. The performance on a CPU will vary depending on the specific hardware configuration.
Try It Out
You can test the model directly in your browser through the following Hugging Face Spaces link: https://huggingface.co/spaces/DeepMount00/universal_ner_ita.
📄 License
This model is licensed under the Apache-2.0 license.
Property |
Details |
Model Type |
Named Entity Recognition (NER) |
Training Data |
DeepMount00/GLINER_ITA |
Library Name |
gliner |
License |
apache-2.0 |
Pipeline Tag |
token-classification |