Text to speech for python! ideas appreciated!
#1
i've been toying with the idea of adding text to speech support to the xbox (not sure if it's possible (prolly is) or probable to do an actual xbox t2s app). here is the beta release of my text to speech server (written in vb, source code below) that is easily used by any python script. the server resides on your lan pc (like the kai engine.) you python script posts the text to convert to the pc and the pc returns a streaming wav file of the converted text to your xbmc empowered tv. i've included links to both the source code and an installable setup program.

the source code requires ms vb 6.0 and ms speech api 5.1 to compile.

the installation comes with sapi.dll so i'm not sure if any other files are needed for an installation (xp comes with t2s voices... ex ms sam, ms mary...)

caution!!!
this is an early release of software. use at your own risk! (there should be little risk involved but you've been warned)

text to speech server (source code and install)
http://oldphotopreserve.com/xbmc.t2s.ser...a).src.zip
http://oldphotopreserve.com/xbmc.t2s.ser....setup.zip

ms sapi 5.1 link
http://www.microsoft.com/speech/download/sdk51/

a sample python script is included with both distributions.

this is a very early release. it's 5:12am and i've been working on this idea all night. i'll post more as it becomes available.

there is plenty of work left to do as i'm a complete newb in python scripting. and the server side leaves much to be desired...

as i said, this is an early release to determine the demand for such a component. should be easily incorporated into email readers, news readers, rss readers, etc...

i look forward to hearing ideas to use and improve this component!

lostit
Image
Softmodded
XMBC enthusiast since Dec. 2004
Reply
#2
thoughts related to t2s server...

needs:
code commenting
better error handling and debug printing

t2s server ideas:
wav to mp3 conversion? (for lower bandwidth networks like the internet) (i know vb isn't the most scalable languages but it could support a half dozen or more xb's depending on demand... this would definately require more security!Wink
port change (user changeable)
ip allow list
ip block list
word/phrase replacement (ex lol = laughing out loud… xbmc = x box media center)
simple censoring (option to censor out the more common ‘bad’ words)
start with windows option
speech options (can be set using scripted commands or in server)
-pitch
-voice
-speed
alternative to
/xplay.t2s.wav (reads the pre-set text through xbox audio) (change to /xbplay.t2s.wav ?)
/pcplay.t2s (reads the pre-set text through pc audio)
(pay attention to the extensions. one returns plain text while the other returns audio data.)

python t2s script ideas:
rol = read out load
rol online/downloaded ebooks
rol news sites (articles)
rol rss feeds
rol emails
rol appointments (calendar)
greeting on boot up
rol kai buddies online/status change
rol weather
Image
Softmodded
XMBC enthusiast since Dec. 2004
Reply
#3
all i can say is wow. very very cool, could be implemented in many ways.
Reply
#4
actually this technology would be great as an accessibility feature for the vision impared. as far as accessibility goes xbmc doesnt have much (well anything really). im sure these people would want to stream music as much as the next....

i can see this as leading to some vi-friendly music browsing scripts or vi-friendly versions of existing scripts (my stock browser could make use of it maybe). as far as the main code goes though... you'd have to be able to get the text of the currently selected control and read it. in theory you may be able to do this in the current python api but i dont think there are any python scripts out there that have attempted to interact with a non-python control like this. it would work better as part of the main code but it is unknown how much of a demand there is for this (and does seem like a significant change)

it would be great for an alerting system in scripts (as in you are watching a slideshow and hear "you have a new message from billiebob")... unfortunately i dont think there is a way to play an audio message during movies or music.

unfortunately though because it requires installation on both pc and xbox, as well as configuring for your network setup, it is harder get running than xbmc is. it would need a huge value-add for the end-user to justify the effort which i dont see happening for most (although you would definitely find people whod try it for the gee-whiz factor). vi users would do this though but again that niche audience who would really want this is pretty small.
Reply
#5
Quote:unfortunately though because it requires installation on both pc and xbox, as well as configuring for your network setup, it is harder get running than xbmc is. it would need a huge value-add for the end-user to justify the effort which i dont see happening for most...

didn't you have to configure your network to allow ftp access to you xbox? didn't you need to install an ftp client? i don't see configuring a script as being that hard for the average computer/xbmc user. point taken though. i'll try to keep it as easy to use as possible.

thanks for the ideas buys!

i just uploaded some revisions to my t2s server. (same links as before.)

mp3 support - i added support for lame mp3 encoding of t2s wav files before sending to the xbox. this may add a little more pc work but results in roughly 90% less bandwidth usage.

minor cosmetics

the links at the beginning of this topic are still good. check it out.
Image
Softmodded
XMBC enthusiast since Dec. 2004
Reply
#6
here's a screenshot of the server.
http://ttdev.net/t2sserver.jpg

nothing too impressive. still not very configurable. i changed the page request links.i added ability to read out load on the pc by command of the xbox.

i'm not going to post the setup again... i'll put the current version install on my site when i get there. (just got the domain.)

here's a link to the latest visual basic (6.0) source code. (example python script included.)
http://ww.ttdev.net/xbmc.t2s.server.(0.8.9).src.zip

don't forget you will need the ms sapi 5.1
http://www.microsoft.com/speech/download/sdk51/
Image
Softmodded
XMBC enthusiast since Dec. 2004
Reply

Logout Mark Read Team Forum Stats Members Help
Text to speech for python! ideas appreciated!0