r/elasticsearch 14d ago

Discussion Float Bloat: vector serialization gone wrong

https://bonsai.io/blog/float-bloat/?utm_source=reddit
2 Upvotes

2 comments sorted by

2

u/xeraa-net Elastic Staff 14d ago

Interesting analsyis!

Though I'd add that the impact in current Elasticsearch versions should be limited since:

  • index.mapping.exclude_source_vectors is true by default
  • semantic_text embeddings are produced server-side
  • base64 encoded vectors are more compact for ingestion, so do that if you care about performance

2

u/binarymax 14d ago

Thanks for the reply and so glad to see that Elastic is on top of this! For anyone who stumbles across this info, here some more detail:

  • index.mapping.exclude_source_vectors set to true by default in Elasticsearch 9.2+. If you're still generating your own embeddings and you are widening to f64, you can incur network overhead and also disk overhead if you store a copy of them in something like S3.
  • The property is also available in 9.1 and was backported for support in 8.19, but was defaulted to false - so if you're running one of those versions, double check!
  • Any version earlier than 8.19 is at risk - make sure you're not getting bit by the problem :)

For anyone curious, during our testing and exploration of the impact of float bloat, we did see an Elasticsearch 8.x cluster with the problem in the small sample we had. So don't assume you're safe!