diff --git a/Objective-C/CBLDefaults.h b/Objective-C/CBLDefaults.h index ccf4739de..fbb9f7a44 100644 --- a/Objective-C/CBLDefaults.h +++ b/Objective-C/CBLDefaults.h @@ -33,9 +33,6 @@ /** [NO] Plaintext is not used, and instead binary encoding is used in log files */ extern const BOOL kCBLDefaultLogFileUsePlaintext; -/** [NO] Plaintext is not used, and instead binary encoding is used in log files */ -extern const BOOL kCBLDefaultLogFileUsePlainText __deprecated_msg("Use kCBLDefaultLogFileUsePlaintext instead."); - /** [524288] 512 KiB for the size of a log file */ extern const uint64_t kCBLDefaultLogFileMaxSize; @@ -86,12 +83,24 @@ extern const BOOL kCBLDefaultReplicatorAcceptParentCookies; #pragma mark - CBLVectorIndexConfiguration +/** [YES] Vectors are not lazily indexed, by default */ +extern const BOOL kCBLDefaultVectorIndexIsLazy; + /** [kCBLSQ8] Vectors are encoded by using 8-bit Scalar Quantizer encoding, by default */ extern const CBLScalarQuantizerType kCBLDefaultVectorIndexEncoding; /** [kCBLDistanceMetricEuclidean] By default, vectors are compared using Euclidean metrics */ extern const CBLDistanceMetric kCBLDefaultVectorIndexDistanceMetric; +/** [0] By default, the value will be determined based on the number of centroids, encoding types, and the encoding parameters. */ +extern const unsigned int kCBLDefaultVectorIndexMinTrainingSize; + +/** [0] By default, the value will be determined based on the number of centroids, encoding types, and the encoding parameters */ +extern const unsigned int kCBLDefaultVectorIndexMaxTrainingSize; + +/** [0] By default, the value will be determined based on the number of centroids. */ +extern const unsigned int kCBLDefaultVectorIndexNumProbes; + #pragma mark - CBLURLEndpointListenerConfiguration /** [0] No port specified, the OS will assign one */ diff --git a/Objective-C/CBLDefaults.m b/Objective-C/CBLDefaults.m index 8373eb6ba..585d188c3 100644 --- a/Objective-C/CBLDefaults.m +++ b/Objective-C/CBLDefaults.m @@ -26,8 +26,6 @@ const BOOL kCBLDefaultLogFileUsePlaintext = NO; -const BOOL kCBLDefaultLogFileUsePlainText = NO; - const uint64_t kCBLDefaultLogFileMaxSize = 524288; const NSInteger kCBLDefaultLogFileMaxRotateCount = 1; @@ -64,10 +62,18 @@ #pragma mark - CBLVectorIndexConfiguration +const BOOL kCBLDefaultVectorIndexIsLazy = NO; + const CBLScalarQuantizerType kCBLDefaultVectorIndexEncoding = kCBLSQ8; const CBLDistanceMetric kCBLDefaultVectorIndexDistanceMetric = kCBLDistanceMetricEuclidean; +const unsigned int kCBLDefaultVectorIndexMinTrainingSize = 0; + +const unsigned int kCBLDefaultVectorIndexMaxTrainingSize = 0; + +const unsigned int kCBLDefaultVectorIndexNumProbes = 0; + #pragma mark - CBLURLEndpointListenerConfiguration const unsigned short kCBLDefaultListenerPort = 0; diff --git a/Objective-C/Exports/CBL_EE.txt b/Objective-C/Exports/CBL_EE.txt index 79ebbef56..15d7b41c6 100644 --- a/Objective-C/Exports/CBL_EE.txt +++ b/Objective-C/Exports/CBL_EE.txt @@ -47,8 +47,12 @@ _kCBLDefaultListenerPort _kCBLDefaultListenerDisableTls _kCBLDefaultListenerReadOnly _kCBLDefaultListenerEnableDeltaSync +_kCBLDefaultVectorIndexIsLazy _kCBLDefaultVectorIndexDistanceMetric _kCBLDefaultVectorIndexEncoding +_kCBLDefaultVectorIndexMinTrainingSize +_kCBLDefaultVectorIndexMaxTrainingSize +_kCBLDefaultVectorIndexNumProbes _kCBLCertAttrCommonName _kCBLCertAttrCountry _kCBLCertAttrEmailAddress diff --git a/Objective-C/Exports/Generated/CBL_EE.exp b/Objective-C/Exports/Generated/CBL_EE.exp index babe2e82d..795be47c5 100644 --- a/Objective-C/Exports/Generated/CBL_EE.exp +++ b/Objective-C/Exports/Generated/CBL_EE.exp @@ -22,6 +22,7 @@ .objc_class_name_CBLDocumentFragment .objc_class_name_CBLDocumentReplication .objc_class_name_CBLEncryptionKey +.objc_class_name_CBLExtension .objc_class_name_CBLFileLogger .objc_class_name_CBLFragment .objc_class_name_CBLFullTextIndex @@ -130,4 +131,8 @@ _kCBLDefaultReplicatorType _kCBLDefaultScopeName _kCBLDefaultVectorIndexDistanceMetric _kCBLDefaultVectorIndexEncoding +_kCBLDefaultVectorIndexIsLazy +_kCBLDefaultVectorIndexMaxTrainingSize +_kCBLDefaultVectorIndexMinTrainingSize +_kCBLDefaultVectorIndexNumProbes _kCBLTypeProperty diff --git a/Swift/Defaults.swift b/Swift/Defaults.swift index 1adefabca..07ca1f387 100644 --- a/Swift/Defaults.swift +++ b/Swift/Defaults.swift @@ -26,10 +26,6 @@ public extension LogFileConfiguration { /// [false] Plaintext is not used, and instead binary encoding is used in log files static let defaultUsePlaintext: Bool = false - - /// [false] Plaintext is not used, and instead binary encoding is used in log files - /// @available(*, deprecated, message: "Use LogFileConfiguration.defaultUsePlaintext instead.") - static let defaultUsePlainText: Bool = false /// [524288] 512 KiB for the size of a log file static let defaultMaxSize: UInt64 = 524288 @@ -72,7 +68,7 @@ public extension ReplicatorConfiguration { /// [300] Max wait time between retry attempts in seconds /// @available(*, deprecated, message: "Use ReplicatorConfiguration.defaultMaxAttemptsWaitTime instead.") static let defaultMaxAttemptWaitTime: TimeInterval = 300 - + /// [true] Purge documents when a user loses access static let defaultEnableAutoPurge: Bool = true @@ -88,12 +84,24 @@ public extension ReplicatorConfiguration { public extension VectorIndexConfiguration { + /// [false] Vectors are not lazily indexed, by default + static let defaultIsLazy: Bool = false + /// [ScalarQuantizerType.SQ8] Vectors are encoded by using 8-bit Scalar Quantizer encoding, by default static let defaultEncoding: ScalarQuantizerType = ScalarQuantizerType.SQ8 /// [DistanceMetric.euclidean] By default, vectors are compared using Euclidean metrics static let defaultDistanceMetric: DistanceMetric = DistanceMetric.euclidean + /// [0] By default, the value will be determined based on the number of centroids, encoding types, and the encoding parameters. + static let defaultMinTrainingSize: UInt32 = 0 + + /// [0] By default, the value will be determined based on the number of centroids, encoding types, and the encoding parameters + static let defaultMaxTrainingSize: UInt32 = 0 + + /// [0] By default, the value will be determined based on the number of centroids. + static let defaultNumProbes: UInt32 = 0 + } public extension URLEndpointListenerConfiguration {