Spaces:
Sleeping
Sleeping
updated app.py
Browse files
app.py
CHANGED
@@ -66,6 +66,10 @@ to create another adventure soon!
|
|
66 |
|
67 |
prompt_template = ChatPromptTemplate.from_messages([("system", system), ("human", "{text}")])
|
68 |
|
|
|
|
|
|
|
|
|
69 |
# FastAPI endpoint to generate the story
|
70 |
@app.post("/generate_story/")
|
71 |
async def generate_story(story_request: StoryRequest):
|
|
|
66 |
|
67 |
prompt_template = ChatPromptTemplate.from_messages([("system", system), ("human", "{text}")])
|
68 |
|
69 |
+
@app.get("/")
|
70 |
+
def read_root():
|
71 |
+
return {"message": "Welcome to the Story Generation API!"}
|
72 |
+
|
73 |
# FastAPI endpoint to generate the story
|
74 |
@app.post("/generate_story/")
|
75 |
async def generate_story(story_request: StoryRequest):
|