Skip to content
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
Show all changes
63 commits
Select commit Hold shift + click to select a range
c72eda6
Add BFloat16 raw vector format to bbq_hnsw and bbq_disk
thecoop Oct 10, 2025
b4c682a
Remove tripping assertion
thecoop Oct 10, 2025
803dfc1
Enable direct IO and bfloat16
thecoop Oct 10, 2025
c2c52e7
[CI] Auto commit changes from spotless
Oct 10, 2025
05f0b71
Merge branch 'bbq_hnsw-bfloat16' into hnsw-directio-bfloat16-enabled
thecoop Oct 10, 2025
2f8e975
Remove tripping assertion
thecoop Oct 10, 2025
4030f47
PR comments
thecoop Oct 10, 2025
17a58a2
Merge branch 'bbq_hnsw-bfloat16' into hnsw-directio-bfloat16-enabled
thecoop Oct 10, 2025
e910cd5
Propagate files across
thecoop Oct 10, 2025
5ef4cf1
PR comments
thecoop Oct 10, 2025
69f52cb
Turn the generic format into a proper format
thecoop Oct 10, 2025
2c31186
Merge branch 'bbq_hnsw-bfloat16' into hnsw-directio-bfloat16-enabled
thecoop Oct 10, 2025
5ce914d
More propagation
thecoop Oct 10, 2025
2e815fe
Add a basic generic HNSW implementation
thecoop Oct 10, 2025
9c81e33
Relax unit vector check for bfloat16
thecoop Oct 13, 2025
90ca761
Merge branch 'main' into bbq_hnsw-bfloat16
thecoop Oct 13, 2025
ce690ff
Add tests for ES93HnswVectorsFormat
thecoop Oct 13, 2025
1de5bd8
Remove unquantized format
thecoop Oct 13, 2025
e54d4c6
Consolidate parameter order
thecoop Oct 13, 2025
80d9809
Use the correct values
thecoop Oct 13, 2025
d6491a2
Merge branch 'main' into bbq_hnsw-bfloat16
thecoop Oct 14, 2025
74bb130
Remove unneeded method
thecoop Oct 14, 2025
37e3257
Merge commit '74bb130' into bbq_hnsw-bfloat16-format
thecoop Oct 14, 2025
4c669ec
Merge branch 'main' into bbq_hnsw-bfloat16-format
thecoop Oct 14, 2025
be062e7
Merge commit '4c669ec513f' into hnsw-directio-bfloat16-enabled
thecoop Oct 14, 2025
38183b7
Use bfloat16/directio in rescore tests
thecoop Oct 14, 2025
5277641
Test updates
thecoop Oct 14, 2025
201ed46
Get parameters the right way round
thecoop Oct 15, 2025
9258804
Merge branch 'main' into hnsw-directio-bfloat16-enabled
thecoop Oct 15, 2025
5e6ddc9
Use ElementType
thecoop Oct 15, 2025
0b8fcf2
Add basic HNSW support
thecoop Oct 15, 2025
a3e7cb6
Merge branch 'main' into hnsw-directio-bfloat16-enabled
thecoop Oct 23, 2025
2766e4b
Use new formats
thecoop Oct 23, 2025
f352602
Add normal HNSW
thecoop Oct 23, 2025
415bc94
Merge branch 'main' into hnsw-directio-bfloat16-enabled
thecoop Oct 24, 2025
ca4551c
Update for merge
thecoop Oct 24, 2025
8f92014
Update tests
thecoop Oct 24, 2025
8c697c3
Leave semantic text and rank vectors alone for the moment
thecoop Oct 24, 2025
99395e5
Need some basic support in downstream classes
thecoop Oct 24, 2025
297db11
Test updates
thecoop Oct 24, 2025
5965de3
Non-quantized HNSW doesn't need direct IO
thecoop Oct 24, 2025
ba7427f
Merge branch 'main' into hnsw-directio-bfloat16-enabled
thecoop Oct 30, 2025
2bd4423
Use DenseVectorFieldMapper ElementType
thecoop Oct 30, 2025
a87ffd7
Update docs/changelog/135940.yaml
thecoop Oct 30, 2025
e871fbc
Some updates
thecoop Oct 30, 2025
4f2f673
Provide some more implementations
thecoop Oct 30, 2025
8395687
Test and fixes
thecoop Oct 30, 2025
a8de10f
Merge branch 'main' into hnsw-directio-bfloat16-enabled
thecoop Oct 30, 2025
9eaa152
PR comments
thecoop Oct 31, 2025
7b36722
Merge branch 'main' into hnsw-directio-bfloat16-enabled
thecoop Nov 5, 2025
6bef1f0
Add assert for an interface it shouldn't implement yet
thecoop Nov 5, 2025
1e905de
Add case
thecoop Nov 5, 2025
e2c2730
Base64 support
thecoop Nov 5, 2025
cc414b0
Merge branch 'main' into hnsw-directio-bfloat16-enabled
thecoop Nov 5, 2025
ee46e00
Add a feature flag for the new formats
thecoop Nov 5, 2025
9db655c
Merge branch 'main' into hnsw-directio-bfloat16-enabled
thecoop Nov 6, 2025
dce8dd8
Update the feature flag & cluster feature names
thecoop Nov 6, 2025
66aa767
Remove obsoleted yaml tests
thecoop Nov 6, 2025
eed749e
Turn off yaml tests for now
thecoop Nov 6, 2025
ab5ee25
Remove index version (not needed yet)
thecoop Nov 7, 2025
2a58d2f
Don't accept the rescore option if the flag is not enabled
thecoop Nov 7, 2025
749780d
Add generic vector flag to the yaml runners
thecoop Nov 7, 2025
2a0d9ba
Merge branch 'main' into hnsw-directio-bfloat16-enabled
thecoop Nov 7, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,8 @@ public class CcsCommonYamlTestSuiteIT extends ESClientYamlSuiteTestCase {
// geohex_grid requires gold license
.setting("xpack.license.self_generated.type", "trial")
.feature(FeatureFlag.TIME_SERIES_MODE)
.feature(FeatureFlag.SYNTHETIC_VECTORS);
.feature(FeatureFlag.SYNTHETIC_VECTORS)
.feature(FeatureFlag.GENERIC_VECTOR_FORMAT);

private static ElasticsearchCluster remoteCluster = ElasticsearchCluster.local()
.name(REMOTE_CLUSTER_NAME)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ public class RcsCcsCommonYamlTestSuiteIT extends ESClientYamlSuiteTestCase {
.setting("xpack.security.remote_cluster_client.ssl.enabled", "false")
.feature(FeatureFlag.TIME_SERIES_MODE)
.feature(FeatureFlag.SYNTHETIC_VECTORS)
.feature(FeatureFlag.GENERIC_VECTOR_FORMAT)
.user("test_admin", "x-pack-test-password");

private static ElasticsearchCluster fulfillingCluster = ElasticsearchCluster.local()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ public class SmokeTestMultiNodeClientYamlTestSuiteIT extends ESClientYamlSuiteTe
.feature(FeatureFlag.DOC_VALUES_SKIPPER)
.feature(FeatureFlag.SYNTHETIC_VECTORS)
.feature(FeatureFlag.RANDOM_SAMPLING)
.feature(FeatureFlag.GENERIC_VECTOR_FORMAT)
.build();

public SmokeTestMultiNodeClientYamlTestSuiteIT(@Name("yaml") ClientYamlTestCandidate testCandidate) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ public class ClientYamlTestSuiteIT extends ESClientYamlSuiteTestCase {
.feature(FeatureFlag.DOC_VALUES_SKIPPER)
.feature(FeatureFlag.SYNTHETIC_VECTORS)
.feature(FeatureFlag.RANDOM_SAMPLING)
.feature(FeatureFlag.GENERIC_VECTOR_FORMAT)
.build();

public ClientYamlTestSuiteIT(@Name("yaml") ClientYamlTestCandidate testCandidate) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -164,10 +164,7 @@ setup:
"dense_vector docvalues with bfloat16":
- requires:
cluster_features: [ "mapper.vectors.generic_vector_format" ]
reason: Needs bfloat16 support
- skip:
awaits_fix: https://github.com/elastic/elasticsearch/issues/131109
reason: Feature flag not enabled
reason: Needs generic vector support
- do:
indices.create:
index: test-bfloat16
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
setup:
- requires:
cluster_features: ["mapper.vectors.hnsw_bfloat16_on_disk_rescoring"]
reason: 'bfloat16 needs to be supported'
- skip:
awaits_fix: https://github.com/elastic/elasticsearch/issues/131109
reason: Feature flag not enabled
cluster_features: [ "mapper.vectors.generic_vector_format" ]
reason: Needs generic vector support
- do:
indices.create:
index: test
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -340,11 +340,8 @@ setup:
---
"Test index configured rescore vector with on-disk rescoring":
- requires:
cluster_features: ["mapper.vectors.generic_vector_format"]
reason: Needs on_disk_rescoring feature
- skip:
awaits_fix: https://github.com/elastic/elasticsearch/issues/131109
reason: Feature flag not enabled
cluster_features: [ "mapper.vectors.generic_vector_format" ]
reason: Needs generic vector support
- skip:
features: "headers"
- do:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
setup:
- requires:
cluster_features: "mapper.vectors.generic_vector_format"
reason: 'bfloat16 needs to be supported'
- skip:
awaits_fix: https://github.com/elastic/elasticsearch/issues/131109
reason: Feature flag not enabled
cluster_features: [ "mapper.vectors.generic_vector_format" ]
reason: Needs generic vector support
- do:
indices.create:
index: bbq_hnsw
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
setup:
- requires:
cluster_features: "mapper.vectors.generic_vector_format"
reason: 'bfloat16 needs to be supported'
- skip:
awaits_fix: https://github.com/elastic/elasticsearch/issues/131109
reason: Feature flag not enabled
cluster_features: [ "mapper.vectors.generic_vector_format" ]
reason: Needs generic vector support
- do:
indices.create:
index: bbq_flat
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
setup:
- requires:
cluster_features: ["mapper.vectors.hnsw_bfloat16_on_disk_rescoring"]
reason: 'bfloat16 needs to be supported'
- skip:
awaits_fix: https://github.com/elastic/elasticsearch/issues/131109
reason: Feature flag not enabled
cluster_features: [ "mapper.vectors.generic_vector_format" ]
reason: Needs generic vector support
- skip:
features: "headers"
- do:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1640,7 +1640,9 @@ public boolean supportsDimension(int dims) {
public DenseVectorIndexOptions parseIndexOptions(String fieldName, Map<String, ?> indexOptionsMap, IndexVersion indexVersion) {
Object mNode = indexOptionsMap.remove("m");
Object efConstructionNode = indexOptionsMap.remove("ef_construction");
Object onDiskRescoreNode = indexOptionsMap.remove("on_disk_rescore");
Object onDiskRescoreNode = ES93GenericFlatVectorsFormat.GENERIC_VECTOR_FORMAT.isEnabled()
? indexOptionsMap.remove("on_disk_rescore")
: false;

int m = XContentMapValues.nodeIntegerValue(mNode, Lucene99HnswVectorsFormat.DEFAULT_MAX_CONN);
int efConstruction = XContentMapValues.nodeIntegerValue(efConstructionNode, Lucene99HnswVectorsFormat.DEFAULT_BEAM_WIDTH);
Expand Down Expand Up @@ -1731,7 +1733,9 @@ public DenseVectorIndexOptions parseIndexOptions(String fieldName, Map<String, ?
}
}

Object onDiskRescoreNode = indexOptionsMap.remove("on_disk_rescore");
Object onDiskRescoreNode = ES93GenericFlatVectorsFormat.GENERIC_VECTOR_FORMAT.isEnabled()
? indexOptionsMap.remove("on_disk_rescore")
: false;
Comment on lines -1693 to +1738
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not sure we can do this? Do we know if we have shipped a version of ES that allowed this option for diskbbq?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

9.2 didn't include it, so we can change it here

boolean onDiskRescore = XContentMapValues.nodeBooleanValue(onDiskRescoreNode, false);

MappingParser.checkNoRemainingFields(fieldName, indexOptionsMap);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@ public enum FeatureFlag {
null
),
RANDOM_SAMPLING("es.random_sampling_feature_flag_enabled=true", Version.fromString("9.2.0"), null),
INFERENCE_API_CCM("es.inference_api_ccm_feature_flag_enabled=true", Version.fromString("9.3.0"), null);
INFERENCE_API_CCM("es.inference_api_ccm_feature_flag_enabled=true", Version.fromString("9.3.0"), null),
GENERIC_VECTOR_FORMAT("es.generic_vector_format_feature_flag_enabled=true", Version.fromString("9.3.0"), null);

public final String systemProperty;
public final Version from;
Expand Down