Giter VIP home page Giter VIP logo

qwxgz / vr-speech-sandbox-vive Goto Github PK

View Code? Open in Web Editor NEW

This project forked from ibm/vr-speech-sandbox-vive

0.0 2.0 0.0 122.4 MB

A sample application that demonstrates how to integrate voice commands and speech recognition into a virtual reality experience.

Home Page: https://developer.ibm.com/code/patterns/create-a-virtual-reality-speech-sandbox/

License: Apache License 2.0

C# 98.10% ShaderLab 1.50% GLSL 0.40%

vr-speech-sandbox-vive's Introduction

Create voice commands for VR experiences with Watson services

Read this in other languages: 한국어, **.

Watson Conversation is now Watson Assistant. Although some images in this code pattern may show the service as Watson Conversation, the steps and processes will still work.

In this Code Pattern we will create a Virtual Reality game based on Watson's Speech-to-Text and Watson's Assistant services.

In Virtual Reality, where you truly “inhabit” the space, speech can feel like a more natural interface than other methods. Providing speech controls allows developers to create more immersive experiences. The HTC Vive is the 3rd most popular head-mounted VR devices (not including Google Cardboard) and an ideal candidate for Speech interaction, selling roughly 400 thousand units in 2016.

When the reader has completed this Code Pattern, they will understand how to:

  • Add IBM Watson Speech-to-Text and Assistant to a Virtual Reality environment build in Unity.

Flow

  1. User interacts in virtual reality and gives voice commands such as "Create a large black box".
  2. The HTC Vive Headset microphone picks up the voice command and the running application sends it to Watson Speech-to-Text.
  3. Watson Speech-to-Text converts the audio to text and returns it to the running Application that powers the HTC Vive.
  4. The application sends the text to Watson Assistant. Watson Assistant returns the recognized intent "Create" and the entities "large", "black", and "box". The virtual reality application then displays the large black box (which falls from the sky).

Included components

Featured technologies

  • Unity: A cross-platform game engine used to develop video games for PC, Mac, consoles, mobile devices and websites.

Watch the Video

Steps

  1. Before you begin
  2. Create IBM Cloud services
  3. Building and Running

1. Before You Begin

2. Create IBM Cloud services

On your local machine:

  1. git clone https://github.com/IBM/vr-speech-sandbox-vive.git
  2. cd vr-speech-sandbox-vive

In IBM Cloud:

  1. Create a Speech-To-Text service instance.
  2. Create an Assistant service instance.
  3. Once you see the services in the Dashboard, select the Assistant service you created and click the "Launch Tool" button.
  4. After logging into the Assistant Tool, click the "Import" button.
  5. Import the Assistant workspace.json file located in your clone of this repository.

3. Building and Running

Note: This has been compiled and tested using Unity 2018.2.0f2 and Watson Unity SDK from the Unity asset Store as of July 24, 2018 and tested with the develop branch of the github unity-sdk as of commit 44d8df33922 July 12.

Note: If you are in any IBM Cloud region other than US-South you must use Unity 2018.2 or higher. This is because Unity 2018.2 or higher is needed for TLS 1.2, which is the only TLS version available in all regions other than US-South.

  1. Either download the Watson Unity SDK from the Unity asset store or perform the following:

git clone https://github.com/watson-developer-cloud/unity-sdk.git

For the github version make sure you are on the develop branch.

  1. Open Unity and inside the project launcher select the Open button.

  2. Navigate to where you cloned this repository and open the Creation Sandbox directory.

  3. If prompted to upgrade the project to a newer Unity version, do so.

  4. Follow these instructions to add the Watson Unity SDK downloaded in step 1 to the project.

  5. Follow these instructions to create your Speech To Text and Watson Assistant services and find their credentials (using IBM Cloud You can find your workspace ID by selecting the expansion menu on your assistant workspace and selecting View details.

    View Details Location

  6. In the Unity Hierarchy view, click on _Scenes->MainGame->MainMenu and then the SaveCredentials object.

  7. In the Inspector you will see Variables for Speech To Text and Watson Assistant and either CF Authentication for the Cloud Foundry username and password, or the IAM Authentication if you have the IAM apikey. Since you only have only one version of these credentials, fill out only one of the two for each service.

  8. Fill out the Speech To Text Service Url, the Assistant Service Url, the Assistant Workspace Id, and the Assistant Version Date. There are tool tips which will show help and any defaults.

  1. Install Blender
  2. In the Unity editor project tab, select Assets->Scenes->MainGame->MainMenu and double click to load the scene.
  3. Press Play

Links

Learn more

  • Artificial Intelligence Code Patterns: Enjoyed this Code Pattern? Check out our other AI Code Patterns.
  • AI and Data Code Pattern Playlist: Bookmark our playlist with all of our Code Pattern videos
  • With Watson: Want to take your Watson app to the next level? Looking to utilize Watson Brand assets? Join the With Watson program to leverage exclusive brand, marketing, and tech resources to amplify and accelerate your Watson embedded commercial solution.

License

Apache 2.0

vr-speech-sandbox-vive's People

Contributors

stevemart avatar scottdangelo avatar hisunah avatar craigkj312 avatar dolph avatar stevemar avatar kant avatar rhagarty avatar lnrego avatar wwalisa avatar

Watchers

James Cloos avatar VQ avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.