Model Composition

The main function of the Design Studio is to compose the ML Models to produce a meaningful application.

Criteria for Model Composition

Currently the Design Studio implements a simple model composition strategy based on matching the output message of the output port of one ML Model to the input message of the input port of another ML Model.

In the Design Studio a pair of ports are compatible if the requirement of one port can be matched with the capability of another port. Or if the output of one model can be consumed by the input port of another model so as to get some service from the latter.

The matching criterion is based on comparing the Protobuf message signature of the output port to the message signature of the input port of another model.

A pair of output and input messages are compatible if all the following conditions are satisfied:

  1. The number of tags in both their message signatures is the same
  2. For each tag number, the fields on both the sides are of the same type
  3. For each tag number, the fields on both the sides have the same role – repeated, optional, etc.

NOTE: the field names are not taken into consideration for determining compatibility.

A pair of output and input ports are compatible, if all the following conditions are satisfied:

  1. They both produce and consume identical number of messages
  2. Each message on one side is compatible with another message on another side, as per the compatibility definition given above

NOTE: the message names are not taken into consideration for determining the compatibility.