Skip to content

Commit 6630be7

Browse files
Update minimal supported version and add Hugging Face transport version constants
1 parent 7670d2c commit 6630be7

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

server/src/main/java/org/elasticsearch/TransportVersions.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,7 @@ static TransportVersion def(int id) {
164164
public static final TransportVersion SEARCH_INCREMENTAL_TOP_DOCS_NULL_BACKPORT_8_19 = def(8_841_0_20);
165165
public static final TransportVersion ML_INFERENCE_SAGEMAKER_8_19 = def(8_841_0_21);
166166
public static final TransportVersion ESQL_REPORT_ORIGINAL_TYPES_BACKPORT_8_19 = def(8_841_0_22);
167+
public static final TransportVersion ML_INFERENCE_HUGGING_FACE_8_19 = def(8_841_0_23);
167168
public static final TransportVersion V_9_0_0 = def(9_000_0_09);
168169
public static final TransportVersion INITIAL_ELASTICSEARCH_9_0_1 = def(9_000_0_10);
169170
public static final TransportVersion COHERE_BIT_EMBEDDING_TYPE_SUPPORT_ADDED = def(9_001_0_00);
@@ -236,6 +237,7 @@ static TransportVersion def(int id) {
236237
public static final TransportVersion PINNED_RETRIEVER = def(9_068_0_00);
237238
public static final TransportVersion ML_INFERENCE_SAGEMAKER = def(9_069_0_00);
238239
public static final TransportVersion WRITE_LOAD_INCLUDES_BUFFER_WRITES = def(9_070_00_0);
240+
public static final TransportVersion ML_INFERENCE_HUGGING_FACE = def(9_071_0_00);
239241

240242
/*
241243
* STOP! READ THIS FIRST! No, really,

x-pack/plugin/inference/src/main/java/org/elasticsearch/xpack/inference/services/huggingface/completion/HuggingFaceChatCompletionServiceSettings.java

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -178,18 +178,15 @@ public String getWriteableName() {
178178

179179
@Override
180180
public TransportVersion getMinimalSupportedVersion() {
181-
return TransportVersions.V_8_14_0;
181+
return TransportVersions.ML_INFERENCE_HUGGING_FACE;
182182
}
183183

184184
@Override
185185
public void writeTo(StreamOutput out) throws IOException {
186186
out.writeOptionalString(modelId);
187187
out.writeString(uri.toString());
188188
out.writeOptionalVInt(maxInputTokens);
189-
190-
if (out.getTransportVersion().onOrAfter(TransportVersions.V_8_15_0)) {
191-
rateLimitSettings.writeTo(out);
192-
}
189+
rateLimitSettings.writeTo(out);
193190
}
194191

195192
@Override

0 commit comments

Comments
 (0)