You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: Doxyfile
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -2,7 +2,7 @@
2
2
# Generated by Anupam Maurya
3
3
4
4
PROJECT_NAME = "@faiss-node/native"
5
-
PROJECT_NUMBER = "0.1.2"
5
+
PROJECT_NUMBER = "0.1.10"
6
6
PROJECT_BRIEF = "High-performance Node.js native bindings for Facebook FAISS - the fastest vector similarity search library. Supports FLAT_L2, IVF_FLAT, and HNSW index types with async operations, persistence, and batch search."
-`config.pqSegments` (number, optional): Number of PQ subquantizers for PQ and IVF_PQ
124
+
-`config.pqBits` (number, optional): Bits per PQ code for PQ and IVF_PQ (default: 8)
125
+
-`config.sqType` (string, optional): Scalar quantizer type for IVF_SQ (default: `'SQ8'`)
121
126
122
-
Use `nlist` and `nprobe` only with `IVF_FLAT`, and use `M`, `efConstruction`, and `efSearch` only with `HNSW`.
127
+
Use `nlist` and `nprobe` only with `IVF_FLAT`, `IVF_PQ`, or `IVF_SQ`. Use `pqSegments`and `pqBits` only with `PQ` or `IVF_PQ`. Use `M`, `efConstruction`, and `efSearch` only with `HNSW`. Use `factory` by itself for advanced FAISS pipelines, because the topology is encoded directly in the factory string.
123
128
124
129
**Examples:**
125
130
@@ -141,6 +146,36 @@ const ivfIndex = new FaissIndex({
141
146
});
142
147
awaitivfIndex.train(trainingVectors); // Must train before adding vectors!
143
148
149
+
// PQ - Memory efficient quantization without IVF
150
+
constpqIndex=newFaissIndex({
151
+
type:'PQ',
152
+
dims:768,
153
+
pqSegments:48,
154
+
pqBits:8
155
+
});
156
+
awaitpqIndex.train(trainingVectors);
157
+
158
+
// IVF_PQ - IVF coarse quantization plus PQ compression
159
+
constivfPqIndex=newFaissIndex({
160
+
type:'IVF_PQ',
161
+
dims:768,
162
+
nlist:100,
163
+
nprobe:10,
164
+
pqSegments:48,
165
+
pqBits:8
166
+
});
167
+
awaitivfPqIndex.train(trainingVectors);
168
+
169
+
// IVF_SQ - IVF with scalar quantization
170
+
constivfSqIndex=newFaissIndex({
171
+
type:'IVF_SQ',
172
+
dims:768,
173
+
nlist:100,
174
+
nprobe:10,
175
+
sqType:'SQ8'
176
+
});
177
+
awaitivfSqIndex.train(trainingVectors);
178
+
144
179
// HNSW - State-of-the-art approximate search (best for large datasets)
145
180
consthnswIndex=newFaissIndex({
146
181
type:'HNSW',
@@ -149,6 +184,18 @@ const hnswIndex = new FaissIndex({
149
184
efConstruction:200, // Construction parameter
150
185
efSearch:50// Search parameter (higher = more accurate, slower)
0 commit comments