SDK3.12.14版本,
类似如下发送文字:
CHAR_T *request_id = "TriggerAiChat";
CHAR_T *content = "你好呀,今天天气怎么样?";
Code: Select all
rt = ty_ai_proc_event_send(s_ai_toy->llm, AI_PROC_INTERRUPT_EVENT, NULL, 0);
rt |= ty_ai_proc_event_send(s_ai_toy->llm, AI_PROC_SKILL_EVENT, request_id, strlen(request_id));
rt |= ty_ai_proc_event_send(s_ai_toy->llm, AI_PROC_TEXT_EVENT, content, strlen(content));
rt |= ty_ai_proc_event_send(s_ai_toy->llm, AI_PROC_FINSH_EVENT, NULL, 0);
if (OPRT_OK != rt) {
TAL_PR_ERR("ty_ai_proc_event_send failed");
return OPRT_COM_ERROR;
}
第一次可以回复语音,后面的就只回复文字了,能让他一直回复语音?