AI Vision Extract

The Artificial Intelligence Vision Extract block enables automated data extraction from images using AI, allowing testers to retrieve relevant information without manual inspection.

It supports extracting text, numbers, or visual elements from uploaded or referenced images, making it highly valuable in scenarios involving OCR, validation of image-based workflows, or automation testing across UI components.

image-20260207-125111.png

Notes:

  • The screenshot on this page uses the Elegance Design, introduced in 2025.3. If you are using an earlier version, your layout may look different.

  • To use this block, cloud blocks must be activated for your tenant in the add-ons section of Customer Portal. Make sure this is enabled before adding the block to your flows.

  • AI accuracy is not guaranteed, as it relies on probabilities and the daily performance of OpenAI’s technology. Occasional inaccuracies may occur due to inherent limitations of the technology. For more details, please refer to OpenAI’s documentation.

Quick-start

  1. Drag AI Vision Extract onto the canvas.

  2. Choose a Source type (Image File or Local Path).

  3. Provide the image input either by upload or via file path.

  4. Enter an Action Prompt describing what information to extract (e.g., invoice number, product label, expiry date).

  5. Use Add field to extract to create one field for each item you want to capture.

  6. Connect the green input and output connectors.

  7. Run the flow when it’s ready.

Building block parameters

Parameters
  • Block header: The green input connector triggers the block to start executing. The green output connector triggers when the block execution is complete. The block title (“AI Vision Extract”) can be renamed by double-clicking it and typing in a new title.

  • File Input: Lets the block connect to the File Output of other blocks, supporting image-processing workflows where an upstream block provides the image file.

  • Source Type: Selects where the image comes from:

    • Image File: The image is uploaded and stored inside Leapwork.

    • Local Path: The image is referenced from a specified path without being uploaded.

  • Prompt: The criteria for the extraction. Use this field to define what you want to extract from the image (for example text, numbers, or specific visual elements).

  • Add field to extract: Adds a new field to map extracted data from the image. The extracted field can be used as an output in other blocks for further processing.

  • Default timeout: Controls whether the block uses the flow’s default timeout or a fixed timeout. If the checkbox is not selected, the timeout is 30 seconds. If the checkbox is selected, the Default timeout value from the flow settings applies.

  • Timeout: The maximum time spent extracting the specified information before giving up and triggering Failed. This is separate from the case global timeout in Settings, which can cancel a run if the whole case exceeds it.

  • Failed: Triggers if the block does not extract the specified information within the configured timeout, so you can branch the flow (for example, retry, log, or fail the case).

Resources

Topic

Description

Flows FAQ

Common questions about creating, running, and managing flows in Leapwork.

Flows Troubleshooting

Guidelines and solutions for identifying and fixing issues that occur when building or running flows in Leapwork.

Customer Portal Add-ons

Customer portal section to activate your cloud blocks.

Guidelines for using AI blocks

Common guidelines for prompting, generating, validating, extracting, and transforming AI-driven test data in Leapwork’s AI Blocks.