fix: 优化长语音上传交互并修复输入框高度跳变
This commit is contained in:
@@ -314,6 +314,7 @@ async def _process_audio_segment_async(
|
||||
"data": {
|
||||
"text": transcript_text or "",
|
||||
"audio_duration": audio_duration,
|
||||
"voice_session_id": voice_session_id,
|
||||
"segment_index": segment_index,
|
||||
"is_last": is_last,
|
||||
},
|
||||
@@ -383,18 +384,6 @@ async def _process_audio_segment_async(
|
||||
user=user,
|
||||
)
|
||||
|
||||
if is_last:
|
||||
await manager.send_message(conversation_id, {
|
||||
"type": MessageType.AGENT_RESPONSE,
|
||||
"conversation_id": conversation_id,
|
||||
"data": {
|
||||
"text": "最后一段语音已收到,我会继续完善这一轮总结。",
|
||||
"transition": True,
|
||||
"is_last": True,
|
||||
"segment_index": segment_index,
|
||||
},
|
||||
"timestamp": datetime.now(timezone.utc).isoformat(),
|
||||
})
|
||||
break
|
||||
|
||||
except Exception as e:
|
||||
|
||||
Reference in New Issue
Block a user