diff --git a/demos/streaming_asr_server/server.sh b/demos/streaming_asr_server/server.sh index 0d255807c8841396528696198ce1d136b93c69ce..f532546e7c2280cdf9dab0f0e09765031673edf0 100755 --- a/demos/streaming_asr_server/server.sh +++ b/demos/streaming_asr_server/server.sh @@ -4,6 +4,6 @@ export CUDA_VISIBLE_DEVICE=0,1,2,3 # nohup python3 punc_server.py --config_file conf/punc_application.yaml > punc.log 2>&1 & paddlespeech_server start --config_file conf/punc_application.yaml &> punc.log & -# nohup python3 streaming_asr_server.py --config_file conf/ws_conformer_application.yaml > streaming_asr.log 2>&1 & -paddlespeech_server start --config_file conf/ws_conformer_application.yaml &> streaming_asr.log & +# nohup python3 streaming_asr_server.py --config_file conf/ws_conformer_wenetspeech_application.yaml > streaming_asr.log 2>&1 & +paddlespeech_server start --config_file conf/ws_conformer_wenetspeech_application.yaml &> streaming_asr.log & diff --git a/paddlespeech/server/engine/asr/online/asr_engine.py b/paddlespeech/server/engine/asr/online/asr_engine.py index 8fc210e5a32b3c4e67192d47842d87f5a1bb6b1b..6b9eed508cfd9e666be16f3ed63d050985bb01f9 100644 --- a/paddlespeech/server/engine/asr/online/asr_engine.py +++ b/paddlespeech/server/engine/asr/online/asr_engine.py @@ -161,7 +161,9 @@ class PaddleASRConnectionHanddler: self.model_reset() self.searcher.reset() self.endpointer.reset() - self.output_reset() + + # reset hys will trancate history transcripts. + # self.output_reset() def reset(self): if "deepspeech2" in self.model_type: diff --git a/paddlespeech/server/ws/asr_api.py b/paddlespeech/server/ws/asr_api.py index ff4ec7b0bc1cfd3d066d65515642072cbe75636b..23609b41ae1c91afb64221c0c1d1024be75746bd 100644 --- a/paddlespeech/server/ws/asr_api.py +++ b/paddlespeech/server/ws/asr_api.py @@ -92,6 +92,7 @@ async def websocket_endpoint(websocket: WebSocket): else: resp = {"status": "ok", "message": "no valid json data"} await websocket.send_json(resp) + elif "bytes" in message: # bytes for the pcm data message = message["bytes"]