Spaces:
Running
Running
test
Browse files
main.py
CHANGED
|
@@ -13,12 +13,10 @@ app = FastAPI()
|
|
| 13 |
def root():
|
| 14 |
return {"API": "Sum of 2 Squares"}
|
| 15 |
|
| 16 |
-
@app.
|
| 17 |
-
async def
|
| 18 |
-
|
| 19 |
-
prediction = number_1**2 + number_2**2
|
| 20 |
|
| 21 |
-
|
| 22 |
-
|
| 23 |
|
| 24 |
|
|
|
|
| 13 |
def root():
|
| 14 |
return {"API": "Sum of 2 Squares"}
|
| 15 |
|
| 16 |
+
@app.post('/predict')
|
| 17 |
+
async def predict_with_prompt(prompt: str):
|
|
|
|
|
|
|
| 18 |
|
| 19 |
+
|
| 20 |
+
return "你好"+prompt
|
| 21 |
|
| 22 |
|