Skip to main content

Block

A Snippet is made up of one or more Blocks which are connected in sequence, with each block taking inputs from the previous block and producing outputs for the next one.

As the screenshots below show:

A block is made up of four distinct parts: Input, Output, Variable Declaration, and Specific Block Configuration. Some blocks may not have all of these parts.

Input

Input declares the necessary information that the block requires to perform its specific function.

Input are made up of Parameters, and Parameters are made up of Primitive Types.

Output

This section defines what the block will output after processing the input.

Output are made up of Parameters, and Parameters are made up of Primitive Types.

Variable Declaration

Here, variables used within the block are declared and defined. All variable declared is available to next following blocks.

Variable Declarations are made up of Parameters, and Parameters are made up of Primitive Types.

Configuration about Specific Block

This section includes any unique configuration that is specific to this particular block. For example, the AI Model Application Block has the following configuration:

  1. URL
  2. Model Type
  3. Result Confirmer
  4. Confidence Threshold

Parameters and Primitive Types

A Parameter consists of one Primitive Type or a collection of Primitive Types. Currently there are 5 Primitive Types:

  1. any: any type of data
  2. array: an array of any primitive type
  3. string: a string of characters
  4. number: a number
  5. data: consist of bytes
  6. image: an image
  7. visionObservation: a vision observation
  8. textObservation: a text observation

Specific blocks may not have all of these Primitive Types available. For example, the Photo Libray Block can only accept image as output.