Talky to your Ghosty

Add speech interactions to your blog posts with these itsy bitsy javascripties! AnnYang is a tiny javascript library that lets your visitors control your site with voice commands. It supports multiple languages, has no dependencies, weighs just 2kb and is free to use. And there are more...

(This one has only been verified to work on Chrome. Scroll down for links to more voice control scripts.)

Try it right now... say Show my report.

To get this simple example working, in the editor for this post, I simply inserted 2 HTML cards:

<script src="//cdnjs.cloudflare.com/ajax/libs/annyang/2.6.0/annyang.min.js"></script>

<style>
    
    #myreport {
        position:fixed;
        z-index:1000;
        bottom:-600px;
        right:10px;
        width:33vw;
        -webkit-transform:rotate(-15deg);
        -moz-transform:rotate(-15deg);
        -ms-transform:rotate(-15deg);
        -o-transform:rotate(-15deg);
        transform:rotate(-15deg);
        -webkit-box-shadow:2px 1px 6px 1px #555;
        box-shadow:2px 1px 6px 1px #555
    }
    
    .hide {
        display:none
    }
    
</style>


<script>
  "use strict";

  // first we make sure annyang started succesfully
  if (annyang) {

    // define the functions our commands will run.
    var showMy = function(type) {
      $('#myreport').show().animate({
        bottom: '-100px'
      }).delay('3000').animate({
        bottom: '-600px'
      });
    }

    // define our commands.
    var commands = {
      'show :type report':    showMy,
    };

    // Add voice commands to respond to
    annyang.addCommands(commands);

    // Start listening.
    annyang.start();
  } else {
    $(document).ready(function() {
      $('#unsupported').fadeIn('fast');
    });
  }

  var scrollTo = function(identifier, speed) {
    $('html, body').animate({
        scrollTop: $(identifier).offset().top
    }, speed || 1000);
  }
  </script>


<p class="voice_instructions">Try it right now... say Show my report.</p>
<img src="https://www.talater.com/annyang/images/tpscover.jpg" id="myreport" class="hide">
annyang! Easily add speech recognition to your site
annyang is a JavaScript SpeechRecognition library that makes adding voice commands to your site super-easy. Let your users control your site with their voice.

And there are others...

sdkcarlos/artyom.js
A voice control - voice commands - speech recognition and speech synthesis javascript library. Create your own siri,google now or cortana with Google Chrome within your website. - sdkcarlos/artyom.js
Live Cross-Browser Speech Recognition in Node with socket.io & Google
situative design & development in Berlin
anycontrol
AnyControl is a small JavaScript SpeechRecognition library that lets your users control your site with voice commands. It is build on top of Webkit Speech API.
jimmybyrum/voice-commands.js
Simple wrapper for Javascript Speech-to-text to add voice commands. - jimmybyrum/voice-commands.js
syl22-00/pocketsphinx.js
Speech recognition in JavaScript and WebAssembly. Contribute to syl22-00/pocketsphinx.js development by creating an account on GitHub.
Delivering a Smooth Cross-Browser Speech to Text Experience
Research in speech to text is always up and running at iGenius. CTO Michele Pini and frontend developer Giuseppe Cozzolino explain what they encountered in their speech recognition feature. How do…
5 Voice Control JavaScript Libraries for Developers

We can even add some facial recognition and artificial intelligence into the mix...

iLoveYouTrainer.com
iLoveYouTrainer.com lets you test your honesty-factor when saying “I love you” based on an algorithm that analyzes your voice and facial expressions.