Class RankEvalMetricDetail.Builder
java.lang.Object
co.elastic.clients.util.ObjectBuilderBase
co.elastic.clients.util.WithJsonObjectBuilderBase<RankEvalMetricDetail.Builder>
co.elastic.clients.elasticsearch.core.rank_eval.RankEvalMetricDetail.Builder
- All Implemented Interfaces:
WithJson<RankEvalMetricDetail.Builder>,ObjectBuilder<RankEvalMetricDetail>
- Enclosing class:
- RankEvalMetricDetail
public static class RankEvalMetricDetail.Builder
extends WithJsonObjectBuilderBase<RankEvalMetricDetail.Builder>
implements ObjectBuilder<RankEvalMetricDetail>
Builder for
RankEvalMetricDetail.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds aRankEvalMetricDetail.hits(RankEvalHitItem value, RankEvalHitItem... values) Required - The hits section shows a grouping of the search results with their supplied ratingsRequired - The hits section shows a grouping of the search results with their supplied ratingshits(List<RankEvalHitItem> list) Required - The hits section shows a grouping of the search results with their supplied ratingsmetricDetails(String key, Map<String, JsonData> value) Required - The metric_details give additional information about the calculated quality metric (e.g.Required - The metric_details give additional information about the calculated quality metric (e.g.metricScore(double value) Required - The metric_score in the details section shows the contribution of this query to the global quality metric scoreprotected RankEvalMetricDetail.Builderself()unratedDocs(UnratedDocument value, UnratedDocument... values) Required - The unrated_docs section contains an _index and _id entry for each document in the search result for this query that didn’t have a ratings value.Required - The unrated_docs section contains an _index and _id entry for each document in the search result for this query that didn’t have a ratings value.unratedDocs(List<UnratedDocument> list) Required - The unrated_docs section contains an _index and _id entry for each document in the search result for this query that didn’t have a ratings value.Methods inherited from class co.elastic.clients.util.WithJsonObjectBuilderBase
withJsonMethods inherited from class co.elastic.clients.util.ObjectBuilderBase
_checkSingleUse, _listAdd, _listAddAll, _mapPut, _mapPutAll
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
metricScore
Required - The metric_score in the details section shows the contribution of this query to the global quality metric scoreAPI name:
metric_score -
unratedDocs
Required - The unrated_docs section contains an _index and _id entry for each document in the search result for this query that didn’t have a ratings value. This can be used to ask the user to supply ratings for these documentsAPI name:
unrated_docsAdds all elements of
listtounratedDocs. -
unratedDocs
public final RankEvalMetricDetail.Builder unratedDocs(UnratedDocument value, UnratedDocument... values) Required - The unrated_docs section contains an _index and _id entry for each document in the search result for this query that didn’t have a ratings value. This can be used to ask the user to supply ratings for these documentsAPI name:
unrated_docsAdds one or more values to
unratedDocs. -
unratedDocs
public final RankEvalMetricDetail.Builder unratedDocs(Function<UnratedDocument.Builder, ObjectBuilder<UnratedDocument>> fn) Required - The unrated_docs section contains an _index and _id entry for each document in the search result for this query that didn’t have a ratings value. This can be used to ask the user to supply ratings for these documentsAPI name:
unrated_docsAdds a value to
unratedDocsusing a builder lambda. -
hits
Required - The hits section shows a grouping of the search results with their supplied ratingsAPI name:
hitsAdds all elements of
listtohits. -
hits
Required - The hits section shows a grouping of the search results with their supplied ratingsAPI name:
hitsAdds one or more values to
hits. -
hits
public final RankEvalMetricDetail.Builder hits(Function<RankEvalHitItem.Builder, ObjectBuilder<RankEvalHitItem>> fn) Required - The hits section shows a grouping of the search results with their supplied ratingsAPI name:
hitsAdds a value to
hitsusing a builder lambda. -
metricDetails
Required - The metric_details give additional information about the calculated quality metric (e.g. how many of the retrieved documents were relevant). The content varies for each metric but allows for better interpretation of the resultsAPI name:
metric_detailsAdds all entries of
maptometricDetails. -
metricDetails
Required - The metric_details give additional information about the calculated quality metric (e.g. how many of the retrieved documents were relevant). The content varies for each metric but allows for better interpretation of the resultsAPI name:
metric_detailsAdds an entry to
metricDetails. -
self
- Specified by:
selfin classWithJsonObjectBuilderBase<RankEvalMetricDetail.Builder>
-
build
Builds aRankEvalMetricDetail.- Specified by:
buildin interfaceObjectBuilder<RankEvalMetricDetail>- Throws:
NullPointerException- if some of the required fields are null.
-