Skip to main content

Rhino Speech-to-Intent engine demos.

Project description

Rhino Speech-to-Intent Engine Demos

Made in Vancouver, Canada by Picovoice

This package contains demos and commandline utilities for processing real-time audio (i.e. microphone) and audio files using Rhino Speech-to-Intent engine.

Rhino

Rhino is Picovoice's Speech-to-Intent engine. It directly infers intent from spoken commands within a given context of interest, in real-time. For example, given a spoken command

Can I have a small double-shot espresso?

Rhino infers that the user and emits the following inference result:

{
  "isUnderstood": "true",
  "intent": "orderBeverage",
  "slots": {
    "beverage": "espresso",
    "size": "small",
    "numberOfShots": "2"
  }
}

Rhino is:

  • using deep neural networks trained in real-world environments.
  • compact and computationally-efficient. It is perfect for IoT.
  • self-service. Developers can train custom models using Picovoice Console.

Compatibility

  • Python 3
  • Runs on Linux (x86_64), Mac (x86_64, arm64), Windows (x86_64), Raspberry Pi (all variants), NVIDIA Jetson Nano and BeagleBone.

Installation

sudo pip3 install pvrhinodemo

AccessKey

Rhino requires a valid AccessKey at initialization. AccessKeys act as your credentials when using Rhino SDKs. You can create your AccessKey for free. Make sure to keep your AccessKey secret.

To obtain your AccessKey:

  1. Login or Signup for a free account on the Picovoice Console.
  2. Once logged in, go to the AccessKey tab to create one or use an existing AccessKey.

Usage

File Demo

It allows testing Rhino on a corpus of audio files. The demo is mainly useful for quantitative performance benchmarking. It accepts 16kHz audio files. Rhino processes a single-channel audio stream if a stereo file is provided it only processes the first (left) channel. Note that only the relevant spoken command should be present in the file and no other speech. There also needs to be at least one second of silence at the end of the file.

rhino_demo_file --input_audio_path ${AUDIO_PATH} --access_key ${ACCESS_KEY} --context_path ${CONTEXT_PATH} 

Microphone Demo

It opens an audio stream from a microphone and performs inference in spoken commands:

rhino_demo_mic --access_key ${ACCESS_KEY} --context_path ${CONTEXT_PATH}

It is possible that the default audio input device recognized by the demo is not the one being used. There are a couple of debugging facilities baked into the demo application to solve this. First, type the following into the console:

rhino_demo_mic --show_audio_devices

It provides information about various audio input devices on the box. On a Linux box, this is the console output

index: 0, device name: USB Audio Device
index: 1, device name: MacBook Air Microphone

You can use the device index to specify which microphone to use for the demo. For instance, if you want to use the USB Audio Device in the above example, you can invoke the demo application as below:

rhino_demo_mic --access_key ${ACCESS_KEY} --context_path ${CONTEXT_PATH} --audio_device_index 0

If a problem occurs, we suggest storing the recorded audio into a file for inspection. This can be achieved by:

rhino_demo_mic --access_key ${ACCESS_KEY} --context_path ${CONTEXT_PATH} --audio_device_index 0 --output_path ~/test.wav

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pvrhinodemo-2.0.3.tar.gz (8.7 kB view details)

Uploaded Source

Built Distribution

pvrhinodemo-2.0.3-py3-none-any.whl (7.7 kB view details)

Uploaded Python 3

File details

Details for the file pvrhinodemo-2.0.3.tar.gz.

File metadata

  • Download URL: pvrhinodemo-2.0.3.tar.gz
  • Upload date:
  • Size: 8.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.22.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.10

File hashes

Hashes for pvrhinodemo-2.0.3.tar.gz
Algorithm Hash digest
SHA256 d24257781eb4b7640493f5bbce0677cab753de98c65d645a22a2dadaab78acc4
MD5 887c28498e798d035462ad9e87afb512
BLAKE2b-256 bbf1e8d99ffb466ae2195d1b95c69f48c0e1a8cf4d0bb1dfb5178bd37ae079fd

See more details on using hashes here.

File details

Details for the file pvrhinodemo-2.0.3-py3-none-any.whl.

File metadata

  • Download URL: pvrhinodemo-2.0.3-py3-none-any.whl
  • Upload date:
  • Size: 7.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.22.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.10

File hashes

Hashes for pvrhinodemo-2.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 48559c990716287fead3f1b08fc394c9881731a3497c1319b1ecaf111b6c8e7c
MD5 417e1298783c5bb7c612845d0f21493c
BLAKE2b-256 e281e5f85e58841ece8e5a892797ae34fc47ff7909d25f29ad0c276dcbfadc66

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page