| import gradio as gr | |
| from transformers import pipeline | |
| ner = pipeline( | |
| "NER-indian", | |
| model="techysanoj/fine-tuned-IndicNER", | |
| aggregation_strategy="simple" | |
| ) | |
| def predict(text): | |
| return ner(text) | |
| gr.Interface(fn=predict, inputs="text", outputs="json").launch() | |