GithubHelp home page GithubHelp logo

localcroft's Introduction

DEPRECATED.

See elsewhere for more reasons why, but this is no longer a useful repo for mycroft. Neon and/or OVOS are the places you should be looking into, both of which are well beyond the things discussed here. I'll keep this around for archival/amusement purposes, but you're better off looking for the ovos backend and such instead.

DEPRECATED.

Local mycroft things

This includes several file changes to help run a local instance of mycroft, and some how-i-did-it pages for running local resources.

Building my Precise custom wake word model

More on that here.

Mycroft client DeepSpeech STT adjustments

Trying to improve local deep speech audio handling. First remove the start_listening noise*. Second, padding the wav file with .1 seconds of silence at the beginning and the end.

Uses pydub, numpy, scipy, rnnoise-python. sudo apt install ffmpeg; sudo pip3 install pydub or whatever for your env to usually get these installed on picroft.

File itself replaces the one in mycroft-core/mycroft/stt/, then restart services. Note this file defaults to using rnnoise, which can add asignificant time to processing audio files. If you're capable of using this repo you can figure out how to comment that line out if need be.

  • I created a .05s silent wav file for my start_listening.wav.

non-mycroft Deepspeech stuff

here

Moz/wav TTS connector

@domcross got the mozilla tts bits into core, so just use that. It should in theory work with most any URL submission that takes the text as url parameters and returns a wav file.

See the TTS config bits below for how to configure in your local conf.

Local Wikipedia

See here for more on that.

precise uploads

A recent PR has also added local saving of wake words! This can be substituted if preferred to uploading.

Run the uploader.py in a screen session on a friendly host. Requires flask. May need to edit to adjust listen IP or save directory. This makes use of the listener.url config.

Selene backend and updated personal server should handle this more directly if you go that route.

config

bits I use to make things work locally...

  "listener": {
    "wake_word": "yourwordhere",
    "wake_word_upload": {
      "disable": false,
      "url": "http://127.0.0.1:4000/precise/upload"
    },
  "hotwords": {
    "yourwordhere": {
        "module": "precise",
        "phonemes": "U R FO NE M Z HE R E",
        "threshold": "1e-30",
        "local_model_file": "/home/pi/.mycroft/precise/yourwordhere.pb"
        }
    },

This is used to set your wake word, whether to upload the detected wakewords to the upload server, and which wake word engine and options to use. Pocketsphinx uses the phonemes.

  "stt": {
    "module": "deepspeech_server",
    "deepspeech_server": {
      "uri": "http://127.0.0.1:2000/stt"
    }
  },

The default STT file has more enumeration on what choices are available, this is just the one I end up using the most.

  "tts": {
    "module": "mimic2",
    "mimic2": {
      "lang": "en-us",
      "url": "http://127.0.0.1:3000"
    },

TTS server configuration. The URL might be tricky if your endpoint requires odd pagenames but this should work with the mimic2 connector I have here for anything that returns a .wav file.

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.