Hacker News new | past | comments | ask | show | jobs | submit login

We've thought about this question a lot at Mito[1], where we're building a spreadsheet that code-gens Python code for you as you edit it. For us, it's been useful to decompose the question of "what code-gen is good for" into a few sub-questions that help us think about how generative AI approaches effect us:

1. Why is it necessary to generate code in the first place? Can you just skip to the "solution?" 2. Why is just writing the code by the hand not the best solution? 3. So you do want to do code-gen, does it make sense to do it in a chat interface, or can we do better?

As a Figma user, I'd answer these in the following way:

> Why is it necessary to generate code in the first place?

Because mockups aren't your production website, and your production website is written in code. But maybe this is just for now?

I'm sure some high-up PM at Figma has this as their goal - mockup the website in Figma, it generates the code for a website (you don't see this code!), and then you can click deploy _so easily_. Who wants to bet that hosting services like Vercel etc reach out to Figma once a week to try and pitch them...

In the meantime, while we have websites that don't fit neatly inside Figma constraints, while developers are easier to hire than good designers (in my experience), while no-code tools are continually thought of as limiting and a bad long-term solution -- Figma code export is good.

> Why is just writing the code by the hand not the best solution?

For the majority of us full-stack devs who have written >0 CSS but are less than masters, I'll leave this as self-evident.

> So you do want to do code-gen, does it make sense to do it in a chat interface, or can we do better?

In the case of Figma, if they were a new startup with no existing product and they were trying to "automation UI creation" -- v1 of their interface probably would be a "describe your website" and then we'll generate the code for it.

This would probably suck. What if you wanted to easily tweak the output? What if you had trouble describing what you wanted, but you could draw it (ok, OpenAI vision might help on this one)? What if you had experience with existing design tools you could use to augment the AI. A chat interface is not the best interface for design work.

ChatGPT-style code-generation is like v0.1. Github Copilot is an example of next step - it's not just a chat interface, it's something a bit more integrated into an environment that make sense in the context of the work you're doing. For design work, a canvas (literally! [2]) like Figma is well-suited as an environment for code-gen that can augment (and maybe one day replace) the programmers working on frontend. For tabular data work, we think a spreadsheet is the interface where users want to be, and the interface it makes sense to bring code-gen to.

Any thoughts appreciated!

[1] https://trymito.io, https://github.com/mito-ds/mito [2] https://www.figma.com/blog/building-a-professional-design-to...




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: