Hardware:Raspberry Pi 3 or 2
SD card and power source
Display, mouse and keyboard
USB soundcard

Installing Jasper on the Raspberry Pi 3 with Wit.ai for voice recognition

The Jasper Project is a voice recognition software bundle and works well with the Raspberry Pi. Voice control software always consists of packages for Speech-To-Text (STT) and Text-To-Speech (TTS) conversion. This tutorial uses Mary for TTS and Wit.ai for STT. Wit.ai has the advantage of giving good results, but needs an always-on internet connection and the data passes facebooks servers. An alternative would be OpenCyc.
Thanks to the Jasper team and especially Matt Curry for providing the new images!

Jasper disk image
For installing Jasper on Raspbian Jessie and a Raspberry Pi 3 or 2, download the new Jasper images from the Jasper support forums.This requires installing btsync.
After burning the image onto a SD card, attach the USB soundcard and the headset to the Raspberry Pi, then boot. Start raspi-config with sudo raspi-config, then extend the partition and change the keyboard layout if necessary.

Jasper installation
Enter in the terminal

and confirm the installation locations when asked.

Wit.ai for voice recognition
Register on Wit.ai, create a dummy app, select the dummy app, click Settings and find the Server Acess Token (in Settings you can also choose another language for Wit.ai).
With the language code, open profile.yml with

and enter your access token in

Also, you may enter your name, Gmail account and other, but that’s not necessary for running Jasper.

Test Jasper
Start Jasper by typing

in the terminal. Say a few words (in the language you chose on Wit.ai) and see if Jasper transcribes them. Test a module: say ‘jasper’, then ‘time’ after the beep and Jasper should output the current time.

Further readings

Wit.ai Website: https://wit.ai/
OpenCyc website: http://sw.opencyc.org/
Jasper Project on Github: http://jasperproject.github.io
Matt Curry Website: http://www.mattcurry.com/projects-2/the-n-a-o-m-i-project/
Jasper Support Forums: https://groups.google.com/forum/#!forum/jasper-support-forum
ALSA manual: https://wiki.archlinux.org/index.php/Advanced_Linux_Sound_Architecture
Tutorial custom voice commands for Jasper: http://www.knight-of-pi.org/raspberry-pi-and-jasper-a-custom-voice-command-for-measuring-the-distance/
Jasper for the RPi2 and 3: https://groups.google.com/forum/#!msg/jasper-support-forum/Jhe5ZVH3iMA/ErtFvQQeAgAJ
Tutorial: Burn a disk image to a SD card: http://www.knight-of-pi.org/installation/

Knight of Pi

Johannes Bergs aka Knight of Pi. Diploma in Bioinformatics, some Webdesign and Python coding then. Living in the beautiful city of Vienna.


  1. Hi dude,

    Glad to found your tutorial (and to see your still active)

    Small question : I’ve a project for which I intend to install a few different programs and scripts in addition to Jasper. Your guide advices to copy an image of Jasper. Shall I be able to add those files?
    Otherwise, do you plan to do a guide on how to install jasper manually on an already existing Raspbian ?

    Thanks whatever :)

    • Hey Michel,
      you’re welcome! Feel free the drop a little donation if you want to support this site.

      Best way probably is forking the Jasper project GitHub repository and adding your files.
      I haven’t tried that, but copying the image, executing the installer, then pulling the modified GitHub Repo should work without additional steps.

      If you want to go the manual way: Burn the jasper image, then enter
      in the terminal and open the installer scripts if necessary. This shows all steps required (if they didn’t clean the history which is likely).

      • Hey mate.

        Just so i’m sure I get it : your link for an image of Jasper only contains Jasper? Or does it contain like a whole raspbian with jasper pre-installed on top? Cause I don’t really want to have to re-re-reformat the sd card (I’m on a bad connection so I don’t really have time for this)

        • It’s the full image, but it’s zipped and should be around 1.5Gb. Since i haven’t received updates from the support forums recently, i assume the current version is stable.

          So long

  2. Hi, I’m getting an error when I entered cd ~/jasper-client/client
    it showed
    -bash: cd: /home/pi/jasper-client/client: No such file or directory
    How can I solve it? Thank you

      • Sorry for the late reply. It shows ” ls: cannot access /home/pi/jasp: No such file or directory”

        • So i guess
          ls ~
          did not show anything with jasper in the name?
          If so, just re-download the Jasper image from the Jasper support forums and burn it onto an SD card. Might be that you downloaded a corrupt version. Anyways, i’ll redo the installation in a few days; if something doesn’t work, i’ll let you know.

  3. I already have Raspbian on my pi and its running well (it requires me to keep the SD card in the pi) how do I install the jasper image on it?? please help

    • Hey Ray, the manual installation of Jasper onto Raspbian Jessie is very complicated, or at least it was last time i tried.
      It’s better if you download the Jasper Image supplied on the Jasper Project forums, burn it onto an SD card and continue from there.

      • I followed your instructions and burn the image file on my SD card and when I boot my pi i get a rainbow picture. Any idea what it means?

        • Hmmm, the rainbow picture is the first thing you see when the RPi boots normally.
          Did you safely eject the SD card before unplugging it? That’s a frequent cause of problems.

  4. I have sucessfully installed jasper with witai.
    Jasper responds back if I said: “Jasper” …. followed by the question like “weather”
    It basically returns the current weather.

    But how do I get witai story to reply back and transcribe the text to speech via Jasper?

    Do you have example of your witai story?

  5. Hi,

    Im getting error :

    Traceback (most recent call last):
    File “./jasper-client/jasper.py”, line 12, in
    from client import tts, stt, jasperpath, diagnose
    File “/home/pi/jasper-client/client/tts.py”, line 41, in
    import diagnose
    File “/home/pi/jasper-client/client/diagnose.py”, line 10, in
    import jasperpath
    File “/home/pi/jasper-client/client/jasperpath.py”, line 12, in
    from client import tts, stt, jasperpath, diagnose
    ImportError: cannot import name tts

    Any idea?

    • Hi,
      you are using the newest image from the Jasper support forums, right?
      Did you setup Wit.ai as described or did you try to start Jasper directly after installing the image?

  6. im having a ver bad internet connection…..
    so wit.ai is working terribly bad.
    is there any offline stt
    i have heard about julius and sphinx
    many reviews said that pocketsphinx works bad in raspberry pi 3
    and I dont know how to insall julius in rpi3 jasper image ,,,,,,,,,,,,,

    please help…….

    • Hey Jithu, i didn’t try Julius, it looked difficult to install and needs training.
      However, i’ve heard that OpenCyc should give good results and does not need internet, but i don’t know when i’ll find the time to test ist.

  7. I am getting errors while doing this……..
    jasper is showing errors !

    ScannerError: while scanning for the next token
    found character ‘\t’ that cannot start any token
    in “/home/pi/.jasper/profile.yml”, line 10,column 1

    could you please help …
    Thank you

    • Jithu, this means that you have a tabulator key in the profile.yml.
      Try opening that file and replace every indention with spaces. Maybe before or after your access key? It’s spaces in the sample code in this tutorial…


Time limit is exhausted. Please reload CAPTCHA.