diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/mapping/TextIndexPrefixes.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/mapping/TextIndexPrefixes.java index 1802423738..7dc1a8c21b 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/mapping/TextIndexPrefixes.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/_types/mapping/TextIndexPrefixes.java @@ -26,13 +26,13 @@ import co.elastic.clients.json.JsonpUtils; import co.elastic.clients.json.ObjectBuilderDeserializer; import co.elastic.clients.json.ObjectDeserializer; -import co.elastic.clients.util.ApiTypeHelper; import co.elastic.clients.util.ObjectBuilder; import co.elastic.clients.util.WithJsonObjectBuilderBase; import jakarta.json.stream.JsonGenerator; import java.lang.Integer; import java.util.Objects; import java.util.function.Function; +import javax.annotation.Nullable; //---------------------------------------------------------------- // THIS CODE IS GENERATED. MANUAL EDITS WILL BE LOST. @@ -59,16 +59,18 @@ */ @JsonpDeserializable public class TextIndexPrefixes implements JsonpSerializable { - private final int maxChars; + @Nullable + private final Integer maxChars; - private final int minChars; + @Nullable + private final Integer minChars; // --------------------------------------------------------------------------------------------- private TextIndexPrefixes(Builder builder) { - this.maxChars = ApiTypeHelper.requireNonNull(builder.maxChars, this, "maxChars", 0); - this.minChars = ApiTypeHelper.requireNonNull(builder.minChars, this, "minChars", 0); + this.maxChars = builder.maxChars; + this.minChars = builder.minChars; } @@ -77,16 +79,18 @@ public static TextIndexPrefixes of(Function implements ObjectBuilder { + @Nullable private Integer maxChars; + @Nullable private Integer minChars; public Builder() { @@ -133,17 +144,17 @@ private Builder(TextIndexPrefixes instance) { } /** - * Required - API name: {@code max_chars} + * API name: {@code max_chars} */ - public final Builder maxChars(int value) { + public final Builder maxChars(@Nullable Integer value) { this.maxChars = value; return this; } /** - * Required - API name: {@code min_chars} + * API name: {@code min_chars} */ - public final Builder minChars(int value) { + public final Builder minChars(@Nullable Integer value) { this.minChars = value; return this; } diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/doc-files/api-spec.html b/java-client/src/main/java/co/elastic/clients/elasticsearch/doc-files/api-spec.html index 43a1441f4e..672eaa904d 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/doc-files/api-spec.html +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/doc-files/api-spec.html @@ -142,7 +142,7 @@ '_global.rank_eval.UnratedDocument': '_global/rank_eval/types.ts#L150-L153', '_global.reindex.Destination': '_global/reindex/types.ts#L39-L67', '_global.reindex.RemoteSource': '_global/reindex/types.ts#L127-L163', -'_global.reindex.Request': '_global/reindex/ReindexRequest.ts#L32-L192', +'_global.reindex.Request': '_global/reindex/ReindexRequest.ts#L32-L195', '_global.reindex.Response': '_global/reindex/ReindexResponse.ts#L27-L97', '_global.reindex.Source': '_global/reindex/types.ts#L69-L125', '_global.reindex_rethrottle.ParentReindexStatus': '_global/reindex_rethrottle/types.ts#L46-L48', @@ -3562,10 +3562,10 @@ if (hash.length > 1) { hash = hash.substring(1); } - window.location = "https://github.com/elastic/elasticsearch-specification/tree/ea5cd764eeab3a374bc18999c0ea39e554e62d2d/specification/" + (paths[hash] || ""); + window.location = "https://github.com/elastic/elasticsearch-specification/tree/22c7eb88e9919e130aa40d86bf0dccd5de355673/specification/" + (paths[hash] || ""); - Please see the Elasticsearch API specification. + Please see the Elasticsearch API specification. diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/inference/AzureOpenAIServiceSettings.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/inference/AzureOpenAIServiceSettings.java index af92c676cf..276242f466 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/inference/AzureOpenAIServiceSettings.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/inference/AzureOpenAIServiceSettings.java @@ -134,7 +134,7 @@ public final String apiVersion() { } /** - * For OAuth 2.0 authentication using the client credentials grant flow. The + * For OAuth 2.0 authorization using the client credentials grant flow. The * application ID that's assigned to your app. *

