https://retellai.com/?utm_source=discord&utm_medium=seo logo
Unable to pass additional data through websocket d...
# ❓・bug-report
r
Hey there, We're currently trying to show additional supported data which we have it. We want to show on our UI for the authenticity of answer that We are providing. But due to RetellWebClient, We are unable to do. Kindly help us, how can we pass our additional data to ui dynamically during webcall with websocket streaming data?
r
@Zexia - Retell AI cc
s
Hi @retellai @Zexia - Retell AI will you be able to help with this? This is a critical feature for us. Thanks!
z
just trying to understand here, you are trying to pass data from your backend to your frontend to show in UI. Could you directly pass it? Is there anything in particular that makes you want to pass it in retell websocket?
r
Hi @Zexia - Retell AI , We are attempting to pass data dynamically through the Retell WebSocket during a web call. The process works as follows: When a user submits a query, it is sent to our RAG pipeline to retrieve relevant documents and provide the user with an answer. Our goal is to display these RAG-retrieved documents in the UI concurrently with the LLM responses. This will allow users to see the documents that informed the LLM’s responses, enhancing the credibility of the answers provided. However, we are encountering a challenge: The display of the documents in the UI needs to be synchronized with each LLM response. Currently, we are unable to dynamically update the UI with the corresponding RAG documents for each LLM response due to the dependencies between the LLM responses and the document retrieval process. Could you advise on how we might overcome this issue to effectively display the documents alongside the LLM responses in real time? Thank you for your assistance.
n
Hey, we had a discussion about this in the office hours! We understand your use case and the challenges you might face! We are planning to provide support for additional data to be sent alongside the websocket! @Zexia - Retell AI and team will keep you guys posted! Thanks 🙂
r
Thank you for the reply @NJ ! We're happy to hear that you're planning to enable additional data to be sent alongside the websocket. Looking forward to hearing from you @Zexia - Retell AI .
z
This feature is now live. Check https://docs.retellai.com/api-references/llm-websocket#metadata-event for the schema to pass metadata to Retellc Check https://docs.retellai.com/api-references/audio-websocket#metadata-event for the metadata event forwarded to frontend. This is also present in the newest version of the frontend SDK now. Listen to "metadata" event.