[NCLUG] Two quick items...

Brian Sturgill bsturgill at ataman.com
Fri Oct 2 13:54:30 MDT 2020


First, a little humor.
You may possibly have heard of low code/no code "apps" trending. It's not
really new, every few years there's a new attempt.
Well this guy made an open source no code solution:
https://github.com/kelseyhightower/nocode
Make sure you read the pull requests.

Second, for my intercom I needed to translate text notifications to audio.
Microsoft and Apple make this hard to do, especially from a service.
I had very little respect for the Open Source TTS options... they are hard
to understand.
Well... there's now a solution... it's not as good as Siri/Cortana/Bossy
Google Lady, but
it is at least understandable. It uses an existing TTS engine, but with a
newly available voice.

Here's how to do it:
sudo apt-get install festival -y
sudo apt-get install festvox-us-slt-hts -y

Testing it:
festival -i
festival> (voice_cmu_us_slt_arctic_hts)
festival> (SayText "Don't hate me, I'm just doing my job!")

Here's how I use it for text via my intercom:
def handle_in_q():
    while True:
        txt = in_q.get(True) + " ..."  # Use " ..." to make the ending more
distinct.
        os_f, tf = tempfile.mkstemp(suffix=".pcm", prefix="txticom_")
        os.close(os_f)
        print(f"{tf}")
        c = f"text2wave -o '{tf}' -eval '(voice_cmu_us_slt_arctic_hts)'
-otype raw -F 44100 -scale 5.0"
        print(c)
        f = os.popen(c, mode='w')
        f.write(txt)
        f.close()
        out_q.put(tf)

--
"text2wave" is a script (in scheme) that works with festival to create a
file from text using festival.
-- 

Brian


More information about the NCLUG mailing list