sentiment-tool / app.py
Chris4K's picture
Update app.py
0065a7e verified
raw
history blame
396 Bytes
from sentiment_analysis import SentimentAnalysisTool
# Create an instance of the tool
sentiment_tool = SentimentAnalysisTool()
# Launch the Gradio interface
if __name__ == "__main__":
import gradio as gr
gr.Interface(
fn=sentiment_tool,
inputs=gr.Textbox(label="Text to analyze"),
outputs=gr.JSON(label="Sentiment Analysis Results")
).launch(share=True)