Studio Editor: Using the AI Assistant to Add Custom Code
6 min
In this article
- Adding custom behavior with AI
- Reverting code changes done by AI
- FAQs
Currently, this feature is in alpha mode.
Add custom code behaviors to elements, without any coding experience, using our AI assistant. Whether you're enhancing interactivity or creating tailored experiences, AI makes it simple. Focus on your creative vision while the assistant handles the technical coding, offering suggestions or implementing your own ideas.
How can I access the AI assistant?

Adding custom behavior with AI
Access the AI assistant from the Code panel, or right-click the specific element you want to customize. The assistant will send an initial message on your behalf – ‘What interactive behavior can you apply to (element ID)?’— and offer tailored suggestions based on the element.
Pick a suggested behavior or describe the customization you have in mind. You’ll always have the chance to preview and approve the code before it’s added to your client’s site.
To add custom behavior with AI:
- Go to your editor.
- Right-click the relevant element.
- Select Add Custom Behavior with AI.
Tip: This opens the chat with the AI assistant (within the Code panel) on the left side of the editor. - Review the AI assistant's suggestions for custom behaviors it can add.
- Describe what you want to customize and click the Send icon
.
Tip: It doesn't have to be one of the suggestions if you had a different idea in mind. The AI assistant will evaluate and advise if it can add the customization you're thinking of. - Choose what to do next:
- Refine the customization: Continue chatting to the AI assistant to clarify the specific customization you want it to add.
- Preview the code: Click Show code to see the code AI intends to add. It also provides a breakdown of what the code does, clarifying how it applies the customization.
- Add the code: Add the code to your client's site.
- Click Add code.
- Click Approve to confirm adding the code.
What's next?
- Click Preview under Generated Code to see how your customization looks.
- You can always click the New Chat icon
to start a conversation about another customization you want AI to make.

Reverting code changes done by AI
Restore your client's site to its previous state if you want to undo changes made by the AI assistant. You can access your chat history with the assistant and revert any generated code back to an earlier version.
To restore the code to the previous state:
- Go to your editor.
- Click Code
on the left side of the editor.
- Click AI Assistant.
- Click the More Actions icon
at the top right of the code panel.
- Select Show chat history.

- Select the relevant conversation.
- Click Restore under the relevant Generated Code section.

FAQs
Click a question below to learn more.
Are there customizations that are not supported?
The AI assistant gave me a list of element IDs (e.g. 'box 3', 'section1') - how do I find these?