Interface ModelVersion

All Superinterfaces:
Auditable
All Known Implementing Classes:
ModelVersionDTO

@Evolving public interface ModelVersion extends Auditable
An interface representing a single model checkpoint under a model Model. A model version is a snapshot at a point of time of a model artifact in ML. Users can link a model version to a registered model.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final String
    The property name for the default uri name of the model version.
    static final String
    The reserved URI name to indicate the URI name is unknown.
  • Method Summary

    Modifier and Type
    Method
    Description
    The aliases of this model version.
    default String
    The comment of this model version.
    default Map<String,String>
    The properties of the model version.
    default String
    uri()
    The unnamed URI of the model artifact.
    The name and corresponding URI of the model artifact.
    int
    The version of this model object.

    Methods inherited from interface org.apache.gravitino.Auditable

    auditInfo
  • Field Details

    • PROPERTY_DEFAULT_URI_NAME

      static final String PROPERTY_DEFAULT_URI_NAME
      The property name for the default uri name of the model version.
      See Also:
    • URI_NAME_UNKNOWN

      static final String URI_NAME_UNKNOWN
      The reserved URI name to indicate the URI name is unknown.
      See Also:
  • Method Details

    • version

      int version()
      The version of this model object. The version number is an integer number starts from 0. Each time the model checkpoint / snapshot is linked to the registered, the version number will be increased by 1.
      Returns:
      The version of the model object.
    • comment

      default String comment()
      The comment of this model version. This comment can be different from the comment of the model to provide more detailed information about this version.
      Returns:
      The comment of the model version. Null is returned if no comment is set.
    • aliases

      String[] aliases()
      The aliases of this model version. The aliases are the alternative names of the model version. The aliases are optional. The aliases are unique for a model version. If the alias is already set to one model version, it cannot be set to another model version.
      Returns:
      The aliases of the model version.
    • uri

      default String uri()
      The unnamed URI of the model artifact. The URI is the location of the model artifact. The URI can be a file path or a remote URI.
      Returns:
      The URI of the model artifact.
    • uris

      Map<String,String> uris()
      The name and corresponding URI of the model artifact. The key is the name of the URI, and the value is the URI of the model artifact, which can be a file path or a remote URI.

      The "unknown" URI name is reserved for the compatibility with single URI.

      Returns:
      The URIs of the model version, the key is the name of the URI and the value is the URI of the model artifact.
    • properties

      default Map<String,String> properties()
      The properties of the model version. The properties are key-value pairs that can be used to store additional information of the model version. The properties are optional.
      Returns:
      the properties of the model version.