#Historical data

1 messages · Page 1 of 1 (latest)

nocturne surge
#

Morning all, got assist working really well with openAI …. Is they a way for it to see historical data ?

For example this is my request :

What has the temperature been like in my room for the past 24hours.

Gets the response of what the current temp is and unfortunately not able to see historical data.

oblique totem
#

I don't think so. You could however create a script that outputs the historical data of a temperature sensor and expose that script to Assist. Provide a good description in the script, that typically helps for AI to pick it up and use it correctly.

#
nocturne surge
#

Grand thank you, I’ll have a look into that tonight

oblique totem
#

At a closer look, this might not be as trivial as I thought it to be. You can only fetch historical data via the SQL integration (https://www.home-assistant.io/integrations/sql/#state-of-an-entity-x-time-ago). This makes it rather static, as you'd have to create a new SQL query sensor with a fixed input sensor and a fixed time range. Also the SQL integration is designed to output 1 value not an array of multiple values. I think that route is rather hacky.

Home Assistant
SQL

Instructions how to integrate SQL sensors into Home Assistant.