This demo will show you how to integrate Wit.ai (NLU service) and A-Frame (WebXR library) to build a voice enabled VR application (that can be adapted for AR as well). The app will allow users to ask our sudo AI voice assistant built with the Web-Speech-API to add 3D objects to our VR environment with voice commands, such as “Hey Gizmo, drop a box”.
F8.Voice.XR.Wit.ai.Talk.mp4
Slides for Building Immersive Voice XR Experiences with Wit.ai.pdf
- Create a Wit.ai account
- Use a Web-Speech-API compatible browser
- Use a WebGL compatible browser
- Have a microphone connected to your computer
- Create a new Wit.ai app
- Unzip and import
src/wit_example.zip
to your Wit.ai app - Update
CLIENT_TOKEN
insrc/voice.js
to the client token obtained from your app’s Settings page - Open the
src/index.html
file in your browser - Allow microphone access
Below are some voice commands that are supported, but you can also go to your Wit.ai app and select Utterances to view and extend them:
- “drop a box”
- “add a cylinder”
- “drop a sphere”
- “I summon a box”
- “can you add a cylinder”
- “please add a cylinder”
See the CONTRIBUTING file for how to help out.
Wit.ai WebXR Voice Demo is licensed, as found in the LICENSE file.