MycroftAI / mycroft-core

Mycroft Core, the Mycroft Artificial Intelligence platform.
https://mycroft.ai
Apache License 2.0
6.49k stars 1.27k forks source link

Intent support relative dates #135

Closed alexrallen closed 8 years ago

alexrallen commented 8 years ago

Mycroft weather skill should to be able to take datetimes of any form as input and needs to be able to understand them. This should also apply to any other skill requiring a datetime.

Example:

What is the weather like in two weeks?
What is the weather like in 3 days?
Will it storm in the next week?

The general idea being that skills such as the weather, should parse datetimes the same way that the alarm skill does. The actual parsing is mostly implemented with "time_rules" although the actual code needs to be added to the intent builders of the skills that need it.

I propose perhaps adding time_rules and time processing (Such as is in "ScheduledSkills") to the intent system so that one can require a "datetime" that the intent system can parse and send back to the skill. However, I am not sure how features of this type are planned to be implemented so I would like feedback from the team on this idea before trying it.

Either way the weather command definitely needs this feature.

alexrallen commented 8 years ago

If the Mycroft team thinks this is worth integrating in with Intents I can start work on that. If y'all would rather keep it separate on a skill by skill basis I can start working on the weather skill individually too. I think its something that will eventually be needed by many skills though and should be a part of Mycroft's understanding of your input in general.

grahamreeds commented 8 years ago

A Google search I use regularly is to see the weather at a particular location at a particular time.

So asking "Mycroft, what is the weather like on Sunday?" would hopefully ellicit a response after checking a calendar, see I am at Teesside Autodrome and then look up the weather for the racetrack and not a generalist response for the day.

GR

Sent from my Nexus 5. On 12 Jun 2016 3:43 a.m., "RobodudeMC" notifications@github.com wrote:

If the Mycroft team thinks this is worth integrating in with Intents I can start work on that. If y'all would rather keep it separate on a skill by skill basis I can start working on the weather skill individually too. I think its something that will eventually be needed by many skills though and should be a part of Mycroft's understanding of your input in general.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/MycroftAI/mycroft-core/issues/135#issuecomment-225406403, or mute the thread https://github.com/notifications/unsubscribe/AEy9nKETwKwi_baVr1lDWfgOcVXZVat-ks5qK3JXgaJpZM4IzpFj .

clusterfudge commented 8 years ago

@robocoder99 We have most of what you're asking for (with respect to relative dates) in our reminders and alarm skills. It is based on parsedatetime and implemented within mycroft, but our longer term solution is to push datetimes as a first class citizen down into Adapt. Until datetimes exist within Adapt, it would be difficult to do this well. I have opened https://github.com/MycroftAI/adapt/issues/30 to track there.

Currently the weather skill supports current weather, 3-day forecast, and 5 days(?) forecast, as a mirroring of the weather functionality we have from OWM APIs.

alexrallen commented 8 years ago

@clusterfudge I will close this for the time being as it is an Adapt problem more than an Mycroft one for now.

clusterfudge commented 8 years ago

cool. Feel free to watch the adapt ticket for updates!