| import gradio as gr | |
| from transformers import pipeline | |
| # Load your model from your Hugging Face profile | |
| classifier = pipeline('text-classification', model='AmirRghp/distilbert-base-uncasedimdb-text-classification') | |
| def classify_text(text): | |
| result = classifier(text) | |
| return result | |
| gr.Interface(fn=classify_text, inputs="text", outputs="json").launch() | |