github.com/instill-ai/component@v0.16.0-beta/schema.json (about)

     1  {
     2    "$defs": {
     3      "instill_types": {
     4        "bounding_box": {
     5          "additionalProperties": false,
     6          "description": "The detected bounding box in (left, top, width, height) format.",
     7          "instillFormat": "structured/bounding_box",
     8          "properties": {
     9            "height": {
    10              "description": "Bounding box height value",
    11              "instillFormat": "number",
    12              "instillUIOrder": 3,
    13              "title": "Height",
    14              "type": "number"
    15            },
    16            "left": {
    17              "description": "Bounding box left x-axis value",
    18              "instillFormat": "number",
    19              "instillUIOrder": 0,
    20              "title": "Left",
    21              "type": "number"
    22            },
    23            "top": {
    24              "description": "Bounding box top y-axis value",
    25              "instillFormat": "number",
    26              "instillUIOrder": 1,
    27              "title": "Top",
    28              "type": "number"
    29            },
    30            "width": {
    31              "description": "Bounding box width value",
    32              "instillFormat": "number",
    33              "instillUIOrder": 2,
    34              "title": "Width",
    35              "type": "number"
    36            }
    37          },
    38          "required": [
    39            "left",
    40            "top",
    41            "width",
    42            "height"
    43          ],
    44          "title": "Bounding Box",
    45          "type": "object"
    46        },
    47        "chat_messages": {
    48          "instillFormat": "array:structured/chat_messages",
    49          "items": {
    50            "instillFormat": "structured/chat_message",
    51            "properties": {
    52              "content": {
    53                "$ref": "#/$defs/instill_types/multi_modal_content",
    54                "description": "The message content",
    55                "instillUIOrder": 1,
    56                "title": "Content"
    57              },
    58              "metadata": {
    59                "additionalProperties": true,
    60                "description": "The message metadata",
    61                "instillFormat": "semi-structured/object",
    62                "instillUIOrder": 2,
    63                "required": [],
    64                "title": "Metadata",
    65                "type": "object"
    66              },
    67              "role": {
    68                "description": "The message role, i.e. 'system', 'user' or 'assistant'",
    69                "instillFormat": "string",
    70                "instillUIOrder": 0,
    71                "title": "Role",
    72                "type": "string"
    73              }
    74            },
    75            "required": [
    76              "role",
    77              "content"
    78            ],
    79            "type": "object"
    80          },
    81          "title": "Chat Message",
    82          "type": "array"
    83        },
    84        "classification": {
    85          "additionalProperties": false,
    86          "properties": {
    87            "category": {
    88              "description": "The predicted category of the input.",
    89              "instillFormat": "string",
    90              "instillUIOrder": 0,
    91              "title": "Category",
    92              "type": "string"
    93            },
    94            "score": {
    95              "description": "The confidence score of the predicted category of the input.",
    96              "instillFormat": "number",
    97              "instillUIOrder": 1,
    98              "title": "Score",
    99              "type": "number"
   100            }
   101          },
   102          "required": [
   103            "category",
   104            "score"
   105          ],
   106          "type": "object"
   107        },
   108        "detection": {
   109          "additionalProperties": false,
   110          "properties": {
   111            "objects": {
   112              "description": "A list of detected objects.",
   113              "instillFormat": "array:structured/detection_object",
   114              "instillUIOrder": 0,
   115              "items": {
   116                "additionalProperties": false,
   117                "instillFormat": "structured/detection_object",
   118                "properties": {
   119                  "bounding_box": {
   120                    "$ref": "#/$defs/instill_types/bounding_box",
   121                    "instillUIOrder": 1,
   122                    "title": "Bounding box"
   123                  },
   124                  "category": {
   125                    "description": "The predicted category of the bounding box.",
   126                    "instillFormat": "string",
   127                    "instillUIOrder": 2,
   128                    "title": "Category",
   129                    "type": "string"
   130                  },
   131                  "score": {
   132                    "description": "The confidence score of the predicted category of the bounding box.",
   133                    "instillFormat": "number",
   134                    "instillUIOrder": 3,
   135                    "title": "Score",
   136                    "type": "number"
   137                  }
   138                },
   139                "required": [
   140                  "bounding_box",
   141                  "category",
   142                  "score"
   143                ],
   144                "title": "Object",
   145                "type": "object"
   146              },
   147              "title": "Objects",
   148              "type": "array"
   149            }
   150          },
   151          "required": [
   152            "objects"
   153          ],
   154          "type": "object"
   155        },
   156        "embedding": {
   157          "instillFormat": "array:number",
   158          "items": {
   159            "instillFormat": "number",
   160            "title": "Embedding",
   161            "type": "number"
   162          },
   163          "title": "Embedding",
   164          "type": "array"
   165        },
   166        "instance_segmentation": {
   167          "additionalProperties": false,
   168          "properties": {
   169            "objects": {
   170              "description": "A list of detected instance bounding boxes.",
   171              "instillFormat": "array:structured/instance_segmentation_object",
   172              "instillUIOrder": 0,
   173              "items": {
   174                "instillFormat": "structured/instance_segmentation_object",
   175                "properties": {
   176                  "bounding_box": {
   177                    "$ref": "#/$defs/instill_types/bounding_box",
   178                    "instillUIOrder": 1,
   179                    "title": "Bounding Box"
   180                  },
   181                  "category": {
   182                    "description": "The predicted category of the bounding box.",
   183                    "instillFormat": "string",
   184                    "instillUIOrder": 2,
   185                    "title": "Category",
   186                    "type": "string"
   187                  },
   188                  "rle": {
   189                    "description": "Run Length Encoding (RLE) of instance mask within the bounding box.",
   190                    "instillFormat": "string",
   191                    "instillUIOrder": 0,
   192                    "title": "RLE",
   193                    "type": "string"
   194                  },
   195                  "score": {
   196                    "description": "The confidence score of the predicted instance object.",
   197                    "instillFormat": "number",
   198                    "instillUIOrder": 3,
   199                    "title": "Score",
   200                    "type": "number"
   201                  }
   202                },
   203                "required": [
   204                  "rle",
   205                  "bounding_box",
   206                  "category",
   207                  "score"
   208                ],
   209                "title": "Object",
   210                "type": "object"
   211              },
   212              "title": "Objects",
   213              "type": "array"
   214            }
   215          },
   216          "required": [
   217            "objects"
   218          ],
   219          "type": "object"
   220        },
   221        "keypoint": {
   222          "additionalProperties": false,
   223          "properties": {
   224            "objects": {
   225              "description": "A list of keypoint objects, a keypoint object includes all the pre-defined keypoints of a detected object.",
   226              "instillFormat": "array:structured/keypoint_object",
   227              "instillUIOrder": 0,
   228              "items": {
   229                "instillFormat": "structured/keypoint_object",
   230                "properties": {
   231                  "bounding_box": {
   232                    "$ref": "#/$defs/instill_types/bounding_box",
   233                    "instillUIOrder": 2,
   234                    "title": "Bounding Box"
   235                  },
   236                  "keypoints": {
   237                    "description": "A keypoint group is composed of a list of pre-defined keypoints of a detected object.",
   238                    "instillUIOrder": 0,
   239                    "items": {
   240                      "instillUIOrder": 0,
   241                      "properties": {
   242                        "v": {
   243                          "description": "visibility score of the keypoint.",
   244                          "instillFormat": "number",
   245                          "instillUIOrder": 2,
   246                          "type": "number"
   247                        },
   248                        "x": {
   249                          "description": "x coordinate of the keypoint.",
   250                          "instillFormat": "number",
   251                          "instillUIOrder": 0,
   252                          "type": "number"
   253                        },
   254                        "y": {
   255                          "description": "y coordinate of the keypoint.",
   256                          "instillFormat": "number",
   257                          "instillUIOrder": 1,
   258                          "type": "number"
   259                        }
   260                      },
   261                      "required": [
   262                        "x",
   263                        "y",
   264                        "v"
   265                      ],
   266                      "title": "Keypoints",
   267                      "type": "object"
   268                    },
   269                    "title": "Keypoints",
   270                    "type": "array"
   271                  },
   272                  "score": {
   273                    "description": "The confidence score of the predicted object.",
   274                    "instillFormat": "number",
   275                    "instillUIOrder": 1,
   276                    "title": "Score",
   277                    "type": "number"
   278                  }
   279                },
   280                "required": [
   281                  "keypoints",
   282                  "score",
   283                  "bounding_box"
   284                ],
   285                "title": "Object",
   286                "type": "object"
   287              },
   288              "title": "Objects",
   289              "type": "array"
   290            }
   291          },
   292          "required": [
   293            "objects"
   294          ],
   295          "type": "object"
   296        },
   297        "multi_modal_content": {
   298          "instillFormat": "structured/multi_modal_content",
   299          "items": {
   300            "properties": {
   301              "image_url": {
   302                "properties": {
   303                  "url": {
   304                    "description": "Either a URL of the image or the base64 encoded image data.",
   305                    "type": "string"
   306                  }
   307                },
   308                "required": [
   309                  "url"
   310                ],
   311                "type": "object"
   312              },
   313              "text": {
   314                "description": "The text content.",
   315                "instillFormat": "string",
   316                "type": "string"
   317              },
   318              "type": {
   319                "description": "The type of the content part.",
   320                "enum": [
   321                  "text",
   322                  "image_url"
   323                ],
   324                "instillFormat": "string",
   325                "type": "string"
   326              }
   327            },
   328            "required": [
   329              "type"
   330            ],
   331            "type": "object"
   332          },
   333          "type": "array"
   334        },
   335        "ocr": {
   336          "additionalProperties": false,
   337          "properties": {
   338            "objects": {
   339              "description": "A list of detected bounding boxes.",
   340              "instillFormat": "array:structured/ocr_object",
   341              "instillUIOrder": 0,
   342              "items": {
   343                "instillFormat": "structured/ocr_object",
   344                "properties": {
   345                  "bounding_box": {
   346                    "$ref": "#/$defs/instill_types/bounding_box",
   347                    "instillUIOrder": 0,
   348                    "title": "Bounding Box"
   349                  },
   350                  "score": {
   351                    "description": "The confidence score of the predicted object.",
   352                    "instillFormat": "number",
   353                    "instillUIOrder": 2,
   354                    "title": "Score",
   355                    "type": "number"
   356                  },
   357                  "text": {
   358                    "description": "Text string recognised per bounding box.",
   359                    "instillFormat": "string",
   360                    "instillUIOrder": 1,
   361                    "title": "Text",
   362                    "type": "string"
   363                  }
   364                },
   365                "required": [
   366                  "bounding_box",
   367                  "text",
   368                  "score"
   369                ],
   370                "title": "Object",
   371                "type": "object"
   372              },
   373              "title": "Objects",
   374              "type": "array"
   375            }
   376          },
   377          "required": [
   378            "objects"
   379          ],
   380          "type": "object"
   381        },
   382        "semantic_segmentation": {
   383          "additionalProperties": false,
   384          "properties": {
   385            "stuffs": {
   386              "description": "A list of RLE binary masks.",
   387              "instillFormat": "array:structured/semantic_segmentation_stuff",
   388              "instillUIOrder": 0,
   389              "items": {
   390                "instillFormat": "structured/semantic_segmentation_stuff",
   391                "properties": {
   392                  "category": {
   393                    "description": "Category text string corresponding to each stuff mask.",
   394                    "instillFormat": "string",
   395                    "instillUIOrder": 1,
   396                    "title": "Category",
   397                    "type": "string"
   398                  },
   399                  "rle": {
   400                    "description": "Run Length Encoding (RLE) of each stuff mask within the image.",
   401                    "instillFormat": "string",
   402                    "instillUIOrder": 0,
   403                    "title": "RLE",
   404                    "type": "string"
   405                  }
   406                },
   407                "required": [
   408                  "rle",
   409                  "category"
   410                ],
   411                "title": "Object",
   412                "type": "object"
   413              },
   414              "title": "Stuffs",
   415              "type": "array"
   416            }
   417          },
   418          "required": [
   419            "stuffs"
   420          ],
   421          "type": "object"
   422        }
   423      }
   424    }
   425  }