-
Notifications
You must be signed in to change notification settings - Fork 1
DST-252: set up code for accordion implementation #41
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,7 +12,6 @@ | |
import socket | ||
from functools import cached_property | ||
from io import StringIO | ||
from typing import Dict | ||
|
||
import dotenv | ||
from fastapi import Body, FastAPI, Request, status | ||
|
@@ -47,8 +46,8 @@ def chat_engine(self): | |
|
||
# This function cannot be async because it uses a single non-thread-safe app_state | ||
@app.post("/query") | ||
def query(message: str | Dict): | ||
response = app_state.chat_engine().gen_response(message) | ||
def query(message: str): | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. removed There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This fixed the underlying error? I'm a bit surprised, since I didn't think type annotations could affect runtime! |
||
response = app_state.chat_engine.gen_response(message) | ||
return response | ||
|
||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
removed due to unexpected key error