Downloads · 30 days
4
4% of all-time downloads
sravan1817/indicbertv2-ner-te-kn
indicbertv2-ner-te-kn is a machine learning model from sravan1817. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
This model is fine-tuned with limited data(1000 samples from both telugu and kannada combinely) for Named Entity Recognition:
Downloads · 30 days
4
4% of all-time downloads
All-time downloads
96
Public
Parameters
277M
8.9 GB on disk
Likes
1
Public
Click a slice to open those files.
.pt4.4 GB · 50%
From the Hugging Face model README
This model is fine-tuned with limited data(1000 samples from both telugu and kannada combinely) for Named Entity Recognition:
from transformers import AutoTokenizer, AutoModelForTokenClassification, pipeline
# Load model
model_name = "sravan1817/indicbertv2-ner-te-kn"
tokenizer = AutoTokenizer.from_pretrained(model_name)
model = AutoModelForTokenClassification.from_pretrained(model_name)
# Build NER pipeline
ner = pipeline(
"ner",
model=model,
tokenizer=tokenizer,
aggregation_strategy="average" # groups subwords into full words
)
# Example Telugu text
text_te = "విరాట్ కోహ్లీ భారత క్రికెట్ జట్టు మాజీ కెప్టెన్."
# Example Kannada text
text_kn = "ಬೆಂಗಳೂರು ಕರ್ನಾಟಕದ ರಾಜಧಾನಿ ನಗರ."
# Run predictions
print("Telugu Prediction:")
print(ner(text_te))
print("\nKannada Prediction:")
print(ner(text_kn))