|
28 | 28 | import io.weaviate.client6.v1.api.collections.data.BatchReference; |
29 | 29 | import io.weaviate.client6.v1.api.collections.data.Reference; |
30 | 30 | import io.weaviate.client6.v1.api.collections.data.ReferenceAddManyResponse; |
| 31 | +import io.weaviate.client6.v1.api.collections.quantizers.PQ; |
31 | 32 | import io.weaviate.client6.v1.api.collections.rerankers.CohereReranker; |
32 | 33 | import io.weaviate.client6.v1.api.collections.vectorindex.Distance; |
33 | 34 | import io.weaviate.client6.v1.api.collections.vectorindex.Flat; |
@@ -147,6 +148,76 @@ public static Object[][] testCases() { |
147 | 148 | } |
148 | 149 | """, |
149 | 150 | }, |
| 151 | + { |
| 152 | + VectorConfig.class, |
| 153 | + SelfProvidedVectorizer.of(none -> none |
| 154 | + .quantization(Quantization.pq(pq -> pq |
| 155 | + .centroids(8) |
| 156 | + .encoderDistribution(PQ.EncoderDistribution.NORMAL) |
| 157 | + .encoderType(PQ.EncoderType.TILE) |
| 158 | + .segments(16) |
| 159 | + .trainingLimit(1024) |
| 160 | + .bitCompression(true)))), |
| 161 | + """ |
| 162 | + { |
| 163 | + "vectorIndexType": "hnsw", |
| 164 | + "vectorizer": {"none": {}}, |
| 165 | + "vectorIndexConfig": { |
| 166 | + "pq": { |
| 167 | + "enabled": true, |
| 168 | + "centroids": 8, |
| 169 | + "encoder_distribution": "normal", |
| 170 | + "encoder_type": "tile", |
| 171 | + "segments": 16, |
| 172 | + "training_limit": 1024, |
| 173 | + "bit_compression": true |
| 174 | + } |
| 175 | + } |
| 176 | + } |
| 177 | + """, |
| 178 | + }, |
| 179 | + { |
| 180 | + VectorConfig.class, |
| 181 | + SelfProvidedVectorizer.of(none -> none |
| 182 | + .quantization(Quantization.sq(sq -> sq |
| 183 | + .rescoreLimit(10) |
| 184 | + .trainingLimit(1024) |
| 185 | + .cache(true)))), |
| 186 | + """ |
| 187 | + { |
| 188 | + "vectorIndexType": "hnsw", |
| 189 | + "vectorizer": {"none": {}}, |
| 190 | + "vectorIndexConfig": { |
| 191 | + "sq": { |
| 192 | + "enabled": true, |
| 193 | + "rescore_limit": 10, |
| 194 | + "training_limit": 1024, |
| 195 | + "cache": true |
| 196 | + } |
| 197 | + } |
| 198 | + } |
| 199 | + """, |
| 200 | + }, |
| 201 | + { |
| 202 | + VectorConfig.class, |
| 203 | + SelfProvidedVectorizer.of(none -> none |
| 204 | + .quantization(Quantization.rq(rq -> rq |
| 205 | + .rescoreLimit(10) |
| 206 | + .bits(8)))), |
| 207 | + """ |
| 208 | + { |
| 209 | + "vectorIndexType": "hnsw", |
| 210 | + "vectorizer": {"none": {}}, |
| 211 | + "vectorIndexConfig": { |
| 212 | + "rq": { |
| 213 | + "enabled": true, |
| 214 | + "rescore_limit": 10, |
| 215 | + "bits": 8 |
| 216 | + } |
| 217 | + } |
| 218 | + } |
| 219 | + """, |
| 220 | + }, |
150 | 221 | { |
151 | 222 | VectorConfig.class, |
152 | 223 | SelfProvidedVectorizer.of(none -> none |
|
0 commit comments