Spaces:
Runtime error
Runtime error
Greg Thompson
commited on
Commit
•
b50e39f
1
Parent(s):
74e75c0
Remove sentiment endpoint
Browse files
app.py
CHANGED
@@ -11,7 +11,7 @@ from fastapi import FastAPI, Request
|
|
11 |
from fastapi.responses import JSONResponse
|
12 |
from fastapi.staticfiles import StaticFiles
|
13 |
from fastapi.templating import Jinja2Templates
|
14 |
-
from mathtext.sentiment import sentiment
|
15 |
from mathtext.text2int import text2int
|
16 |
from pydantic import BaseModel
|
17 |
|
@@ -62,11 +62,11 @@ def hello(content: Text = None):
|
|
62 |
return JSONResponse(content=content)
|
63 |
|
64 |
|
65 |
-
@app.post("/sentiment-analysis")
|
66 |
-
def sentiment_analysis_ep(content: Text = None):
|
67 |
-
|
68 |
-
|
69 |
-
|
70 |
|
71 |
|
72 |
@app.post("/text2int")
|
|
|
11 |
from fastapi.responses import JSONResponse
|
12 |
from fastapi.staticfiles import StaticFiles
|
13 |
from fastapi.templating import Jinja2Templates
|
14 |
+
# from mathtext.sentiment import sentiment
|
15 |
from mathtext.text2int import text2int
|
16 |
from pydantic import BaseModel
|
17 |
|
|
|
62 |
return JSONResponse(content=content)
|
63 |
|
64 |
|
65 |
+
# @app.post("/sentiment-analysis")
|
66 |
+
# def sentiment_analysis_ep(content: Text = None):
|
67 |
+
# ml_response = sentiment(content.content)
|
68 |
+
# content = {"message": ml_response}
|
69 |
+
# return JSONResponse(content=content)
|
70 |
|
71 |
|
72 |
@app.post("/text2int")
|