@@ -12,9 +12,9 @@ use chroma_types::{
1212 CreateTenantError , CreateTenantResponse , Database , DatabaseUuid , DeleteCollectionError ,
1313 DeleteDatabaseError , DeleteDatabaseResponse , GetCollectionWithSegmentsError ,
1414 GetCollectionsError , GetDatabaseError , GetSegmentsError , GetTenantError , GetTenantResponse ,
15- InternalCollectionConfiguration , ListDatabasesError , Metadata , MetadataValue , ResetError ,
16- ResetResponse , Segment , SegmentScope , SegmentType , SegmentUuid , UpdateCollectionConfiguration ,
17- UpdateCollectionError ,
15+ InternalCollectionConfiguration , InternalUpdateCollectionConfiguration , ListDatabasesError ,
16+ Metadata , MetadataValue , ResetError , ResetResponse , Segment , SegmentScope , SegmentType ,
17+ SegmentUuid , UpdateCollectionError ,
1818} ;
1919use futures:: TryStreamExt ;
2020use sea_query_binder:: SqlxBinder ;
@@ -356,7 +356,7 @@ impl SqliteSysDb {
356356 name : Option < String > ,
357357 metadata : Option < CollectionMetadataUpdate > ,
358358 dimension : Option < u32 > ,
359- configuration : Option < UpdateCollectionConfiguration > ,
359+ configuration : Option < InternalUpdateCollectionConfiguration > ,
360360 ) -> Result < ( ) , UpdateCollectionError > {
361361 let mut tx = self
362362 . db
@@ -1048,8 +1048,9 @@ mod tests {
10481048 use super :: * ;
10491049 use chroma_sqlite:: db:: test_utils:: get_new_sqlite_db;
10501050 use chroma_types:: {
1051- SegmentScope , SegmentType , SegmentUuid , UpdateHnswConfiguration , UpdateMetadata ,
1052- UpdateMetadataValue , VectorIndexConfiguration ,
1051+ InternalUpdateCollectionConfiguration , SegmentScope , SegmentType , SegmentUuid ,
1052+ UpdateHnswConfiguration , UpdateMetadata , UpdateMetadataValue ,
1053+ UpdateVectorIndexConfiguration , VectorIndexConfiguration ,
10531054 } ;
10541055
10551056 #[ tokio:: test]
@@ -1354,13 +1355,14 @@ mod tests {
13541355 Some ( "new_name" . to_string ( ) ) ,
13551356 Some ( CollectionMetadataUpdate :: UpdateMetadata ( metadata) ) ,
13561357 Some ( 1024 ) ,
1357- Some ( UpdateCollectionConfiguration {
1358- hnsw : Some ( UpdateHnswConfiguration {
1359- ef_search : Some ( 20 ) ,
1360- num_threads : Some ( 4 ) ,
1361- ..Default :: default ( )
1362- } ) ,
1363- spann : None ,
1358+ Some ( InternalUpdateCollectionConfiguration {
1359+ vector_index : Some ( UpdateVectorIndexConfiguration :: Hnsw ( Some (
1360+ UpdateHnswConfiguration {
1361+ ef_search : Some ( 10 ) ,
1362+ num_threads : Some ( 2 ) ,
1363+ ..Default :: default ( )
1364+ } ,
1365+ ) ) ) ,
13641366 embedding_function : None ,
13651367 } ) ,
13661368 )
@@ -1387,7 +1389,7 @@ mod tests {
13871389 // Access HNSW configuration through pattern matching
13881390 match & collection. config . vector_index {
13891391 VectorIndexConfiguration :: Hnsw ( hnsw) => {
1390- assert_eq ! ( hnsw. ef_search, 20 ) ;
1392+ assert_eq ! ( hnsw. ef_search, 10 ) ;
13911393 }
13921394 _ => panic ! ( "Expected HNSW configuration" ) ,
13931395 }
0 commit comments