hyperspace-sdk-ts 3.1.1 → 3.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +158 -13
- package/dist/client.d.ts +122 -5
- package/dist/client.js +828 -168
- package/dist/math.d.ts +4 -0
- package/dist/math.js +150 -0
- package/dist/proto/hyperspace_grpc_pb.js +222 -0
- package/dist/proto/hyperspace_pb.js +9862 -4739
- package/package.json +1 -1
package/dist/math.d.ts
CHANGED
|
@@ -42,3 +42,7 @@ export declare function koopmanExtrapolate(past: number[], current: number[], st
|
|
|
42
42
|
* Pulls the thought towards the context along the geodesic by `resonanceFactor` [0, 1].
|
|
43
43
|
*/
|
|
44
44
|
export declare function contextResonance(thought: number[], globalContext: number[], resonanceFactor: number, c?: number): number[];
|
|
45
|
+
export declare function generateOrthogonalMatrix(dimension: number, seedBytes: Uint8Array): number[][];
|
|
46
|
+
export declare function generateLorentzMatrix(dimension: number, seedBytes: Uint8Array): number[][];
|
|
47
|
+
export declare function projectVector(v: number[], projectionMatrix: number[][]): number[];
|
|
48
|
+
export declare function injectAnisotropicNoise(vector: number[], noiseSeed: Uint8Array, sigma?: number): number[];
|
package/dist/math.js
CHANGED
|
@@ -21,6 +21,10 @@ exports.localEntropy = localEntropy;
|
|
|
21
21
|
exports.lyapunovConvergence = lyapunovConvergence;
|
|
22
22
|
exports.koopmanExtrapolate = koopmanExtrapolate;
|
|
23
23
|
exports.contextResonance = contextResonance;
|
|
24
|
+
exports.generateOrthogonalMatrix = generateOrthogonalMatrix;
|
|
25
|
+
exports.generateLorentzMatrix = generateLorentzMatrix;
|
|
26
|
+
exports.projectVector = projectVector;
|
|
27
|
+
exports.injectAnisotropicNoise = injectAnisotropicNoise;
|
|
24
28
|
function dot(a, b) {
|
|
25
29
|
let sum = 0;
|
|
26
30
|
for (let i = 0; i < a.length; i++)
|
|
@@ -232,3 +236,149 @@ function contextResonance(thought, globalContext, resonanceFactor, c = 1.0) {
|
|
|
232
236
|
const appliedPull = pullDir.map(v => v * factor);
|
|
233
237
|
return expMap(thought, appliedPull, c);
|
|
234
238
|
}
|
|
239
|
+
function generateOrthogonalMatrix(dimension, seedBytes) {
|
|
240
|
+
const crypto = require('crypto');
|
|
241
|
+
const matrix = [];
|
|
242
|
+
let currentHash = crypto.createHash('sha256').update(seedBytes).digest();
|
|
243
|
+
let hashOffset = 0;
|
|
244
|
+
for (let i = 0; i < dimension; i++) {
|
|
245
|
+
const row = [];
|
|
246
|
+
for (let j = 0; j < dimension; j++) {
|
|
247
|
+
if (hashOffset >= 32) {
|
|
248
|
+
currentHash = crypto.createHash('sha256').update(currentHash).digest();
|
|
249
|
+
hashOffset = 0;
|
|
250
|
+
}
|
|
251
|
+
const val = (currentHash.readUInt32LE(hashOffset) / 4294967296.0) * 2.0 - 1.0;
|
|
252
|
+
row.push(val);
|
|
253
|
+
hashOffset += 4;
|
|
254
|
+
}
|
|
255
|
+
matrix.push(row);
|
|
256
|
+
}
|
|
257
|
+
// Gram-Schmidt Orthonormalization with Reorthogonalization (twice is enough)
|
|
258
|
+
for (let i = 0; i < dimension; i++) {
|
|
259
|
+
let v = matrix[i];
|
|
260
|
+
for (let j = 0; j < i; j++) {
|
|
261
|
+
const u = matrix[j];
|
|
262
|
+
let uDotV = dot(u, v);
|
|
263
|
+
v = v.map((vi, k) => vi - uDotV * u[k]);
|
|
264
|
+
// Re-project to eliminate floating-point leakage
|
|
265
|
+
uDotV = dot(u, v);
|
|
266
|
+
v = v.map((vi, k) => vi - uDotV * u[k]);
|
|
267
|
+
}
|
|
268
|
+
const vNorm = norm(v);
|
|
269
|
+
if (vNorm > 1e-15) {
|
|
270
|
+
matrix[i] = v.map(vi => vi / vNorm);
|
|
271
|
+
}
|
|
272
|
+
else {
|
|
273
|
+
matrix[i] = new Array(dimension).fill(0);
|
|
274
|
+
matrix[i][i] = 1.0;
|
|
275
|
+
}
|
|
276
|
+
}
|
|
277
|
+
return matrix;
|
|
278
|
+
}
|
|
279
|
+
function generateLorentzMatrix(dimension, seedBytes) {
|
|
280
|
+
const d = dimension - 1;
|
|
281
|
+
const crypto = require('crypto');
|
|
282
|
+
const rSeed = crypto.createHash('sha256').update(seedBytes).update("spatial").digest();
|
|
283
|
+
const R = generateOrthogonalMatrix(d, rSeed);
|
|
284
|
+
const bSeed = crypto.createHash('sha256').update(seedBytes).update("boost").digest();
|
|
285
|
+
let beta = [];
|
|
286
|
+
let currentHash = bSeed;
|
|
287
|
+
let hashOffset = 0;
|
|
288
|
+
for (let i = 0; i < d; i++) {
|
|
289
|
+
if (hashOffset >= 32) {
|
|
290
|
+
currentHash = crypto.createHash('sha256').update(currentHash).digest();
|
|
291
|
+
hashOffset = 0;
|
|
292
|
+
}
|
|
293
|
+
const val = (currentHash.readUInt32LE(hashOffset) / 4294967296.0) * 2.0 - 1.0;
|
|
294
|
+
beta.push(val);
|
|
295
|
+
hashOffset += 4;
|
|
296
|
+
}
|
|
297
|
+
const betaNorm = norm(beta);
|
|
298
|
+
if (betaNorm > 1e-15) {
|
|
299
|
+
beta = beta.map(v => (v / betaNorm) * 0.1);
|
|
300
|
+
}
|
|
301
|
+
else {
|
|
302
|
+
beta = new Array(d).fill(0);
|
|
303
|
+
beta[0] = 0.1;
|
|
304
|
+
}
|
|
305
|
+
const betaSq = dot(beta, beta);
|
|
306
|
+
const gamma = 1.0 / Math.sqrt(1.0 - betaSq);
|
|
307
|
+
const Lambda_B = [];
|
|
308
|
+
for (let i = 0; i < dimension; i++) {
|
|
309
|
+
Lambda_B.push(new Array(dimension).fill(0));
|
|
310
|
+
}
|
|
311
|
+
Lambda_B[0][0] = gamma;
|
|
312
|
+
for (let j = 1; j < dimension; j++) {
|
|
313
|
+
Lambda_B[0][j] = -gamma * beta[j - 1];
|
|
314
|
+
Lambda_B[j][0] = -gamma * beta[j - 1];
|
|
315
|
+
}
|
|
316
|
+
const factor = (gamma - 1.0) / betaSq;
|
|
317
|
+
for (let i = 1; i < dimension; i++) {
|
|
318
|
+
for (let j = 1; j < dimension; j++) {
|
|
319
|
+
const delta = i === j ? 1.0 : 0.0;
|
|
320
|
+
Lambda_B[i][j] = delta + factor * beta[i - 1] * beta[j - 1];
|
|
321
|
+
}
|
|
322
|
+
}
|
|
323
|
+
const Lambda_R = [];
|
|
324
|
+
for (let i = 0; i < dimension; i++) {
|
|
325
|
+
Lambda_R.push(new Array(dimension).fill(0));
|
|
326
|
+
}
|
|
327
|
+
Lambda_R[0][0] = 1.0;
|
|
328
|
+
for (let i = 1; i < dimension; i++) {
|
|
329
|
+
for (let j = 1; j < dimension; j++) {
|
|
330
|
+
Lambda_R[i][j] = R[i - 1][j - 1];
|
|
331
|
+
}
|
|
332
|
+
}
|
|
333
|
+
const Lambda = [];
|
|
334
|
+
for (let i = 0; i < dimension; i++) {
|
|
335
|
+
const row = [];
|
|
336
|
+
for (let j = 0; j < dimension; j++) {
|
|
337
|
+
let sum = 0;
|
|
338
|
+
for (let k = 0; k < dimension; k++) {
|
|
339
|
+
sum += Lambda_R[i][k] * Lambda_B[k][j];
|
|
340
|
+
}
|
|
341
|
+
row.push(sum);
|
|
342
|
+
}
|
|
343
|
+
Lambda.push(row);
|
|
344
|
+
}
|
|
345
|
+
return Lambda;
|
|
346
|
+
}
|
|
347
|
+
function projectVector(v, projectionMatrix) {
|
|
348
|
+
const dimension = v.length;
|
|
349
|
+
const projected = new Array(dimension).fill(0);
|
|
350
|
+
for (let j = 0; j < dimension; j++) {
|
|
351
|
+
let sum = 0;
|
|
352
|
+
for (let i = 0; i < dimension; i++) {
|
|
353
|
+
sum += v[i] * projectionMatrix[i][j];
|
|
354
|
+
}
|
|
355
|
+
projected[j] = sum;
|
|
356
|
+
}
|
|
357
|
+
return projected;
|
|
358
|
+
}
|
|
359
|
+
function injectAnisotropicNoise(vector, noiseSeed, sigma = 0.02) {
|
|
360
|
+
if (sigma <= 0.0)
|
|
361
|
+
return [...vector];
|
|
362
|
+
const crypto = require('crypto');
|
|
363
|
+
const vecBytes = Buffer.from(vector.toString());
|
|
364
|
+
const hash = crypto.createHash('sha256').update(noiseSeed).update(vecBytes).digest();
|
|
365
|
+
let currentHash = hash;
|
|
366
|
+
const noise = [];
|
|
367
|
+
for (let i = 0; i < vector.length; i++) {
|
|
368
|
+
if (currentHash.length < 16) {
|
|
369
|
+
currentHash = crypto.createHash('sha256').update(currentHash).digest();
|
|
370
|
+
}
|
|
371
|
+
const u1 = Math.max(1e-15, (currentHash.readUInt32LE(0) + 1) / 4294967296);
|
|
372
|
+
const u2 = Math.max(1e-15, (currentHash.readUInt32LE(4) + 1) / 4294967296);
|
|
373
|
+
const z0 = Math.sqrt(-2.0 * Math.log(u1)) * Math.cos(2.0 * Math.PI * u2);
|
|
374
|
+
noise.push(z0 * sigma);
|
|
375
|
+
currentHash = currentHash.subarray(8);
|
|
376
|
+
}
|
|
377
|
+
const noisy = vector.map((v, i) => v + noise[i]);
|
|
378
|
+
const origNorm = norm(vector);
|
|
379
|
+
const noisyNorm = norm(noisy);
|
|
380
|
+
if (noisyNorm > 1e-15) {
|
|
381
|
+
return noisy.map(v => (v / noisyNorm) * origNorm);
|
|
382
|
+
}
|
|
383
|
+
return noisy;
|
|
384
|
+
}
|
|
@@ -70,6 +70,28 @@ function deserialize_hyperspace_ConfigUpdate(buffer_arg) {
|
|
|
70
70
|
return hyperspace_pb.ConfigUpdate.deserializeBinary(new Uint8Array(buffer_arg));
|
|
71
71
|
}
|
|
72
72
|
|
|
73
|
+
function serialize_hyperspace_CountRequest(arg) {
|
|
74
|
+
if (!(arg instanceof hyperspace_pb.CountRequest)) {
|
|
75
|
+
throw new Error('Expected argument of type hyperspace.CountRequest');
|
|
76
|
+
}
|
|
77
|
+
return Buffer.from(arg.serializeBinary());
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
function deserialize_hyperspace_CountRequest(buffer_arg) {
|
|
81
|
+
return hyperspace_pb.CountRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
function serialize_hyperspace_CountResponse(arg) {
|
|
85
|
+
if (!(arg instanceof hyperspace_pb.CountResponse)) {
|
|
86
|
+
throw new Error('Expected argument of type hyperspace.CountResponse');
|
|
87
|
+
}
|
|
88
|
+
return Buffer.from(arg.serializeBinary());
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
function deserialize_hyperspace_CountResponse(buffer_arg) {
|
|
92
|
+
return hyperspace_pb.CountResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
|
93
|
+
}
|
|
94
|
+
|
|
73
95
|
function serialize_hyperspace_CreateCollectionRequest(arg) {
|
|
74
96
|
if (!(arg instanceof hyperspace_pb.CreateCollectionRequest)) {
|
|
75
97
|
throw new Error('Expected argument of type hyperspace.CreateCollectionRequest');
|
|
@@ -191,6 +213,17 @@ function deserialize_hyperspace_FindSemanticClustersResponse(buffer_arg) {
|
|
|
191
213
|
return hyperspace_pb.FindSemanticClustersResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
|
192
214
|
}
|
|
193
215
|
|
|
216
|
+
function serialize_hyperspace_FreezeCollectionRequest(arg) {
|
|
217
|
+
if (!(arg instanceof hyperspace_pb.FreezeCollectionRequest)) {
|
|
218
|
+
throw new Error('Expected argument of type hyperspace.FreezeCollectionRequest');
|
|
219
|
+
}
|
|
220
|
+
return Buffer.from(arg.serializeBinary());
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
function deserialize_hyperspace_FreezeCollectionRequest(buffer_arg) {
|
|
224
|
+
return hyperspace_pb.FreezeCollectionRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
|
225
|
+
}
|
|
226
|
+
|
|
194
227
|
function serialize_hyperspace_GetConceptParentsRequest(arg) {
|
|
195
228
|
if (!(arg instanceof hyperspace_pb.GetConceptParentsRequest)) {
|
|
196
229
|
throw new Error('Expected argument of type hyperspace.GetConceptParentsRequest');
|
|
@@ -246,6 +279,50 @@ function deserialize_hyperspace_GetNodeRequest(buffer_arg) {
|
|
|
246
279
|
return hyperspace_pb.GetNodeRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
|
247
280
|
}
|
|
248
281
|
|
|
282
|
+
function serialize_hyperspace_GetPointsRequest(arg) {
|
|
283
|
+
if (!(arg instanceof hyperspace_pb.GetPointsRequest)) {
|
|
284
|
+
throw new Error('Expected argument of type hyperspace.GetPointsRequest');
|
|
285
|
+
}
|
|
286
|
+
return Buffer.from(arg.serializeBinary());
|
|
287
|
+
}
|
|
288
|
+
|
|
289
|
+
function deserialize_hyperspace_GetPointsRequest(buffer_arg) {
|
|
290
|
+
return hyperspace_pb.GetPointsRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
|
291
|
+
}
|
|
292
|
+
|
|
293
|
+
function serialize_hyperspace_GetPointsResponse(arg) {
|
|
294
|
+
if (!(arg instanceof hyperspace_pb.GetPointsResponse)) {
|
|
295
|
+
throw new Error('Expected argument of type hyperspace.GetPointsResponse');
|
|
296
|
+
}
|
|
297
|
+
return Buffer.from(arg.serializeBinary());
|
|
298
|
+
}
|
|
299
|
+
|
|
300
|
+
function deserialize_hyperspace_GetPointsResponse(buffer_arg) {
|
|
301
|
+
return hyperspace_pb.GetPointsResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
|
302
|
+
}
|
|
303
|
+
|
|
304
|
+
function serialize_hyperspace_GetSubsumptionTreeRequest(arg) {
|
|
305
|
+
if (!(arg instanceof hyperspace_pb.GetSubsumptionTreeRequest)) {
|
|
306
|
+
throw new Error('Expected argument of type hyperspace.GetSubsumptionTreeRequest');
|
|
307
|
+
}
|
|
308
|
+
return Buffer.from(arg.serializeBinary());
|
|
309
|
+
}
|
|
310
|
+
|
|
311
|
+
function deserialize_hyperspace_GetSubsumptionTreeRequest(buffer_arg) {
|
|
312
|
+
return hyperspace_pb.GetSubsumptionTreeRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
|
313
|
+
}
|
|
314
|
+
|
|
315
|
+
function serialize_hyperspace_GetSubsumptionTreeResponse(arg) {
|
|
316
|
+
if (!(arg instanceof hyperspace_pb.GetSubsumptionTreeResponse)) {
|
|
317
|
+
throw new Error('Expected argument of type hyperspace.GetSubsumptionTreeResponse');
|
|
318
|
+
}
|
|
319
|
+
return Buffer.from(arg.serializeBinary());
|
|
320
|
+
}
|
|
321
|
+
|
|
322
|
+
function deserialize_hyperspace_GetSubsumptionTreeResponse(buffer_arg) {
|
|
323
|
+
return hyperspace_pb.GetSubsumptionTreeResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
|
324
|
+
}
|
|
325
|
+
|
|
249
326
|
function serialize_hyperspace_GraphNode(arg) {
|
|
250
327
|
if (!(arg instanceof hyperspace_pb.GraphNode)) {
|
|
251
328
|
throw new Error('Expected argument of type hyperspace.GraphNode');
|
|
@@ -257,6 +334,17 @@ function deserialize_hyperspace_GraphNode(buffer_arg) {
|
|
|
257
334
|
return hyperspace_pb.GraphNode.deserializeBinary(new Uint8Array(buffer_arg));
|
|
258
335
|
}
|
|
259
336
|
|
|
337
|
+
function serialize_hyperspace_HealthCheckResponse(arg) {
|
|
338
|
+
if (!(arg instanceof hyperspace_pb.HealthCheckResponse)) {
|
|
339
|
+
throw new Error('Expected argument of type hyperspace.HealthCheckResponse');
|
|
340
|
+
}
|
|
341
|
+
return Buffer.from(arg.serializeBinary());
|
|
342
|
+
}
|
|
343
|
+
|
|
344
|
+
function deserialize_hyperspace_HealthCheckResponse(buffer_arg) {
|
|
345
|
+
return hyperspace_pb.HealthCheckResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
|
346
|
+
}
|
|
347
|
+
|
|
260
348
|
function serialize_hyperspace_InsertRequest(arg) {
|
|
261
349
|
if (!(arg instanceof hyperspace_pb.InsertRequest)) {
|
|
262
350
|
throw new Error('Expected argument of type hyperspace.InsertRequest');
|
|
@@ -356,6 +444,28 @@ function deserialize_hyperspace_ReplicationRequest(buffer_arg) {
|
|
|
356
444
|
return hyperspace_pb.ReplicationRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
|
357
445
|
}
|
|
358
446
|
|
|
447
|
+
function serialize_hyperspace_ScrollRequest(arg) {
|
|
448
|
+
if (!(arg instanceof hyperspace_pb.ScrollRequest)) {
|
|
449
|
+
throw new Error('Expected argument of type hyperspace.ScrollRequest');
|
|
450
|
+
}
|
|
451
|
+
return Buffer.from(arg.serializeBinary());
|
|
452
|
+
}
|
|
453
|
+
|
|
454
|
+
function deserialize_hyperspace_ScrollRequest(buffer_arg) {
|
|
455
|
+
return hyperspace_pb.ScrollRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
|
456
|
+
}
|
|
457
|
+
|
|
458
|
+
function serialize_hyperspace_ScrollResponse(arg) {
|
|
459
|
+
if (!(arg instanceof hyperspace_pb.ScrollResponse)) {
|
|
460
|
+
throw new Error('Expected argument of type hyperspace.ScrollResponse');
|
|
461
|
+
}
|
|
462
|
+
return Buffer.from(arg.serializeBinary());
|
|
463
|
+
}
|
|
464
|
+
|
|
465
|
+
function deserialize_hyperspace_ScrollResponse(buffer_arg) {
|
|
466
|
+
return hyperspace_pb.ScrollResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
|
467
|
+
}
|
|
468
|
+
|
|
359
469
|
function serialize_hyperspace_SearchMultiCollectionRequest(arg) {
|
|
360
470
|
if (!(arg instanceof hyperspace_pb.SearchMultiCollectionRequest)) {
|
|
361
471
|
throw new Error('Expected argument of type hyperspace.SearchMultiCollectionRequest');
|
|
@@ -510,6 +620,28 @@ function deserialize_hyperspace_TraverseResponse(buffer_arg) {
|
|
|
510
620
|
return hyperspace_pb.TraverseResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
|
511
621
|
}
|
|
512
622
|
|
|
623
|
+
function serialize_hyperspace_UnfreezeCollectionRequest(arg) {
|
|
624
|
+
if (!(arg instanceof hyperspace_pb.UnfreezeCollectionRequest)) {
|
|
625
|
+
throw new Error('Expected argument of type hyperspace.UnfreezeCollectionRequest');
|
|
626
|
+
}
|
|
627
|
+
return Buffer.from(arg.serializeBinary());
|
|
628
|
+
}
|
|
629
|
+
|
|
630
|
+
function deserialize_hyperspace_UnfreezeCollectionRequest(buffer_arg) {
|
|
631
|
+
return hyperspace_pb.UnfreezeCollectionRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
|
632
|
+
}
|
|
633
|
+
|
|
634
|
+
function serialize_hyperspace_UpdatePayloadRequest(arg) {
|
|
635
|
+
if (!(arg instanceof hyperspace_pb.UpdatePayloadRequest)) {
|
|
636
|
+
throw new Error('Expected argument of type hyperspace.UpdatePayloadRequest');
|
|
637
|
+
}
|
|
638
|
+
return Buffer.from(arg.serializeBinary());
|
|
639
|
+
}
|
|
640
|
+
|
|
641
|
+
function deserialize_hyperspace_UpdatePayloadRequest(buffer_arg) {
|
|
642
|
+
return hyperspace_pb.UpdatePayloadRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
|
643
|
+
}
|
|
644
|
+
|
|
513
645
|
function serialize_hyperspace_VectorizeRequest(arg) {
|
|
514
646
|
if (!(arg instanceof hyperspace_pb.VectorizeRequest)) {
|
|
515
647
|
throw new Error('Expected argument of type hyperspace.VectorizeRequest');
|
|
@@ -579,6 +711,28 @@ createCollection: {
|
|
|
579
711
|
responseSerialize: serialize_hyperspace_CollectionStatsResponse,
|
|
580
712
|
responseDeserialize: deserialize_hyperspace_CollectionStatsResponse,
|
|
581
713
|
},
|
|
714
|
+
freezeCollection: {
|
|
715
|
+
path: '/hyperspace.Database/FreezeCollection',
|
|
716
|
+
requestStream: false,
|
|
717
|
+
responseStream: false,
|
|
718
|
+
requestType: hyperspace_pb.FreezeCollectionRequest,
|
|
719
|
+
responseType: hyperspace_pb.StatusResponse,
|
|
720
|
+
requestSerialize: serialize_hyperspace_FreezeCollectionRequest,
|
|
721
|
+
requestDeserialize: deserialize_hyperspace_FreezeCollectionRequest,
|
|
722
|
+
responseSerialize: serialize_hyperspace_StatusResponse,
|
|
723
|
+
responseDeserialize: deserialize_hyperspace_StatusResponse,
|
|
724
|
+
},
|
|
725
|
+
unfreezeCollection: {
|
|
726
|
+
path: '/hyperspace.Database/UnfreezeCollection',
|
|
727
|
+
requestStream: false,
|
|
728
|
+
responseStream: false,
|
|
729
|
+
requestType: hyperspace_pb.UnfreezeCollectionRequest,
|
|
730
|
+
responseType: hyperspace_pb.StatusResponse,
|
|
731
|
+
requestSerialize: serialize_hyperspace_UnfreezeCollectionRequest,
|
|
732
|
+
requestDeserialize: deserialize_hyperspace_UnfreezeCollectionRequest,
|
|
733
|
+
responseSerialize: serialize_hyperspace_StatusResponse,
|
|
734
|
+
responseDeserialize: deserialize_hyperspace_StatusResponse,
|
|
735
|
+
},
|
|
582
736
|
// Insert vectors
|
|
583
737
|
insert: {
|
|
584
738
|
path: '/hyperspace.Database/Insert',
|
|
@@ -647,6 +801,51 @@ delete: {
|
|
|
647
801
|
responseSerialize: serialize_hyperspace_DeleteResponse,
|
|
648
802
|
responseDeserialize: deserialize_hyperspace_DeleteResponse,
|
|
649
803
|
},
|
|
804
|
+
// Extended Data Ops
|
|
805
|
+
getPoints: {
|
|
806
|
+
path: '/hyperspace.Database/GetPoints',
|
|
807
|
+
requestStream: false,
|
|
808
|
+
responseStream: false,
|
|
809
|
+
requestType: hyperspace_pb.GetPointsRequest,
|
|
810
|
+
responseType: hyperspace_pb.GetPointsResponse,
|
|
811
|
+
requestSerialize: serialize_hyperspace_GetPointsRequest,
|
|
812
|
+
requestDeserialize: deserialize_hyperspace_GetPointsRequest,
|
|
813
|
+
responseSerialize: serialize_hyperspace_GetPointsResponse,
|
|
814
|
+
responseDeserialize: deserialize_hyperspace_GetPointsResponse,
|
|
815
|
+
},
|
|
816
|
+
updatePayload: {
|
|
817
|
+
path: '/hyperspace.Database/UpdatePayload',
|
|
818
|
+
requestStream: false,
|
|
819
|
+
responseStream: false,
|
|
820
|
+
requestType: hyperspace_pb.UpdatePayloadRequest,
|
|
821
|
+
responseType: hyperspace_pb.StatusResponse,
|
|
822
|
+
requestSerialize: serialize_hyperspace_UpdatePayloadRequest,
|
|
823
|
+
requestDeserialize: deserialize_hyperspace_UpdatePayloadRequest,
|
|
824
|
+
responseSerialize: serialize_hyperspace_StatusResponse,
|
|
825
|
+
responseDeserialize: deserialize_hyperspace_StatusResponse,
|
|
826
|
+
},
|
|
827
|
+
scroll: {
|
|
828
|
+
path: '/hyperspace.Database/Scroll',
|
|
829
|
+
requestStream: false,
|
|
830
|
+
responseStream: false,
|
|
831
|
+
requestType: hyperspace_pb.ScrollRequest,
|
|
832
|
+
responseType: hyperspace_pb.ScrollResponse,
|
|
833
|
+
requestSerialize: serialize_hyperspace_ScrollRequest,
|
|
834
|
+
requestDeserialize: deserialize_hyperspace_ScrollRequest,
|
|
835
|
+
responseSerialize: serialize_hyperspace_ScrollResponse,
|
|
836
|
+
responseDeserialize: deserialize_hyperspace_ScrollResponse,
|
|
837
|
+
},
|
|
838
|
+
count: {
|
|
839
|
+
path: '/hyperspace.Database/Count',
|
|
840
|
+
requestStream: false,
|
|
841
|
+
responseStream: false,
|
|
842
|
+
requestType: hyperspace_pb.CountRequest,
|
|
843
|
+
responseType: hyperspace_pb.CountResponse,
|
|
844
|
+
requestSerialize: serialize_hyperspace_CountRequest,
|
|
845
|
+
requestDeserialize: deserialize_hyperspace_CountRequest,
|
|
846
|
+
responseSerialize: serialize_hyperspace_CountResponse,
|
|
847
|
+
responseDeserialize: deserialize_hyperspace_CountResponse,
|
|
848
|
+
},
|
|
650
849
|
// Search (ANN)
|
|
651
850
|
search: {
|
|
652
851
|
path: '/hyperspace.Database/Search',
|
|
@@ -739,6 +938,17 @@ getNode: {
|
|
|
739
938
|
responseSerialize: serialize_hyperspace_FindSemanticClustersResponse,
|
|
740
939
|
responseDeserialize: deserialize_hyperspace_FindSemanticClustersResponse,
|
|
741
940
|
},
|
|
941
|
+
getSubsumptionTree: {
|
|
942
|
+
path: '/hyperspace.Database/GetSubsumptionTree',
|
|
943
|
+
requestStream: false,
|
|
944
|
+
responseStream: false,
|
|
945
|
+
requestType: hyperspace_pb.GetSubsumptionTreeRequest,
|
|
946
|
+
responseType: hyperspace_pb.GetSubsumptionTreeResponse,
|
|
947
|
+
requestSerialize: serialize_hyperspace_GetSubsumptionTreeRequest,
|
|
948
|
+
requestDeserialize: deserialize_hyperspace_GetSubsumptionTreeRequest,
|
|
949
|
+
responseSerialize: serialize_hyperspace_GetSubsumptionTreeResponse,
|
|
950
|
+
responseDeserialize: deserialize_hyperspace_GetSubsumptionTreeResponse,
|
|
951
|
+
},
|
|
742
952
|
// Stream statistics for TUI (Global or Collection tailored)
|
|
743
953
|
monitor: {
|
|
744
954
|
path: '/hyperspace.Database/Monitor',
|
|
@@ -880,6 +1090,18 @@ syncPush: {
|
|
|
880
1090
|
responseSerialize: serialize_hyperspace_SyncPushResponse,
|
|
881
1091
|
responseDeserialize: deserialize_hyperspace_SyncPushResponse,
|
|
882
1092
|
},
|
|
1093
|
+
// Health Status
|
|
1094
|
+
healthCheck: {
|
|
1095
|
+
path: '/hyperspace.Database/HealthCheck',
|
|
1096
|
+
requestStream: false,
|
|
1097
|
+
responseStream: false,
|
|
1098
|
+
requestType: hyperspace_pb.Empty,
|
|
1099
|
+
responseType: hyperspace_pb.HealthCheckResponse,
|
|
1100
|
+
requestSerialize: serialize_hyperspace_Empty,
|
|
1101
|
+
requestDeserialize: deserialize_hyperspace_Empty,
|
|
1102
|
+
responseSerialize: serialize_hyperspace_HealthCheckResponse,
|
|
1103
|
+
responseDeserialize: deserialize_hyperspace_HealthCheckResponse,
|
|
1104
|
+
},
|
|
883
1105
|
};
|
|
884
1106
|
|
|
885
1107
|
exports.DatabaseClient = grpc.makeGenericClientConstructor(DatabaseService, 'Database');
|