Multiple text classification using hugging face with gradio app
Hi, I want to classify multi class text classification. But I’m confuse, how to classify them with 5 different categories like we classify image.def text(txt):
    x = pipeline (txt)
    return xtext("the macdonald food is not good")gr.Interface(fn=predict,inputs="text",outputs=gr.Label.output(5)).launch()
2022-09-14T22:54:41Z
Hi@Imran1, what format isxhere? If it is a dictionary of labels and probabilities, then the following code should work:gr.Interface(fn=predict,inputs="text",outputs="label").launch()