A simple example implementation of the VoiceRAG pattern to power interactive voice generative AI experiences using RAG with Azure AI Search and Azure OpenAI's gpt-4o-realtime-preview model.
Error
in64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/129.0.0.0 Safari/537.36 Edg/129.0.0.0"
ERROR:aiohttp.server:Error handling request
Traceback (most recent call last):
File "/workspaces/aisearch-openai-rag-audio/.venv/lib/python3.12/site-packages/aiohttp/web_protocol.py", line 452, in _handle_request
resp = await request_handler(request)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/workspaces/aisearch-openai-rag-audio/.venv/lib/python3.12/site-packages/aiohttp/web_app.py", line 543, in _handle
resp = await handler(request)
^^^^^^^^^^^^^^^^^^^^^^
File "/workspaces/aisearch-openai-rag-audio/app/backend/rtmt.py", line 208, in _websocket_handler
await self._forward_messages(ws)
File "/workspaces/aisearch-openai-rag-audio/app/backend/rtmt.py", line 171, in _forward_messages
async with aiohttp.ClientSession(base_url=self.endpoint) as session:
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/workspaces/aisearch-openai-rag-audio/.venv/lib/python3.12/site-packages/aiohttp/client.py", line 248, in init
self._base_url.origin() == self._base_url
^^^^^^^^^^^^^^^^^^^^^^^
File "/workspaces/aisearch-openai-rag-audio/.venv/lib/python3.12/site-packages/yarl/_url.py", line 563, in origin
return self._origin
^^^^^^^^^^^^
File "src/propcache/_helpers_c.pyx", line 41, in propcache._helpers_c.under_cached_property.get
File "/workspaces/aisearch-openai-rag-audio/.venv/lib/python3.12/site-packages/yarl/_url.py", line 573, in _origin
raise ValueError("URL should be absolute")
ValueError: URL should be absolute
Note:
Saw following error while building app
vite v5.4.8 building for production...
node_modules/framer-motion/dist/es/components/AnimatePresence/index.mjs (1:0): Error when using sourcemap for reporting an error: Can't resolve original location of error.
node_modules/framer-motion/dist/es/motion/index.mjs (1:0): Error when using sourcemap for reporting an error: Can't resolve original location of error.
✓ 1937 modules transformed.
../backend/static/index.html 0.47 kB │ gzip: 0.31 kB
../backend/static/assets/index-MbNbqoGC.css 14.11 kB │ gzip: 3.75 kB
../backend/static/assets/index-C--kc_TS.js 316.59 kB │ gzip: 102.06 kB │ map: 1,216.15 kB
✓ built in 5.00s
Steps to follow
App started
Error in64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/129.0.0.0 Safari/537.36 Edg/129.0.0.0" ERROR:aiohttp.server:Error handling request Traceback (most recent call last): File "/workspaces/aisearch-openai-rag-audio/.venv/lib/python3.12/site-packages/aiohttp/web_protocol.py", line 452, in _handle_request resp = await request_handler(request) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/workspaces/aisearch-openai-rag-audio/.venv/lib/python3.12/site-packages/aiohttp/web_app.py", line 543, in _handle resp = await handler(request) ^^^^^^^^^^^^^^^^^^^^^^ File "/workspaces/aisearch-openai-rag-audio/app/backend/rtmt.py", line 208, in _websocket_handler await self._forward_messages(ws) File "/workspaces/aisearch-openai-rag-audio/app/backend/rtmt.py", line 171, in _forward_messages async with aiohttp.ClientSession(base_url=self.endpoint) as session: ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/workspaces/aisearch-openai-rag-audio/.venv/lib/python3.12/site-packages/aiohttp/client.py", line 248, in init self._base_url.origin() == self._base_url ^^^^^^^^^^^^^^^^^^^^^^^ File "/workspaces/aisearch-openai-rag-audio/.venv/lib/python3.12/site-packages/yarl/_url.py", line 563, in origin return self._origin ^^^^^^^^^^^^ File "src/propcache/_helpers_c.pyx", line 41, in propcache._helpers_c.under_cached_property.get File "/workspaces/aisearch-openai-rag-audio/.venv/lib/python3.12/site-packages/yarl/_url.py", line 573, in _origin raise ValueError("URL should be absolute") ValueError: URL should be absolute
Note:
Saw following error while building app
vite v5.4.8 building for production... node_modules/framer-motion/dist/es/components/AnimatePresence/index.mjs (1:0): Error when using sourcemap for reporting an error: Can't resolve original location of error. node_modules/framer-motion/dist/es/motion/index.mjs (1:0): Error when using sourcemap for reporting an error: Can't resolve original location of error. ✓ 1937 modules transformed. ../backend/static/index.html 0.47 kB │ gzip: 0.31 kB ../backend/static/assets/index-MbNbqoGC.css 14.11 kB │ gzip: 3.75 kB ../backend/static/assets/index-C--kc_TS.js 316.59 kB │ gzip: 102.06 kB │ map: 1,216.15 kB ✓ built in 5.00s