Package org.elasticsearch.client.ml
Class GetTrainedModelsRequest
java.lang.Object
org.elasticsearch.client.ml.GetTrainedModelsRequest
- All Implemented Interfaces:
Validatable
public class GetTrainedModelsRequest extends java.lang.Object implements Validatable
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
ALLOW_NO_MATCH
static java.lang.String
DECOMPRESS_DEFINITION
static java.lang.String
FOR_EXPORT
static java.lang.String
INCLUDE
static java.lang.String
TAGS
-
Constructor Summary
Constructors Constructor Description GetTrainedModelsRequest(java.lang.String... ids)
-
Method Summary
Modifier and Type Method Description boolean
equals(java.lang.Object o)
java.lang.Boolean
getAllowNoMatch()
static GetTrainedModelsRequest
getAllTrainedModelConfigsRequest()
Helper method to create a request that will get ALL TrainedModelConfigsjava.lang.Boolean
getDecompressDefinition()
java.lang.Boolean
getForExport()
java.util.List<java.lang.String>
getIds()
java.util.Set<java.lang.String>
getIncludes()
PageParams
getPageParams()
java.util.List<java.lang.String>
getTags()
int
hashCode()
GetTrainedModelsRequest
includeDefinition()
GetTrainedModelsRequest
includeFeatureImportanceBaseline()
GetTrainedModelsRequest
includeTotalFeatureImportance()
GetTrainedModelsRequest
setAllowNoMatch(boolean allowNoMatch)
Whether to ignore if a wildcard expression matches no trained models.GetTrainedModelsRequest
setDecompressDefinition(java.lang.Boolean decompressDefinition)
Whether or not to decompress the trained model, or keep it in its compressed string formGetTrainedModelsRequest
setForExport(java.lang.Boolean forExport)
Setting this flag to `true` removes certain fields from the model definition on retrieval.GetTrainedModelsRequest
setIncludeDefinition(java.lang.Boolean includeDefinition)
Deprecated.GetTrainedModelsRequest
setPageParams(PageParams pageParams)
GetTrainedModelsRequest
setTags(java.lang.String... tags)
SeesetTags(List)
GetTrainedModelsRequest
setTags(java.util.List<java.lang.String> tags)
The tags that the trained model must match.java.util.Optional<ValidationException>
validate()
Perform validation.
-
Field Details
-
ALLOW_NO_MATCH
public static final java.lang.String ALLOW_NO_MATCH- See Also:
- Constant Field Values
-
FOR_EXPORT
public static final java.lang.String FOR_EXPORT- See Also:
- Constant Field Values
-
DECOMPRESS_DEFINITION
public static final java.lang.String DECOMPRESS_DEFINITION- See Also:
- Constant Field Values
-
TAGS
public static final java.lang.String TAGS- See Also:
- Constant Field Values
-
INCLUDE
public static final java.lang.String INCLUDE- See Also:
- Constant Field Values
-
-
Constructor Details
-
GetTrainedModelsRequest
public GetTrainedModelsRequest(java.lang.String... ids)
-
-
Method Details
-
getAllTrainedModelConfigsRequest
Helper method to create a request that will get ALL TrainedModelConfigs- Returns:
- new
GetTrainedModelsRequest
object for the id "_all"
-
getIds
public java.util.List<java.lang.String> getIds() -
getAllowNoMatch
public java.lang.Boolean getAllowNoMatch() -
setAllowNoMatch
Whether to ignore if a wildcard expression matches no trained models.- Parameters:
allowNoMatch
- If this isfalse
, then an error is returned when a wildcard (or_all
) does not match any trained models
-
getPageParams
-
setPageParams
-
getIncludes
public java.util.Set<java.lang.String> getIncludes() -
includeDefinition
-
includeTotalFeatureImportance
-
includeFeatureImportanceBaseline
-
setIncludeDefinition
@Deprecated public GetTrainedModelsRequest setIncludeDefinition(java.lang.Boolean includeDefinition)Deprecated.Whether to include the full model definition. The full model definition can be very large.- Parameters:
includeDefinition
- Iftrue
, the definition is included.
-
getDecompressDefinition
public java.lang.Boolean getDecompressDefinition() -
setDecompressDefinition
Whether or not to decompress the trained model, or keep it in its compressed string form- Parameters:
decompressDefinition
- Iftrue
, the definition is decompressed.
-
getTags
public java.util.List<java.lang.String> getTags() -
setTags
The tags that the trained model must match. These correspond toTrainedModelConfig.getTags()
. The models returned will match ALL tags supplied. If none are provided, only the provided ids are used to find models- Parameters:
tags
- The tags to match when finding models
-
setTags
SeesetTags(List)
-
getForExport
public java.lang.Boolean getForExport() -
setForExport
Setting this flag to `true` removes certain fields from the model definition on retrieval. This is useful when getting the model and wanting to put it in another cluster. Default value is false.- Parameters:
forExport
- Boolean value indicating if certain fields should be removed from the mode on GET
-
validate
Description copied from interface:Validatable
Perform validation. This method does not have to be overridden in the event that no validation needs to be done, or the validation was done during object construction time. AValidationException
that is not null is assumed to contain validation errors and will be thrown.- Specified by:
validate
in interfaceValidatable
- Returns:
- An
Optional
ValidationException
that contains a list of validation errors.
-
equals
public boolean equals(java.lang.Object o)- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()- Overrides:
hashCode
in classjava.lang.Object
-