my streaming_handler is None
dinhan92 opened this issue · comments
Here is my code: I run debug and see that streaming_handler is None, I see in the example and the streaming_handler only appear in hitl file, I still don't know how to use it.
@app.route('/api/chatbot', methods=['GET', 'POST'])
@token_required
@serving(websocket=True)
def chatbot(**kwargs) -> str:
streaming_handler = kwargs.get('streaming_handler')
input_text = request.data.decode("utf-8")
Hey @dinhan92, can you wrap your code in a code-block for better readability?
I am sorry, I just have check back. I see it has been changed, did you fix it ? @deepankarm ? ^^
Hey @dinhan92, can you please remove the app route and just use the serving
decorator on its own?
@serving(websocket=True)
def chatbot(**kwargs) -> str:
streaming_handler = kwargs.get('streaming_handler')