Package org.apache.gravitino.model
Interface Model
- All Superinterfaces:
Auditable
- All Known Implementing Classes:
ModelDTO
An interface representing an ML model under a schema
Namespace
. A model is a metadata
object that represents the model artifact in ML. Users can register a model object in Gravitino
to manage the model metadata. The typical use case is to manage the model in ML lifecycle with a
unified way in Gravitino, and access the model artifact with a unified identifier. Also, with the
model registered in Gravitino, users can govern the model with Gravitino's unified audit, tag,
and role management.
The difference of Model and tabular data is that the model is schema-free, and the main property of the model is the model artifact URL. The difference compared to the fileset is that the model is versioned, and the model object contains the version information.
-
Method Summary
Modifier and TypeMethodDescriptiondefault String
comment()
The comment of the model object.int
The latest version of the model object.name()
The properties of the model object.default SupportsPolicies
default SupportsRoles
default SupportsTags
-
Method Details
-
name
String name()- Returns:
- Name of the model object.
-
comment
The comment of the model object. This is the general description of the model object. User can still add more detailed information in the model version.- Returns:
- The comment of the model object. Null is returned if no comment is set.
-
properties
The properties of the model object. The properties are key-value pairs that can be used to store additional information of the model object. The properties are optional.Users can still specify the properties in the model version for different information.
- Returns:
- the properties of the model object.
-
latestVersion
int latestVersion()The latest version of the model object. The latest version is the version number of the latest model checkpoint / snapshot that is linked to the registered model.- Returns:
- The latest version of the model object.
-
supportsTags
- Returns:
- The
SupportsTags
if the model supports tag operations. - Throws:
UnsupportedOperationException
- If the model does not support tag operations.
-
supportsPolicies
- Returns:
- The
SupportsPolicies
if the model supports policy operations. - Throws:
UnsupportedOperationException
- If the model does not support policy operations.
-
supportsRoles
- Returns:
- The
SupportsRoles
if the model supports role operations. - Throws:
UnsupportedOperationException
- If the model does not support role operations.
-