- All Superinterfaces:
FilteredXContent
,NamedWriteable
,ToXContent
,ToXContentObject
,VersionedNamedWriteable
,Writeable
public interface ServiceSettings
extends ToXContentObject, VersionedNamedWriteable, FilteredXContent
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.elasticsearch.xcontent.ToXContent
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.Params
Nested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V>
-
Field Summary
Fields inherited from interface org.elasticsearch.xcontent.ToXContent
EMPTY, EMPTY_PARAMS
-
Method Summary
Modifier and TypeMethodDescriptiondefault Integer
Number of dimensions the service works with.default Boolean
Boolean signifying whether the dimensions were set by the userThe data type for the embeddings this service works with.modelId()
The model to use in the inference endpoint (e.g.default SimilarityMeasure
Similarity used in the service.Methods inherited from interface org.elasticsearch.inference.FilteredXContent
getFilteredXContentObject
Methods inherited from interface org.elasticsearch.xcontent.ToXContent
toXContent
Methods inherited from interface org.elasticsearch.xcontent.ToXContentObject
isFragment
Methods inherited from interface org.elasticsearch.common.io.stream.VersionedNamedWriteable
getMinimalSupportedVersion, getWriteableName
-
Method Details
-
similarity
Similarity used in the service. Will be null if not applicable.- Returns:
- similarity
-
dimensions
Number of dimensions the service works with. Will be null if not applicable.- Returns:
- number of dimensions
-
dimensionsSetByUser
Boolean signifying whether the dimensions were set by the user- Returns:
- boolean signifying whether the dimensions were set by the user
-
elementType
The data type for the embeddings this service works with. Defaults to null, Text Embedding models should return a non-null value- Returns:
- the element type
-
modelId
The model to use in the inference endpoint (e.g. text-embedding-ada-002). Sometimes the model is not defined in the service settings. This can happen for external providers (e.g. hugging face, azure ai studio) where the provider requires that the model be chosen when initializing a deployment within their service. In this situation, return null.- Returns:
- the model used to perform inference or null if the model is not defined
-