Hi!
It is mentioned in the docs:
Object IDs are not randomly generated. The same value always generates the same ID.
Weaviate throws an error if you provide a duplicate ID. Use deterministic IDs to avoid inserting duplicate objects.
I am generating uuid based on two IDs, and I expect duplicate IDs with slightly different object values, and I want the object with duplicate ID to replace the old one, is that possible on batch create operation ?
Yes, the batch endpoints are already idem-potent and act as upsert (=insert or update depending on whether the ID exists).
v1.24
will bring a lot of improvements around idempotent batch. But they are mainly from an efficiency standpoint. For example, updates that don’t require touching the vector index (because the vector wasn’t changed) will bypass it. That’s a lot faster.
But overriding objects with the same ID is as described above is already possible.
1 Like