Flow Metadata & AI Assistant

Overview

Flow Metadata & AI Assistant is a combined metadata and prompt-generation feature for Salesforce Flow Builder.

It provides a side-panel experience that helps users:

The feature is designed to support documentation, design analysis, testing, improvement review, and diagram generation workflows.

Flow Metadata & AI Assistant Module

Where it appears

Flow Metadata & AI Assistant is intended for Salesforce Flow Builder.

When activated, it opens a panel overlay titled:

Flow Metadata & Flow Metadata & AI Assistant

The panel is displayed over the current Flow Builder page and can be closed by:

What the feature does

Flow Metadata & AI Assistant currently provides the following functionality:

  1. Detects that the user is in Flow Builder.
  2. Opens a dedicated panel overlay when activated.
  3. Retrieves the current Flow metadata using the current Flow ID.
  4. Builds both a raw metadata object and a cleaned metadata version.
  5. Displays a high-level Flow summary.
  6. Provides metadata copy and download actions.
  7. Lets the user choose an AI prompt template.
  8. Lets the user choose between raw and cleaned metadata.
  9. Shows an estimated token count for the assembled prompt.
  10. Copies the assembled prompt to the clipboard for use in an external AI tool.

Panel sections

The panel is currently divided into three main sections.

Flow Summary

The Flow Summary section displays core metadata about the current Flow, including:

This gives the user a quick overview before choosing whether to copy metadata or generate a prompt.

Flow Metadata

The metadata section provides actions for working with the current Flow metadata directly.

It currently shows:

It also provides action buttons for:

AI Prompt Assistant

The AI Prompt Assistant section allows the user to:

Flow Metadata & AI Assistant Summary/Metadata Sections

Metadata formats

AI Assistant currently supports two metadata formats.

Raw metadata

Raw metadata is the Flow metadata returned directly from the source record.

This format is useful when the user wants the fullest available JSON representation.

Clean metadata

Clean metadata is a processed version of the Flow metadata.

The cleaned version is intended to reduce unnecessary payload and improve usefulness for AI-assisted workflows by focusing on the parts most likely to matter.

The panel also shows an estimated token saving percentage to help users choose between raw and cleaned JSON.

Metadata actions

The current metadata actions are:

Copy actions

Copy actions place the selected JSON content onto the clipboard.

If the normal clipboard API is not available, the feature includes a fallback copy approach.

Download actions

Download actions create a downloadable JSON file using the current Flow name.

Generated filenames follow this pattern:

Prompt templates

The AI Assistant includes a registry of prompt templates that can be selected from a dropdown.

Current templates include:

Each template includes:

When a template is selected, the assistant assembles the final prompt by combining the template prompt text with either the raw or cleaned metadata JSON.

Flow Metadata & AI Assistant Prompt Template Section

Flow Metadata & AI Assistant Prompt Template Section Options

Current prompt template purposes

Summarise Flow

Produces a plain-English summary of the Flow intended to be suitable for a Salesforce Flow description.

Generate Flow, Element, and Resource Descriptions

Produces structured documentation output including:

Generate Draw.io Diagram

Produces Draw.io compatible XML intended to represent the Flow visually.

Suggest Improvements

Analyses the Flow against best-practice themes such as:

Generate Test Scenarios

Produces structured test scenarios intended to exercise Flow paths, branches, edge cases, and fault handling.

Token estimation

AI Assistant shows estimated token counts to help users judge prompt size before copying content into an AI tool.

The token estimate updates when:

This helps users compare the likely size impact of:

How to use it

  1. Open a Flow in Salesforce Flow Builder.
  2. Launch AI Assistant from the extension.
  3. Wait for the current Flow metadata to be retrieved.
  4. Review the Flow Summary section if needed.
  5. Choose whether you want to work with raw or cleaned metadata.
  6. Select a prompt template.
  7. Review the token estimate.
  8. Click Copy Prompt to Clipboard.
  9. Paste the copied prompt into your preferred AI tool.

You can also use the panel purely for metadata operations without using the prompt-generation section.

User feedback

The panel includes a status area that is used to show action feedback such as:

If metadata retrieval fails, the panel shows an explicit error message instead of the normal content.

Notes and limitations

Current implementation notes:

Settings behaviour

The current implementation reads a default AI template setting from storage.

This means the prompt template dropdown can open with a configured default selection rather than always starting from the same template.

Accessibility and usability notes

The current implementation includes: