few-analyst-46
09/04/2025, 2:46 PMasync def update_chat_ctx(self, chat_ctx: llm.ChatContext) -> None:
# Volcengine Realtime Dialogue uses dialog_id for context continuity
# For now, we'll just log the update
async with self._update_chat_ctx_lock:
if not chat_ctx.items:
return
last_item = chat_ctx.items[-1]
if not isinstance(last_item, llm.ChatMessage):
return
if last_item.role != 'user':
return
parts = [i for i in last_item.content if isinstance(i, str)]
content = '\n'.join(parts)
# NOTICE: without this, pure audio works
# self.send_text_query(content)
logger.info('adding user message: %s', content)