mirror of
https://github.com/langgenius/dify.git
synced 2024-11-16 11:42:29 +08:00
This commit is contained in:
parent
e4ed916baa
commit
c531b4a911
|
@ -231,6 +231,7 @@ class AdvancedChatAppGenerateTaskPipeline(BasedGenerateTaskPipeline, WorkflowCyc
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
logger.error(e)
|
logger.error(e)
|
||||||
break
|
break
|
||||||
|
if tts_publisher:
|
||||||
yield MessageAudioEndStreamResponse(audio="", task_id=task_id)
|
yield MessageAudioEndStreamResponse(audio="", task_id=task_id)
|
||||||
|
|
||||||
def _process_stream_response(
|
def _process_stream_response(
|
||||||
|
|
|
@ -212,6 +212,7 @@ class WorkflowAppGenerateTaskPipeline(BasedGenerateTaskPipeline, WorkflowCycleMa
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
logger.error(e)
|
logger.error(e)
|
||||||
break
|
break
|
||||||
|
if tts_publisher:
|
||||||
yield MessageAudioEndStreamResponse(audio="", task_id=task_id)
|
yield MessageAudioEndStreamResponse(audio="", task_id=task_id)
|
||||||
|
|
||||||
def _process_stream_response(
|
def _process_stream_response(
|
||||||
|
|
|
@ -248,6 +248,7 @@ class EasyUIBasedGenerateTaskPipeline(BasedGenerateTaskPipeline, MessageCycleMan
|
||||||
else:
|
else:
|
||||||
start_listener_time = time.time()
|
start_listener_time = time.time()
|
||||||
yield MessageAudioStreamResponse(audio=audio.audio, task_id=task_id)
|
yield MessageAudioStreamResponse(audio=audio.audio, task_id=task_id)
|
||||||
|
if publisher:
|
||||||
yield MessageAudioEndStreamResponse(audio="", task_id=task_id)
|
yield MessageAudioEndStreamResponse(audio="", task_id=task_id)
|
||||||
|
|
||||||
def _process_stream_response(
|
def _process_stream_response(
|
||||||
|
|
|
@ -48,7 +48,7 @@ from ._utils import (
|
||||||
)
|
)
|
||||||
|
|
||||||
if TYPE_CHECKING:
|
if TYPE_CHECKING:
|
||||||
from pydantic_core.core_schema import LiteralSchema, ModelField, ModelFieldsSchema
|
from pydantic_core.core_schema import ModelField
|
||||||
|
|
||||||
__all__ = ["BaseModel", "GenericModel"]
|
__all__ = ["BaseModel", "GenericModel"]
|
||||||
_BaseModelT = TypeVar("_BaseModelT", bound="BaseModel")
|
_BaseModelT = TypeVar("_BaseModelT", bound="BaseModel")
|
||||||
|
|
Loading…
Reference in New Issue
Block a user