Spaces:
Runtime error
Runtime error
from flask import Flask, request | |
from inference import predict, predict_general | |
app = Flask(__name__) | |
def index(): | |
return {"output": "Hello, world!"} | |
def predict_sentiment(text): | |
return predict(text)[0] | |
def predict_sentiment_general(text): | |
return predict_general(text)[0] | |
if __name__ == "__main__": | |
app.run(host="0.0.0.0", port=7860) | |