diff options
Diffstat (limited to 'app/graphql/types/ml/model_type.rb')
-rw-r--r-- | app/graphql/types/ml/model_type.rb | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/app/graphql/types/ml/model_type.rb b/app/graphql/types/ml/model_type.rb new file mode 100644 index 00000000000..2d686b185dd --- /dev/null +++ b/app/graphql/types/ml/model_type.rb @@ -0,0 +1,19 @@ +# frozen_string_literal: true + +module Types + module Ml + # rubocop: disable Graphql/AuthorizeTypes -- authorization in ModelDetailsResolver + class ModelType < ::Types::BaseObject + graphql_name 'MlModel' + description 'Machine learning model in the model registry' + + field :id, ::Types::GlobalIDType[::Ml::Model], null: false, description: 'ID of the model.' + + field :name, ::GraphQL::Types::String, null: false, description: 'Name of the model.' + + field :versions, ::Types::Ml::ModelVersionType.connection_type, null: true, + description: 'Versions of the model.' + end + # rubocop: enable Graphql/AuthorizeTypes + end +end |