Skip to content

Commit 522c8ae

Browse files
committed
Add test feature for bfloat16
1 parent 370feb2 commit 522c8ae

File tree

3 files changed

+9
-1
lines changed

3 files changed

+9
-1
lines changed

rest-api-spec/src/yamlRestTest/resources/rest-api-spec/test/search.vectors/41_knn_search_bbq_hnsw_bfloat16.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
11
setup:
2+
- requires:
3+
cluster_features: "mapper.bbq_bfloat16"
4+
reason: 'bfloat16 needs to be supported'
25
- do:
36
indices.create:
47
index: bbq_hnsw

rest-api-spec/src/yamlRestTest/resources/rest-api-spec/test/search.vectors/42_knn_search_bbq_flat_bfloat16.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
11
setup:
2+
- requires:
3+
cluster_features: "mapper.bbq_bfloat16"
4+
reason: 'bfloat16 needs to be supported'
25
- do:
36
indices.create:
47
index: bbq_flat

server/src/main/java/org/elasticsearch/index/mapper/MapperFeatures.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ public class MapperFeatures implements FeatureSpecification {
4747
static final NodeFeature BBQ_DISK_SUPPORT = new NodeFeature("mapper.bbq_disk_support");
4848
static final NodeFeature SEARCH_LOAD_PER_SHARD = new NodeFeature("mapper.search_load_per_shard");
4949
static final NodeFeature PATTERNED_TEXT = new NodeFeature("mapper.patterned_text");
50+
static final NodeFeature BBQ_BFLOAT16 = new NodeFeature("mapper.bbq_bfloat16");
5051

5152
@Override
5253
public Set<NodeFeature> getTestFeatures() {
@@ -80,7 +81,8 @@ public Set<NodeFeature> getTestFeatures() {
8081
BBQ_DISK_SUPPORT,
8182
SEARCH_LOAD_PER_SHARD,
8283
SPARSE_VECTOR_INDEX_OPTIONS_FEATURE,
83-
PATTERNED_TEXT
84+
PATTERNED_TEXT,
85+
BBQ_BFLOAT16
8486
);
8587
}
8688
}

0 commit comments

Comments
 (0)