Spaces:
Sleeping
Sleeping
import gradio as gr | |
from huggingface_hub import InferenceClient | |
client = InferenceClient("Intercept-Intelligence/Txt-Analyst-AI") | |
def classify(text): | |
result = client.text_classification(text) | |
return result[0]["label"] | |
demo = gr.Interface( | |
fn=classify, | |
inputs=gr.Textbox(label="Text to Analyze", placeholder="Enter text here..."), | |
outputs=gr.Textbox(label="Classification Result"), | |
title="Txt Analyst AI", | |
description="Enter any text and let Intercept's AI classify it based on its training." | |
) | |
if __name__ == "__main__": | |
demo.launch() |