simon 0.3.0 has been released about two weeks ago and this means that even tough temperatures outside disagree it's once again summer in trunk!
Our newest addition is actually one that has been in the works for quite some time (in a separate branch) and presents itself to the user as a new plugin: The Dialog plugin.
While simon 0.3.0 is ideally suited to silently execute the commands you tell him, the next version of simon will talk back.
The basic idea is quite simple: The dialog system lets the user define an arbitrary amount of states which each has some transitions to move on to other states of the dialog. Each transition can also execute other simon commands if configured to do so.
An example use case could look like this:
Every day at 10 am the system displays a dialog that asks the user if he has already taken his medication. Yes -> "Great!"; No -> "Do you need help?" -> etc.
But you could also create quite complex menus like this:
You: "Computer!"
Computer: "Hi! What do you want to do? Say any of the following options: Read e-Mails; Browse the web; Check calendar; Close"
You: "Check calendar"
Computer: "Alright. These are your upcoming events: Birthday at Susies Place in Graz"
You: "Where am I?"
Computer: "You are in Graz, Austria."
You: "Thanks"
Sounds ridiculous, right? Well, let's look at this example in a little bit more detail...
States, Options and Transitions
The above dialog is a quite simple state based dialog. You can see three states: "Welcome", "Calendar" and "Location". We can define them in the dialog configuration.
You can see that dialog options to continue to other states can be added there as well. The text of the state actually goes through a templating engine so you can define paramters for that in the "Template options" page.
But more interesting is probably the "Bound values" page. There you can define variables and bind them to values. Those values can be static, determined at runtime through QtScript (Javascript) or values from plasma dataengines.
For example you can bind $currentTime$ to the Local/Time of the date and time plasma data engine. And because there already lots of great plasma data engines this means that the dialog system is already quite powerful.
TTS
Remember that I said that simon will talk back to you in simon 0.4? Yes we also have an all new TTS layer but I'll cover this in a separate blog post as this one is already too long :)
Demo
So to show off the current state of development, I created a very short demo video displaying the dialog above. While the code is not production ready, I didn't cheat: both the upcoming events and the location is determined dynamically, at runtime, through plasma data engines (upcoming events use the calendar data engine to get data from your Akonadi calendar).
For RRS readers here a direct link.
4 Kommentare:
How mature is simon? I tried installing it before but it kept crashing.
By the way are you at Graz Uni of Technology?
It's always great to see how Simon progresses. Thanks a lot for your work and contribution to the free software world.
On my plan for this week is ordering a Bluetooth microphone to play with Simon.
And a question: when you talk about a (new) TTS system do you use the KDE tts system (jovie or something) or integrate another one?
@xSacha: simon should be mature enough. There are no open crash bugs in the simon codebase that I know of. There are, however a lot of issues in QtMultimedia.
The next time you get a crash look at the detailed information - it will most probably show a trace to QAudioDeviceInfoInternal().
Also, @unormal: At least for me, QtMultimedia didn't work with bluetooth devices. I reported it upstream but sadly this issue is not going to be fixed in QtMultimedia any time soon:
http://bugreports.qt.nokia.com/browse/QTBUG-9905
The TTS system can use Jovie, a webservice (especially OpenMary) and pre recorded soundsnippets (can be exported and imported).
@xSacha: Almost forgot: Yes, I'm a student there. You too?
Kommentar veröffentlichen