Spaces:
Sleeping
Sleeping
test2023h5
commited on
Update main.py
Browse files
main.py
CHANGED
@@ -109,10 +109,10 @@ async def say_hello():
|
|
109 |
async def process_text(request: ProcessRequest):
|
110 |
if request.method == 0:
|
111 |
#processed_text = request.text.upper()
|
112 |
-
processed_text = predict(request.text, 0)
|
113 |
elif request.method == 1:
|
114 |
#processed_text = request.text.lower()
|
115 |
-
processed_text = predict(request.text, 1)
|
116 |
elif request.method == 2:
|
117 |
processed_text = request.text[::-1] # 反转字符串
|
118 |
else:
|
|
|
109 |
async def process_text(request: ProcessRequest):
|
110 |
if request.method == 0:
|
111 |
#processed_text = request.text.upper()
|
112 |
+
processed_text = "predict(request.text, 0)"
|
113 |
elif request.method == 1:
|
114 |
#processed_text = request.text.lower()
|
115 |
+
processed_text = "predict(request.text, 1)"
|
116 |
elif request.method == 2:
|
117 |
processed_text = request.text[::-1] # 反转字符串
|
118 |
else:
|