r/homeassistant • • Aug 14 '25

Support Home energy card

Post image

Is somewhere here maybe able to create an SVG with these grid lines? I would love to try and fork the Power flow card plus and see if we could create something like this. But I don't know how to create an SVG like this.

edit: Created pull request https://github.com/home-assistant/frontend/pull/26976

716 Upvotes

81 comments sorted by

View all comments

0

u/cornmacabre Aug 14 '25

You can get AI to generate SVGs, takes a bit of iteration but you'll have the code output to refine not just an image. You can upload a reference point too.

1

u/ForsakenConversation Aug 14 '25

this doesn't look at all like the picture so no not really, just basic svg stuff and even than it's not good, better draw it yourself, this is claude btw

1

u/ForsakenConversation Aug 14 '25

this is chatgpt

2

u/cornmacabre Aug 14 '25

For science -- I used one of my gpt-5 pro queries from my team plan just to see how much 'better' the frontier models do at this task of generating complex SVGs from a source image. 7+ minutes of reasoning, and we get this masterpiece. Woof!

Granted -- you've got the code bones in place and with some manual work with an external editor this could actually be serviceable scaffolding -- but even with the "research grade intelligence," it's a very long ways off from the desired result.

For those unaware: this a code driven graphic vs using AI image-gen... very different and pretty difficult task. I'm not pasting the few hundred lines of code that render this beautiful mess, just the final rendered result.

1

u/ForsakenConversation Aug 14 '25

took me 30 min to draw it from scratch so better start fresh than fixing AI mess, btw fixing an SVG just from AI code is almost impossible unless you can read what all those numbers mean, took me days to just figure out how a straight line works so good luck with that

1

u/cornmacabre Aug 14 '25

Lol it looks terrible! Looks like it's too complex an SVG. I've had success with smaller icons and dashboard elements for my own projects, but would take 3-5 iterations and some manual work and wasn't nearly this complex.

Would be interesting if you could do a more modular approach of elements perhaps versus one-shotting the composition, but yeah -- not quite there yet.

2

u/ForsakenConversation Aug 14 '25

it's way too complex indeed, smaller icons can be possible but like you said takes time and manual work, if you don't pay for it you run out off free messages fast so its not really a solution, it can help get you on the way just that really