chroma icon indicating copy to clipboard operation
chroma copied to clipboard

[Feature Request]: Stronger validation checks for static hnsw params and propagation of dynamic ones

Open tazarov opened this issue 2 years ago • 5 comments

Describe the problem

Some of the hnsw parameters like (ef_search) are tunable after index creation and also at query time while others are immutable. Today there is no guide or any indication as to what happens if a user attempts to change these parameters after index creation.

Describe the proposed solution

Raise error for static params. Verify that parameters are propagated for dynamic params.

Alternatives considered

No response

Importance

would make my life easier

Additional Information

No response

tazarov avatar Sep 26 '23 13:09 tazarov

Hi @tazarov , Is there any way I can view and modify the parameters of the HNSW index at the moment? I want to deploy a vector database on a local PC and balance RAM and search performance with control over hnsw parameters.

Amphetaminewei avatar Sep 16 '24 14:09 Amphetaminewei

I find a class HnswParams, it seems that if I don't set the parameters via metadata when creating the Collection, the default values in this class will be used.

Amphetaminewei avatar Sep 18 '24 07:09 Amphetaminewei

@Amphetaminewei yes that is correct for now - though we are planning to change this

jeffchuber avatar Sep 19 '24 02:09 jeffchuber

@Amphetaminewei, another "side-effect" of recent changes is that you can only set the HNSW params when creating the collection. Updating collection with collection.modify(metadata={} will not work.

Recently we've merged a PR that structures these params in a strongly type class system which will make managing collection HNSW params more robust and far less error-prone.

tazarov avatar Sep 19 '24 05:09 tazarov

@jeffchuber @tazarov Okay thank you!

Amphetaminewei avatar Sep 24 '24 11:09 Amphetaminewei

done with collection configuration

jairad26 avatar Jun 13 '25 21:06 jairad26