* IMPORTANT: To configure OAuth 2.0, you must specify client_id, scopes, @@ -149,7 +149,7 @@ public final String clientId() { } /** - * For OAuth 2.0 authentication using the client credentials grant flow. The + * For OAuth 2.0 authorization using the client credentials grant flow. The * application secret that you created in the Microsoft app registration portal * for your app. *

@@ -221,7 +221,7 @@ public final String resourceName() { } /** - * For OAuth 2.0 authentication using the client credentials grant flow. The + * For OAuth 2.0 authorization using the client credentials grant flow. The * resource identifier (application ID URI) of the resource you want, suffixed * with .default For example: * @@ -243,7 +243,7 @@ public final List scopes() { } /** - * For OAuth 2.0 authentication using the client credentials grant flow. The + * For OAuth 2.0 authorization using the client credentials grant flow. The * directory tenant the application plans to operate against. *

* IMPORTANT: To configure OAuth 2.0, you must specify client_id, scopes, @@ -403,7 +403,7 @@ public final Builder apiVersion(String value) { } /** - * For OAuth 2.0 authentication using the client credentials grant flow. The + * For OAuth 2.0 authorization using the client credentials grant flow. The * application ID that's assigned to your app. *

* IMPORTANT: To configure OAuth 2.0, you must specify client_id, scopes, @@ -418,7 +418,7 @@ public final Builder clientId(@Nullable String value) { } /** - * For OAuth 2.0 authentication using the client credentials grant flow. The + * For OAuth 2.0 authorization using the client credentials grant flow. The * application secret that you created in the Microsoft app registration portal * for your app. *

@@ -506,7 +506,7 @@ public final Builder resourceName(String value) { } /** - * For OAuth 2.0 authentication using the client credentials grant flow. The + * For OAuth 2.0 authorization using the client credentials grant flow. The * resource identifier (application ID URI) of the resource you want, suffixed * with .default For example: * @@ -531,7 +531,7 @@ public final Builder scopes(List list) { } /** - * For OAuth 2.0 authentication using the client credentials grant flow. The + * For OAuth 2.0 authorization using the client credentials grant flow. The * resource identifier (application ID URI) of the resource you want, suffixed * with .default For example: * @@ -556,7 +556,7 @@ public final Builder scopes(String value, String... values) { } /** - * For OAuth 2.0 authentication using the client credentials grant flow. The + * For OAuth 2.0 authorization using the client credentials grant flow. The * directory tenant the application plans to operate against. *

* IMPORTANT: To configure OAuth 2.0, you must specify client_id, scopes, diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/inference/CustomServiceSettings.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/inference/CustomServiceSettings.java index a35ce5ee47..b661816ed2 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/inference/CustomServiceSettings.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/inference/CustomServiceSettings.java @@ -115,7 +115,7 @@ public final Integer batchSize() { } /** - * Specifies the HTTP header parameters – such as Authentication or + * Specifies the HTTP header parameters – such as Authorization or * Content-Type – that are required to access the custom service. * For example: * @@ -379,7 +379,7 @@ public final Builder batchSize(@Nullable Integer value) { } /** - * Specifies the HTTP header parameters – such as Authentication or + * Specifies the HTTP header parameters – such as Authorization or * Content-Type – that are required to access the custom service. * For example: * @@ -401,7 +401,7 @@ public final Builder headers(Map map) { } /** - * Specifies the HTTP header parameters – such as Authentication or + * Specifies the HTTP header parameters – such as Authorization or * Content-Type – that are required to access the custom service. * For example: * diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/inference/JinaAIServiceSettings.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/inference/JinaAIServiceSettings.java index cd7d1f4307..710fef9d11 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/inference/JinaAIServiceSettings.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/inference/JinaAIServiceSettings.java @@ -76,7 +76,7 @@ public class JinaAIServiceSettings implements JsonpSerializable { private final Integer dimensions; @Nullable - private final JinaAIElementType elementType; + private final JinaAIElementType embeddingType; @Nullable private final Boolean multimodalModel; @@ -90,7 +90,7 @@ private JinaAIServiceSettings(Builder builder) { this.rateLimit = builder.rateLimit; this.similarity = builder.similarity; this.dimensions = builder.dimensions; - this.elementType = builder.elementType; + this.embeddingType = builder.embeddingType; this.multimodalModel = builder.multimodalModel; } @@ -167,11 +167,11 @@ public final Integer dimensions() { * (this is a synonym of bit). Use float for the * default float embeddings. *

- * API name: {@code element_type} + * API name: {@code embedding_type} */ @Nullable - public final JinaAIElementType elementType() { - return this.elementType; + public final JinaAIElementType embeddingType() { + return this.embeddingType; } /** @@ -221,9 +221,9 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) { generator.write(this.dimensions); } - if (this.elementType != null) { - generator.writeKey("element_type"); - this.elementType.serialize(generator, mapper); + if (this.embeddingType != null) { + generator.writeKey("embedding_type"); + this.embeddingType.serialize(generator, mapper); } if (this.multimodalModel != null) { generator.writeKey("multimodal_model"); @@ -261,7 +261,7 @@ public static class Builder extends WithJsonObjectBuilderBase private Integer dimensions; @Nullable - private JinaAIElementType elementType; + private JinaAIElementType embeddingType; @Nullable private Boolean multimodalModel; @@ -274,7 +274,7 @@ private Builder(JinaAIServiceSettings instance) { this.rateLimit = instance.rateLimit; this.similarity = instance.similarity; this.dimensions = instance.dimensions; - this.elementType = instance.elementType; + this.embeddingType = instance.embeddingType; this.multimodalModel = instance.multimodalModel; } @@ -359,10 +359,10 @@ public final Builder dimensions(@Nullable Integer value) { * (this is a synonym of bit). Use float for the * default float embeddings. *

- * API name: {@code element_type} + * API name: {@code embedding_type} */ - public final Builder elementType(@Nullable JinaAIElementType value) { - this.elementType = value; + public final Builder embeddingType(@Nullable JinaAIElementType value) { + this.embeddingType = value; return this; } @@ -421,7 +421,7 @@ protected static void setupJinaAIServiceSettingsDeserializer(ObjectDeserializer< op.add(Builder::rateLimit, RateLimitSetting._DESERIALIZER, "rate_limit"); op.add(Builder::similarity, JinaAISimilarityType._DESERIALIZER, "similarity"); op.add(Builder::dimensions, JsonpDeserializer.integerDeserializer(), "dimensions"); - op.add(Builder::elementType, JinaAIElementType._DESERIALIZER, "element_type"); + op.add(Builder::embeddingType, JinaAIElementType._DESERIALIZER, "embedding_type"); op.add(Builder::multimodalModel, JsonpDeserializer.booleanDeserializer(), "multimodal_model"); } diff --git a/java-client/src/main/java/co/elastic/clients/elasticsearch/ml/PutTrainedModelRequest.java b/java-client/src/main/java/co/elastic/clients/elasticsearch/ml/PutTrainedModelRequest.java index d600c7865d..9ab7d6d085 100644 --- a/java-client/src/main/java/co/elastic/clients/elasticsearch/ml/PutTrainedModelRequest.java +++ b/java-client/src/main/java/co/elastic/clients/elasticsearch/ml/PutTrainedModelRequest.java @@ -253,10 +253,9 @@ public final TrainedModelType modelType() { * processor architecture and OS combination, then this field specifies which. * The format of the string must match the platform identifiers used by * Elasticsearch, so one of, linux-x86_64, - * linux-aarch64, darwin-x86_64, - * darwin-aarch64, or windows-x86_64. For portable - * models (those that work independent of processor architecture or OS - * features), leave this field unset. + * linux-aarch64, darwin-aarch64, or + * windows-x86_64. For portable models (those that work independent + * of processor architecture or OS features), leave this field unset. *

* API name: {@code platform_architecture} */ @@ -597,10 +596,9 @@ public final Builder modelType(@Nullable TrainedModelType value) { * processor architecture and OS combination, then this field specifies which. * The format of the string must match the platform identifiers used by * Elasticsearch, so one of, linux-x86_64, - * linux-aarch64, darwin-x86_64, - * darwin-aarch64, or windows-x86_64. For portable - * models (those that work independent of processor architecture or OS - * features), leave this field unset. + * linux-aarch64, darwin-aarch64, or + * windows-x86_64. For portable models (those that work independent + * of processor architecture or OS features), leave this field unset. *

* API name: {@code platform_architecture} */