Skip to content

AI assistant

Studio’s AI assistant understands your content schemas, the current entry you’re editing, and your entire project structure. It can create and edit content, modify source files, update styling, and manage pull requests — all through natural conversation with multi-turn tool execution.

The AI assistant is available from both the visual editor and the collection browser. Open it by clicking the AI Assistant button in the Studio toolbar.

The assistant is fully contextual — it automatically receives information about the current branch, the active collection’s Zod schema (as JSON Schema), and the entry you are viewing. This means you can ask questions or give instructions without needing to specify which collection or entry you are working with.

The assistant has access to 24 specialised tools organised into six categories. Each tool can be chained together in a single conversation turn, so a prompt like “create a blog post and open a pull request” triggers multiple tools in sequence.

ToolDescription
create_entryCreate a new content entry in a collection with frontmatter and body
update_entryMerge updated frontmatter fields into an existing entry without overwriting unchanged fields
patch_entry_bodyFind and replace text within an entry’s Markdown or MDX body
delete_entryRemove a content entry from a collection
list_entriesList all entries in a collection with their frontmatter summaries
get_entryRetrieve the full frontmatter and body of a specific entry
ToolDescription
list_collectionsList all content collections defined in the project
get_schemaRetrieve the Zod schema for a collection as a JSON Schema object
create_collectionCreate a new content collection with field definitions and an Astro page template
ToolDescription
read_fileRead the contents of any file in the project
write_fileCreate or overwrite a file with new content
patch_fileFind and replace text within any source file
list_filesList files in the project matching a glob pattern
create_directoryCreate a new directory in the project file tree
ToolDescription
list_mediaList all media assets available in the project
upload_mediaUpload a new media asset to the project’s media directory
ToolDescription
update_tailwind_configModify the Tailwind CSS configuration (colours, spacing, fonts, and other design tokens)
update_global_stylesEdit the project’s global stylesheet
ToolDescription
create_pull_requestOpen a new pull request from the current branch with a title and description
list_pull_requestsList open pull requests for the project
get_pull_requestRetrieve details of a specific pull request including status and reviewers
add_pr_commentAdd a comment to an existing pull request
get_pr_commentsRetrieve all comments on a pull request
get_pr_filesList the files changed in a pull request

Here are practical examples you can try with the AI assistant:

  • “Create a new blog post about getting started with Astro” — The assistant uses create_entry to scaffold a complete entry with frontmatter fields populated from the blog collection’s schema.
  • “Update the hero image on my latest post to /images/new-hero.jpg — The assistant uses update_entry to merge the new image path into the entry’s frontmatter without touching other fields.
  • “Add a category enum field to the blog schema with options: tutorial, news, opinion” — The assistant uses create_collection or modifies the schema definition to add the new field.
  • “Change the primary colour in Tailwind config to #007c64 — The assistant uses update_tailwind_config to locate and update the colour value in your Tailwind configuration.
  • “Create a pull request with my changes titled ‘New blog posts for February’” — The assistant uses create_pull_request to open a PR from your current branch with the specified title.

The AI assistant is powered by Claude with multi-turn tool calling. Each request can trigger multiple tool executions in a loop — up to 25 rounds per conversation turn — allowing the assistant to complete complex, multi-step tasks without further input.

When you send a message, the assistant receives rich context automatically:

  • Current branch — so it commits changes to the correct branch
  • Collection schema — the full Zod schema for the active collection, serialised as JSON Schema
  • Current entry — the frontmatter fields and Markdown body of the entry you are editing

Changes made by the assistant are committed directly to the current branch. When content or styles are modified, the live preview updates automatically so you can see the results immediately.

  • Code editor — Browse and edit source files directly in the Monaco-powered in-browser IDE
  • Branches and environments — Learn how Git-native branch workflows power preview environments and content review