Code Monkey home page Code Monkey logo

sonus's Introduction

sonus

Build Status Dependency Status

This project is in active development and is rapidly evolving. As of v0.1.0 it uses semantic versioning.

Sonus is a speech to text library you can use to quickly and easally add a VUI (Voice User Interface) to any hardware or software project. Just like Alexa, Google Now, and Siri, Sonus is always listening offline for a customizable hotword. Once that hotword is detected your speech is streamed to the cloud recognition service of your choice - then you get the results.

Platform Support

  • Linux - most major distros (Including Raspbian)
  • macOS
  • Windows

Streaming Recognition Services

  • Google Cloud Speech
  • Alexa Voice Services
  • Wit.ai
  • Microsoft Cognitive Services
  • Houndify

Installation

npm install --save sonus

Dependencies

Generally, running npm install should suffice. This module however, requires you to install SoX.

For most linux disto's

Recommended: use arecord, which comes with most linux distros. Alternatively:

sudo apt-get install sox libsox-fmt-all

For macOS

brew install sox

Usage

Configure out cloud speech recognition system of choice, like Google Cloud Speech API.

Add sonus and said recognizer:

const Sonus = require('sonus')
const speech = require('@google-cloud/speech')({
  projectId: 'streaming-speech-sample',
  keyFilename: './keyfile.json'
})

Add your keyword and initialize Sonus with a Snowboy hotword:

const hotwords = [{ file: 'resources/snowboy.umdl', hotword: 'snowboy' }]
const sonus = Sonus.init({ hotwords }, speech)

Create your own Alexa in less than a tweet:

Sonus.start(sonus)
sonus.on('hotword', (index, keyword) => console.log("!"))
sonus.on('final-result', console.log)

How do I set up Google Cloud Speech API?

Follow these instructions.

How do I make my own hotword?

Sonus uses Snowboy for offline hotword recognition. You can use their website or API to train a model for a new hotword. Hotword training must occur online through their web service.

If you build a project with Sonus send a PR and include it here!

Authors

Evan Cohen: @_evnc Ashish Chandwani: @ashishschandwa1

License

Licensed under MIT.

sonus's People

Contributors

evancohen avatar ashishsc avatar matrixoperator avatar jaumard avatar black-snow avatar hackergrrl avatar manzonif avatar mathiskeller avatar

Watchers

 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.