Bug bash for Direct Line Speech with Web Chat and C#/JavaScript bot

Steps

Prerequisites

  • Make sure your box has Node.js 8.x installed

Create Azure Speech resource

  1. Create a new Azure Speech resource, either by
  2. Use this link
  3. On Portal
    1. Click "Create a resource"
    2. Click "AI + Machine Learning"
    3. Click "See all" (next to "Featured" on top)
    4. On "Cognitive Services" section, click "See More"
    5. Select "Speech"
  4. In Quick Start, write down subscription key and the region (inside endpoint, e.g. westus2)

Create a Web App bot

You must create Azure Speech resource first.

  1. Create a new Web App Bot
  2. Select C# Echo Bot for bot template
  3. Click "Test in Web Chat", make sure it is working
  4. Go to Channels settings
    1. Adds a new "Direct Line Speech" channel
    2. Cognitive service account, select your Azure Speech resource

Create a website with Web Chat

Before starting, first clone this repository.

Using a subscription key

  1. Edit /transcript-using-key/index.html
  2. Update your subscription key at COGNITIVE_SERVICE_KEY
  3. Update your region at COGNITIVE_SERVICE_REGION
  4. Host the website by running npx serve
  5. Navigate to the URL displayed (usually http://localhost:5000)

Using an authorization token

  1. Edit /transcript-using-token/index.html
  2. Update your subscription key at COGNITIVE_SERVICE_KEY
  3. Update your region at COGNITIVE_SERVICE_REGION
  4. Host the website by running npx serve
  5. Navigate to the URL displayed (usually http://localhost:5000)

Using a full React app

  1. Edit /smart-display/src/fetchSpeechServicesCredentials.js
  2. Update your subscription key at COGNITIVE_SERVICE_KEY
  3. Update your region at COGNITIVE_SERVICE_REGION
  4. Run npm install
  5. Run npm start
  6. Navigate to the URL displayed (usually http://localhost:3000)