The new Smart edit actions in Pinegrow AI Assistant let you efficiently edit HTML documents without regenerating the whole document or section.
What’s so smart about it?
Instead of simply regenerating the updated code (as is the case with the Transform action), Smart HTML Edit sends the code of the whole page to the AI model and provides the model with tools to update specific elements, remove elements, set attributes and more.
This lets the AI model do the task faster and with less output tokens.
A strong AI model is required because this approach is much more complex compared to just generating code. Recommended and tested models are:
Claude Sonnet 3.7
(best),OpenAI o3-mini
andOpenAI gpt-4.1
.
Choosing between editing the whole page or just the selected element
To access the new actions, click on the Action selector:
Then, under Smart HTML Edit, choose Pages or Element:
Pages lets AI Assistant edit the whole current page as well as all pages that are open in the editor. The selected element can be used as a reference in the prompt (for example, select multiple headings and ask the assistant to “Make them more readable.”).
The drawback is that the code of the whole page needs to be sent to the AI model. Pinegrow is using token caching where available, but still the number of input tokens can quickly balloon with this method, depending on the size of the document.
Element limits the editing to just the selected element. If you know that editing is contained to just a particular section and no context outside of it is needed, than this is a good way to reduce costs. Selected elements can not be used as references with this approach.
Watch the video guide
Watch this action packed video to see examples and learn how to use the Smart HTML Editing: