@ruvector/edge-net 0.1.0
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/LICENSE +21 -0
- package/README.md +1168 -0
- package/cli.js +275 -0
- package/package.json +72 -0
- package/ruvector_edge_net.d.ts +2939 -0
- package/ruvector_edge_net.js +8049 -0
- package/ruvector_edge_net_bg.wasm +0 -0
- package/ruvector_edge_net_bg.wasm.d.ts +625 -0
|
@@ -0,0 +1,2939 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
|
|
4
|
+
export class AdaptiveSecurity {
|
|
5
|
+
free(): void;
|
|
6
|
+
[Symbol.dispose](): void;
|
|
7
|
+
/**
|
|
8
|
+
* Choose action using epsilon-greedy policy
|
|
9
|
+
*/
|
|
10
|
+
chooseAction(state: string, available_actions: string): string;
|
|
11
|
+
/**
|
|
12
|
+
* Detect if request matches known attack pattern
|
|
13
|
+
*/
|
|
14
|
+
detectAttack(features: Float32Array): number;
|
|
15
|
+
/**
|
|
16
|
+
* Export learned patterns for persistence
|
|
17
|
+
*/
|
|
18
|
+
exportPatterns(): Uint8Array;
|
|
19
|
+
/**
|
|
20
|
+
* Import learned patterns
|
|
21
|
+
*/
|
|
22
|
+
importPatterns(data: Uint8Array): void;
|
|
23
|
+
getMinReputation(): number;
|
|
24
|
+
getRateLimitMax(): number;
|
|
25
|
+
getSecurityLevel(): number;
|
|
26
|
+
/**
|
|
27
|
+
* Get current adaptive thresholds
|
|
28
|
+
*/
|
|
29
|
+
getRateLimitWindow(): bigint;
|
|
30
|
+
/**
|
|
31
|
+
* Record attack pattern for learning
|
|
32
|
+
*/
|
|
33
|
+
recordAttackPattern(pattern_type: string, features: Float32Array, severity: number): void;
|
|
34
|
+
/**
|
|
35
|
+
* Update network health metrics
|
|
36
|
+
*/
|
|
37
|
+
updateNetworkHealth(active_nodes: number, suspicious_nodes: number, attacks_hour: number, false_positives: number, avg_response_ms: number): void;
|
|
38
|
+
getSpotCheckProbability(): number;
|
|
39
|
+
constructor();
|
|
40
|
+
/**
|
|
41
|
+
* Learn from security event outcome (batched for better performance)
|
|
42
|
+
*/
|
|
43
|
+
learn(state: string, action: string, reward: number, next_state: string): void;
|
|
44
|
+
/**
|
|
45
|
+
* Get learning statistics
|
|
46
|
+
*/
|
|
47
|
+
getStats(): string;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
export class AdversarialSimulator {
|
|
51
|
+
free(): void;
|
|
52
|
+
[Symbol.dispose](): void;
|
|
53
|
+
/**
|
|
54
|
+
* Simulate DDoS attack
|
|
55
|
+
*/
|
|
56
|
+
simulateDDoS(requests_per_second: number, duration_ms: bigint): string;
|
|
57
|
+
/**
|
|
58
|
+
* Simulate Sybil attack
|
|
59
|
+
*/
|
|
60
|
+
simulateSybil(fake_nodes: number, same_fingerprint: boolean): string;
|
|
61
|
+
/**
|
|
62
|
+
* Enable chaos mode for continuous testing
|
|
63
|
+
*/
|
|
64
|
+
enableChaosMode(enabled: boolean): void;
|
|
65
|
+
/**
|
|
66
|
+
* Run comprehensive security audit
|
|
67
|
+
*/
|
|
68
|
+
runSecurityAudit(): string;
|
|
69
|
+
/**
|
|
70
|
+
* Simulate Byzantine node behavior
|
|
71
|
+
*/
|
|
72
|
+
simulateByzantine(byzantine_nodes: number, total_nodes: number): string;
|
|
73
|
+
/**
|
|
74
|
+
* Get defence metrics
|
|
75
|
+
*/
|
|
76
|
+
getDefenceMetrics(): string;
|
|
77
|
+
/**
|
|
78
|
+
* Get recommendations based on testing
|
|
79
|
+
*/
|
|
80
|
+
getRecommendations(): string;
|
|
81
|
+
/**
|
|
82
|
+
* Generate chaos event
|
|
83
|
+
*/
|
|
84
|
+
generateChaosEvent(): string | undefined;
|
|
85
|
+
/**
|
|
86
|
+
* Simulate free-riding attack
|
|
87
|
+
*/
|
|
88
|
+
simulateFreeRiding(consumption_rate: number, contribution_rate: number): string;
|
|
89
|
+
/**
|
|
90
|
+
* Simulate double-spend attempt
|
|
91
|
+
*/
|
|
92
|
+
simulateDoubleSpend(amount: bigint, concurrent_targets: number): string;
|
|
93
|
+
/**
|
|
94
|
+
* Simulate result tampering
|
|
95
|
+
*/
|
|
96
|
+
simulateResultTampering(tamper_percentage: number): string;
|
|
97
|
+
constructor();
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
export class AuditLog {
|
|
101
|
+
free(): void;
|
|
102
|
+
[Symbol.dispose](): void;
|
|
103
|
+
/**
|
|
104
|
+
* Export events as JSON
|
|
105
|
+
*/
|
|
106
|
+
exportEvents(): string;
|
|
107
|
+
/**
|
|
108
|
+
* Get events for a node
|
|
109
|
+
*/
|
|
110
|
+
getEventsForNode(node_id: string): number;
|
|
111
|
+
/**
|
|
112
|
+
* Get events by severity
|
|
113
|
+
*/
|
|
114
|
+
getEventsBySeverity(min_severity: number): number;
|
|
115
|
+
/**
|
|
116
|
+
* Log an event
|
|
117
|
+
*/
|
|
118
|
+
log(event_type: string, node_id: string, details: string, severity: number): void;
|
|
119
|
+
constructor();
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
export class BrowserFingerprint {
|
|
123
|
+
private constructor();
|
|
124
|
+
free(): void;
|
|
125
|
+
[Symbol.dispose](): void;
|
|
126
|
+
/**
|
|
127
|
+
* Generate anonymous uniqueness score
|
|
128
|
+
* This doesn't track users, just ensures one node per browser
|
|
129
|
+
*/
|
|
130
|
+
static generate(): Promise<string>;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
export class ByzantineDetector {
|
|
134
|
+
free(): void;
|
|
135
|
+
[Symbol.dispose](): void;
|
|
136
|
+
/**
|
|
137
|
+
* Get maximum allowed magnitude
|
|
138
|
+
*/
|
|
139
|
+
getMaxMagnitude(): number;
|
|
140
|
+
/**
|
|
141
|
+
* Create a new Byzantine detector
|
|
142
|
+
*/
|
|
143
|
+
constructor(max_magnitude: number, zscore_threshold: number);
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
export class CoherenceEngine {
|
|
147
|
+
free(): void;
|
|
148
|
+
[Symbol.dispose](): void;
|
|
149
|
+
/**
|
|
150
|
+
* Get event log length
|
|
151
|
+
*/
|
|
152
|
+
eventCount(): number;
|
|
153
|
+
/**
|
|
154
|
+
* Check if context has drifted
|
|
155
|
+
*/
|
|
156
|
+
hasDrifted(context_hex: string): boolean;
|
|
157
|
+
/**
|
|
158
|
+
* Check if a claim can be used in decisions
|
|
159
|
+
*/
|
|
160
|
+
canUseClaim(claim_id: string): boolean;
|
|
161
|
+
/**
|
|
162
|
+
* Get witness count for a claim
|
|
163
|
+
*/
|
|
164
|
+
witnessCount(claim_id: string): number;
|
|
165
|
+
/**
|
|
166
|
+
* Get conflict count
|
|
167
|
+
*/
|
|
168
|
+
conflictCount(): number;
|
|
169
|
+
/**
|
|
170
|
+
* Get current Merkle root
|
|
171
|
+
*/
|
|
172
|
+
getMerkleRoot(): string;
|
|
173
|
+
/**
|
|
174
|
+
* Get quarantined claim count
|
|
175
|
+
*/
|
|
176
|
+
quarantinedCount(): number;
|
|
177
|
+
/**
|
|
178
|
+
* Check quarantine level for a claim
|
|
179
|
+
*/
|
|
180
|
+
getQuarantineLevel(claim_id: string): number;
|
|
181
|
+
/**
|
|
182
|
+
* Check if claim has sufficient witnesses
|
|
183
|
+
*/
|
|
184
|
+
hasSufficientWitnesses(claim_id: string): boolean;
|
|
185
|
+
/**
|
|
186
|
+
* Create a new coherence engine
|
|
187
|
+
*/
|
|
188
|
+
constructor();
|
|
189
|
+
/**
|
|
190
|
+
* Get drift for a context
|
|
191
|
+
*/
|
|
192
|
+
getDrift(context_hex: string): number;
|
|
193
|
+
/**
|
|
194
|
+
* Get statistics as JSON
|
|
195
|
+
*/
|
|
196
|
+
getStats(): string;
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
export class CollectiveMemory {
|
|
200
|
+
free(): void;
|
|
201
|
+
[Symbol.dispose](): void;
|
|
202
|
+
/**
|
|
203
|
+
* Get queue size
|
|
204
|
+
*/
|
|
205
|
+
queueSize(): number;
|
|
206
|
+
/**
|
|
207
|
+
* Run consolidation (call during idle periods)
|
|
208
|
+
*/
|
|
209
|
+
consolidate(): number;
|
|
210
|
+
/**
|
|
211
|
+
* Check if a pattern ID exists
|
|
212
|
+
*/
|
|
213
|
+
hasPattern(pattern_id: string): boolean;
|
|
214
|
+
/**
|
|
215
|
+
* Get pattern count in shared index
|
|
216
|
+
*/
|
|
217
|
+
patternCount(): number;
|
|
218
|
+
/**
|
|
219
|
+
* Create new collective memory with default config
|
|
220
|
+
*/
|
|
221
|
+
constructor(node_id: string);
|
|
222
|
+
/**
|
|
223
|
+
* Search for similar patterns
|
|
224
|
+
*/
|
|
225
|
+
search(query_json: string, k: number): string;
|
|
226
|
+
/**
|
|
227
|
+
* Get statistics as JSON
|
|
228
|
+
*/
|
|
229
|
+
getStats(): string;
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
export class ContributionStream {
|
|
233
|
+
free(): void;
|
|
234
|
+
[Symbol.dispose](): void;
|
|
235
|
+
/**
|
|
236
|
+
* Check if streams are healthy
|
|
237
|
+
*/
|
|
238
|
+
isHealthy(): boolean;
|
|
239
|
+
/**
|
|
240
|
+
* Process network fee distribution
|
|
241
|
+
*/
|
|
242
|
+
processFees(total_fees: bigint, epoch: bigint): bigint;
|
|
243
|
+
/**
|
|
244
|
+
* Get total distributed
|
|
245
|
+
*/
|
|
246
|
+
getTotalDistributed(): bigint;
|
|
247
|
+
constructor();
|
|
248
|
+
}
|
|
249
|
+
|
|
250
|
+
export class DifferentialPrivacy {
|
|
251
|
+
free(): void;
|
|
252
|
+
[Symbol.dispose](): void;
|
|
253
|
+
/**
|
|
254
|
+
* Check if DP is enabled
|
|
255
|
+
*/
|
|
256
|
+
isEnabled(): boolean;
|
|
257
|
+
/**
|
|
258
|
+
* Get epsilon value
|
|
259
|
+
*/
|
|
260
|
+
getEpsilon(): number;
|
|
261
|
+
/**
|
|
262
|
+
* Enable/disable differential privacy
|
|
263
|
+
*/
|
|
264
|
+
setEnabled(enabled: boolean): void;
|
|
265
|
+
/**
|
|
266
|
+
* Create a new differential privacy module
|
|
267
|
+
*/
|
|
268
|
+
constructor(epsilon: number, sensitivity: number);
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
export class DriftTracker {
|
|
272
|
+
free(): void;
|
|
273
|
+
[Symbol.dispose](): void;
|
|
274
|
+
/**
|
|
275
|
+
* Check if context has drifted beyond threshold
|
|
276
|
+
*/
|
|
277
|
+
hasDrifted(context_hex: string): boolean;
|
|
278
|
+
/**
|
|
279
|
+
* Get contexts with significant drift
|
|
280
|
+
*/
|
|
281
|
+
getDriftedContexts(): string;
|
|
282
|
+
/**
|
|
283
|
+
* Create a new drift tracker
|
|
284
|
+
*/
|
|
285
|
+
constructor(drift_threshold: number);
|
|
286
|
+
/**
|
|
287
|
+
* Get drift for a context
|
|
288
|
+
*/
|
|
289
|
+
getDrift(context_hex: string): number;
|
|
290
|
+
}
|
|
291
|
+
|
|
292
|
+
export class EconomicEngine {
|
|
293
|
+
free(): void;
|
|
294
|
+
[Symbol.dispose](): void;
|
|
295
|
+
/**
|
|
296
|
+
* Get economic health status
|
|
297
|
+
*/
|
|
298
|
+
getHealth(): EconomicHealth;
|
|
299
|
+
/**
|
|
300
|
+
* Get treasury balance
|
|
301
|
+
*/
|
|
302
|
+
getTreasury(): bigint;
|
|
303
|
+
/**
|
|
304
|
+
* Advance to next epoch
|
|
305
|
+
*/
|
|
306
|
+
advanceEpoch(): void;
|
|
307
|
+
/**
|
|
308
|
+
* Process task completion and distribute rewards
|
|
309
|
+
*/
|
|
310
|
+
processReward(base_amount: bigint, multiplier: number): RewardDistribution;
|
|
311
|
+
/**
|
|
312
|
+
* Get protocol fund balance (for development sustainability)
|
|
313
|
+
*/
|
|
314
|
+
getProtocolFund(): bigint;
|
|
315
|
+
/**
|
|
316
|
+
* Check if network can sustain itself
|
|
317
|
+
*/
|
|
318
|
+
isSelfSustaining(active_nodes: number, daily_tasks: bigint): boolean;
|
|
319
|
+
constructor();
|
|
320
|
+
}
|
|
321
|
+
|
|
322
|
+
export class EconomicHealth {
|
|
323
|
+
private constructor();
|
|
324
|
+
free(): void;
|
|
325
|
+
[Symbol.dispose](): void;
|
|
326
|
+
/**
|
|
327
|
+
* Velocity of rUv (transactions per period)
|
|
328
|
+
*/
|
|
329
|
+
velocity: number;
|
|
330
|
+
/**
|
|
331
|
+
* Network utilization rate
|
|
332
|
+
*/
|
|
333
|
+
utilization: number;
|
|
334
|
+
/**
|
|
335
|
+
* Supply growth rate
|
|
336
|
+
*/
|
|
337
|
+
growth_rate: number;
|
|
338
|
+
/**
|
|
339
|
+
* Stability index (0-1)
|
|
340
|
+
*/
|
|
341
|
+
stability: number;
|
|
342
|
+
}
|
|
343
|
+
|
|
344
|
+
export class EdgeNetConfig {
|
|
345
|
+
free(): void;
|
|
346
|
+
[Symbol.dispose](): void;
|
|
347
|
+
memoryLimit(bytes: number): EdgeNetConfig;
|
|
348
|
+
minIdleTime(ms: number): EdgeNetConfig;
|
|
349
|
+
respectBattery(respect: boolean): EdgeNetConfig;
|
|
350
|
+
constructor(site_id: string);
|
|
351
|
+
build(): EdgeNetNode;
|
|
352
|
+
addRelay(url: string): EdgeNetConfig;
|
|
353
|
+
cpuLimit(limit: number): EdgeNetConfig;
|
|
354
|
+
}
|
|
355
|
+
|
|
356
|
+
export class EdgeNetNode {
|
|
357
|
+
free(): void;
|
|
358
|
+
[Symbol.dispose](): void;
|
|
359
|
+
/**
|
|
360
|
+
* Disconnect from the network
|
|
361
|
+
*/
|
|
362
|
+
disconnect(): void;
|
|
363
|
+
/**
|
|
364
|
+
* Enable HDC for hyperdimensional computing
|
|
365
|
+
*/
|
|
366
|
+
enableHDC(): boolean;
|
|
367
|
+
/**
|
|
368
|
+
* Enable Neural Autonomous Organization for governance
|
|
369
|
+
*/
|
|
370
|
+
enableNAO(quorum: number): boolean;
|
|
371
|
+
/**
|
|
372
|
+
* Enable WTA for instant decisions
|
|
373
|
+
*/
|
|
374
|
+
enableWTA(num_neurons: number): boolean;
|
|
375
|
+
/**
|
|
376
|
+
* Enable BTSP for one-shot learning
|
|
377
|
+
*/
|
|
378
|
+
enableBTSP(input_dim: number): boolean;
|
|
379
|
+
/**
|
|
380
|
+
* Propose an action in the NAO
|
|
381
|
+
*/
|
|
382
|
+
proposeNAO(action: string): string;
|
|
383
|
+
/**
|
|
384
|
+
* Alias for creditBalance - returns rUv balance
|
|
385
|
+
*/
|
|
386
|
+
ruvBalance(): bigint;
|
|
387
|
+
/**
|
|
388
|
+
* Submit a task to the network
|
|
389
|
+
*/
|
|
390
|
+
submitTask(task_type: string, payload: Uint8Array, max_credits: bigint): Promise<any>;
|
|
391
|
+
/**
|
|
392
|
+
* Check for active celebration events
|
|
393
|
+
*/
|
|
394
|
+
checkEvents(): string;
|
|
395
|
+
/**
|
|
396
|
+
* Get current throttle level (0.0 - 1.0)
|
|
397
|
+
*/
|
|
398
|
+
getThrottle(): number;
|
|
399
|
+
/**
|
|
400
|
+
* Get treasury balance for operations
|
|
401
|
+
*/
|
|
402
|
+
getTreasury(): bigint;
|
|
403
|
+
/**
|
|
404
|
+
* Check if a claim can be used (not quarantined)
|
|
405
|
+
*/
|
|
406
|
+
canUseClaim(claim_id: string): boolean;
|
|
407
|
+
/**
|
|
408
|
+
* Process epoch for economic distribution
|
|
409
|
+
*/
|
|
410
|
+
processEpoch(): void;
|
|
411
|
+
/**
|
|
412
|
+
* Store a learned pattern in the reasoning bank
|
|
413
|
+
*/
|
|
414
|
+
storePattern(pattern_json: string): number;
|
|
415
|
+
/**
|
|
416
|
+
* Get current rUv (Resource Utility Voucher) balance
|
|
417
|
+
*/
|
|
418
|
+
creditBalance(): bigint;
|
|
419
|
+
/**
|
|
420
|
+
* Get motivational message (subtle Easter egg)
|
|
421
|
+
*/
|
|
422
|
+
getMotivation(): string;
|
|
423
|
+
/**
|
|
424
|
+
* Get current contribution multiplier based on network size
|
|
425
|
+
*/
|
|
426
|
+
getMultiplier(): number;
|
|
427
|
+
/**
|
|
428
|
+
* Prune low-quality learned patterns
|
|
429
|
+
*/
|
|
430
|
+
prunePatterns(min_usage: number, min_confidence: number): number;
|
|
431
|
+
/**
|
|
432
|
+
* Get current Merkle root for audit (Axiom 11: Equivocation detectable)
|
|
433
|
+
*/
|
|
434
|
+
getMerkleRoot(): string;
|
|
435
|
+
/**
|
|
436
|
+
* Lookup similar patterns for task optimization
|
|
437
|
+
*/
|
|
438
|
+
lookupPatterns(query_json: string, k: number): string;
|
|
439
|
+
/**
|
|
440
|
+
* Get all available exotic capabilities and their status
|
|
441
|
+
*/
|
|
442
|
+
getCapabilities(): any;
|
|
443
|
+
/**
|
|
444
|
+
* Check if this node should replicate (high performer)
|
|
445
|
+
*/
|
|
446
|
+
shouldReplicate(): boolean;
|
|
447
|
+
/**
|
|
448
|
+
* Enable MicroLoRA for self-learning
|
|
449
|
+
*/
|
|
450
|
+
enableMicroLoRA(rank: number): boolean;
|
|
451
|
+
/**
|
|
452
|
+
* Get founding contributor count
|
|
453
|
+
*/
|
|
454
|
+
getFounderCount(): number;
|
|
455
|
+
/**
|
|
456
|
+
* Get optimal peers for task routing
|
|
457
|
+
*/
|
|
458
|
+
getOptimalPeers(count: number): string[];
|
|
459
|
+
/**
|
|
460
|
+
* Get stored pattern count
|
|
461
|
+
*/
|
|
462
|
+
getPatternCount(): number;
|
|
463
|
+
/**
|
|
464
|
+
* Get protocol development fund balance
|
|
465
|
+
*/
|
|
466
|
+
getProtocolFund(): bigint;
|
|
467
|
+
/**
|
|
468
|
+
* Get themed network status
|
|
469
|
+
*/
|
|
470
|
+
getThemedStatus(node_count: number): string;
|
|
471
|
+
/**
|
|
472
|
+
* Get contribution stream health
|
|
473
|
+
*/
|
|
474
|
+
isStreamHealthy(): boolean;
|
|
475
|
+
/**
|
|
476
|
+
* Process the next available task (called by worker)
|
|
477
|
+
*/
|
|
478
|
+
processNextTask(): Promise<boolean>;
|
|
479
|
+
/**
|
|
480
|
+
* Step all exotic capabilities forward
|
|
481
|
+
*/
|
|
482
|
+
stepCapabilities(dt: number): void;
|
|
483
|
+
/**
|
|
484
|
+
* Get active conflict count (Axiom 6: Disagreement is signal)
|
|
485
|
+
*/
|
|
486
|
+
getConflictCount(): number;
|
|
487
|
+
/**
|
|
488
|
+
* Get learning statistics
|
|
489
|
+
*/
|
|
490
|
+
getLearningStats(): string;
|
|
491
|
+
/**
|
|
492
|
+
* Check if network is self-sustaining
|
|
493
|
+
*/
|
|
494
|
+
isSelfSustaining(active_nodes: number, daily_tasks: bigint): boolean;
|
|
495
|
+
/**
|
|
496
|
+
* Record node performance for evolution
|
|
497
|
+
*/
|
|
498
|
+
recordPerformance(success_rate: number, throughput: number): void;
|
|
499
|
+
/**
|
|
500
|
+
* Run security audit (adversarial testing)
|
|
501
|
+
*/
|
|
502
|
+
runSecurityAudit(): string;
|
|
503
|
+
/**
|
|
504
|
+
* Enable Time Crystal for P2P synchronization
|
|
505
|
+
*/
|
|
506
|
+
enableTimeCrystal(oscillators: number): boolean;
|
|
507
|
+
/**
|
|
508
|
+
* Get coherence statistics
|
|
509
|
+
*/
|
|
510
|
+
getCoherenceStats(): string;
|
|
511
|
+
/**
|
|
512
|
+
* Get economic health metrics
|
|
513
|
+
*/
|
|
514
|
+
getEconomicHealth(): string;
|
|
515
|
+
/**
|
|
516
|
+
* Get network fitness score (0-1)
|
|
517
|
+
*/
|
|
518
|
+
getNetworkFitness(): number;
|
|
519
|
+
/**
|
|
520
|
+
* Record task routing outcome for optimization
|
|
521
|
+
*/
|
|
522
|
+
recordTaskRouting(task_type: string, node_id: string, latency_ms: bigint, success: boolean): void;
|
|
523
|
+
/**
|
|
524
|
+
* Enable Morphogenetic Network for emergent topology
|
|
525
|
+
*/
|
|
526
|
+
enableMorphogenetic(size: number): boolean;
|
|
527
|
+
/**
|
|
528
|
+
* Get trajectory count for learning analysis
|
|
529
|
+
*/
|
|
530
|
+
getTrajectoryCount(): number;
|
|
531
|
+
/**
|
|
532
|
+
* Get energy efficiency ratio from spike-driven attention
|
|
533
|
+
*/
|
|
534
|
+
getEnergyEfficiency(seq_len: number, hidden_dim: number): number;
|
|
535
|
+
/**
|
|
536
|
+
* Get quarantined claim count (Axiom 9: Quarantine is mandatory)
|
|
537
|
+
*/
|
|
538
|
+
getQuarantinedCount(): number;
|
|
539
|
+
/**
|
|
540
|
+
* Get Time Crystal synchronization level (0.0 - 1.0)
|
|
541
|
+
*/
|
|
542
|
+
getTimeCrystalSync(): number;
|
|
543
|
+
/**
|
|
544
|
+
* Get optimization statistics
|
|
545
|
+
*/
|
|
546
|
+
getOptimizationStats(): string;
|
|
547
|
+
/**
|
|
548
|
+
* Get recommended configuration for new nodes
|
|
549
|
+
*/
|
|
550
|
+
getRecommendedConfig(): string;
|
|
551
|
+
/**
|
|
552
|
+
* Enable Global Workspace for attention
|
|
553
|
+
*/
|
|
554
|
+
enableGlobalWorkspace(capacity: number): boolean;
|
|
555
|
+
/**
|
|
556
|
+
* Record peer interaction for topology optimization
|
|
557
|
+
*/
|
|
558
|
+
recordPeerInteraction(peer_id: string, success_rate: number): void;
|
|
559
|
+
/**
|
|
560
|
+
* Get capabilities summary as JSON
|
|
561
|
+
*/
|
|
562
|
+
getCapabilitiesSummary(): any;
|
|
563
|
+
/**
|
|
564
|
+
* Get coherence engine event count
|
|
565
|
+
*/
|
|
566
|
+
getCoherenceEventCount(): number;
|
|
567
|
+
/**
|
|
568
|
+
* Get quarantine level for a claim
|
|
569
|
+
*/
|
|
570
|
+
getClaimQuarantineLevel(claim_id: string): number;
|
|
571
|
+
/**
|
|
572
|
+
* Record a task execution trajectory for learning
|
|
573
|
+
*/
|
|
574
|
+
recordLearningTrajectory(trajectory_json: string): boolean;
|
|
575
|
+
/**
|
|
576
|
+
* Create a new EdgeNet node
|
|
577
|
+
*/
|
|
578
|
+
constructor(site_id: string, config?: NodeConfig | null);
|
|
579
|
+
/**
|
|
580
|
+
* Pause contribution
|
|
581
|
+
*/
|
|
582
|
+
pause(): void;
|
|
583
|
+
/**
|
|
584
|
+
* Start contributing to the network
|
|
585
|
+
*/
|
|
586
|
+
start(): void;
|
|
587
|
+
/**
|
|
588
|
+
* Resume contribution
|
|
589
|
+
*/
|
|
590
|
+
resume(): void;
|
|
591
|
+
/**
|
|
592
|
+
* Check if user is currently idle
|
|
593
|
+
*/
|
|
594
|
+
isIdle(): boolean;
|
|
595
|
+
/**
|
|
596
|
+
* Get the node's unique identifier
|
|
597
|
+
*/
|
|
598
|
+
nodeId(): string;
|
|
599
|
+
/**
|
|
600
|
+
* Vote on a NAO proposal
|
|
601
|
+
*/
|
|
602
|
+
voteNAO(proposal_id: string, weight: number): boolean;
|
|
603
|
+
/**
|
|
604
|
+
* Get node statistics
|
|
605
|
+
*/
|
|
606
|
+
getStats(): NodeStats;
|
|
607
|
+
}
|
|
608
|
+
|
|
609
|
+
export class EntropyConsensus {
|
|
610
|
+
free(): void;
|
|
611
|
+
[Symbol.dispose](): void;
|
|
612
|
+
/**
|
|
613
|
+
* Get belief probability for a decision
|
|
614
|
+
*/
|
|
615
|
+
getBelief(decision_id: bigint): number;
|
|
616
|
+
/**
|
|
617
|
+
* Get number of negotiation rounds completed
|
|
618
|
+
*/
|
|
619
|
+
getRounds(): number;
|
|
620
|
+
/**
|
|
621
|
+
* Set initial belief for a decision
|
|
622
|
+
*/
|
|
623
|
+
setBelief(decision_id: bigint, probability: number): void;
|
|
624
|
+
/**
|
|
625
|
+
* Get the winning decision (if converged)
|
|
626
|
+
*/
|
|
627
|
+
getDecision(): bigint | undefined;
|
|
628
|
+
/**
|
|
629
|
+
* Get number of decision options
|
|
630
|
+
*/
|
|
631
|
+
optionCount(): number;
|
|
632
|
+
/**
|
|
633
|
+
* Check if negotiation has timed out
|
|
634
|
+
*/
|
|
635
|
+
hasTimedOut(): boolean;
|
|
636
|
+
/**
|
|
637
|
+
* Set belief without normalizing (for batch updates)
|
|
638
|
+
* Call normalize_beliefs() after all set_belief_raw calls
|
|
639
|
+
*/
|
|
640
|
+
set_belief_raw(decision_id: bigint, probability: number): void;
|
|
641
|
+
/**
|
|
642
|
+
* Create with custom entropy threshold
|
|
643
|
+
*/
|
|
644
|
+
static withThreshold(threshold: number): EntropyConsensus;
|
|
645
|
+
/**
|
|
646
|
+
* Get current temperature (for annealing)
|
|
647
|
+
*/
|
|
648
|
+
getTemperature(): number;
|
|
649
|
+
/**
|
|
650
|
+
* Manually trigger normalization (for use after set_belief_raw)
|
|
651
|
+
*/
|
|
652
|
+
finalize_beliefs(): void;
|
|
653
|
+
/**
|
|
654
|
+
* Get entropy history as JSON
|
|
655
|
+
*/
|
|
656
|
+
getEntropyHistory(): string;
|
|
657
|
+
/**
|
|
658
|
+
* Get the entropy threshold for convergence
|
|
659
|
+
*/
|
|
660
|
+
getEntropyThreshold(): number;
|
|
661
|
+
/**
|
|
662
|
+
* Create new entropy consensus with default configuration
|
|
663
|
+
*/
|
|
664
|
+
constructor();
|
|
665
|
+
/**
|
|
666
|
+
* Reset consensus state for new decision
|
|
667
|
+
*/
|
|
668
|
+
reset(): void;
|
|
669
|
+
/**
|
|
670
|
+
* Get current entropy of belief distribution
|
|
671
|
+
*/
|
|
672
|
+
entropy(): number;
|
|
673
|
+
/**
|
|
674
|
+
* Check if consensus has been reached
|
|
675
|
+
*/
|
|
676
|
+
converged(): boolean;
|
|
677
|
+
/**
|
|
678
|
+
* Get consensus statistics as JSON
|
|
679
|
+
*/
|
|
680
|
+
getStats(): string;
|
|
681
|
+
}
|
|
682
|
+
|
|
683
|
+
export class EventLog {
|
|
684
|
+
free(): void;
|
|
685
|
+
[Symbol.dispose](): void;
|
|
686
|
+
/**
|
|
687
|
+
* Get total event count
|
|
688
|
+
*/
|
|
689
|
+
totalEvents(): number;
|
|
690
|
+
/**
|
|
691
|
+
* Get current event count (includes all events)
|
|
692
|
+
*/
|
|
693
|
+
len(): number;
|
|
694
|
+
/**
|
|
695
|
+
* Create a new event log
|
|
696
|
+
*/
|
|
697
|
+
constructor();
|
|
698
|
+
/**
|
|
699
|
+
* Get current Merkle root as hex string
|
|
700
|
+
*/
|
|
701
|
+
getRoot(): string;
|
|
702
|
+
/**
|
|
703
|
+
* Check if log is empty
|
|
704
|
+
*/
|
|
705
|
+
isEmpty(): boolean;
|
|
706
|
+
}
|
|
707
|
+
|
|
708
|
+
export class EvolutionEngine {
|
|
709
|
+
free(): void;
|
|
710
|
+
[Symbol.dispose](): void;
|
|
711
|
+
/**
|
|
712
|
+
* Check if node should replicate (spawn similar node)
|
|
713
|
+
*/
|
|
714
|
+
shouldReplicate(node_id: string): boolean;
|
|
715
|
+
/**
|
|
716
|
+
* Record node performance for fitness evaluation
|
|
717
|
+
*/
|
|
718
|
+
recordPerformance(node_id: string, success_rate: number, throughput: number): void;
|
|
719
|
+
/**
|
|
720
|
+
* Get network fitness score
|
|
721
|
+
*/
|
|
722
|
+
getNetworkFitness(): number;
|
|
723
|
+
/**
|
|
724
|
+
* Get recommended configuration for new nodes
|
|
725
|
+
*/
|
|
726
|
+
getRecommendedConfig(): string;
|
|
727
|
+
constructor();
|
|
728
|
+
/**
|
|
729
|
+
* Evolve patterns for next generation
|
|
730
|
+
*/
|
|
731
|
+
evolve(): void;
|
|
732
|
+
}
|
|
733
|
+
|
|
734
|
+
export class FederatedModel {
|
|
735
|
+
free(): void;
|
|
736
|
+
[Symbol.dispose](): void;
|
|
737
|
+
/**
|
|
738
|
+
* Get parameter dimension
|
|
739
|
+
*/
|
|
740
|
+
getDimension(): number;
|
|
741
|
+
/**
|
|
742
|
+
* Get parameters as array
|
|
743
|
+
*/
|
|
744
|
+
getParameters(): Float32Array;
|
|
745
|
+
/**
|
|
746
|
+
* Set parameters from array
|
|
747
|
+
*/
|
|
748
|
+
setParameters(params: Float32Array): void;
|
|
749
|
+
/**
|
|
750
|
+
* Apply aggregated gradients to update model
|
|
751
|
+
*/
|
|
752
|
+
applyGradients(gradients: Float32Array): void;
|
|
753
|
+
/**
|
|
754
|
+
* Set local epochs per round
|
|
755
|
+
*/
|
|
756
|
+
setLocalEpochs(epochs: number): void;
|
|
757
|
+
/**
|
|
758
|
+
* Set learning rate
|
|
759
|
+
*/
|
|
760
|
+
setLearningRate(lr: number): void;
|
|
761
|
+
/**
|
|
762
|
+
* Create a new federated model
|
|
763
|
+
*/
|
|
764
|
+
constructor(dimension: number, learning_rate: number, momentum: number);
|
|
765
|
+
/**
|
|
766
|
+
* Get current round
|
|
767
|
+
*/
|
|
768
|
+
getRound(): bigint;
|
|
769
|
+
}
|
|
770
|
+
|
|
771
|
+
export class FoundingRegistry {
|
|
772
|
+
free(): void;
|
|
773
|
+
[Symbol.dispose](): void;
|
|
774
|
+
/**
|
|
775
|
+
* Process epoch distribution
|
|
776
|
+
*/
|
|
777
|
+
processEpoch(current_epoch: bigint, available_amount: bigint): any[];
|
|
778
|
+
/**
|
|
779
|
+
* Calculate vested amount for current epoch
|
|
780
|
+
*/
|
|
781
|
+
calculateVested(current_epoch: bigint, pool_balance: bigint): bigint;
|
|
782
|
+
/**
|
|
783
|
+
* Get founding contributor count
|
|
784
|
+
*/
|
|
785
|
+
getFounderCount(): number;
|
|
786
|
+
/**
|
|
787
|
+
* Register additional founding contributor
|
|
788
|
+
*/
|
|
789
|
+
registerContributor(id: string, category: string, weight: number): void;
|
|
790
|
+
constructor();
|
|
791
|
+
}
|
|
792
|
+
|
|
793
|
+
export class GenesisKey {
|
|
794
|
+
free(): void;
|
|
795
|
+
[Symbol.dispose](): void;
|
|
796
|
+
/**
|
|
797
|
+
* Get ID as hex
|
|
798
|
+
*/
|
|
799
|
+
getIdHex(): string;
|
|
800
|
+
/**
|
|
801
|
+
* Export ultra-compact genesis key (21 bytes only)
|
|
802
|
+
*/
|
|
803
|
+
exportUltraCompact(): Uint8Array;
|
|
804
|
+
/**
|
|
805
|
+
* Create a new genesis key
|
|
806
|
+
*/
|
|
807
|
+
constructor(creator: PiKey, epoch: number);
|
|
808
|
+
/**
|
|
809
|
+
* Get the φ-sized genesis ID
|
|
810
|
+
*/
|
|
811
|
+
getId(): Uint8Array;
|
|
812
|
+
/**
|
|
813
|
+
* Verify this genesis key was created by a specific Pi-Key
|
|
814
|
+
*/
|
|
815
|
+
verify(creator_public_key: Uint8Array): boolean;
|
|
816
|
+
/**
|
|
817
|
+
* Get epoch
|
|
818
|
+
*/
|
|
819
|
+
getEpoch(): number;
|
|
820
|
+
}
|
|
821
|
+
|
|
822
|
+
export class GenesisSunset {
|
|
823
|
+
free(): void;
|
|
824
|
+
[Symbol.dispose](): void;
|
|
825
|
+
/**
|
|
826
|
+
* Check if it's safe to retire genesis nodes
|
|
827
|
+
*/
|
|
828
|
+
canRetire(): boolean;
|
|
829
|
+
/**
|
|
830
|
+
* Get sunset status
|
|
831
|
+
*/
|
|
832
|
+
getStatus(): string;
|
|
833
|
+
/**
|
|
834
|
+
* Check if genesis nodes should be read-only
|
|
835
|
+
*/
|
|
836
|
+
isReadOnly(): boolean;
|
|
837
|
+
/**
|
|
838
|
+
* Get current sunset phase
|
|
839
|
+
* 0 = Active (genesis required)
|
|
840
|
+
* 1 = Transition (stop new connections)
|
|
841
|
+
* 2 = Read-only (genesis read-only)
|
|
842
|
+
* 3 = Retired (genesis can be removed)
|
|
843
|
+
*/
|
|
844
|
+
getCurrentPhase(): number;
|
|
845
|
+
/**
|
|
846
|
+
* Update network node count
|
|
847
|
+
*/
|
|
848
|
+
updateNodeCount(count: number): number;
|
|
849
|
+
/**
|
|
850
|
+
* Check if network is self-sustaining
|
|
851
|
+
*/
|
|
852
|
+
isSelfSustaining(): boolean;
|
|
853
|
+
/**
|
|
854
|
+
* Register a genesis node
|
|
855
|
+
*/
|
|
856
|
+
registerGenesisNode(node_id: string): void;
|
|
857
|
+
/**
|
|
858
|
+
* Check if genesis nodes should accept new connections
|
|
859
|
+
*/
|
|
860
|
+
shouldAcceptConnections(): boolean;
|
|
861
|
+
constructor();
|
|
862
|
+
}
|
|
863
|
+
|
|
864
|
+
export class GradientGossip {
|
|
865
|
+
free(): void;
|
|
866
|
+
[Symbol.dispose](): void;
|
|
867
|
+
/**
|
|
868
|
+
* Get number of active peers
|
|
869
|
+
*/
|
|
870
|
+
peerCount(): number;
|
|
871
|
+
/**
|
|
872
|
+
* Prune stale peer gradients
|
|
873
|
+
*/
|
|
874
|
+
pruneStale(): number;
|
|
875
|
+
/**
|
|
876
|
+
* Configure differential privacy
|
|
877
|
+
*/
|
|
878
|
+
configureDifferentialPrivacy(epsilon: number, sensitivity: number): void;
|
|
879
|
+
/**
|
|
880
|
+
* Advance to next consensus round
|
|
881
|
+
*/
|
|
882
|
+
advanceRound(): bigint;
|
|
883
|
+
/**
|
|
884
|
+
* Get gradient dimension
|
|
885
|
+
*/
|
|
886
|
+
getDimension(): number;
|
|
887
|
+
/**
|
|
888
|
+
* Enable/disable differential privacy
|
|
889
|
+
*/
|
|
890
|
+
setDPEnabled(enabled: boolean): void;
|
|
891
|
+
/**
|
|
892
|
+
* Set model hash for version compatibility
|
|
893
|
+
*/
|
|
894
|
+
setModelHash(hash: Uint8Array): void;
|
|
895
|
+
/**
|
|
896
|
+
* Get current consensus round
|
|
897
|
+
*/
|
|
898
|
+
getCurrentRound(): bigint;
|
|
899
|
+
/**
|
|
900
|
+
* Set local gradients from JavaScript
|
|
901
|
+
*/
|
|
902
|
+
setLocalGradients(gradients: Float32Array): void;
|
|
903
|
+
/**
|
|
904
|
+
* Get compression ratio achieved
|
|
905
|
+
*/
|
|
906
|
+
getCompressionRatio(): number;
|
|
907
|
+
/**
|
|
908
|
+
* Get aggregated gradients as JavaScript array
|
|
909
|
+
*/
|
|
910
|
+
getAggregatedGradients(): Float32Array;
|
|
911
|
+
/**
|
|
912
|
+
* Create a new GradientGossip instance
|
|
913
|
+
*
|
|
914
|
+
* # Arguments
|
|
915
|
+
* * `local_peer_id` - 32-byte peer identifier
|
|
916
|
+
* * `dimension` - Gradient vector dimension
|
|
917
|
+
* * `k_ratio` - TopK sparsification ratio (0.1 = keep top 10%)
|
|
918
|
+
*/
|
|
919
|
+
constructor(local_peer_id: Uint8Array, dimension: number, k_ratio: number);
|
|
920
|
+
/**
|
|
921
|
+
* Get statistics as JSON
|
|
922
|
+
*/
|
|
923
|
+
getStats(): string;
|
|
924
|
+
}
|
|
925
|
+
|
|
926
|
+
export class ModelConsensusManager {
|
|
927
|
+
free(): void;
|
|
928
|
+
[Symbol.dispose](): void;
|
|
929
|
+
/**
|
|
930
|
+
* Get number of tracked models
|
|
931
|
+
*/
|
|
932
|
+
modelCount(): number;
|
|
933
|
+
/**
|
|
934
|
+
* Get number of active disputes
|
|
935
|
+
*/
|
|
936
|
+
disputeCount(): number;
|
|
937
|
+
/**
|
|
938
|
+
* Get number of quarantined updates
|
|
939
|
+
*/
|
|
940
|
+
quarantinedUpdateCount(): number;
|
|
941
|
+
/**
|
|
942
|
+
* Create a new model consensus manager
|
|
943
|
+
*/
|
|
944
|
+
constructor(min_witnesses: number);
|
|
945
|
+
/**
|
|
946
|
+
* Get statistics as JSON
|
|
947
|
+
*/
|
|
948
|
+
getStats(): string;
|
|
949
|
+
}
|
|
950
|
+
|
|
951
|
+
export class MultiHeadAttention {
|
|
952
|
+
free(): void;
|
|
953
|
+
[Symbol.dispose](): void;
|
|
954
|
+
/**
|
|
955
|
+
* Get embedding dimension
|
|
956
|
+
*/
|
|
957
|
+
dim(): number;
|
|
958
|
+
/**
|
|
959
|
+
* Create new multi-head attention
|
|
960
|
+
*/
|
|
961
|
+
constructor(dim: number, num_heads: number);
|
|
962
|
+
/**
|
|
963
|
+
* Get number of heads
|
|
964
|
+
*/
|
|
965
|
+
numHeads(): number;
|
|
966
|
+
}
|
|
967
|
+
|
|
968
|
+
export class NetworkEvents {
|
|
969
|
+
free(): void;
|
|
970
|
+
[Symbol.dispose](): void;
|
|
971
|
+
/**
|
|
972
|
+
* Get a subtle motivational message
|
|
973
|
+
*/
|
|
974
|
+
getMotivation(balance: bigint): string;
|
|
975
|
+
/**
|
|
976
|
+
* Check for discovery triggers (Easter eggs)
|
|
977
|
+
*/
|
|
978
|
+
checkDiscovery(action: string, node_id: string): string | undefined;
|
|
979
|
+
/**
|
|
980
|
+
* Get ASCII art for special occasions
|
|
981
|
+
*/
|
|
982
|
+
getSpecialArt(): string | undefined;
|
|
983
|
+
/**
|
|
984
|
+
* Check milestone achievements
|
|
985
|
+
*/
|
|
986
|
+
checkMilestones(balance: bigint, node_id: string): string;
|
|
987
|
+
/**
|
|
988
|
+
* Set current time (for testing)
|
|
989
|
+
*/
|
|
990
|
+
setCurrentTime(timestamp: bigint): void;
|
|
991
|
+
/**
|
|
992
|
+
* Get network status with thematic flair
|
|
993
|
+
*/
|
|
994
|
+
getThemedStatus(node_count: number, total_ruv: bigint): string;
|
|
995
|
+
/**
|
|
996
|
+
* Check for active special events
|
|
997
|
+
*/
|
|
998
|
+
checkActiveEvents(): string;
|
|
999
|
+
/**
|
|
1000
|
+
* Get celebration multiplier boost
|
|
1001
|
+
*/
|
|
1002
|
+
getCelebrationBoost(): number;
|
|
1003
|
+
constructor();
|
|
1004
|
+
}
|
|
1005
|
+
|
|
1006
|
+
export class NetworkLearning {
|
|
1007
|
+
free(): void;
|
|
1008
|
+
[Symbol.dispose](): void;
|
|
1009
|
+
/**
|
|
1010
|
+
* Get pattern count
|
|
1011
|
+
*/
|
|
1012
|
+
patternCount(): number;
|
|
1013
|
+
/**
|
|
1014
|
+
* Store a learned pattern
|
|
1015
|
+
*/
|
|
1016
|
+
storePattern(pattern_json: string): number;
|
|
1017
|
+
/**
|
|
1018
|
+
* Look up similar patterns
|
|
1019
|
+
*/
|
|
1020
|
+
lookupPatterns(query_json: string, k: number): string;
|
|
1021
|
+
/**
|
|
1022
|
+
* Get energy savings ratio for spike-driven attention
|
|
1023
|
+
*/
|
|
1024
|
+
getEnergyRatio(seq_len: number, hidden_dim: number): number;
|
|
1025
|
+
/**
|
|
1026
|
+
* Get trajectory count
|
|
1027
|
+
*/
|
|
1028
|
+
trajectoryCount(): number;
|
|
1029
|
+
/**
|
|
1030
|
+
* Record a task execution trajectory
|
|
1031
|
+
*/
|
|
1032
|
+
recordTrajectory(trajectory_json: string): boolean;
|
|
1033
|
+
/**
|
|
1034
|
+
* Create new network learning intelligence
|
|
1035
|
+
*/
|
|
1036
|
+
constructor();
|
|
1037
|
+
/**
|
|
1038
|
+
* Prune low-quality patterns
|
|
1039
|
+
*/
|
|
1040
|
+
prune(min_usage: number, min_confidence: number): number;
|
|
1041
|
+
/**
|
|
1042
|
+
* Get combined statistics
|
|
1043
|
+
*/
|
|
1044
|
+
getStats(): string;
|
|
1045
|
+
}
|
|
1046
|
+
|
|
1047
|
+
export class NetworkTopology {
|
|
1048
|
+
free(): void;
|
|
1049
|
+
[Symbol.dispose](): void;
|
|
1050
|
+
/**
|
|
1051
|
+
* Register a node in the topology
|
|
1052
|
+
*/
|
|
1053
|
+
registerNode(node_id: string, capabilities: Float32Array): void;
|
|
1054
|
+
/**
|
|
1055
|
+
* Get optimal peers for a node
|
|
1056
|
+
*/
|
|
1057
|
+
getOptimalPeers(node_id: string, count: number): string[];
|
|
1058
|
+
/**
|
|
1059
|
+
* Update connection strength between nodes
|
|
1060
|
+
*/
|
|
1061
|
+
updateConnection(from: string, to: string, success_rate: number): void;
|
|
1062
|
+
constructor();
|
|
1063
|
+
}
|
|
1064
|
+
|
|
1065
|
+
export class NodeConfig {
|
|
1066
|
+
private constructor();
|
|
1067
|
+
free(): void;
|
|
1068
|
+
[Symbol.dispose](): void;
|
|
1069
|
+
/**
|
|
1070
|
+
* Maximum CPU usage when idle (0.0 - 1.0)
|
|
1071
|
+
*/
|
|
1072
|
+
cpu_limit: number;
|
|
1073
|
+
/**
|
|
1074
|
+
* Maximum memory usage in bytes
|
|
1075
|
+
*/
|
|
1076
|
+
memory_limit: number;
|
|
1077
|
+
/**
|
|
1078
|
+
* Maximum bandwidth in bytes/sec
|
|
1079
|
+
*/
|
|
1080
|
+
bandwidth_limit: number;
|
|
1081
|
+
/**
|
|
1082
|
+
* Minimum idle time before contributing (ms)
|
|
1083
|
+
*/
|
|
1084
|
+
min_idle_time: number;
|
|
1085
|
+
/**
|
|
1086
|
+
* Whether to reduce contribution on battery
|
|
1087
|
+
*/
|
|
1088
|
+
respect_battery: boolean;
|
|
1089
|
+
}
|
|
1090
|
+
|
|
1091
|
+
export class NodeStats {
|
|
1092
|
+
private constructor();
|
|
1093
|
+
free(): void;
|
|
1094
|
+
[Symbol.dispose](): void;
|
|
1095
|
+
/**
|
|
1096
|
+
* Total rUv (Resource Utility Vouchers) earned
|
|
1097
|
+
*/
|
|
1098
|
+
ruv_earned: bigint;
|
|
1099
|
+
/**
|
|
1100
|
+
* Total rUv spent
|
|
1101
|
+
*/
|
|
1102
|
+
ruv_spent: bigint;
|
|
1103
|
+
/**
|
|
1104
|
+
* Tasks completed
|
|
1105
|
+
*/
|
|
1106
|
+
tasks_completed: bigint;
|
|
1107
|
+
/**
|
|
1108
|
+
* Tasks submitted
|
|
1109
|
+
*/
|
|
1110
|
+
tasks_submitted: bigint;
|
|
1111
|
+
/**
|
|
1112
|
+
* Total uptime in seconds
|
|
1113
|
+
*/
|
|
1114
|
+
uptime_seconds: bigint;
|
|
1115
|
+
/**
|
|
1116
|
+
* Current reputation score (0.0 - 1.0)
|
|
1117
|
+
*/
|
|
1118
|
+
reputation: number;
|
|
1119
|
+
/**
|
|
1120
|
+
* Current contribution multiplier
|
|
1121
|
+
*/
|
|
1122
|
+
multiplier: number;
|
|
1123
|
+
/**
|
|
1124
|
+
* Active lifecycle events
|
|
1125
|
+
*/
|
|
1126
|
+
celebration_boost: number;
|
|
1127
|
+
}
|
|
1128
|
+
|
|
1129
|
+
export class OptimizationEngine {
|
|
1130
|
+
free(): void;
|
|
1131
|
+
[Symbol.dispose](): void;
|
|
1132
|
+
/**
|
|
1133
|
+
* Record task routing outcome
|
|
1134
|
+
*/
|
|
1135
|
+
recordRouting(task_type: string, node_id: string, latency_ms: bigint, success: boolean): void;
|
|
1136
|
+
/**
|
|
1137
|
+
* Get optimal node for a task type
|
|
1138
|
+
*/
|
|
1139
|
+
selectOptimalNode(task_type: string, candidates: string[]): string;
|
|
1140
|
+
constructor();
|
|
1141
|
+
/**
|
|
1142
|
+
* Get optimization stats
|
|
1143
|
+
*/
|
|
1144
|
+
getStats(): string;
|
|
1145
|
+
}
|
|
1146
|
+
|
|
1147
|
+
export class PiKey {
|
|
1148
|
+
free(): void;
|
|
1149
|
+
[Symbol.dispose](): void;
|
|
1150
|
+
/**
|
|
1151
|
+
* Get the Pi-sized identity (40 bytes)
|
|
1152
|
+
*/
|
|
1153
|
+
getIdentity(): Uint8Array;
|
|
1154
|
+
/**
|
|
1155
|
+
* Get short identity (first 8 bytes as hex)
|
|
1156
|
+
*/
|
|
1157
|
+
getShortId(): string;
|
|
1158
|
+
/**
|
|
1159
|
+
* Export minimal key representation (Pi + Phi sized = 61 bytes total)
|
|
1160
|
+
*/
|
|
1161
|
+
exportCompact(): Uint8Array;
|
|
1162
|
+
/**
|
|
1163
|
+
* Get public key for verification
|
|
1164
|
+
*/
|
|
1165
|
+
getPublicKey(): Uint8Array;
|
|
1166
|
+
/**
|
|
1167
|
+
* Verify this key has Pi magic marker
|
|
1168
|
+
*/
|
|
1169
|
+
verifyPiMagic(): boolean;
|
|
1170
|
+
/**
|
|
1171
|
+
* Get identity as hex string
|
|
1172
|
+
*/
|
|
1173
|
+
getIdentityHex(): string;
|
|
1174
|
+
/**
|
|
1175
|
+
* Restore from encrypted backup (supports both v1 legacy and v2 Argon2id)
|
|
1176
|
+
*/
|
|
1177
|
+
static restoreFromBackup(backup: Uint8Array, password: string): PiKey;
|
|
1178
|
+
/**
|
|
1179
|
+
* Create encrypted backup of private key using Argon2id KDF
|
|
1180
|
+
*/
|
|
1181
|
+
createEncryptedBackup(password: string): Uint8Array;
|
|
1182
|
+
/**
|
|
1183
|
+
* Get the Phi-sized genesis fingerprint (21 bytes)
|
|
1184
|
+
*/
|
|
1185
|
+
getGenesisFingerprint(): Uint8Array;
|
|
1186
|
+
/**
|
|
1187
|
+
* Sign data with this key
|
|
1188
|
+
*/
|
|
1189
|
+
sign(data: Uint8Array): Uint8Array;
|
|
1190
|
+
/**
|
|
1191
|
+
* Verify signature from another Pi-Key
|
|
1192
|
+
*/
|
|
1193
|
+
verify(data: Uint8Array, signature: Uint8Array, public_key: Uint8Array): boolean;
|
|
1194
|
+
/**
|
|
1195
|
+
* Generate a new Pi-Key with genesis linking
|
|
1196
|
+
*/
|
|
1197
|
+
constructor(genesis_seed?: Uint8Array | null);
|
|
1198
|
+
/**
|
|
1199
|
+
* Get key statistics
|
|
1200
|
+
*/
|
|
1201
|
+
getStats(): string;
|
|
1202
|
+
}
|
|
1203
|
+
|
|
1204
|
+
export class QDAGLedger {
|
|
1205
|
+
free(): void;
|
|
1206
|
+
[Symbol.dispose](): void;
|
|
1207
|
+
/**
|
|
1208
|
+
* Export ledger state for sync
|
|
1209
|
+
*/
|
|
1210
|
+
exportState(): Uint8Array;
|
|
1211
|
+
/**
|
|
1212
|
+
* Import ledger state from sync
|
|
1213
|
+
*/
|
|
1214
|
+
importState(state_bytes: Uint8Array): number;
|
|
1215
|
+
/**
|
|
1216
|
+
* Get total supply
|
|
1217
|
+
*/
|
|
1218
|
+
totalSupply(): bigint;
|
|
1219
|
+
/**
|
|
1220
|
+
* Get staked amount for a node
|
|
1221
|
+
*/
|
|
1222
|
+
stakedAmount(node_id: string): bigint;
|
|
1223
|
+
/**
|
|
1224
|
+
* Create genesis transaction (called once at network start)
|
|
1225
|
+
*/
|
|
1226
|
+
createGenesis(initial_supply: bigint, founder_pubkey: Uint8Array): Uint8Array;
|
|
1227
|
+
/**
|
|
1228
|
+
* Get transaction count
|
|
1229
|
+
*/
|
|
1230
|
+
transactionCount(): number;
|
|
1231
|
+
/**
|
|
1232
|
+
* Create and validate a new transaction
|
|
1233
|
+
*/
|
|
1234
|
+
createTransaction(sender_id: string, recipient_id: string, amount: bigint, tx_type: number, sender_privkey: Uint8Array, sender_pubkey: Uint8Array): Uint8Array;
|
|
1235
|
+
/**
|
|
1236
|
+
* Create a new QDAG ledger
|
|
1237
|
+
*/
|
|
1238
|
+
constructor();
|
|
1239
|
+
/**
|
|
1240
|
+
* Get balance for a node
|
|
1241
|
+
*/
|
|
1242
|
+
balance(node_id: string): bigint;
|
|
1243
|
+
/**
|
|
1244
|
+
* Get tip count
|
|
1245
|
+
*/
|
|
1246
|
+
tipCount(): number;
|
|
1247
|
+
}
|
|
1248
|
+
|
|
1249
|
+
export class QuarantineManager {
|
|
1250
|
+
free(): void;
|
|
1251
|
+
[Symbol.dispose](): void;
|
|
1252
|
+
/**
|
|
1253
|
+
* Get number of quarantined claims
|
|
1254
|
+
*/
|
|
1255
|
+
quarantinedCount(): number;
|
|
1256
|
+
/**
|
|
1257
|
+
* Create a new quarantine manager
|
|
1258
|
+
*/
|
|
1259
|
+
constructor();
|
|
1260
|
+
/**
|
|
1261
|
+
* Check if claim can be used in decisions
|
|
1262
|
+
*/
|
|
1263
|
+
canUse(claim_id: string): boolean;
|
|
1264
|
+
/**
|
|
1265
|
+
* Check quarantine level for a claim
|
|
1266
|
+
*/
|
|
1267
|
+
getLevel(claim_id: string): number;
|
|
1268
|
+
/**
|
|
1269
|
+
* Set quarantine level
|
|
1270
|
+
*/
|
|
1271
|
+
setLevel(claim_id: string, level: number): void;
|
|
1272
|
+
}
|
|
1273
|
+
|
|
1274
|
+
export class RacEconomicEngine {
|
|
1275
|
+
free(): void;
|
|
1276
|
+
[Symbol.dispose](): void;
|
|
1277
|
+
/**
|
|
1278
|
+
* Get summary statistics as JSON
|
|
1279
|
+
*/
|
|
1280
|
+
getSummary(): string;
|
|
1281
|
+
/**
|
|
1282
|
+
* Check if node can participate (has stake + reputation)
|
|
1283
|
+
*/
|
|
1284
|
+
canParticipate(node_id: Uint8Array): boolean;
|
|
1285
|
+
/**
|
|
1286
|
+
* Get combined score (stake-weighted reputation)
|
|
1287
|
+
*/
|
|
1288
|
+
getCombinedScore(node_id: Uint8Array): number;
|
|
1289
|
+
/**
|
|
1290
|
+
* Create a new RAC economic engine
|
|
1291
|
+
*/
|
|
1292
|
+
constructor();
|
|
1293
|
+
}
|
|
1294
|
+
|
|
1295
|
+
export class RacSemanticRouter {
|
|
1296
|
+
free(): void;
|
|
1297
|
+
[Symbol.dispose](): void;
|
|
1298
|
+
/**
|
|
1299
|
+
* Get peer count
|
|
1300
|
+
*/
|
|
1301
|
+
peerCount(): number;
|
|
1302
|
+
/**
|
|
1303
|
+
* Create a new semantic router
|
|
1304
|
+
*/
|
|
1305
|
+
constructor();
|
|
1306
|
+
}
|
|
1307
|
+
|
|
1308
|
+
export class RateLimiter {
|
|
1309
|
+
free(): void;
|
|
1310
|
+
[Symbol.dispose](): void;
|
|
1311
|
+
/**
|
|
1312
|
+
* Check if request is allowed
|
|
1313
|
+
*/
|
|
1314
|
+
checkAllowed(node_id: string): boolean;
|
|
1315
|
+
constructor(window_ms: bigint, max_requests: number);
|
|
1316
|
+
/**
|
|
1317
|
+
* Reset rate limiter
|
|
1318
|
+
*/
|
|
1319
|
+
reset(): void;
|
|
1320
|
+
/**
|
|
1321
|
+
* Get current count for a node
|
|
1322
|
+
*/
|
|
1323
|
+
getCount(node_id: string): number;
|
|
1324
|
+
}
|
|
1325
|
+
|
|
1326
|
+
export class ReasoningBank {
|
|
1327
|
+
free(): void;
|
|
1328
|
+
[Symbol.dispose](): void;
|
|
1329
|
+
/**
|
|
1330
|
+
* Create a new ReasoningBank
|
|
1331
|
+
*/
|
|
1332
|
+
constructor();
|
|
1333
|
+
/**
|
|
1334
|
+
* Get total pattern count
|
|
1335
|
+
*/
|
|
1336
|
+
count(): number;
|
|
1337
|
+
/**
|
|
1338
|
+
* Prune low-quality patterns
|
|
1339
|
+
*/
|
|
1340
|
+
prune(min_usage: number, min_confidence: number): number;
|
|
1341
|
+
/**
|
|
1342
|
+
* Store a new pattern (JSON format)
|
|
1343
|
+
*/
|
|
1344
|
+
store(pattern_json: string): number;
|
|
1345
|
+
/**
|
|
1346
|
+
* Lookup most similar patterns (OPTIMIZED with spatial indexing)
|
|
1347
|
+
*/
|
|
1348
|
+
lookup(query_json: string, k: number): string;
|
|
1349
|
+
/**
|
|
1350
|
+
* Get bank statistics
|
|
1351
|
+
*/
|
|
1352
|
+
getStats(): string;
|
|
1353
|
+
}
|
|
1354
|
+
|
|
1355
|
+
export class ReputationManager {
|
|
1356
|
+
free(): void;
|
|
1357
|
+
[Symbol.dispose](): void;
|
|
1358
|
+
/**
|
|
1359
|
+
* Get number of tracked nodes
|
|
1360
|
+
*/
|
|
1361
|
+
nodeCount(): number;
|
|
1362
|
+
/**
|
|
1363
|
+
* Get effective reputation for a node (with decay applied)
|
|
1364
|
+
*/
|
|
1365
|
+
getReputation(node_id: Uint8Array): number;
|
|
1366
|
+
/**
|
|
1367
|
+
* Get average network reputation
|
|
1368
|
+
*/
|
|
1369
|
+
averageReputation(): number;
|
|
1370
|
+
/**
|
|
1371
|
+
* Check if node has sufficient reputation
|
|
1372
|
+
*/
|
|
1373
|
+
hasSufficientReputation(node_id: Uint8Array): boolean;
|
|
1374
|
+
/**
|
|
1375
|
+
* Create a new reputation manager
|
|
1376
|
+
*/
|
|
1377
|
+
constructor(decay_rate: number, decay_interval_ms: bigint);
|
|
1378
|
+
}
|
|
1379
|
+
|
|
1380
|
+
export class ReputationSystem {
|
|
1381
|
+
free(): void;
|
|
1382
|
+
[Symbol.dispose](): void;
|
|
1383
|
+
/**
|
|
1384
|
+
* Get reputation score for a node
|
|
1385
|
+
*/
|
|
1386
|
+
getReputation(node_id: string): number;
|
|
1387
|
+
/**
|
|
1388
|
+
* Record failed task completion
|
|
1389
|
+
*/
|
|
1390
|
+
recordFailure(node_id: string): void;
|
|
1391
|
+
/**
|
|
1392
|
+
* Record penalty (fraud, invalid result)
|
|
1393
|
+
*/
|
|
1394
|
+
recordPenalty(node_id: string, severity: number): void;
|
|
1395
|
+
/**
|
|
1396
|
+
* Record successful task completion
|
|
1397
|
+
*/
|
|
1398
|
+
recordSuccess(node_id: string): void;
|
|
1399
|
+
/**
|
|
1400
|
+
* Check if node can participate
|
|
1401
|
+
*/
|
|
1402
|
+
canParticipate(node_id: string): boolean;
|
|
1403
|
+
constructor();
|
|
1404
|
+
}
|
|
1405
|
+
|
|
1406
|
+
export class RewardDistribution {
|
|
1407
|
+
private constructor();
|
|
1408
|
+
free(): void;
|
|
1409
|
+
[Symbol.dispose](): void;
|
|
1410
|
+
total: bigint;
|
|
1411
|
+
contributor_share: bigint;
|
|
1412
|
+
treasury_share: bigint;
|
|
1413
|
+
protocol_share: bigint;
|
|
1414
|
+
founder_share: bigint;
|
|
1415
|
+
}
|
|
1416
|
+
|
|
1417
|
+
export class RewardManager {
|
|
1418
|
+
free(): void;
|
|
1419
|
+
[Symbol.dispose](): void;
|
|
1420
|
+
/**
|
|
1421
|
+
* Get number of pending rewards
|
|
1422
|
+
*/
|
|
1423
|
+
pendingCount(): number;
|
|
1424
|
+
/**
|
|
1425
|
+
* Get total pending reward amount
|
|
1426
|
+
*/
|
|
1427
|
+
pendingAmount(): bigint;
|
|
1428
|
+
/**
|
|
1429
|
+
* Get claimable rewards for a node
|
|
1430
|
+
*/
|
|
1431
|
+
claimableAmount(node_id: Uint8Array): bigint;
|
|
1432
|
+
/**
|
|
1433
|
+
* Create a new reward manager
|
|
1434
|
+
*/
|
|
1435
|
+
constructor(default_vesting_ms: bigint);
|
|
1436
|
+
}
|
|
1437
|
+
|
|
1438
|
+
export class SemanticRouter {
|
|
1439
|
+
free(): void;
|
|
1440
|
+
[Symbol.dispose](): void;
|
|
1441
|
+
/**
|
|
1442
|
+
* Get peer count
|
|
1443
|
+
*/
|
|
1444
|
+
peerCount(): number;
|
|
1445
|
+
/**
|
|
1446
|
+
* Get topic count
|
|
1447
|
+
*/
|
|
1448
|
+
topicCount(): number;
|
|
1449
|
+
/**
|
|
1450
|
+
* Create with custom parameters
|
|
1451
|
+
*/
|
|
1452
|
+
static withParams(embedding_dim: number, semantic_neighbors: number, random_sample: number): SemanticRouter;
|
|
1453
|
+
/**
|
|
1454
|
+
* Set my peer identity
|
|
1455
|
+
*/
|
|
1456
|
+
setMyPeerId(peer_id: Uint8Array): void;
|
|
1457
|
+
/**
|
|
1458
|
+
* Get active peer count (seen in last 60 seconds)
|
|
1459
|
+
*/
|
|
1460
|
+
activePeerCount(): number;
|
|
1461
|
+
/**
|
|
1462
|
+
* Set my capabilities and update my centroid
|
|
1463
|
+
*/
|
|
1464
|
+
setMyCapabilities(capabilities: string[]): void;
|
|
1465
|
+
/**
|
|
1466
|
+
* Create a new semantic router
|
|
1467
|
+
*/
|
|
1468
|
+
constructor();
|
|
1469
|
+
/**
|
|
1470
|
+
* Get statistics as JSON
|
|
1471
|
+
*/
|
|
1472
|
+
getStats(): string;
|
|
1473
|
+
}
|
|
1474
|
+
|
|
1475
|
+
export class SessionKey {
|
|
1476
|
+
free(): void;
|
|
1477
|
+
[Symbol.dispose](): void;
|
|
1478
|
+
/**
|
|
1479
|
+
* Get ID as hex
|
|
1480
|
+
*/
|
|
1481
|
+
getIdHex(): string;
|
|
1482
|
+
/**
|
|
1483
|
+
* Check if session is expired
|
|
1484
|
+
*/
|
|
1485
|
+
isExpired(): boolean;
|
|
1486
|
+
/**
|
|
1487
|
+
* Get parent identity fingerprint
|
|
1488
|
+
*/
|
|
1489
|
+
getParentIdentity(): Uint8Array;
|
|
1490
|
+
/**
|
|
1491
|
+
* Create a new session key linked to a Pi-Key identity
|
|
1492
|
+
*/
|
|
1493
|
+
constructor(parent: PiKey, ttl_seconds: number);
|
|
1494
|
+
/**
|
|
1495
|
+
* Get the e-sized session ID
|
|
1496
|
+
*/
|
|
1497
|
+
getId(): Uint8Array;
|
|
1498
|
+
/**
|
|
1499
|
+
* Decrypt data with this session key
|
|
1500
|
+
*/
|
|
1501
|
+
decrypt(data: Uint8Array): Uint8Array;
|
|
1502
|
+
/**
|
|
1503
|
+
* Encrypt data with this session key
|
|
1504
|
+
*/
|
|
1505
|
+
encrypt(plaintext: Uint8Array): Uint8Array;
|
|
1506
|
+
}
|
|
1507
|
+
|
|
1508
|
+
export class SpikeDrivenAttention {
|
|
1509
|
+
free(): void;
|
|
1510
|
+
[Symbol.dispose](): void;
|
|
1511
|
+
/**
|
|
1512
|
+
* Create with custom parameters
|
|
1513
|
+
*/
|
|
1514
|
+
static withConfig(threshold: number, steps: number, refractory: number): SpikeDrivenAttention;
|
|
1515
|
+
/**
|
|
1516
|
+
* Estimate energy savings ratio compared to standard attention
|
|
1517
|
+
*/
|
|
1518
|
+
energyRatio(seq_len: number, hidden_dim: number): number;
|
|
1519
|
+
/**
|
|
1520
|
+
* Create new spike-driven attention with default config
|
|
1521
|
+
*/
|
|
1522
|
+
constructor();
|
|
1523
|
+
}
|
|
1524
|
+
|
|
1525
|
+
export class SpotChecker {
|
|
1526
|
+
free(): void;
|
|
1527
|
+
[Symbol.dispose](): void;
|
|
1528
|
+
/**
|
|
1529
|
+
* Check if a task should include a spot-check
|
|
1530
|
+
*/
|
|
1531
|
+
shouldCheck(): boolean;
|
|
1532
|
+
/**
|
|
1533
|
+
* Add a known challenge-response pair
|
|
1534
|
+
*/
|
|
1535
|
+
addChallenge(task_type: string, input: Uint8Array, expected_output: Uint8Array): void;
|
|
1536
|
+
/**
|
|
1537
|
+
* Get a random challenge for a task type
|
|
1538
|
+
*/
|
|
1539
|
+
getChallenge(task_type: string): Uint8Array | undefined;
|
|
1540
|
+
/**
|
|
1541
|
+
* Verify a challenge response
|
|
1542
|
+
*/
|
|
1543
|
+
verifyResponse(input_hash: Uint8Array, output: Uint8Array): boolean;
|
|
1544
|
+
constructor(check_probability: number);
|
|
1545
|
+
}
|
|
1546
|
+
|
|
1547
|
+
export class StakeManager {
|
|
1548
|
+
free(): void;
|
|
1549
|
+
[Symbol.dispose](): void;
|
|
1550
|
+
/**
|
|
1551
|
+
* Get number of stakers
|
|
1552
|
+
*/
|
|
1553
|
+
stakerCount(): number;
|
|
1554
|
+
/**
|
|
1555
|
+
* Get total staked amount in network
|
|
1556
|
+
*/
|
|
1557
|
+
totalStaked(): bigint;
|
|
1558
|
+
/**
|
|
1559
|
+
* Get minimum stake requirement
|
|
1560
|
+
*/
|
|
1561
|
+
getMinStake(): bigint;
|
|
1562
|
+
/**
|
|
1563
|
+
* Check if node has sufficient stake
|
|
1564
|
+
*/
|
|
1565
|
+
hasSufficientStake(node_id: Uint8Array): boolean;
|
|
1566
|
+
/**
|
|
1567
|
+
* Create a new stake manager
|
|
1568
|
+
*/
|
|
1569
|
+
constructor(min_stake: bigint);
|
|
1570
|
+
/**
|
|
1571
|
+
* Get staked amount for a node
|
|
1572
|
+
*/
|
|
1573
|
+
getStake(node_id: Uint8Array): bigint;
|
|
1574
|
+
}
|
|
1575
|
+
|
|
1576
|
+
export class SwarmIntelligence {
|
|
1577
|
+
free(): void;
|
|
1578
|
+
[Symbol.dispose](): void;
|
|
1579
|
+
/**
|
|
1580
|
+
* Get queue size
|
|
1581
|
+
*/
|
|
1582
|
+
queueSize(): number;
|
|
1583
|
+
/**
|
|
1584
|
+
* Set belief for a topic's decision
|
|
1585
|
+
*/
|
|
1586
|
+
setBelief(topic: string, decision_id: bigint, probability: number): void;
|
|
1587
|
+
/**
|
|
1588
|
+
* Add pattern to collective memory
|
|
1589
|
+
*/
|
|
1590
|
+
addPattern(pattern_json: string): boolean;
|
|
1591
|
+
/**
|
|
1592
|
+
* Run memory consolidation
|
|
1593
|
+
*/
|
|
1594
|
+
consolidate(): number;
|
|
1595
|
+
/**
|
|
1596
|
+
* Check if topic has reached consensus
|
|
1597
|
+
*/
|
|
1598
|
+
hasConsensus(topic: string): boolean;
|
|
1599
|
+
/**
|
|
1600
|
+
* Get collective memory pattern count
|
|
1601
|
+
*/
|
|
1602
|
+
patternCount(): number;
|
|
1603
|
+
/**
|
|
1604
|
+
* Search collective memory
|
|
1605
|
+
*/
|
|
1606
|
+
searchPatterns(query_json: string, k: number): string;
|
|
1607
|
+
/**
|
|
1608
|
+
* Start a new consensus round for a topic
|
|
1609
|
+
*/
|
|
1610
|
+
startConsensus(topic: string, threshold: number): void;
|
|
1611
|
+
/**
|
|
1612
|
+
* Negotiate beliefs for a topic
|
|
1613
|
+
*/
|
|
1614
|
+
negotiateBeliefs(topic: string, beliefs_json: string): boolean;
|
|
1615
|
+
/**
|
|
1616
|
+
* Get consensus decision for topic
|
|
1617
|
+
*/
|
|
1618
|
+
getConsensusDecision(topic: string): bigint | undefined;
|
|
1619
|
+
/**
|
|
1620
|
+
* Create new swarm intelligence coordinator
|
|
1621
|
+
*/
|
|
1622
|
+
constructor(node_id: string);
|
|
1623
|
+
/**
|
|
1624
|
+
* Run hippocampal replay
|
|
1625
|
+
*/
|
|
1626
|
+
replay(): number;
|
|
1627
|
+
/**
|
|
1628
|
+
* Get node ID
|
|
1629
|
+
*/
|
|
1630
|
+
nodeId(): string;
|
|
1631
|
+
/**
|
|
1632
|
+
* Get combined statistics as JSON
|
|
1633
|
+
*/
|
|
1634
|
+
getStats(): string;
|
|
1635
|
+
}
|
|
1636
|
+
|
|
1637
|
+
export class SybilDefense {
|
|
1638
|
+
free(): void;
|
|
1639
|
+
[Symbol.dispose](): void;
|
|
1640
|
+
/**
|
|
1641
|
+
* Register a node with its fingerprint
|
|
1642
|
+
*/
|
|
1643
|
+
registerNode(node_id: string, fingerprint: string): boolean;
|
|
1644
|
+
/**
|
|
1645
|
+
* Get sybil score (0.0 = likely unique, 1.0 = likely sybil)
|
|
1646
|
+
*/
|
|
1647
|
+
getSybilScore(node_id: string): number;
|
|
1648
|
+
/**
|
|
1649
|
+
* Check if node is likely a sybil
|
|
1650
|
+
*/
|
|
1651
|
+
isSuspectedSybil(node_id: string): boolean;
|
|
1652
|
+
constructor();
|
|
1653
|
+
}
|
|
1654
|
+
|
|
1655
|
+
/**
|
|
1656
|
+
* Task priority levels
|
|
1657
|
+
*/
|
|
1658
|
+
export enum TaskPriority {
|
|
1659
|
+
Low = 0,
|
|
1660
|
+
Normal = 1,
|
|
1661
|
+
High = 2,
|
|
1662
|
+
}
|
|
1663
|
+
|
|
1664
|
+
/**
|
|
1665
|
+
* Task types supported by the network
|
|
1666
|
+
*/
|
|
1667
|
+
export enum TaskType {
|
|
1668
|
+
/**
|
|
1669
|
+
* Vector search in HNSW index
|
|
1670
|
+
*/
|
|
1671
|
+
VectorSearch = 0,
|
|
1672
|
+
/**
|
|
1673
|
+
* Vector insertion
|
|
1674
|
+
*/
|
|
1675
|
+
VectorInsert = 1,
|
|
1676
|
+
/**
|
|
1677
|
+
* Generate embeddings
|
|
1678
|
+
*/
|
|
1679
|
+
Embedding = 2,
|
|
1680
|
+
/**
|
|
1681
|
+
* Semantic task-to-agent matching
|
|
1682
|
+
*/
|
|
1683
|
+
SemanticMatch = 3,
|
|
1684
|
+
/**
|
|
1685
|
+
* Neural network inference
|
|
1686
|
+
*/
|
|
1687
|
+
NeuralInference = 4,
|
|
1688
|
+
/**
|
|
1689
|
+
* AES encryption/decryption
|
|
1690
|
+
*/
|
|
1691
|
+
Encryption = 5,
|
|
1692
|
+
/**
|
|
1693
|
+
* Data compression
|
|
1694
|
+
*/
|
|
1695
|
+
Compression = 6,
|
|
1696
|
+
/**
|
|
1697
|
+
* Custom WASM module (requires verification)
|
|
1698
|
+
*/
|
|
1699
|
+
CustomWasm = 7,
|
|
1700
|
+
}
|
|
1701
|
+
|
|
1702
|
+
export class TopKSparsifier {
|
|
1703
|
+
free(): void;
|
|
1704
|
+
[Symbol.dispose](): void;
|
|
1705
|
+
/**
|
|
1706
|
+
* Reset error feedback buffer
|
|
1707
|
+
*/
|
|
1708
|
+
resetErrorFeedback(): void;
|
|
1709
|
+
/**
|
|
1710
|
+
* Get compression ratio
|
|
1711
|
+
*/
|
|
1712
|
+
getCompressionRatio(): number;
|
|
1713
|
+
/**
|
|
1714
|
+
* Get error feedback buffer size
|
|
1715
|
+
*/
|
|
1716
|
+
getErrorBufferSize(): number;
|
|
1717
|
+
/**
|
|
1718
|
+
* Create a new TopK sparsifier
|
|
1719
|
+
*
|
|
1720
|
+
* # Arguments
|
|
1721
|
+
* * `k_ratio` - Fraction of gradients to keep (0.1 = top 10%)
|
|
1722
|
+
*/
|
|
1723
|
+
constructor(k_ratio: number);
|
|
1724
|
+
}
|
|
1725
|
+
|
|
1726
|
+
export class TrajectoryTracker {
|
|
1727
|
+
free(): void;
|
|
1728
|
+
[Symbol.dispose](): void;
|
|
1729
|
+
/**
|
|
1730
|
+
* Create a new trajectory tracker
|
|
1731
|
+
*/
|
|
1732
|
+
constructor(max_size: number);
|
|
1733
|
+
/**
|
|
1734
|
+
* Get count of trajectories
|
|
1735
|
+
*/
|
|
1736
|
+
count(): number;
|
|
1737
|
+
/**
|
|
1738
|
+
* Record a new trajectory
|
|
1739
|
+
*/
|
|
1740
|
+
record(trajectory_json: string): boolean;
|
|
1741
|
+
/**
|
|
1742
|
+
* Get statistics as JSON
|
|
1743
|
+
*/
|
|
1744
|
+
getStats(): string;
|
|
1745
|
+
}
|
|
1746
|
+
|
|
1747
|
+
export class WasmAdapterPool {
|
|
1748
|
+
free(): void;
|
|
1749
|
+
[Symbol.dispose](): void;
|
|
1750
|
+
/**
|
|
1751
|
+
* Get or create an adapter for a task type
|
|
1752
|
+
*/
|
|
1753
|
+
getAdapter(task_type: string): any;
|
|
1754
|
+
/**
|
|
1755
|
+
* Get adapter count
|
|
1756
|
+
*/
|
|
1757
|
+
adapterCount(): number;
|
|
1758
|
+
/**
|
|
1759
|
+
* Export adapter to bytes for P2P sharing
|
|
1760
|
+
*/
|
|
1761
|
+
exportAdapter(task_type: string): Uint8Array;
|
|
1762
|
+
/**
|
|
1763
|
+
* Import adapter from bytes
|
|
1764
|
+
*/
|
|
1765
|
+
importAdapter(task_type: string, bytes: Uint8Array): boolean;
|
|
1766
|
+
/**
|
|
1767
|
+
* Route to best adapter by task embedding
|
|
1768
|
+
*/
|
|
1769
|
+
routeToAdapter(task_embedding: Float32Array): any;
|
|
1770
|
+
/**
|
|
1771
|
+
* Create a new adapter pool
|
|
1772
|
+
*/
|
|
1773
|
+
constructor(hidden_dim: number, max_slots: number);
|
|
1774
|
+
/**
|
|
1775
|
+
* Apply adapter to input
|
|
1776
|
+
*/
|
|
1777
|
+
forward(task_type: string, input: Float32Array): Float32Array;
|
|
1778
|
+
/**
|
|
1779
|
+
* Get pool statistics
|
|
1780
|
+
*/
|
|
1781
|
+
getStats(): any;
|
|
1782
|
+
}
|
|
1783
|
+
|
|
1784
|
+
export class WasmCapabilities {
|
|
1785
|
+
free(): void;
|
|
1786
|
+
[Symbol.dispose](): void;
|
|
1787
|
+
enableHDC(): boolean;
|
|
1788
|
+
enableNAO(_quorum: number): boolean;
|
|
1789
|
+
enableWTA(_num_neurons: number, _inhibition: number, _threshold: number): boolean;
|
|
1790
|
+
competeWTA(_activations: Float32Array): number;
|
|
1791
|
+
enableBTSP(_input_dim: number, _time_constant: number): boolean;
|
|
1792
|
+
executeNAO(_proposal_id: string): boolean;
|
|
1793
|
+
/**
|
|
1794
|
+
* Get a summary of all enabled capabilities
|
|
1795
|
+
*/
|
|
1796
|
+
getSummary(): any;
|
|
1797
|
+
proposeNAO(_action: string): string;
|
|
1798
|
+
forwardBTSP(_input: Float32Array): number;
|
|
1799
|
+
getNAOSync(): number;
|
|
1800
|
+
retrieveHDC(_key: string, _threshold: number): any;
|
|
1801
|
+
addNAOMember(_member_id: string, _stake: bigint): boolean;
|
|
1802
|
+
adaptMicroLoRA(_operator_type: string, _gradient: Float32Array): boolean;
|
|
1803
|
+
applyMicroLoRA(_operator_type: string, input: Float32Array): Float32Array;
|
|
1804
|
+
/**
|
|
1805
|
+
* List all available exotic capabilities
|
|
1806
|
+
*/
|
|
1807
|
+
getCapabilities(): any;
|
|
1808
|
+
enableMicroLoRA(_dim: number, _rank: number): boolean;
|
|
1809
|
+
tickTimeCrystal(): any;
|
|
1810
|
+
growMorphogenetic(_rate: number): void;
|
|
1811
|
+
oneShotAssociate(_pattern: Float32Array, _target: number): boolean;
|
|
1812
|
+
enableTimeCrystal(_oscillators: number, _period_ms: number): boolean;
|
|
1813
|
+
pruneMorphogenetic(_threshold: number): void;
|
|
1814
|
+
enableMorphogenetic(_width: number, _height: number): boolean;
|
|
1815
|
+
getTimeCrystalSync(): number;
|
|
1816
|
+
broadcastToWorkspace(_content: Float32Array, _salience: number, _source_module: number): boolean;
|
|
1817
|
+
getWorkspaceContents(): any;
|
|
1818
|
+
isTimeCrystalStable(): boolean;
|
|
1819
|
+
enableGlobalWorkspace(_capacity: number): boolean;
|
|
1820
|
+
getMorphogeneticStats(): any;
|
|
1821
|
+
differentiateMorphogenetic(): void;
|
|
1822
|
+
getMorphogeneticCellCount(): number;
|
|
1823
|
+
/**
|
|
1824
|
+
* Create a new capabilities manager for a node
|
|
1825
|
+
*/
|
|
1826
|
+
constructor(node_id: string);
|
|
1827
|
+
/**
|
|
1828
|
+
* Step all enabled capabilities forward (for main loop integration)
|
|
1829
|
+
*/
|
|
1830
|
+
step(dt: number): void;
|
|
1831
|
+
tickNAO(_dt: number): void;
|
|
1832
|
+
voteNAO(_proposal_id: string, _weight: number): boolean;
|
|
1833
|
+
storeHDC(_key: string): boolean;
|
|
1834
|
+
}
|
|
1835
|
+
|
|
1836
|
+
export class WasmCreditLedger {
|
|
1837
|
+
free(): void;
|
|
1838
|
+
[Symbol.dispose](): void;
|
|
1839
|
+
/**
|
|
1840
|
+
* Get total spent
|
|
1841
|
+
*/
|
|
1842
|
+
totalSpent(): bigint;
|
|
1843
|
+
/**
|
|
1844
|
+
* Export spent counter for sync
|
|
1845
|
+
*/
|
|
1846
|
+
exportSpent(): Uint8Array;
|
|
1847
|
+
/**
|
|
1848
|
+
* Get total earned (before spending)
|
|
1849
|
+
*/
|
|
1850
|
+
totalEarned(): bigint;
|
|
1851
|
+
/**
|
|
1852
|
+
* Export earned counter for sync
|
|
1853
|
+
*/
|
|
1854
|
+
exportEarned(): Uint8Array;
|
|
1855
|
+
/**
|
|
1856
|
+
* Get staked amount
|
|
1857
|
+
*/
|
|
1858
|
+
stakedAmount(): bigint;
|
|
1859
|
+
/**
|
|
1860
|
+
* Get network compute hours (for multiplier)
|
|
1861
|
+
*/
|
|
1862
|
+
networkCompute(): number;
|
|
1863
|
+
/**
|
|
1864
|
+
* Get current multiplier
|
|
1865
|
+
*/
|
|
1866
|
+
currentMultiplier(): number;
|
|
1867
|
+
/**
|
|
1868
|
+
* Update network compute (from P2P sync)
|
|
1869
|
+
*/
|
|
1870
|
+
updateNetworkCompute(hours: number): void;
|
|
1871
|
+
/**
|
|
1872
|
+
* Create a new credit ledger
|
|
1873
|
+
*/
|
|
1874
|
+
constructor(node_id: string);
|
|
1875
|
+
/**
|
|
1876
|
+
* Merge with another ledger (CRDT merge) - optimized batch processing
|
|
1877
|
+
*/
|
|
1878
|
+
merge(other_earned: Uint8Array, other_spent: Uint8Array): void;
|
|
1879
|
+
/**
|
|
1880
|
+
* Slash staked credits (penalty for bad behavior)
|
|
1881
|
+
*/
|
|
1882
|
+
slash(amount: bigint): bigint;
|
|
1883
|
+
/**
|
|
1884
|
+
* Stake credits for participation
|
|
1885
|
+
*/
|
|
1886
|
+
stake(amount: bigint): void;
|
|
1887
|
+
/**
|
|
1888
|
+
* Credit the ledger (earn credits)
|
|
1889
|
+
*/
|
|
1890
|
+
credit(amount: bigint, reason: string): void;
|
|
1891
|
+
/**
|
|
1892
|
+
* Deduct from the ledger (spend credits)
|
|
1893
|
+
*/
|
|
1894
|
+
deduct(amount: bigint): void;
|
|
1895
|
+
/**
|
|
1896
|
+
* Get current balance
|
|
1897
|
+
*/
|
|
1898
|
+
balance(): bigint;
|
|
1899
|
+
/**
|
|
1900
|
+
* Unstake credits
|
|
1901
|
+
*/
|
|
1902
|
+
unstake(amount: bigint): void;
|
|
1903
|
+
}
|
|
1904
|
+
|
|
1905
|
+
export class WasmIdleDetector {
|
|
1906
|
+
free(): void;
|
|
1907
|
+
[Symbol.dispose](): void;
|
|
1908
|
+
/**
|
|
1909
|
+
* Get status summary
|
|
1910
|
+
*/
|
|
1911
|
+
getStatus(): any;
|
|
1912
|
+
/**
|
|
1913
|
+
* Update FPS measurement
|
|
1914
|
+
*/
|
|
1915
|
+
updateFps(fps: number): void;
|
|
1916
|
+
/**
|
|
1917
|
+
* Check if we should be working
|
|
1918
|
+
*/
|
|
1919
|
+
shouldWork(): boolean;
|
|
1920
|
+
/**
|
|
1921
|
+
* Get current throttle level (0.0 - max_cpu)
|
|
1922
|
+
*/
|
|
1923
|
+
getThrottle(): number;
|
|
1924
|
+
/**
|
|
1925
|
+
* Record user interaction
|
|
1926
|
+
*/
|
|
1927
|
+
recordInteraction(): void;
|
|
1928
|
+
/**
|
|
1929
|
+
* Set battery status (called from JS)
|
|
1930
|
+
*/
|
|
1931
|
+
setBatteryStatus(on_battery: boolean): void;
|
|
1932
|
+
/**
|
|
1933
|
+
* Create a new idle detector
|
|
1934
|
+
*/
|
|
1935
|
+
constructor(max_cpu: number, min_idle_time: number);
|
|
1936
|
+
/**
|
|
1937
|
+
* Stop monitoring
|
|
1938
|
+
*/
|
|
1939
|
+
stop(): void;
|
|
1940
|
+
/**
|
|
1941
|
+
* Pause contribution (user-initiated)
|
|
1942
|
+
*/
|
|
1943
|
+
pause(): void;
|
|
1944
|
+
/**
|
|
1945
|
+
* Start monitoring
|
|
1946
|
+
*/
|
|
1947
|
+
start(): void;
|
|
1948
|
+
/**
|
|
1949
|
+
* Resume contribution
|
|
1950
|
+
*/
|
|
1951
|
+
resume(): void;
|
|
1952
|
+
/**
|
|
1953
|
+
* Check if user is idle
|
|
1954
|
+
*/
|
|
1955
|
+
isIdle(): boolean;
|
|
1956
|
+
}
|
|
1957
|
+
|
|
1958
|
+
export class WasmMcpBroadcast {
|
|
1959
|
+
free(): void;
|
|
1960
|
+
[Symbol.dispose](): void;
|
|
1961
|
+
/**
|
|
1962
|
+
* Set as server mode (responds to requests)
|
|
1963
|
+
*/
|
|
1964
|
+
setServer(server: WasmMcpServer): void;
|
|
1965
|
+
/**
|
|
1966
|
+
* Create a broadcast transport
|
|
1967
|
+
*/
|
|
1968
|
+
constructor(channel_name: string);
|
|
1969
|
+
/**
|
|
1970
|
+
* Send a request (client mode)
|
|
1971
|
+
*/
|
|
1972
|
+
send(request_json: string): void;
|
|
1973
|
+
/**
|
|
1974
|
+
* Close the channel
|
|
1975
|
+
*/
|
|
1976
|
+
close(): void;
|
|
1977
|
+
/**
|
|
1978
|
+
* Start listening for requests (server mode)
|
|
1979
|
+
*/
|
|
1980
|
+
listen(): void;
|
|
1981
|
+
}
|
|
1982
|
+
|
|
1983
|
+
export class WasmMcpServer {
|
|
1984
|
+
free(): void;
|
|
1985
|
+
[Symbol.dispose](): void;
|
|
1986
|
+
/**
|
|
1987
|
+
* Create with custom configuration
|
|
1988
|
+
*/
|
|
1989
|
+
static withConfig(config: any): WasmMcpServer;
|
|
1990
|
+
/**
|
|
1991
|
+
* Set identity for authenticated operations
|
|
1992
|
+
*/
|
|
1993
|
+
setIdentity(identity: WasmNodeIdentity): void;
|
|
1994
|
+
/**
|
|
1995
|
+
* Initialize learning engine
|
|
1996
|
+
*/
|
|
1997
|
+
initLearning(): void;
|
|
1998
|
+
/**
|
|
1999
|
+
* Handle an MCP request (JSON string)
|
|
2000
|
+
*/
|
|
2001
|
+
handleRequest(request_json: string): Promise<string>;
|
|
2002
|
+
/**
|
|
2003
|
+
* Get server info
|
|
2004
|
+
*/
|
|
2005
|
+
getServerInfo(): any;
|
|
2006
|
+
/**
|
|
2007
|
+
* Handle MCP request from JsValue (for direct JS calls)
|
|
2008
|
+
*/
|
|
2009
|
+
handleRequestJs(request: any): Promise<any>;
|
|
2010
|
+
/**
|
|
2011
|
+
* Create a new MCP server with default configuration
|
|
2012
|
+
*/
|
|
2013
|
+
constructor();
|
|
2014
|
+
}
|
|
2015
|
+
|
|
2016
|
+
export class WasmMcpTransport {
|
|
2017
|
+
free(): void;
|
|
2018
|
+
[Symbol.dispose](): void;
|
|
2019
|
+
/**
|
|
2020
|
+
* Create transport from a Worker
|
|
2021
|
+
*/
|
|
2022
|
+
constructor(worker: Worker);
|
|
2023
|
+
/**
|
|
2024
|
+
* Initialize transport (set up message handler)
|
|
2025
|
+
*/
|
|
2026
|
+
init(): void;
|
|
2027
|
+
/**
|
|
2028
|
+
* Send an MCP request and get a Promise for the response
|
|
2029
|
+
*/
|
|
2030
|
+
send(request: any): Promise<any>;
|
|
2031
|
+
/**
|
|
2032
|
+
* Close the transport
|
|
2033
|
+
*/
|
|
2034
|
+
close(): void;
|
|
2035
|
+
/**
|
|
2036
|
+
* Create transport from existing MessagePort
|
|
2037
|
+
*/
|
|
2038
|
+
static fromPort(port: MessagePort): WasmMcpTransport;
|
|
2039
|
+
}
|
|
2040
|
+
|
|
2041
|
+
export class WasmMcpWorkerHandler {
|
|
2042
|
+
free(): void;
|
|
2043
|
+
[Symbol.dispose](): void;
|
|
2044
|
+
/**
|
|
2045
|
+
* Create handler with MCP server
|
|
2046
|
+
*/
|
|
2047
|
+
constructor(server: WasmMcpServer);
|
|
2048
|
+
/**
|
|
2049
|
+
* Start handling messages (call in worker)
|
|
2050
|
+
*/
|
|
2051
|
+
start(): void;
|
|
2052
|
+
}
|
|
2053
|
+
|
|
2054
|
+
export class WasmNetworkManager {
|
|
2055
|
+
free(): void;
|
|
2056
|
+
[Symbol.dispose](): void;
|
|
2057
|
+
/**
|
|
2058
|
+
* Get peer count
|
|
2059
|
+
*/
|
|
2060
|
+
peerCount(): number;
|
|
2061
|
+
/**
|
|
2062
|
+
* Check if connected
|
|
2063
|
+
*/
|
|
2064
|
+
isConnected(): boolean;
|
|
2065
|
+
/**
|
|
2066
|
+
* Register a peer
|
|
2067
|
+
*/
|
|
2068
|
+
registerPeer(node_id: string, pubkey: Uint8Array, capabilities: string[], stake: bigint): void;
|
|
2069
|
+
/**
|
|
2070
|
+
* Select workers for task execution (reputation-weighted random)
|
|
2071
|
+
*/
|
|
2072
|
+
selectWorkers(capability: string, count: number): string[];
|
|
2073
|
+
/**
|
|
2074
|
+
* Get active peer count (seen in last 60s)
|
|
2075
|
+
*/
|
|
2076
|
+
activePeerCount(): number;
|
|
2077
|
+
/**
|
|
2078
|
+
* Update peer reputation
|
|
2079
|
+
*/
|
|
2080
|
+
updateReputation(node_id: string, delta: number): void;
|
|
2081
|
+
/**
|
|
2082
|
+
* Get peers with specific capability
|
|
2083
|
+
*/
|
|
2084
|
+
getPeersWithCapability(capability: string): string[];
|
|
2085
|
+
constructor(node_id: string);
|
|
2086
|
+
/**
|
|
2087
|
+
* Add a relay URL
|
|
2088
|
+
*/
|
|
2089
|
+
addRelay(url: string): void;
|
|
2090
|
+
}
|
|
2091
|
+
|
|
2092
|
+
export class WasmNodeIdentity {
|
|
2093
|
+
private constructor();
|
|
2094
|
+
free(): void;
|
|
2095
|
+
[Symbol.dispose](): void;
|
|
2096
|
+
/**
|
|
2097
|
+
* Verify a signature from another node
|
|
2098
|
+
*/
|
|
2099
|
+
static verifyFrom(public_key: Uint8Array, message: Uint8Array, signature: Uint8Array): boolean;
|
|
2100
|
+
/**
|
|
2101
|
+
* Get the public key as hex string
|
|
2102
|
+
*/
|
|
2103
|
+
publicKeyHex(): string;
|
|
2104
|
+
/**
|
|
2105
|
+
* Restore identity from secret key bytes
|
|
2106
|
+
*/
|
|
2107
|
+
static fromSecretKey(secret_key: Uint8Array, site_id: string): WasmNodeIdentity;
|
|
2108
|
+
/**
|
|
2109
|
+
* Get browser fingerprint
|
|
2110
|
+
*/
|
|
2111
|
+
getFingerprint(): string | undefined;
|
|
2112
|
+
/**
|
|
2113
|
+
* Set browser fingerprint for anti-sybil
|
|
2114
|
+
*/
|
|
2115
|
+
setFingerprint(fingerprint: string): void;
|
|
2116
|
+
/**
|
|
2117
|
+
* Get the public key as bytes
|
|
2118
|
+
*/
|
|
2119
|
+
publicKeyBytes(): Uint8Array;
|
|
2120
|
+
/**
|
|
2121
|
+
* Export secret key encrypted with password (secure backup)
|
|
2122
|
+
* Uses Argon2id for key derivation and AES-256-GCM for encryption
|
|
2123
|
+
*/
|
|
2124
|
+
exportSecretKey(password: string): Uint8Array;
|
|
2125
|
+
/**
|
|
2126
|
+
* Import secret key from encrypted backup
|
|
2127
|
+
*/
|
|
2128
|
+
static importSecretKey(encrypted: Uint8Array, password: string, site_id: string): WasmNodeIdentity;
|
|
2129
|
+
/**
|
|
2130
|
+
* Sign a message
|
|
2131
|
+
*/
|
|
2132
|
+
sign(message: Uint8Array): Uint8Array;
|
|
2133
|
+
/**
|
|
2134
|
+
* Verify a signature
|
|
2135
|
+
*/
|
|
2136
|
+
verify(message: Uint8Array, signature: Uint8Array): boolean;
|
|
2137
|
+
/**
|
|
2138
|
+
* Get the node's unique identifier
|
|
2139
|
+
*/
|
|
2140
|
+
nodeId(): string;
|
|
2141
|
+
/**
|
|
2142
|
+
* Get the site ID
|
|
2143
|
+
*/
|
|
2144
|
+
siteId(): string;
|
|
2145
|
+
/**
|
|
2146
|
+
* Generate a new node identity
|
|
2147
|
+
*/
|
|
2148
|
+
static generate(site_id: string): WasmNodeIdentity;
|
|
2149
|
+
}
|
|
2150
|
+
|
|
2151
|
+
export class WasmStigmergy {
|
|
2152
|
+
free(): void;
|
|
2153
|
+
[Symbol.dispose](): void;
|
|
2154
|
+
/**
|
|
2155
|
+
* Create with custom parameters
|
|
2156
|
+
*/
|
|
2157
|
+
static withParams(decay_rate: number, deposit_rate: number, evaporation_hours: number): WasmStigmergy;
|
|
2158
|
+
/**
|
|
2159
|
+
* Export current state for P2P sharing
|
|
2160
|
+
*/
|
|
2161
|
+
exportState(): string;
|
|
2162
|
+
/**
|
|
2163
|
+
* Get raw pheromone intensity
|
|
2164
|
+
*/
|
|
2165
|
+
getIntensity(task_type: string): number;
|
|
2166
|
+
/**
|
|
2167
|
+
* Set minimum stake for anti-sybil
|
|
2168
|
+
*/
|
|
2169
|
+
setMinStake(min_stake: bigint): void;
|
|
2170
|
+
/**
|
|
2171
|
+
* Should this node accept a task? (combined decision)
|
|
2172
|
+
*/
|
|
2173
|
+
shouldAccept(task_type: string): number;
|
|
2174
|
+
/**
|
|
2175
|
+
* Check and run evaporation if due
|
|
2176
|
+
*/
|
|
2177
|
+
maybeEvaporate(): boolean;
|
|
2178
|
+
/**
|
|
2179
|
+
* Get all task types ranked by attractiveness
|
|
2180
|
+
*/
|
|
2181
|
+
getRankedTasks(): string;
|
|
2182
|
+
/**
|
|
2183
|
+
* Get success rate for a task type
|
|
2184
|
+
*/
|
|
2185
|
+
getSuccessRate(task_type: string): number;
|
|
2186
|
+
/**
|
|
2187
|
+
* Get node's specialization score
|
|
2188
|
+
*/
|
|
2189
|
+
getSpecialization(task_type: string): number;
|
|
2190
|
+
/**
|
|
2191
|
+
* Deposit with success/failure outcome
|
|
2192
|
+
*/
|
|
2193
|
+
depositWithOutcome(task_type: string, peer_id: string, success: boolean, stake: bigint): void;
|
|
2194
|
+
/**
|
|
2195
|
+
* Update node specialization based on outcome
|
|
2196
|
+
*/
|
|
2197
|
+
updateSpecialization(task_type: string, success: boolean): void;
|
|
2198
|
+
/**
|
|
2199
|
+
* Get best specialization recommendation
|
|
2200
|
+
*/
|
|
2201
|
+
getBestSpecialization(): string | undefined;
|
|
2202
|
+
/**
|
|
2203
|
+
* Create a new stigmergy engine
|
|
2204
|
+
*/
|
|
2205
|
+
constructor();
|
|
2206
|
+
/**
|
|
2207
|
+
* Merge peer pheromone state (JSON format)
|
|
2208
|
+
*/
|
|
2209
|
+
merge(peer_state_json: string): boolean;
|
|
2210
|
+
/**
|
|
2211
|
+
* Get acceptance probability for a task type
|
|
2212
|
+
*/
|
|
2213
|
+
follow(task_type: string): number;
|
|
2214
|
+
/**
|
|
2215
|
+
* Deposit pheromone after task completion
|
|
2216
|
+
*/
|
|
2217
|
+
deposit(task_type: string, peer_id: string, success_rate: number, stake: bigint): void;
|
|
2218
|
+
/**
|
|
2219
|
+
* Run evaporation (call periodically)
|
|
2220
|
+
*/
|
|
2221
|
+
evaporate(): void;
|
|
2222
|
+
/**
|
|
2223
|
+
* Get statistics as JSON
|
|
2224
|
+
*/
|
|
2225
|
+
getStats(): string;
|
|
2226
|
+
}
|
|
2227
|
+
|
|
2228
|
+
export class WasmTaskExecutor {
|
|
2229
|
+
free(): void;
|
|
2230
|
+
[Symbol.dispose](): void;
|
|
2231
|
+
/**
|
|
2232
|
+
* Set encryption key for payload decryption
|
|
2233
|
+
*/
|
|
2234
|
+
setTaskKey(key: Uint8Array): void;
|
|
2235
|
+
/**
|
|
2236
|
+
* Create a new task executor
|
|
2237
|
+
*/
|
|
2238
|
+
constructor(max_memory: number);
|
|
2239
|
+
}
|
|
2240
|
+
|
|
2241
|
+
export class WasmTaskQueue {
|
|
2242
|
+
private constructor();
|
|
2243
|
+
free(): void;
|
|
2244
|
+
[Symbol.dispose](): void;
|
|
2245
|
+
}
|
|
2246
|
+
|
|
2247
|
+
export class WasmWorkScheduler {
|
|
2248
|
+
free(): void;
|
|
2249
|
+
[Symbol.dispose](): void;
|
|
2250
|
+
/**
|
|
2251
|
+
* Calculate how many tasks to run this frame
|
|
2252
|
+
*/
|
|
2253
|
+
tasksThisFrame(throttle: number): number;
|
|
2254
|
+
/**
|
|
2255
|
+
* Set pending task count
|
|
2256
|
+
*/
|
|
2257
|
+
setPendingTasks(count: number): void;
|
|
2258
|
+
/**
|
|
2259
|
+
* Record task completion for averaging
|
|
2260
|
+
*/
|
|
2261
|
+
recordTaskDuration(duration_ms: number): void;
|
|
2262
|
+
constructor();
|
|
2263
|
+
}
|
|
2264
|
+
|
|
2265
|
+
export class WitnessTracker {
|
|
2266
|
+
free(): void;
|
|
2267
|
+
[Symbol.dispose](): void;
|
|
2268
|
+
/**
|
|
2269
|
+
* Get witness count for a claim
|
|
2270
|
+
*/
|
|
2271
|
+
witnessCount(claim_id: string): number;
|
|
2272
|
+
/**
|
|
2273
|
+
* Get confidence score based on witness diversity
|
|
2274
|
+
*/
|
|
2275
|
+
witnessConfidence(claim_id: string): number;
|
|
2276
|
+
/**
|
|
2277
|
+
* Check if claim has sufficient independent witnesses
|
|
2278
|
+
*/
|
|
2279
|
+
hasSufficientWitnesses(claim_id: string): boolean;
|
|
2280
|
+
/**
|
|
2281
|
+
* Create a new witness tracker
|
|
2282
|
+
*/
|
|
2283
|
+
constructor(min_witnesses: number);
|
|
2284
|
+
}
|
|
2285
|
+
|
|
2286
|
+
/**
|
|
2287
|
+
* Initialize panic hook for better error messages in console
|
|
2288
|
+
*/
|
|
2289
|
+
export function init_panic_hook(): void;
|
|
2290
|
+
|
|
2291
|
+
export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembly.Module;
|
|
2292
|
+
|
|
2293
|
+
export interface InitOutput {
|
|
2294
|
+
readonly memory: WebAssembly.Memory;
|
|
2295
|
+
readonly __wbg_adaptivesecurity_free: (a: number, b: number) => void;
|
|
2296
|
+
readonly __wbg_adversarialsimulator_free: (a: number, b: number) => void;
|
|
2297
|
+
readonly __wbg_auditlog_free: (a: number, b: number) => void;
|
|
2298
|
+
readonly __wbg_browserfingerprint_free: (a: number, b: number) => void;
|
|
2299
|
+
readonly __wbg_byzantinedetector_free: (a: number, b: number) => void;
|
|
2300
|
+
readonly __wbg_coherenceengine_free: (a: number, b: number) => void;
|
|
2301
|
+
readonly __wbg_collectivememory_free: (a: number, b: number) => void;
|
|
2302
|
+
readonly __wbg_contributionstream_free: (a: number, b: number) => void;
|
|
2303
|
+
readonly __wbg_differentialprivacy_free: (a: number, b: number) => void;
|
|
2304
|
+
readonly __wbg_drifttracker_free: (a: number, b: number) => void;
|
|
2305
|
+
readonly __wbg_economicengine_free: (a: number, b: number) => void;
|
|
2306
|
+
readonly __wbg_economichealth_free: (a: number, b: number) => void;
|
|
2307
|
+
readonly __wbg_edgenetconfig_free: (a: number, b: number) => void;
|
|
2308
|
+
readonly __wbg_edgenetnode_free: (a: number, b: number) => void;
|
|
2309
|
+
readonly __wbg_entropyconsensus_free: (a: number, b: number) => void;
|
|
2310
|
+
readonly __wbg_eventlog_free: (a: number, b: number) => void;
|
|
2311
|
+
readonly __wbg_evolutionengine_free: (a: number, b: number) => void;
|
|
2312
|
+
readonly __wbg_federatedmodel_free: (a: number, b: number) => void;
|
|
2313
|
+
readonly __wbg_foundingregistry_free: (a: number, b: number) => void;
|
|
2314
|
+
readonly __wbg_genesiskey_free: (a: number, b: number) => void;
|
|
2315
|
+
readonly __wbg_genesissunset_free: (a: number, b: number) => void;
|
|
2316
|
+
readonly __wbg_get_economichealth_growth_rate: (a: number) => number;
|
|
2317
|
+
readonly __wbg_get_economichealth_stability: (a: number) => number;
|
|
2318
|
+
readonly __wbg_get_economichealth_utilization: (a: number) => number;
|
|
2319
|
+
readonly __wbg_get_economichealth_velocity: (a: number) => number;
|
|
2320
|
+
readonly __wbg_get_nodeconfig_bandwidth_limit: (a: number) => number;
|
|
2321
|
+
readonly __wbg_get_nodeconfig_memory_limit: (a: number) => number;
|
|
2322
|
+
readonly __wbg_get_nodeconfig_min_idle_time: (a: number) => number;
|
|
2323
|
+
readonly __wbg_get_nodeconfig_respect_battery: (a: number) => number;
|
|
2324
|
+
readonly __wbg_get_nodestats_celebration_boost: (a: number) => number;
|
|
2325
|
+
readonly __wbg_get_nodestats_multiplier: (a: number) => number;
|
|
2326
|
+
readonly __wbg_get_nodestats_reputation: (a: number) => number;
|
|
2327
|
+
readonly __wbg_get_nodestats_ruv_earned: (a: number) => bigint;
|
|
2328
|
+
readonly __wbg_get_nodestats_ruv_spent: (a: number) => bigint;
|
|
2329
|
+
readonly __wbg_get_nodestats_tasks_completed: (a: number) => bigint;
|
|
2330
|
+
readonly __wbg_get_nodestats_tasks_submitted: (a: number) => bigint;
|
|
2331
|
+
readonly __wbg_get_nodestats_uptime_seconds: (a: number) => bigint;
|
|
2332
|
+
readonly __wbg_gradientgossip_free: (a: number, b: number) => void;
|
|
2333
|
+
readonly __wbg_modelconsensusmanager_free: (a: number, b: number) => void;
|
|
2334
|
+
readonly __wbg_networkevents_free: (a: number, b: number) => void;
|
|
2335
|
+
readonly __wbg_networklearning_free: (a: number, b: number) => void;
|
|
2336
|
+
readonly __wbg_networktopology_free: (a: number, b: number) => void;
|
|
2337
|
+
readonly __wbg_nodeconfig_free: (a: number, b: number) => void;
|
|
2338
|
+
readonly __wbg_nodestats_free: (a: number, b: number) => void;
|
|
2339
|
+
readonly __wbg_optimizationengine_free: (a: number, b: number) => void;
|
|
2340
|
+
readonly __wbg_pikey_free: (a: number, b: number) => void;
|
|
2341
|
+
readonly __wbg_qdagledger_free: (a: number, b: number) => void;
|
|
2342
|
+
readonly __wbg_quarantinemanager_free: (a: number, b: number) => void;
|
|
2343
|
+
readonly __wbg_raceconomicengine_free: (a: number, b: number) => void;
|
|
2344
|
+
readonly __wbg_racsemanticrouter_free: (a: number, b: number) => void;
|
|
2345
|
+
readonly __wbg_ratelimiter_free: (a: number, b: number) => void;
|
|
2346
|
+
readonly __wbg_reasoningbank_free: (a: number, b: number) => void;
|
|
2347
|
+
readonly __wbg_reputationmanager_free: (a: number, b: number) => void;
|
|
2348
|
+
readonly __wbg_reputationsystem_free: (a: number, b: number) => void;
|
|
2349
|
+
readonly __wbg_rewarddistribution_free: (a: number, b: number) => void;
|
|
2350
|
+
readonly __wbg_rewardmanager_free: (a: number, b: number) => void;
|
|
2351
|
+
readonly __wbg_semanticrouter_free: (a: number, b: number) => void;
|
|
2352
|
+
readonly __wbg_sessionkey_free: (a: number, b: number) => void;
|
|
2353
|
+
readonly __wbg_set_economichealth_growth_rate: (a: number, b: number) => void;
|
|
2354
|
+
readonly __wbg_set_economichealth_stability: (a: number, b: number) => void;
|
|
2355
|
+
readonly __wbg_set_economichealth_utilization: (a: number, b: number) => void;
|
|
2356
|
+
readonly __wbg_set_economichealth_velocity: (a: number, b: number) => void;
|
|
2357
|
+
readonly __wbg_set_nodeconfig_bandwidth_limit: (a: number, b: number) => void;
|
|
2358
|
+
readonly __wbg_set_nodeconfig_memory_limit: (a: number, b: number) => void;
|
|
2359
|
+
readonly __wbg_set_nodeconfig_min_idle_time: (a: number, b: number) => void;
|
|
2360
|
+
readonly __wbg_set_nodeconfig_respect_battery: (a: number, b: number) => void;
|
|
2361
|
+
readonly __wbg_set_nodestats_celebration_boost: (a: number, b: number) => void;
|
|
2362
|
+
readonly __wbg_set_nodestats_multiplier: (a: number, b: number) => void;
|
|
2363
|
+
readonly __wbg_set_nodestats_reputation: (a: number, b: number) => void;
|
|
2364
|
+
readonly __wbg_set_nodestats_ruv_earned: (a: number, b: bigint) => void;
|
|
2365
|
+
readonly __wbg_set_nodestats_ruv_spent: (a: number, b: bigint) => void;
|
|
2366
|
+
readonly __wbg_set_nodestats_tasks_completed: (a: number, b: bigint) => void;
|
|
2367
|
+
readonly __wbg_set_nodestats_tasks_submitted: (a: number, b: bigint) => void;
|
|
2368
|
+
readonly __wbg_set_nodestats_uptime_seconds: (a: number, b: bigint) => void;
|
|
2369
|
+
readonly __wbg_spikedrivenattention_free: (a: number, b: number) => void;
|
|
2370
|
+
readonly __wbg_spotchecker_free: (a: number, b: number) => void;
|
|
2371
|
+
readonly __wbg_stakemanager_free: (a: number, b: number) => void;
|
|
2372
|
+
readonly __wbg_swarmintelligence_free: (a: number, b: number) => void;
|
|
2373
|
+
readonly __wbg_sybildefense_free: (a: number, b: number) => void;
|
|
2374
|
+
readonly __wbg_topksparsifier_free: (a: number, b: number) => void;
|
|
2375
|
+
readonly __wbg_trajectorytracker_free: (a: number, b: number) => void;
|
|
2376
|
+
readonly __wbg_wasmadapterpool_free: (a: number, b: number) => void;
|
|
2377
|
+
readonly __wbg_wasmcapabilities_free: (a: number, b: number) => void;
|
|
2378
|
+
readonly __wbg_wasmcreditledger_free: (a: number, b: number) => void;
|
|
2379
|
+
readonly __wbg_wasmidledetector_free: (a: number, b: number) => void;
|
|
2380
|
+
readonly __wbg_wasmmcpbroadcast_free: (a: number, b: number) => void;
|
|
2381
|
+
readonly __wbg_wasmmcpserver_free: (a: number, b: number) => void;
|
|
2382
|
+
readonly __wbg_wasmmcptransport_free: (a: number, b: number) => void;
|
|
2383
|
+
readonly __wbg_wasmmcpworkerhandler_free: (a: number, b: number) => void;
|
|
2384
|
+
readonly __wbg_wasmnetworkmanager_free: (a: number, b: number) => void;
|
|
2385
|
+
readonly __wbg_wasmnodeidentity_free: (a: number, b: number) => void;
|
|
2386
|
+
readonly __wbg_wasmstigmergy_free: (a: number, b: number) => void;
|
|
2387
|
+
readonly __wbg_wasmtaskexecutor_free: (a: number, b: number) => void;
|
|
2388
|
+
readonly __wbg_wasmtaskqueue_free: (a: number, b: number) => void;
|
|
2389
|
+
readonly __wbg_witnesstracker_free: (a: number, b: number) => void;
|
|
2390
|
+
readonly adaptivesecurity_chooseAction: (a: number, b: number, c: number, d: number, e: number) => [number, number];
|
|
2391
|
+
readonly adaptivesecurity_detectAttack: (a: number, b: number, c: number) => number;
|
|
2392
|
+
readonly adaptivesecurity_exportPatterns: (a: number) => [number, number, number, number];
|
|
2393
|
+
readonly adaptivesecurity_getMinReputation: (a: number) => number;
|
|
2394
|
+
readonly adaptivesecurity_getRateLimitMax: (a: number) => number;
|
|
2395
|
+
readonly adaptivesecurity_getRateLimitWindow: (a: number) => bigint;
|
|
2396
|
+
readonly adaptivesecurity_getSecurityLevel: (a: number) => number;
|
|
2397
|
+
readonly adaptivesecurity_getSpotCheckProbability: (a: number) => number;
|
|
2398
|
+
readonly adaptivesecurity_getStats: (a: number) => [number, number];
|
|
2399
|
+
readonly adaptivesecurity_importPatterns: (a: number, b: number, c: number) => [number, number];
|
|
2400
|
+
readonly adaptivesecurity_learn: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number) => void;
|
|
2401
|
+
readonly adaptivesecurity_new: () => number;
|
|
2402
|
+
readonly adaptivesecurity_recordAttackPattern: (a: number, b: number, c: number, d: number, e: number, f: number) => void;
|
|
2403
|
+
readonly adaptivesecurity_updateNetworkHealth: (a: number, b: number, c: number, d: number, e: number, f: number) => void;
|
|
2404
|
+
readonly adversarialsimulator_enableChaosMode: (a: number, b: number) => void;
|
|
2405
|
+
readonly adversarialsimulator_generateChaosEvent: (a: number) => [number, number];
|
|
2406
|
+
readonly adversarialsimulator_getDefenceMetrics: (a: number) => [number, number];
|
|
2407
|
+
readonly adversarialsimulator_getRecommendations: (a: number) => [number, number];
|
|
2408
|
+
readonly adversarialsimulator_new: () => number;
|
|
2409
|
+
readonly adversarialsimulator_runSecurityAudit: (a: number) => [number, number];
|
|
2410
|
+
readonly adversarialsimulator_simulateByzantine: (a: number, b: number, c: number) => [number, number];
|
|
2411
|
+
readonly adversarialsimulator_simulateDDoS: (a: number, b: number, c: bigint) => [number, number];
|
|
2412
|
+
readonly adversarialsimulator_simulateDoubleSpend: (a: number, b: bigint, c: number) => [number, number];
|
|
2413
|
+
readonly adversarialsimulator_simulateFreeRiding: (a: number, b: number, c: number) => [number, number];
|
|
2414
|
+
readonly adversarialsimulator_simulateResultTampering: (a: number, b: number) => [number, number];
|
|
2415
|
+
readonly adversarialsimulator_simulateSybil: (a: number, b: number, c: number) => [number, number];
|
|
2416
|
+
readonly auditlog_exportEvents: (a: number) => [number, number];
|
|
2417
|
+
readonly auditlog_getEventsBySeverity: (a: number, b: number) => number;
|
|
2418
|
+
readonly auditlog_getEventsForNode: (a: number, b: number, c: number) => number;
|
|
2419
|
+
readonly auditlog_log: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number) => void;
|
|
2420
|
+
readonly auditlog_new: () => number;
|
|
2421
|
+
readonly browserfingerprint_generate: () => any;
|
|
2422
|
+
readonly byzantinedetector_getMaxMagnitude: (a: number) => number;
|
|
2423
|
+
readonly byzantinedetector_new: (a: number, b: number) => number;
|
|
2424
|
+
readonly coherenceengine_canUseClaim: (a: number, b: number, c: number) => number;
|
|
2425
|
+
readonly coherenceengine_conflictCount: (a: number) => number;
|
|
2426
|
+
readonly coherenceengine_eventCount: (a: number) => number;
|
|
2427
|
+
readonly coherenceengine_getDrift: (a: number, b: number, c: number) => number;
|
|
2428
|
+
readonly coherenceengine_getMerkleRoot: (a: number) => [number, number];
|
|
2429
|
+
readonly coherenceengine_getQuarantineLevel: (a: number, b: number, c: number) => number;
|
|
2430
|
+
readonly coherenceengine_getStats: (a: number) => [number, number];
|
|
2431
|
+
readonly coherenceengine_hasDrifted: (a: number, b: number, c: number) => number;
|
|
2432
|
+
readonly coherenceengine_hasSufficientWitnesses: (a: number, b: number, c: number) => number;
|
|
2433
|
+
readonly coherenceengine_new: () => number;
|
|
2434
|
+
readonly coherenceengine_quarantinedCount: (a: number) => number;
|
|
2435
|
+
readonly coherenceengine_witnessCount: (a: number, b: number, c: number) => number;
|
|
2436
|
+
readonly collectivememory_consolidate: (a: number) => number;
|
|
2437
|
+
readonly collectivememory_getStats: (a: number) => [number, number];
|
|
2438
|
+
readonly collectivememory_hasPattern: (a: number, b: number, c: number) => number;
|
|
2439
|
+
readonly collectivememory_new: (a: number, b: number) => number;
|
|
2440
|
+
readonly collectivememory_patternCount: (a: number) => number;
|
|
2441
|
+
readonly collectivememory_queueSize: (a: number) => number;
|
|
2442
|
+
readonly collectivememory_search: (a: number, b: number, c: number, d: number) => [number, number];
|
|
2443
|
+
readonly contributionstream_getTotalDistributed: (a: number) => bigint;
|
|
2444
|
+
readonly contributionstream_isHealthy: (a: number) => number;
|
|
2445
|
+
readonly contributionstream_new: () => number;
|
|
2446
|
+
readonly contributionstream_processFees: (a: number, b: bigint, c: bigint) => bigint;
|
|
2447
|
+
readonly differentialprivacy_getEpsilon: (a: number) => number;
|
|
2448
|
+
readonly differentialprivacy_isEnabled: (a: number) => number;
|
|
2449
|
+
readonly differentialprivacy_new: (a: number, b: number) => number;
|
|
2450
|
+
readonly differentialprivacy_setEnabled: (a: number, b: number) => void;
|
|
2451
|
+
readonly drifttracker_getDrift: (a: number, b: number, c: number) => number;
|
|
2452
|
+
readonly drifttracker_getDriftedContexts: (a: number) => [number, number];
|
|
2453
|
+
readonly drifttracker_hasDrifted: (a: number, b: number, c: number) => number;
|
|
2454
|
+
readonly drifttracker_new: (a: number) => number;
|
|
2455
|
+
readonly economicengine_advanceEpoch: (a: number) => void;
|
|
2456
|
+
readonly economicengine_getHealth: (a: number) => number;
|
|
2457
|
+
readonly economicengine_getProtocolFund: (a: number) => bigint;
|
|
2458
|
+
readonly economicengine_getTreasury: (a: number) => bigint;
|
|
2459
|
+
readonly economicengine_isSelfSustaining: (a: number, b: number, c: bigint) => number;
|
|
2460
|
+
readonly economicengine_new: () => number;
|
|
2461
|
+
readonly economicengine_processReward: (a: number, b: bigint, c: number) => number;
|
|
2462
|
+
readonly edgenetconfig_addRelay: (a: number, b: number, c: number) => number;
|
|
2463
|
+
readonly edgenetconfig_build: (a: number) => [number, number, number];
|
|
2464
|
+
readonly edgenetconfig_cpuLimit: (a: number, b: number) => number;
|
|
2465
|
+
readonly edgenetconfig_memoryLimit: (a: number, b: number) => number;
|
|
2466
|
+
readonly edgenetconfig_minIdleTime: (a: number, b: number) => number;
|
|
2467
|
+
readonly edgenetconfig_new: (a: number, b: number) => number;
|
|
2468
|
+
readonly edgenetconfig_respectBattery: (a: number, b: number) => number;
|
|
2469
|
+
readonly edgenetnode_canUseClaim: (a: number, b: number, c: number) => number;
|
|
2470
|
+
readonly edgenetnode_checkEvents: (a: number) => [number, number];
|
|
2471
|
+
readonly edgenetnode_creditBalance: (a: number) => bigint;
|
|
2472
|
+
readonly edgenetnode_disconnect: (a: number) => [number, number];
|
|
2473
|
+
readonly edgenetnode_enableBTSP: (a: number, b: number) => number;
|
|
2474
|
+
readonly edgenetnode_enableHDC: (a: number) => number;
|
|
2475
|
+
readonly edgenetnode_enableNAO: (a: number, b: number) => number;
|
|
2476
|
+
readonly edgenetnode_getCapabilities: (a: number) => any;
|
|
2477
|
+
readonly edgenetnode_getCapabilitiesSummary: (a: number) => any;
|
|
2478
|
+
readonly edgenetnode_getClaimQuarantineLevel: (a: number, b: number, c: number) => number;
|
|
2479
|
+
readonly edgenetnode_getCoherenceEventCount: (a: number) => number;
|
|
2480
|
+
readonly edgenetnode_getCoherenceStats: (a: number) => [number, number];
|
|
2481
|
+
readonly edgenetnode_getConflictCount: (a: number) => number;
|
|
2482
|
+
readonly edgenetnode_getEconomicHealth: (a: number) => [number, number];
|
|
2483
|
+
readonly edgenetnode_getEnergyEfficiency: (a: number, b: number, c: number) => number;
|
|
2484
|
+
readonly edgenetnode_getFounderCount: (a: number) => number;
|
|
2485
|
+
readonly edgenetnode_getLearningStats: (a: number) => [number, number];
|
|
2486
|
+
readonly edgenetnode_getMerkleRoot: (a: number) => [number, number];
|
|
2487
|
+
readonly edgenetnode_getMotivation: (a: number) => [number, number];
|
|
2488
|
+
readonly edgenetnode_getMultiplier: (a: number) => number;
|
|
2489
|
+
readonly edgenetnode_getNetworkFitness: (a: number) => number;
|
|
2490
|
+
readonly edgenetnode_getOptimalPeers: (a: number, b: number) => [number, number];
|
|
2491
|
+
readonly edgenetnode_getOptimizationStats: (a: number) => [number, number];
|
|
2492
|
+
readonly edgenetnode_getPatternCount: (a: number) => number;
|
|
2493
|
+
readonly edgenetnode_getProtocolFund: (a: number) => bigint;
|
|
2494
|
+
readonly edgenetnode_getQuarantinedCount: (a: number) => number;
|
|
2495
|
+
readonly edgenetnode_getRecommendedConfig: (a: number) => [number, number];
|
|
2496
|
+
readonly edgenetnode_getStats: (a: number) => number;
|
|
2497
|
+
readonly edgenetnode_getThemedStatus: (a: number, b: number) => [number, number];
|
|
2498
|
+
readonly edgenetnode_getThrottle: (a: number) => number;
|
|
2499
|
+
readonly edgenetnode_getTimeCrystalSync: (a: number) => number;
|
|
2500
|
+
readonly edgenetnode_getTrajectoryCount: (a: number) => number;
|
|
2501
|
+
readonly edgenetnode_getTreasury: (a: number) => bigint;
|
|
2502
|
+
readonly edgenetnode_isIdle: (a: number) => number;
|
|
2503
|
+
readonly edgenetnode_isSelfSustaining: (a: number, b: number, c: bigint) => number;
|
|
2504
|
+
readonly edgenetnode_isStreamHealthy: (a: number) => number;
|
|
2505
|
+
readonly edgenetnode_lookupPatterns: (a: number, b: number, c: number, d: number) => [number, number];
|
|
2506
|
+
readonly edgenetnode_new: (a: number, b: number, c: number) => [number, number, number];
|
|
2507
|
+
readonly edgenetnode_nodeId: (a: number) => [number, number];
|
|
2508
|
+
readonly edgenetnode_pause: (a: number) => void;
|
|
2509
|
+
readonly edgenetnode_processEpoch: (a: number) => void;
|
|
2510
|
+
readonly edgenetnode_processNextTask: (a: number) => any;
|
|
2511
|
+
readonly edgenetnode_proposeNAO: (a: number, b: number, c: number) => [number, number];
|
|
2512
|
+
readonly edgenetnode_prunePatterns: (a: number, b: number, c: number) => number;
|
|
2513
|
+
readonly edgenetnode_recordLearningTrajectory: (a: number, b: number, c: number) => number;
|
|
2514
|
+
readonly edgenetnode_recordPeerInteraction: (a: number, b: number, c: number, d: number) => void;
|
|
2515
|
+
readonly edgenetnode_recordPerformance: (a: number, b: number, c: number) => void;
|
|
2516
|
+
readonly edgenetnode_recordTaskRouting: (a: number, b: number, c: number, d: number, e: number, f: bigint, g: number) => void;
|
|
2517
|
+
readonly edgenetnode_resume: (a: number) => void;
|
|
2518
|
+
readonly edgenetnode_runSecurityAudit: (a: number) => [number, number];
|
|
2519
|
+
readonly edgenetnode_shouldReplicate: (a: number) => number;
|
|
2520
|
+
readonly edgenetnode_start: (a: number) => [number, number];
|
|
2521
|
+
readonly edgenetnode_stepCapabilities: (a: number, b: number) => void;
|
|
2522
|
+
readonly edgenetnode_storePattern: (a: number, b: number, c: number) => number;
|
|
2523
|
+
readonly edgenetnode_submitTask: (a: number, b: number, c: number, d: number, e: number, f: bigint) => any;
|
|
2524
|
+
readonly edgenetnode_voteNAO: (a: number, b: number, c: number, d: number) => number;
|
|
2525
|
+
readonly entropyconsensus_converged: (a: number) => number;
|
|
2526
|
+
readonly entropyconsensus_entropy: (a: number) => number;
|
|
2527
|
+
readonly entropyconsensus_finalize_beliefs: (a: number) => void;
|
|
2528
|
+
readonly entropyconsensus_getBelief: (a: number, b: bigint) => number;
|
|
2529
|
+
readonly entropyconsensus_getDecision: (a: number) => [number, bigint];
|
|
2530
|
+
readonly entropyconsensus_getEntropyHistory: (a: number) => [number, number];
|
|
2531
|
+
readonly entropyconsensus_getEntropyThreshold: (a: number) => number;
|
|
2532
|
+
readonly entropyconsensus_getRounds: (a: number) => number;
|
|
2533
|
+
readonly entropyconsensus_getStats: (a: number) => [number, number];
|
|
2534
|
+
readonly entropyconsensus_getTemperature: (a: number) => number;
|
|
2535
|
+
readonly entropyconsensus_hasTimedOut: (a: number) => number;
|
|
2536
|
+
readonly entropyconsensus_new: () => number;
|
|
2537
|
+
readonly entropyconsensus_optionCount: (a: number) => number;
|
|
2538
|
+
readonly entropyconsensus_reset: (a: number) => void;
|
|
2539
|
+
readonly entropyconsensus_setBelief: (a: number, b: bigint, c: number) => void;
|
|
2540
|
+
readonly entropyconsensus_set_belief_raw: (a: number, b: bigint, c: number) => void;
|
|
2541
|
+
readonly entropyconsensus_withThreshold: (a: number) => number;
|
|
2542
|
+
readonly eventlog_getRoot: (a: number) => [number, number];
|
|
2543
|
+
readonly eventlog_isEmpty: (a: number) => number;
|
|
2544
|
+
readonly eventlog_len: (a: number) => number;
|
|
2545
|
+
readonly eventlog_new: () => number;
|
|
2546
|
+
readonly evolutionengine_evolve: (a: number) => void;
|
|
2547
|
+
readonly evolutionengine_getNetworkFitness: (a: number) => number;
|
|
2548
|
+
readonly evolutionengine_getRecommendedConfig: (a: number) => [number, number];
|
|
2549
|
+
readonly evolutionengine_new: () => number;
|
|
2550
|
+
readonly evolutionengine_recordPerformance: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
2551
|
+
readonly evolutionengine_shouldReplicate: (a: number, b: number, c: number) => number;
|
|
2552
|
+
readonly federatedmodel_applyGradients: (a: number, b: number, c: number) => [number, number];
|
|
2553
|
+
readonly federatedmodel_getDimension: (a: number) => number;
|
|
2554
|
+
readonly federatedmodel_getParameters: (a: number) => [number, number];
|
|
2555
|
+
readonly federatedmodel_getRound: (a: number) => bigint;
|
|
2556
|
+
readonly federatedmodel_new: (a: number, b: number, c: number) => number;
|
|
2557
|
+
readonly federatedmodel_setLearningRate: (a: number, b: number) => void;
|
|
2558
|
+
readonly federatedmodel_setLocalEpochs: (a: number, b: number) => void;
|
|
2559
|
+
readonly federatedmodel_setParameters: (a: number, b: number, c: number) => [number, number];
|
|
2560
|
+
readonly foundingregistry_calculateVested: (a: number, b: bigint, c: bigint) => bigint;
|
|
2561
|
+
readonly foundingregistry_getFounderCount: (a: number) => number;
|
|
2562
|
+
readonly foundingregistry_new: () => number;
|
|
2563
|
+
readonly foundingregistry_processEpoch: (a: number, b: bigint, c: bigint) => [number, number];
|
|
2564
|
+
readonly foundingregistry_registerContributor: (a: number, b: number, c: number, d: number, e: number, f: number) => void;
|
|
2565
|
+
readonly genesiskey_create: (a: number, b: number) => [number, number, number];
|
|
2566
|
+
readonly genesiskey_exportUltraCompact: (a: number) => [number, number];
|
|
2567
|
+
readonly genesiskey_getEpoch: (a: number) => number;
|
|
2568
|
+
readonly genesiskey_getIdHex: (a: number) => [number, number];
|
|
2569
|
+
readonly genesiskey_verify: (a: number, b: number, c: number) => number;
|
|
2570
|
+
readonly genesissunset_canRetire: (a: number) => number;
|
|
2571
|
+
readonly genesissunset_getCurrentPhase: (a: number) => number;
|
|
2572
|
+
readonly genesissunset_getStatus: (a: number) => [number, number];
|
|
2573
|
+
readonly genesissunset_isReadOnly: (a: number) => number;
|
|
2574
|
+
readonly genesissunset_new: () => number;
|
|
2575
|
+
readonly genesissunset_registerGenesisNode: (a: number, b: number, c: number) => void;
|
|
2576
|
+
readonly genesissunset_shouldAcceptConnections: (a: number) => number;
|
|
2577
|
+
readonly genesissunset_updateNodeCount: (a: number, b: number) => number;
|
|
2578
|
+
readonly gradientgossip_advanceRound: (a: number) => bigint;
|
|
2579
|
+
readonly gradientgossip_configureDifferentialPrivacy: (a: number, b: number, c: number) => void;
|
|
2580
|
+
readonly gradientgossip_getAggregatedGradients: (a: number) => [number, number];
|
|
2581
|
+
readonly gradientgossip_getCompressionRatio: (a: number) => number;
|
|
2582
|
+
readonly gradientgossip_getCurrentRound: (a: number) => bigint;
|
|
2583
|
+
readonly gradientgossip_getDimension: (a: number) => number;
|
|
2584
|
+
readonly gradientgossip_getStats: (a: number) => [number, number];
|
|
2585
|
+
readonly gradientgossip_new: (a: number, b: number, c: number, d: number) => [number, number, number];
|
|
2586
|
+
readonly gradientgossip_peerCount: (a: number) => number;
|
|
2587
|
+
readonly gradientgossip_pruneStale: (a: number) => number;
|
|
2588
|
+
readonly gradientgossip_setDPEnabled: (a: number, b: number) => void;
|
|
2589
|
+
readonly gradientgossip_setLocalGradients: (a: number, b: number, c: number) => [number, number];
|
|
2590
|
+
readonly gradientgossip_setModelHash: (a: number, b: number, c: number) => [number, number];
|
|
2591
|
+
readonly init_panic_hook: () => void;
|
|
2592
|
+
readonly modelconsensusmanager_disputeCount: (a: number) => number;
|
|
2593
|
+
readonly modelconsensusmanager_getStats: (a: number) => [number, number];
|
|
2594
|
+
readonly modelconsensusmanager_modelCount: (a: number) => number;
|
|
2595
|
+
readonly modelconsensusmanager_new: (a: number) => number;
|
|
2596
|
+
readonly modelconsensusmanager_quarantinedUpdateCount: (a: number) => number;
|
|
2597
|
+
readonly multiheadattention_dim: (a: number) => number;
|
|
2598
|
+
readonly multiheadattention_new: (a: number, b: number) => number;
|
|
2599
|
+
readonly multiheadattention_numHeads: (a: number) => number;
|
|
2600
|
+
readonly networkevents_checkActiveEvents: (a: number) => [number, number];
|
|
2601
|
+
readonly networkevents_checkDiscovery: (a: number, b: number, c: number, d: number, e: number) => [number, number];
|
|
2602
|
+
readonly networkevents_checkMilestones: (a: number, b: bigint, c: number, d: number) => [number, number];
|
|
2603
|
+
readonly networkevents_getCelebrationBoost: (a: number) => number;
|
|
2604
|
+
readonly networkevents_getMotivation: (a: number, b: bigint) => [number, number];
|
|
2605
|
+
readonly networkevents_getSpecialArt: (a: number) => [number, number];
|
|
2606
|
+
readonly networkevents_getThemedStatus: (a: number, b: number, c: bigint) => [number, number];
|
|
2607
|
+
readonly networkevents_new: () => number;
|
|
2608
|
+
readonly networkevents_setCurrentTime: (a: number, b: bigint) => void;
|
|
2609
|
+
readonly networklearning_getEnergyRatio: (a: number, b: number, c: number) => number;
|
|
2610
|
+
readonly networklearning_getStats: (a: number) => [number, number];
|
|
2611
|
+
readonly networklearning_lookupPatterns: (a: number, b: number, c: number, d: number) => [number, number];
|
|
2612
|
+
readonly networklearning_new: () => number;
|
|
2613
|
+
readonly networklearning_patternCount: (a: number) => number;
|
|
2614
|
+
readonly networklearning_prune: (a: number, b: number, c: number) => number;
|
|
2615
|
+
readonly networklearning_recordTrajectory: (a: number, b: number, c: number) => number;
|
|
2616
|
+
readonly networklearning_storePattern: (a: number, b: number, c: number) => number;
|
|
2617
|
+
readonly networklearning_trajectoryCount: (a: number) => number;
|
|
2618
|
+
readonly networktopology_getOptimalPeers: (a: number, b: number, c: number, d: number) => [number, number];
|
|
2619
|
+
readonly networktopology_new: () => number;
|
|
2620
|
+
readonly networktopology_registerNode: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
2621
|
+
readonly networktopology_updateConnection: (a: number, b: number, c: number, d: number, e: number, f: number) => void;
|
|
2622
|
+
readonly optimizationengine_getStats: (a: number) => [number, number];
|
|
2623
|
+
readonly optimizationengine_new: () => number;
|
|
2624
|
+
readonly optimizationengine_recordRouting: (a: number, b: number, c: number, d: number, e: number, f: bigint, g: number) => void;
|
|
2625
|
+
readonly optimizationengine_selectOptimalNode: (a: number, b: number, c: number, d: number, e: number) => [number, number];
|
|
2626
|
+
readonly pikey_createEncryptedBackup: (a: number, b: number, c: number) => [number, number, number, number];
|
|
2627
|
+
readonly pikey_exportCompact: (a: number) => [number, number];
|
|
2628
|
+
readonly pikey_generate: (a: number, b: number) => [number, number, number];
|
|
2629
|
+
readonly pikey_getGenesisFingerprint: (a: number) => [number, number];
|
|
2630
|
+
readonly pikey_getIdentity: (a: number) => [number, number];
|
|
2631
|
+
readonly pikey_getIdentityHex: (a: number) => [number, number];
|
|
2632
|
+
readonly pikey_getPublicKey: (a: number) => [number, number];
|
|
2633
|
+
readonly pikey_getShortId: (a: number) => [number, number];
|
|
2634
|
+
readonly pikey_getStats: (a: number) => [number, number];
|
|
2635
|
+
readonly pikey_restoreFromBackup: (a: number, b: number, c: number, d: number) => [number, number, number];
|
|
2636
|
+
readonly pikey_sign: (a: number, b: number, c: number) => [number, number];
|
|
2637
|
+
readonly pikey_verify: (a: number, b: number, c: number, d: number, e: number, f: number, g: number) => number;
|
|
2638
|
+
readonly pikey_verifyPiMagic: (a: number) => number;
|
|
2639
|
+
readonly qdagledger_balance: (a: number, b: number, c: number) => bigint;
|
|
2640
|
+
readonly qdagledger_createGenesis: (a: number, b: bigint, c: number, d: number) => [number, number, number, number];
|
|
2641
|
+
readonly qdagledger_createTransaction: (a: number, b: number, c: number, d: number, e: number, f: bigint, g: number, h: number, i: number, j: number, k: number) => [number, number, number, number];
|
|
2642
|
+
readonly qdagledger_exportState: (a: number) => [number, number, number, number];
|
|
2643
|
+
readonly qdagledger_importState: (a: number, b: number, c: number) => [number, number, number];
|
|
2644
|
+
readonly qdagledger_new: () => number;
|
|
2645
|
+
readonly qdagledger_stakedAmount: (a: number, b: number, c: number) => bigint;
|
|
2646
|
+
readonly qdagledger_tipCount: (a: number) => number;
|
|
2647
|
+
readonly qdagledger_totalSupply: (a: number) => bigint;
|
|
2648
|
+
readonly qdagledger_transactionCount: (a: number) => number;
|
|
2649
|
+
readonly quarantinemanager_canUse: (a: number, b: number, c: number) => number;
|
|
2650
|
+
readonly quarantinemanager_getLevel: (a: number, b: number, c: number) => number;
|
|
2651
|
+
readonly quarantinemanager_new: () => number;
|
|
2652
|
+
readonly quarantinemanager_quarantinedCount: (a: number) => number;
|
|
2653
|
+
readonly quarantinemanager_setLevel: (a: number, b: number, c: number, d: number) => void;
|
|
2654
|
+
readonly raceconomicengine_canParticipate: (a: number, b: number, c: number) => number;
|
|
2655
|
+
readonly raceconomicengine_getCombinedScore: (a: number, b: number, c: number) => number;
|
|
2656
|
+
readonly raceconomicengine_getSummary: (a: number) => [number, number];
|
|
2657
|
+
readonly raceconomicengine_new: () => number;
|
|
2658
|
+
readonly racsemanticrouter_new: () => number;
|
|
2659
|
+
readonly racsemanticrouter_peerCount: (a: number) => number;
|
|
2660
|
+
readonly ratelimiter_checkAllowed: (a: number, b: number, c: number) => number;
|
|
2661
|
+
readonly ratelimiter_getCount: (a: number, b: number, c: number) => number;
|
|
2662
|
+
readonly ratelimiter_new: (a: bigint, b: number) => number;
|
|
2663
|
+
readonly ratelimiter_reset: (a: number) => void;
|
|
2664
|
+
readonly reasoningbank_count: (a: number) => number;
|
|
2665
|
+
readonly reasoningbank_getStats: (a: number) => [number, number];
|
|
2666
|
+
readonly reasoningbank_lookup: (a: number, b: number, c: number, d: number) => [number, number];
|
|
2667
|
+
readonly reasoningbank_new: () => number;
|
|
2668
|
+
readonly reasoningbank_prune: (a: number, b: number, c: number) => number;
|
|
2669
|
+
readonly reasoningbank_store: (a: number, b: number, c: number) => number;
|
|
2670
|
+
readonly reputationmanager_averageReputation: (a: number) => number;
|
|
2671
|
+
readonly reputationmanager_getReputation: (a: number, b: number, c: number) => number;
|
|
2672
|
+
readonly reputationmanager_hasSufficientReputation: (a: number, b: number, c: number) => number;
|
|
2673
|
+
readonly reputationmanager_new: (a: number, b: bigint) => number;
|
|
2674
|
+
readonly reputationmanager_nodeCount: (a: number) => number;
|
|
2675
|
+
readonly reputationsystem_canParticipate: (a: number, b: number, c: number) => number;
|
|
2676
|
+
readonly reputationsystem_getReputation: (a: number, b: number, c: number) => number;
|
|
2677
|
+
readonly reputationsystem_new: () => number;
|
|
2678
|
+
readonly reputationsystem_recordFailure: (a: number, b: number, c: number) => void;
|
|
2679
|
+
readonly reputationsystem_recordPenalty: (a: number, b: number, c: number, d: number) => void;
|
|
2680
|
+
readonly reputationsystem_recordSuccess: (a: number, b: number, c: number) => void;
|
|
2681
|
+
readonly rewardmanager_claimableAmount: (a: number, b: number, c: number) => bigint;
|
|
2682
|
+
readonly rewardmanager_new: (a: bigint) => number;
|
|
2683
|
+
readonly rewardmanager_pendingAmount: (a: number) => bigint;
|
|
2684
|
+
readonly rewardmanager_pendingCount: (a: number) => number;
|
|
2685
|
+
readonly semanticrouter_activePeerCount: (a: number) => number;
|
|
2686
|
+
readonly semanticrouter_getStats: (a: number) => [number, number];
|
|
2687
|
+
readonly semanticrouter_new: () => number;
|
|
2688
|
+
readonly semanticrouter_peerCount: (a: number) => number;
|
|
2689
|
+
readonly semanticrouter_setMyCapabilities: (a: number, b: number, c: number) => void;
|
|
2690
|
+
readonly semanticrouter_setMyPeerId: (a: number, b: number, c: number) => void;
|
|
2691
|
+
readonly semanticrouter_topicCount: (a: number) => number;
|
|
2692
|
+
readonly semanticrouter_withParams: (a: number, b: number, c: number) => number;
|
|
2693
|
+
readonly sessionkey_create: (a: number, b: number) => [number, number, number];
|
|
2694
|
+
readonly sessionkey_decrypt: (a: number, b: number, c: number) => [number, number, number, number];
|
|
2695
|
+
readonly sessionkey_encrypt: (a: number, b: number, c: number) => [number, number, number, number];
|
|
2696
|
+
readonly sessionkey_getId: (a: number) => [number, number];
|
|
2697
|
+
readonly sessionkey_getIdHex: (a: number) => [number, number];
|
|
2698
|
+
readonly sessionkey_getParentIdentity: (a: number) => [number, number];
|
|
2699
|
+
readonly sessionkey_isExpired: (a: number) => number;
|
|
2700
|
+
readonly spikedrivenattention_energyRatio: (a: number, b: number, c: number) => number;
|
|
2701
|
+
readonly spikedrivenattention_new: () => number;
|
|
2702
|
+
readonly spikedrivenattention_withConfig: (a: number, b: number, c: number) => number;
|
|
2703
|
+
readonly spotchecker_addChallenge: (a: number, b: number, c: number, d: number, e: number, f: number, g: number) => void;
|
|
2704
|
+
readonly spotchecker_getChallenge: (a: number, b: number, c: number) => [number, number];
|
|
2705
|
+
readonly spotchecker_new: (a: number) => number;
|
|
2706
|
+
readonly spotchecker_shouldCheck: (a: number) => number;
|
|
2707
|
+
readonly spotchecker_verifyResponse: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
2708
|
+
readonly stakemanager_getMinStake: (a: number) => bigint;
|
|
2709
|
+
readonly stakemanager_getStake: (a: number, b: number, c: number) => bigint;
|
|
2710
|
+
readonly stakemanager_hasSufficientStake: (a: number, b: number, c: number) => number;
|
|
2711
|
+
readonly stakemanager_new: (a: bigint) => number;
|
|
2712
|
+
readonly stakemanager_stakerCount: (a: number) => number;
|
|
2713
|
+
readonly stakemanager_totalStaked: (a: number) => bigint;
|
|
2714
|
+
readonly swarmintelligence_addPattern: (a: number, b: number, c: number) => number;
|
|
2715
|
+
readonly swarmintelligence_consolidate: (a: number) => number;
|
|
2716
|
+
readonly swarmintelligence_getConsensusDecision: (a: number, b: number, c: number) => [number, bigint];
|
|
2717
|
+
readonly swarmintelligence_getStats: (a: number) => [number, number];
|
|
2718
|
+
readonly swarmintelligence_hasConsensus: (a: number, b: number, c: number) => number;
|
|
2719
|
+
readonly swarmintelligence_negotiateBeliefs: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
2720
|
+
readonly swarmintelligence_new: (a: number, b: number) => number;
|
|
2721
|
+
readonly swarmintelligence_nodeId: (a: number) => [number, number];
|
|
2722
|
+
readonly swarmintelligence_patternCount: (a: number) => number;
|
|
2723
|
+
readonly swarmintelligence_queueSize: (a: number) => number;
|
|
2724
|
+
readonly swarmintelligence_replay: (a: number) => number;
|
|
2725
|
+
readonly swarmintelligence_searchPatterns: (a: number, b: number, c: number, d: number) => [number, number];
|
|
2726
|
+
readonly swarmintelligence_setBelief: (a: number, b: number, c: number, d: bigint, e: number) => void;
|
|
2727
|
+
readonly swarmintelligence_startConsensus: (a: number, b: number, c: number, d: number) => void;
|
|
2728
|
+
readonly sybildefense_getSybilScore: (a: number, b: number, c: number) => number;
|
|
2729
|
+
readonly sybildefense_isSuspectedSybil: (a: number, b: number, c: number) => number;
|
|
2730
|
+
readonly sybildefense_new: () => number;
|
|
2731
|
+
readonly sybildefense_registerNode: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
2732
|
+
readonly topksparsifier_getCompressionRatio: (a: number) => number;
|
|
2733
|
+
readonly topksparsifier_getErrorBufferSize: (a: number) => number;
|
|
2734
|
+
readonly topksparsifier_new: (a: number) => number;
|
|
2735
|
+
readonly topksparsifier_resetErrorFeedback: (a: number) => void;
|
|
2736
|
+
readonly trajectorytracker_count: (a: number) => number;
|
|
2737
|
+
readonly trajectorytracker_getStats: (a: number) => [number, number];
|
|
2738
|
+
readonly trajectorytracker_new: (a: number) => number;
|
|
2739
|
+
readonly trajectorytracker_record: (a: number, b: number, c: number) => number;
|
|
2740
|
+
readonly wasmadapterpool_adapterCount: (a: number) => number;
|
|
2741
|
+
readonly wasmadapterpool_exportAdapter: (a: number, b: number, c: number) => [number, number];
|
|
2742
|
+
readonly wasmadapterpool_forward: (a: number, b: number, c: number, d: number, e: number) => [number, number];
|
|
2743
|
+
readonly wasmadapterpool_getAdapter: (a: number, b: number, c: number) => any;
|
|
2744
|
+
readonly wasmadapterpool_getStats: (a: number) => any;
|
|
2745
|
+
readonly wasmadapterpool_importAdapter: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
2746
|
+
readonly wasmadapterpool_new: (a: number, b: number) => number;
|
|
2747
|
+
readonly wasmadapterpool_routeToAdapter: (a: number, b: number, c: number) => any;
|
|
2748
|
+
readonly wasmcapabilities_adaptMicroLoRA: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
2749
|
+
readonly wasmcapabilities_addNAOMember: (a: number, b: number, c: number, d: bigint) => number;
|
|
2750
|
+
readonly wasmcapabilities_applyMicroLoRA: (a: number, b: number, c: number, d: number, e: number) => [number, number];
|
|
2751
|
+
readonly wasmcapabilities_broadcastToWorkspace: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
2752
|
+
readonly wasmcapabilities_competeWTA: (a: number, b: number, c: number) => number;
|
|
2753
|
+
readonly wasmcapabilities_differentiateMorphogenetic: (a: number) => void;
|
|
2754
|
+
readonly wasmcapabilities_enableBTSP: (a: number, b: number, c: number) => number;
|
|
2755
|
+
readonly wasmcapabilities_enableGlobalWorkspace: (a: number, b: number) => number;
|
|
2756
|
+
readonly wasmcapabilities_enableHDC: (a: number) => number;
|
|
2757
|
+
readonly wasmcapabilities_enableMicroLoRA: (a: number, b: number, c: number) => number;
|
|
2758
|
+
readonly wasmcapabilities_enableNAO: (a: number, b: number) => number;
|
|
2759
|
+
readonly wasmcapabilities_enableWTA: (a: number, b: number, c: number, d: number) => number;
|
|
2760
|
+
readonly wasmcapabilities_executeNAO: (a: number, b: number, c: number) => number;
|
|
2761
|
+
readonly wasmcapabilities_forwardBTSP: (a: number, b: number, c: number) => number;
|
|
2762
|
+
readonly wasmcapabilities_getCapabilities: (a: number) => any;
|
|
2763
|
+
readonly wasmcapabilities_getMorphogeneticCellCount: (a: number) => number;
|
|
2764
|
+
readonly wasmcapabilities_getMorphogeneticStats: (a: number) => any;
|
|
2765
|
+
readonly wasmcapabilities_getNAOSync: (a: number) => number;
|
|
2766
|
+
readonly wasmcapabilities_getSummary: (a: number) => any;
|
|
2767
|
+
readonly wasmcapabilities_growMorphogenetic: (a: number, b: number) => void;
|
|
2768
|
+
readonly wasmcapabilities_new: (a: number, b: number) => number;
|
|
2769
|
+
readonly wasmcapabilities_oneShotAssociate: (a: number, b: number, c: number, d: number) => number;
|
|
2770
|
+
readonly wasmcapabilities_proposeNAO: (a: number, b: number, c: number) => [number, number];
|
|
2771
|
+
readonly wasmcapabilities_retrieveHDC: (a: number, b: number, c: number, d: number) => any;
|
|
2772
|
+
readonly wasmcapabilities_tickTimeCrystal: (a: number) => any;
|
|
2773
|
+
readonly wasmcapabilities_voteNAO: (a: number, b: number, c: number, d: number) => number;
|
|
2774
|
+
readonly wasmcreditledger_balance: (a: number) => bigint;
|
|
2775
|
+
readonly wasmcreditledger_credit: (a: number, b: bigint, c: number, d: number) => [number, number];
|
|
2776
|
+
readonly wasmcreditledger_currentMultiplier: (a: number) => number;
|
|
2777
|
+
readonly wasmcreditledger_deduct: (a: number, b: bigint) => [number, number];
|
|
2778
|
+
readonly wasmcreditledger_exportEarned: (a: number) => [number, number, number, number];
|
|
2779
|
+
readonly wasmcreditledger_exportSpent: (a: number) => [number, number, number, number];
|
|
2780
|
+
readonly wasmcreditledger_merge: (a: number, b: number, c: number, d: number, e: number) => [number, number];
|
|
2781
|
+
readonly wasmcreditledger_networkCompute: (a: number) => number;
|
|
2782
|
+
readonly wasmcreditledger_new: (a: number, b: number) => [number, number, number];
|
|
2783
|
+
readonly wasmcreditledger_slash: (a: number, b: bigint) => [bigint, number, number];
|
|
2784
|
+
readonly wasmcreditledger_stake: (a: number, b: bigint) => [number, number];
|
|
2785
|
+
readonly wasmcreditledger_stakedAmount: (a: number) => bigint;
|
|
2786
|
+
readonly wasmcreditledger_totalEarned: (a: number) => bigint;
|
|
2787
|
+
readonly wasmcreditledger_totalSpent: (a: number) => bigint;
|
|
2788
|
+
readonly wasmcreditledger_unstake: (a: number, b: bigint) => [number, number];
|
|
2789
|
+
readonly wasmcreditledger_updateNetworkCompute: (a: number, b: number) => void;
|
|
2790
|
+
readonly wasmidledetector_getStatus: (a: number) => any;
|
|
2791
|
+
readonly wasmidledetector_getThrottle: (a: number) => number;
|
|
2792
|
+
readonly wasmidledetector_isIdle: (a: number) => number;
|
|
2793
|
+
readonly wasmidledetector_new: (a: number, b: number) => [number, number, number];
|
|
2794
|
+
readonly wasmidledetector_pause: (a: number) => void;
|
|
2795
|
+
readonly wasmidledetector_recordInteraction: (a: number) => void;
|
|
2796
|
+
readonly wasmidledetector_resume: (a: number) => void;
|
|
2797
|
+
readonly wasmidledetector_setBatteryStatus: (a: number, b: number) => void;
|
|
2798
|
+
readonly wasmidledetector_shouldWork: (a: number) => number;
|
|
2799
|
+
readonly wasmidledetector_start: (a: number) => [number, number];
|
|
2800
|
+
readonly wasmidledetector_stop: (a: number) => void;
|
|
2801
|
+
readonly wasmidledetector_updateFps: (a: number, b: number) => void;
|
|
2802
|
+
readonly wasmmcpbroadcast_close: (a: number) => void;
|
|
2803
|
+
readonly wasmmcpbroadcast_listen: (a: number) => [number, number];
|
|
2804
|
+
readonly wasmmcpbroadcast_new: (a: number, b: number) => [number, number, number];
|
|
2805
|
+
readonly wasmmcpbroadcast_send: (a: number, b: number, c: number) => [number, number];
|
|
2806
|
+
readonly wasmmcpbroadcast_setServer: (a: number, b: number) => void;
|
|
2807
|
+
readonly wasmmcpserver_getServerInfo: (a: number) => any;
|
|
2808
|
+
readonly wasmmcpserver_handleRequest: (a: number, b: number, c: number) => any;
|
|
2809
|
+
readonly wasmmcpserver_handleRequestJs: (a: number, b: any) => any;
|
|
2810
|
+
readonly wasmmcpserver_initLearning: (a: number) => [number, number];
|
|
2811
|
+
readonly wasmmcpserver_new: () => [number, number, number];
|
|
2812
|
+
readonly wasmmcpserver_setIdentity: (a: number, b: number) => void;
|
|
2813
|
+
readonly wasmmcpserver_withConfig: (a: any) => [number, number, number];
|
|
2814
|
+
readonly wasmmcptransport_close: (a: number) => void;
|
|
2815
|
+
readonly wasmmcptransport_fromPort: (a: any) => number;
|
|
2816
|
+
readonly wasmmcptransport_init: (a: number) => [number, number];
|
|
2817
|
+
readonly wasmmcptransport_new: (a: any) => [number, number, number];
|
|
2818
|
+
readonly wasmmcptransport_send: (a: number, b: any) => any;
|
|
2819
|
+
readonly wasmmcpworkerhandler_new: (a: number) => number;
|
|
2820
|
+
readonly wasmmcpworkerhandler_start: (a: number) => [number, number];
|
|
2821
|
+
readonly wasmnetworkmanager_activePeerCount: (a: number) => number;
|
|
2822
|
+
readonly wasmnetworkmanager_addRelay: (a: number, b: number, c: number) => void;
|
|
2823
|
+
readonly wasmnetworkmanager_getPeersWithCapability: (a: number, b: number, c: number) => [number, number];
|
|
2824
|
+
readonly wasmnetworkmanager_isConnected: (a: number) => number;
|
|
2825
|
+
readonly wasmnetworkmanager_new: (a: number, b: number) => number;
|
|
2826
|
+
readonly wasmnetworkmanager_peerCount: (a: number) => number;
|
|
2827
|
+
readonly wasmnetworkmanager_registerPeer: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: bigint) => void;
|
|
2828
|
+
readonly wasmnetworkmanager_selectWorkers: (a: number, b: number, c: number, d: number) => [number, number];
|
|
2829
|
+
readonly wasmnetworkmanager_updateReputation: (a: number, b: number, c: number, d: number) => void;
|
|
2830
|
+
readonly wasmnodeidentity_exportSecretKey: (a: number, b: number, c: number) => [number, number, number, number];
|
|
2831
|
+
readonly wasmnodeidentity_fromSecretKey: (a: number, b: number, c: number, d: number) => [number, number, number];
|
|
2832
|
+
readonly wasmnodeidentity_generate: (a: number, b: number) => [number, number, number];
|
|
2833
|
+
readonly wasmnodeidentity_getFingerprint: (a: number) => [number, number];
|
|
2834
|
+
readonly wasmnodeidentity_importSecretKey: (a: number, b: number, c: number, d: number, e: number, f: number) => [number, number, number];
|
|
2835
|
+
readonly wasmnodeidentity_nodeId: (a: number) => [number, number];
|
|
2836
|
+
readonly wasmnodeidentity_publicKeyBytes: (a: number) => [number, number];
|
|
2837
|
+
readonly wasmnodeidentity_publicKeyHex: (a: number) => [number, number];
|
|
2838
|
+
readonly wasmnodeidentity_setFingerprint: (a: number, b: number, c: number) => void;
|
|
2839
|
+
readonly wasmnodeidentity_sign: (a: number, b: number, c: number) => [number, number];
|
|
2840
|
+
readonly wasmnodeidentity_siteId: (a: number) => [number, number];
|
|
2841
|
+
readonly wasmnodeidentity_verify: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
2842
|
+
readonly wasmnodeidentity_verifyFrom: (a: number, b: number, c: number, d: number, e: number, f: number) => number;
|
|
2843
|
+
readonly wasmstigmergy_deposit: (a: number, b: number, c: number, d: number, e: number, f: number, g: bigint) => void;
|
|
2844
|
+
readonly wasmstigmergy_depositWithOutcome: (a: number, b: number, c: number, d: number, e: number, f: number, g: bigint) => void;
|
|
2845
|
+
readonly wasmstigmergy_evaporate: (a: number) => void;
|
|
2846
|
+
readonly wasmstigmergy_exportState: (a: number) => [number, number];
|
|
2847
|
+
readonly wasmstigmergy_follow: (a: number, b: number, c: number) => number;
|
|
2848
|
+
readonly wasmstigmergy_getBestSpecialization: (a: number) => [number, number];
|
|
2849
|
+
readonly wasmstigmergy_getIntensity: (a: number, b: number, c: number) => number;
|
|
2850
|
+
readonly wasmstigmergy_getRankedTasks: (a: number) => [number, number];
|
|
2851
|
+
readonly wasmstigmergy_getSpecialization: (a: number, b: number, c: number) => number;
|
|
2852
|
+
readonly wasmstigmergy_getStats: (a: number) => [number, number];
|
|
2853
|
+
readonly wasmstigmergy_getSuccessRate: (a: number, b: number, c: number) => number;
|
|
2854
|
+
readonly wasmstigmergy_maybeEvaporate: (a: number) => number;
|
|
2855
|
+
readonly wasmstigmergy_merge: (a: number, b: number, c: number) => number;
|
|
2856
|
+
readonly wasmstigmergy_new: () => number;
|
|
2857
|
+
readonly wasmstigmergy_setMinStake: (a: number, b: bigint) => void;
|
|
2858
|
+
readonly wasmstigmergy_shouldAccept: (a: number, b: number, c: number) => number;
|
|
2859
|
+
readonly wasmstigmergy_updateSpecialization: (a: number, b: number, c: number, d: number) => void;
|
|
2860
|
+
readonly wasmstigmergy_withParams: (a: number, b: number, c: number) => number;
|
|
2861
|
+
readonly wasmtaskexecutor_new: (a: number) => [number, number, number];
|
|
2862
|
+
readonly wasmtaskexecutor_setTaskKey: (a: number, b: number, c: number) => [number, number];
|
|
2863
|
+
readonly wasmworkscheduler_new: () => number;
|
|
2864
|
+
readonly wasmworkscheduler_recordTaskDuration: (a: number, b: number) => void;
|
|
2865
|
+
readonly wasmworkscheduler_setPendingTasks: (a: number, b: number) => void;
|
|
2866
|
+
readonly wasmworkscheduler_tasksThisFrame: (a: number, b: number) => number;
|
|
2867
|
+
readonly witnesstracker_hasSufficientWitnesses: (a: number, b: number, c: number) => number;
|
|
2868
|
+
readonly witnesstracker_new: (a: number) => number;
|
|
2869
|
+
readonly witnesstracker_witnessConfidence: (a: number, b: number, c: number) => number;
|
|
2870
|
+
readonly witnesstracker_witnessCount: (a: number, b: number, c: number) => number;
|
|
2871
|
+
readonly wasmcapabilities_getTimeCrystalSync: (a: number) => number;
|
|
2872
|
+
readonly __wbg_set_nodeconfig_cpu_limit: (a: number, b: number) => void;
|
|
2873
|
+
readonly __wbg_set_rewarddistribution_contributor_share: (a: number, b: bigint) => void;
|
|
2874
|
+
readonly __wbg_set_rewarddistribution_founder_share: (a: number, b: bigint) => void;
|
|
2875
|
+
readonly __wbg_set_rewarddistribution_protocol_share: (a: number, b: bigint) => void;
|
|
2876
|
+
readonly __wbg_set_rewarddistribution_total: (a: number, b: bigint) => void;
|
|
2877
|
+
readonly __wbg_set_rewarddistribution_treasury_share: (a: number, b: bigint) => void;
|
|
2878
|
+
readonly genesissunset_isSelfSustaining: (a: number) => number;
|
|
2879
|
+
readonly edgenetnode_ruvBalance: (a: number) => bigint;
|
|
2880
|
+
readonly eventlog_totalEvents: (a: number) => number;
|
|
2881
|
+
readonly edgenetnode_enableGlobalWorkspace: (a: number, b: number) => number;
|
|
2882
|
+
readonly edgenetnode_enableMicroLoRA: (a: number, b: number) => number;
|
|
2883
|
+
readonly edgenetnode_enableMorphogenetic: (a: number, b: number) => number;
|
|
2884
|
+
readonly edgenetnode_enableTimeCrystal: (a: number, b: number) => number;
|
|
2885
|
+
readonly edgenetnode_enableWTA: (a: number, b: number) => number;
|
|
2886
|
+
readonly wasmcapabilities_pruneMorphogenetic: (a: number, b: number) => void;
|
|
2887
|
+
readonly wasmcapabilities_step: (a: number, b: number) => void;
|
|
2888
|
+
readonly wasmcapabilities_tickNAO: (a: number, b: number) => void;
|
|
2889
|
+
readonly wasmcapabilities_getWorkspaceContents: (a: number) => any;
|
|
2890
|
+
readonly wasmcapabilities_isTimeCrystalStable: (a: number) => number;
|
|
2891
|
+
readonly wasmcapabilities_storeHDC: (a: number, b: number, c: number) => number;
|
|
2892
|
+
readonly wasmcapabilities_enableMorphogenetic: (a: number, b: number, c: number) => number;
|
|
2893
|
+
readonly wasmcapabilities_enableTimeCrystal: (a: number, b: number, c: number) => number;
|
|
2894
|
+
readonly __wbg_get_nodeconfig_cpu_limit: (a: number) => number;
|
|
2895
|
+
readonly __wbg_get_rewarddistribution_contributor_share: (a: number) => bigint;
|
|
2896
|
+
readonly __wbg_get_rewarddistribution_founder_share: (a: number) => bigint;
|
|
2897
|
+
readonly __wbg_get_rewarddistribution_protocol_share: (a: number) => bigint;
|
|
2898
|
+
readonly __wbg_get_rewarddistribution_total: (a: number) => bigint;
|
|
2899
|
+
readonly __wbg_get_rewarddistribution_treasury_share: (a: number) => bigint;
|
|
2900
|
+
readonly __wbg_wasmworkscheduler_free: (a: number, b: number) => void;
|
|
2901
|
+
readonly __wbg_multiheadattention_free: (a: number, b: number) => void;
|
|
2902
|
+
readonly genesiskey_getId: (a: number) => [number, number];
|
|
2903
|
+
readonly wasm_bindgen__convert__closures_____invoke__h8c81ca6cba4eba00: (a: number, b: number, c: any) => void;
|
|
2904
|
+
readonly wasm_bindgen__closure__destroy__h16844f6554aa4052: (a: number, b: number) => void;
|
|
2905
|
+
readonly wasm_bindgen__convert__closures_____invoke__h9a454594a18d3e6f: (a: number, b: number, c: any) => void;
|
|
2906
|
+
readonly wasm_bindgen__closure__destroy__h5a0fd3a052925ed0: (a: number, b: number) => void;
|
|
2907
|
+
readonly wasm_bindgen__convert__closures_____invoke__h094c87b54a975e5a: (a: number, b: number, c: any, d: any) => void;
|
|
2908
|
+
readonly __wbindgen_malloc: (a: number, b: number) => number;
|
|
2909
|
+
readonly __wbindgen_realloc: (a: number, b: number, c: number, d: number) => number;
|
|
2910
|
+
readonly __wbindgen_exn_store: (a: number) => void;
|
|
2911
|
+
readonly __externref_table_alloc: () => number;
|
|
2912
|
+
readonly __wbindgen_externrefs: WebAssembly.Table;
|
|
2913
|
+
readonly __wbindgen_free: (a: number, b: number, c: number) => void;
|
|
2914
|
+
readonly __externref_table_dealloc: (a: number) => void;
|
|
2915
|
+
readonly __externref_drop_slice: (a: number, b: number) => void;
|
|
2916
|
+
readonly __wbindgen_start: () => void;
|
|
2917
|
+
}
|
|
2918
|
+
|
|
2919
|
+
export type SyncInitInput = BufferSource | WebAssembly.Module;
|
|
2920
|
+
|
|
2921
|
+
/**
|
|
2922
|
+
* Instantiates the given `module`, which can either be bytes or
|
|
2923
|
+
* a precompiled `WebAssembly.Module`.
|
|
2924
|
+
*
|
|
2925
|
+
* @param {{ module: SyncInitInput }} module - Passing `SyncInitInput` directly is deprecated.
|
|
2926
|
+
*
|
|
2927
|
+
* @returns {InitOutput}
|
|
2928
|
+
*/
|
|
2929
|
+
export function initSync(module: { module: SyncInitInput } | SyncInitInput): InitOutput;
|
|
2930
|
+
|
|
2931
|
+
/**
|
|
2932
|
+
* If `module_or_path` is {RequestInfo} or {URL}, makes a request and
|
|
2933
|
+
* for everything else, calls `WebAssembly.instantiate` directly.
|
|
2934
|
+
*
|
|
2935
|
+
* @param {{ module_or_path: InitInput | Promise<InitInput> }} module_or_path - Passing `InitInput` directly is deprecated.
|
|
2936
|
+
*
|
|
2937
|
+
* @returns {Promise<InitOutput>}
|
|
2938
|
+
*/
|
|
2939
|
+
export default function __wbg_init (module_or_path?: { module_or_path: InitInput | Promise<InitInput> } | InitInput | Promise<InitInput>): Promise<InitOutput>;
|