christopherrogers1991 / mycroft_routine_skill Goto Github PK
View Code? Open in Web Editor NEWCreate, run, and schedule routines with Mycroft
License: GNU General Public License v3.0
Create, run, and schedule routines with Mycroft
License: GNU General Public License v3.0
Hi,
I've installed the skill on my microft-core in a docker container , but it doesn't work, if i give the commands mycroft can't understand me.
I Can see in the logs file:
021-06-12 18:02:09.776 | INFO | 27 | mycroft.skills.settings:get_local_settings:83 | /opt/mycroft/skills/mycroft_routine_skill.christopherrogers1991/settings.json
File "/opt/mycroft/skills/mycroft_routine_skill.christopherrogers1991/__init__.py", line 59, in initialize
2021-06-12 18:02:09.864 | ERROR | 27 | mycroft.skills.skill_loader:_communicate_load_status:351 | Skill mycroft_routine_skill.christopherrogers1991 failed to load`
I see that settings.json not exist in that folder
Hi
I have just installed this skill on a Picroft (I find the idea amazing honestly), however I can't name my routines, as it seems that instead of listening for the name, Mycroft is listening for a new command... Example:
[code]
create a new routine
What would you like to name it?
morning
Good Morning
[/code]
The same goes with any word I may use... If the word does not match any of Mycroft's skills he'll just say he doesn't understand.
Any ideas?
Thanks :)
Hi again!
Now that I have my first two routines working, I have found something odd... Nothing major but I figured I'd notify you.
In my morning routine I had the instruction "say good morning!" (so, with the word "morning" in it...). I ended up with an infinite loop, Mycroft was repeating the instructions over and over again. I have to re-start the skills service for it to stop.
When I changed the phrase to "say good day!" instead it all stopped. That routine is working normally now.
Also, there seems to be no specific order in which the instructions are executed - here again nothing major, I love this skill and I am definitely going to use it. Maybe just something to consider for a future release :)
It seems logical that "every day" would be a reasonable response to "what days of the week". And routines does not complain. In fact it actually does add a schedule with nothing where the days should be. However we then get an error from from_crontab called by _schedule_routine which is missing a field.
The skill appears to delete the routine, but then throws an uncaught error. Here is the traceback:
Traceback (most recent call last):
File "/home/pi/mycroft-core/mycroft/skills/mycroft_skill/event_container.py", line 73, in wrapper
handler(message)
File "/opt/mycroft/skills/mycroft_routine_skill.christopherrogers1991/init.py", line 338, in _delete_routine
self._delete_routine_quiet(message)
File "/opt/mycroft/skills/mycroft_routine_skill.christopherrogers1991/init.py", line 346, in _delete_routine_quiet
self._show_routines()
TypeError: _show_routines() missing 1 required positional argument: 'message'
@burnsfisher
I will fix it in a few minutes. I did so on my local system. I'll fix it and add a pull request in a few minutes, but I wanted to record it.
I set up a morning routine with Mycroft telling us good morning, telling me the weather, the news, then saying have a good day sweetie. Everything seems to be set up properly, but when I run the routine it does each step over a dozen times, eventually crashing on the news section as it brings up the stream all those times and crashes. Here is my routine json:
{
"morning": {
"tasks": [
"say good morning everybody",
"tell me the weather",
"tell me the news",
"say have a good day everyone"
],
"schedule": "hour='8', minute='0', second='0'",
"enabled": true
}
}
I changed it slightly according to APScheduler's guidelines. Originally when setting the routing for every day at 0800, the schedule said: 5 8 * * 0,1,2,3,4,5,6. So the day of the week was right, but did it switch the time of day with year/month? Either way, I never even got to the schedule part. I've uploaded the skills.log, and I've pulled others if they might be relevant.
skills.log
This feedback came through a person who was doing a lot of translation on the Mycroft Translate platform in the Dutch language
Is it possible to support utterances in 24-hr time, such as "nineteen hundred hours" for 7pm - as this style of phrase is very common in European languages.
I have the skill running, and I have created a routine, but I don't see this file. Do I need to create the directory or is could it be stored somewhere else?
pi@mark_1:~ $ tree ./.mycroft
./.mycroft
└── identity
This is running 19.2.1b
Thanks
I created a routine called "I'm here". It was fine in terms of the contraction being understood by voice recognition, and it was place ok in routines2.json. However:
I have totally rebooted the pi and now it seems ok.
I have installed this skill several different ways. Does it still work? I am tryin to debug it and it would be nice if someone could tell me if the file structure is still supported
The mycroft routine skill fills an important function. With only voice commands, user can program a routine that duplicates the functions of a radio alarm clock. No more tiny buttons, flipping through the manual, or accidentally setting PM instead of AM. Very useful.
Saying "Good Morning" results in the following in the debug log.
Running Mycroft 18.2.9 on Ubuntu 18.04
10:36:27.379 - __main__:handle_utterance:61 - INFO - Utterance: ['good morning']
10:36:27.399 - mycroft.skills.core:wrapper:607 - ERROR - An error occurred while processing a
request in Mycroft Routine Skill
Traceback (most recent call last):
File "/home/parker/mycroft-core/mycroft/skills/core.py", line 598, in wrapper
handler(message)
File "/opt/mycroft/skills/routine.christopherrogers1991/__init__.py", line 143, in _trigger_routine
self._run_routine(name)
File "/opt/mycroft/skills/routine.christopherrogers1991/__init__.py", line 146, in _run_routine
for task in self._routines[name]['tasks']:
KeyError: 'tasks'
When executing the routine Mycroft doesnt wait for one action to stop before it starts a new one, leading to wierd sentence structure and incomplete anouncements.
Hey ! there seems to be some awesome stuff happening here..
Would you be interested to incorporate this routines system into OpenVoiceOS ? (https://github.com/OpenVoiceOS / https://openvoiceos.com / https://community.mycroft.ai/t/openvoiceos-a-bare-minimal-production-type-of-os-based-on-buildroot/)
As a skill this should already work as we are backwards compatible with mycroft-core dev branch but we would like to deeper integrate routines into the ovos ecosystem.
These are just some initial deeper integration ideas I have for routines:
Skill provides voice interface
Move all internal routine management logic from the skill interface to a PHAL Plugin: (what are PHAL plugins? https://github.com/OpenVoiceOS/community-docs#what-is-phal), PHAL plugins in ovos world are also platform integrations and allow for more abstract services that act as intercommunication API's for internals ("this is where i see routines logic living as a service")
Moving the routines logic to a PHAL plugin and making it an always available service also lets us incorporate this with external applications like KDE Connect so routines can be controlled even from an android phone
Add routines as a tabbed interface on our homescreen quick access dashboard
It also seems you do have a GUI interface also for the routines skill already 😄 makes it already much easier to integrate with
What our homescreen dashboard looks like:
If this sounds like an interesting idea to you and everyone working on this or if you got any feedback on this or some cooler integration ideas, do join us on our matrix dev chat channel to discuss and participate :)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.