This would be amazing, perhaps as “helpers”. Simple example would be making a sensor from an attribute.
Having the AI “type what you want” type approach that would auto write the template based on a user writing what they want (eg if this sensor and this sensor is off) would be the icing on the cake.
It’d be nice if the UI prompted for template strings and showed a preview (similar to Developer Tools » Templates). That’d make creating the helpers so much easier.
It would be nice if /developer-tools/template had a button “make a helper out of it”
Or the template helper creation panel would just work the way the developer tools work - because they are awesome
Having simple YAML editor + scratchpad with preview (like Developer Tools → Templates) is sufficient as a first version. It can be developed further later.
I find, especially when working with new users, that trying to create template sensors with some basic mathematics is complex, for example adding two sensors together or multiplying a sensor by a constant value.
A UI helper which creates template sensor by combining the values of other sensors would be very useful.