@nekzus/liop 2.6.1 → 2.7.1

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.
Files changed (109) hide show
  1. package/README.md +85 -38
  2. package/dist/bin/agent.js +27 -894
  3. package/dist/bridge.d.ts +4 -3
  4. package/dist/bridge.js +1 -4
  5. package/dist/chunk-2XHSALII.js +3 -0
  6. package/dist/chunk-2ZYX736J.js +2 -0
  7. package/dist/chunk-3WRKTVOF.js +2 -0
  8. package/dist/chunk-6KFKO6ZX.js +2 -0
  9. package/dist/chunk-6VK2XALI.js +2 -0
  10. package/dist/chunk-AYDF3IFZ.js +2 -0
  11. package/dist/chunk-CTTTLCGL.js +31 -0
  12. package/dist/chunk-ECRS6N33.js +4 -0
  13. package/dist/chunk-FDJMH4CB.js +2 -0
  14. package/dist/chunk-FTF6AMF6.js +0 -1
  15. package/dist/chunk-GWVSCZUS.js +2 -0
  16. package/dist/chunk-LEXMMIQI.js +15 -0
  17. package/dist/chunk-LM26HOJ6.js +31 -0
  18. package/dist/chunk-MQ5SU26J.js +2 -0
  19. package/dist/chunk-N35BC62H.js +2 -0
  20. package/dist/chunk-P6IJ3VBD.js +3 -0
  21. package/dist/chunk-TKLRW52V.js +2 -0
  22. package/dist/chunk-V35CXJQN.js +2 -0
  23. package/dist/chunk-WP5ER7RH.js +3 -0
  24. package/dist/chunk-XLVEDKM6.js +2 -0
  25. package/dist/chunk-Y675R34Z.js +2 -0
  26. package/dist/chunk-YD2AF2M6.js +46 -0
  27. package/dist/chunk-YLCNV764.js +3 -0
  28. package/dist/chunk-ZZMSFCJP.js +3 -0
  29. package/dist/client.d.ts +5 -4
  30. package/dist/client.js +1 -11
  31. package/dist/gateway.d.ts +6 -5
  32. package/dist/gateway.js +1 -11
  33. package/dist/{hybrid-DWe1bMoV.d.ts → hybrid-BZpCiUaV.d.ts} +4 -4
  34. package/dist/{index-BuEQtBHD.d.ts → index-BYDtRGue.d.ts} +8 -4
  35. package/dist/{index-CdW8j8Bn.d.ts → index-ByzjpRCk.d.ts} +30 -2
  36. package/dist/index.d.ts +57 -10
  37. package/dist/index.js +4 -317
  38. package/dist/kyber-PULV7PQX.js +2 -0
  39. package/dist/mesh.d.ts +1 -1
  40. package/dist/mesh.js +1 -5
  41. package/dist/{node-B0b2vUFS.d.ts → node-Djzm6UYd.d.ts} +8 -0
  42. package/dist/protocol/liop_core.proto +22 -6
  43. package/dist/server.d.ts +4 -3
  44. package/dist/server.js +1 -8
  45. package/dist/{types-CzRSOlOo.d.ts → types-29zv9X1V.d.ts} +3 -0
  46. package/dist/types.d.ts +2 -1
  47. package/dist/types.js +1 -2
  48. package/dist/verifier-DqZ9MQ9l.d.ts +82 -0
  49. package/dist/verifier-J4NQYZX5.js +2 -0
  50. package/dist/workers/logic-execution.d.ts +7 -0
  51. package/dist/workers/logic-execution.js +1 -271
  52. package/dist/workers/zk-verifier.d.ts +9 -0
  53. package/dist/workers/zk-verifier.js +1 -173
  54. package/dist/zk-DzYNWBgo.d.ts +104 -0
  55. package/package.json +7 -2
  56. package/dist/bin/agent.js.map +0 -1
  57. package/dist/bridge.js.map +0 -1
  58. package/dist/chunk-2KSO3W4A.js +0 -77
  59. package/dist/chunk-2KSO3W4A.js.map +0 -1
  60. package/dist/chunk-2STZHJ24.js +0 -114
  61. package/dist/chunk-2STZHJ24.js.map +0 -1
  62. package/dist/chunk-3QH44NKZ.js +0 -115
  63. package/dist/chunk-3QH44NKZ.js.map +0 -1
  64. package/dist/chunk-5SWHE62F.js +0 -3683
  65. package/dist/chunk-5SWHE62F.js.map +0 -1
  66. package/dist/chunk-7BSCUYUE.js +0 -421
  67. package/dist/chunk-7BSCUYUE.js.map +0 -1
  68. package/dist/chunk-7PITYWOV.js +0 -68
  69. package/dist/chunk-7PITYWOV.js.map +0 -1
  70. package/dist/chunk-EJ426URA.js +0 -818
  71. package/dist/chunk-EJ426URA.js.map +0 -1
  72. package/dist/chunk-FCFTYOAS.js +0 -793
  73. package/dist/chunk-FCFTYOAS.js.map +0 -1
  74. package/dist/chunk-FTF6AMF6.js.map +0 -1
  75. package/dist/chunk-IK7CGWAZ.js +0 -24
  76. package/dist/chunk-IK7CGWAZ.js.map +0 -1
  77. package/dist/chunk-K3DGJLUY.js +0 -106
  78. package/dist/chunk-K3DGJLUY.js.map +0 -1
  79. package/dist/chunk-PAICJCKJ.js +0 -332
  80. package/dist/chunk-PAICJCKJ.js.map +0 -1
  81. package/dist/chunk-PUDETPL4.js +0 -279
  82. package/dist/chunk-PUDETPL4.js.map +0 -1
  83. package/dist/chunk-UJFWPRDM.js +0 -206884
  84. package/dist/chunk-UJFWPRDM.js.map +0 -1
  85. package/dist/chunk-VRB5HUYU.js +0 -1492
  86. package/dist/chunk-VRB5HUYU.js.map +0 -1
  87. package/dist/chunk-VRDZ5IKE.js +0 -558
  88. package/dist/chunk-VRDZ5IKE.js.map +0 -1
  89. package/dist/chunk-WPTOJYN5.js +0 -181
  90. package/dist/chunk-WPTOJYN5.js.map +0 -1
  91. package/dist/chunk-XRDN232O.js +0 -877
  92. package/dist/chunk-XRDN232O.js.map +0 -1
  93. package/dist/chunk-Y62GORQF.js +0 -51
  94. package/dist/chunk-Y62GORQF.js.map +0 -1
  95. package/dist/chunk-ZP3VVXOI.js +0 -66
  96. package/dist/chunk-ZP3VVXOI.js.map +0 -1
  97. package/dist/client.js.map +0 -1
  98. package/dist/gateway.js.map +0 -1
  99. package/dist/index.js.map +0 -1
  100. package/dist/kyber-CGOA7Q6A.js +0 -3
  101. package/dist/kyber-CGOA7Q6A.js.map +0 -1
  102. package/dist/mesh.js.map +0 -1
  103. package/dist/server.js.map +0 -1
  104. package/dist/types.js.map +0 -1
  105. package/dist/verifier-COnid_dg.d.ts +0 -31
  106. package/dist/verifier-XFU7ZB2W.js +0 -6
  107. package/dist/verifier-XFU7ZB2W.js.map +0 -1
  108. package/dist/workers/logic-execution.js.map +0 -1
  109. package/dist/workers/zk-verifier.js.map +0 -1
package/README.md CHANGED
@@ -4,7 +4,7 @@
4
4
  <img alt="Logic-Injection-on-Origin Protocol Logo" src="https://raw.githubusercontent.com/Nekzus/LIOP/main/docs/logo/light.svg" width="700">
5
5
  </picture>
6
6
 
7
- <h1>Logic-Injection-on-Origin Protocol (LIOP) — TypeScript SDK</h1>
7
+ <h1>Logic-Injection-on-Origin Protocol (LIOP), TypeScript SDK</h1>
8
8
  <p><strong>The official TypeScript SDK and MCP Bridge for the Logic-Injection-on-Origin Protocol.</strong></p>
9
9
 
10
10
  <p align="center">
@@ -19,7 +19,7 @@
19
19
 
20
20
  ---
21
21
 
22
- ## 📚 Official Documentation
22
+ ## Official Documentation
23
23
 
24
24
  Comprehensive interactive guides, architectural deep dives, and API specifications are hosted on our official portal:
25
25
 
@@ -37,7 +37,7 @@ Comprehensive interactive guides, architectural deep dives, and API specificatio
37
37
 
38
38
  ## Overview
39
39
 
40
- `@nekzus/liop` is an SDK that implements the **Logic-Injection-on-Origin (LIO)** paradigm: instead of extracting raw data from a server and sending it to an LLM, the LLM injects a micro-module of logic to be executed *at the data source*, inside a secure sandbox. The result — never the raw data — is returned.
40
+ `@nekzus/liop` is an SDK that implements the **Logic-Injection-on-Origin (LIO)** paradigm: instead of extracting raw data from a server and sending it to an LLM, the LLM injects a micro-module of logic to be executed *at the data source*, inside a secure sandbox. The result, and never the raw data, is returned.
41
41
 
42
42
  This addresses the data privacy, bandwidth, and latency bottlenecks of distributed agent data analysis.
43
43
 
@@ -53,7 +53,7 @@ This addresses the data privacy, bandwidth, and latency bottlenecks of distribut
53
53
  | **Multi-Tier Sovereign Enclaves** | Physical socket isolation via `@libp2p/pnet` (256-bit Swarm Key PSK) and Border LIO Gateway (`blg`) with OAuth 2.1 authentication. |
54
54
  | **AST Fuel Metering** | Deterministic AST instruction fuel scoring with 100-bucket quantization for NIST SP 800-53 timing side-channel elimination (`stddev = 0`).|
55
55
  | **Differential Privacy Engine** | NIST SP 800-226 Laplace mechanism with CSPRNG entropy, query-aware sensitivity, and deterministic ZK-Receipt auditing (`DpEngine`). |
56
- | **MCP Drop-in Replacement** | `LiopServer` mirrors the Anthropic MCP `Server` API — tools, resources, and prompts with `Zod` schemas. |
56
+ | **MCP Drop-in Replacement** | `LiopServer` mirrors the Anthropic MCP `Server` API (tools, resources, and prompts with `Zod` schemas). |
57
57
  | **Guardian AST** | Pre-execution heuristic inspection blocks sandbox escapes (`require`, `fs`, `eval`, `fetch`, prototype pollution). |
58
58
  | **IFC Taint Analyzer** | 5-pass Acorn AST information flow control tracking collection aliases, correlation guards, and extrema gates at preflight. |
59
59
  | **WASI Sandbox** | JavaScript payloads execute inside V8 isolates with CPU fuel limits, no Node.js globals, and safe environment isolation (`allowEnv`). |
@@ -61,8 +61,8 @@ This addresses the data privacy, bandwidth, and latency bottlenecks of distribut
61
61
  | **Resilient Hybrid Routing** | Deterministic per-tool multiplexing across `http-gateway`, `p2p-grpc`, and `local` with 5-failure circuit breaker (`RoutingTable`).|
62
62
  | **OAuth 2.1 M2M Lifecycle** | Concurrency in-flight de-duplication, 30-second preemptive refresh buffer, and reactive invalidation (`TokenManager`). |
63
63
  | **Sliding-Window Rate Limiter**| In-memory OWASP API4:2023 rate limiting with background cleanup unreferenced intervals (`InMemoryRateLimiter`). |
64
- | **PII Shield** | Multi-layer egress filter with Regional Presets, custom keys, and recursive floats sanitization (`sanitizeOutput`). |
65
- | **ZK-Receipts** | Cryptographic proof with `output_hash` cross-verification (Replay Mitigation) and balanced-brace proxy extraction. |
64
+ | **ZK-Receipts** | Tri-modal Zero-Knowledge proofs: HMAC-SHA256 (v1), Groth16 BN254 with 144-byte binary journal (v2), and dual-layer ML-DSA-65 post-quantum hybrid receipts (v2.1). Enforces `ZK_BLOCKING` on Tier 1 Enclaves. |
65
+ | **Hardware TEE Attestation** | Pre-flight validation of confidential hardware root-of-trust evidence for AMD SEV-SNP (1,184-byte report) and AWS Nitro Enclaves (`verifyTeeAttestationDetailed`). |
66
66
  | **Worker Pool** | Heavy computation (crypto, sandboxing) dispatched to OS threads via `piscina` with background async warmup. |
67
67
  | **Post-Quantum Ready** | ML-KEM-768 (Kyber) + ML-DSA-65 (Dilithium) with 1-hour session lifetime and AES-256-GCM encryption. |
68
68
  | **Enterprise Observability** | Immutable SOC 2 Hash-Chain audit log (`AuditLogger`), physical wire egress tracking, Prometheus metrics (`/metrics`), and K8s probes. |
@@ -122,7 +122,7 @@ npm install -g @nekzus/liop@latest
122
122
  liop
123
123
  ```
124
124
 
125
- ### 🤖 Claude Desktop Configuration
125
+ ### Claude Desktop Configuration
126
126
 
127
127
  To integrate LIOP into Claude Desktop, update your `claude_desktop_config.json` (typically found in `%APPDATA%\Claude\claude_desktop_config.json` on Windows):
128
128
 
@@ -186,7 +186,7 @@ server.tool(
186
186
  "Analyzes local log files without sending raw data to the LLM.",
187
187
  { target_error: z.string().describe("The error pattern to search for") },
188
188
  async ({ target_error }) => {
189
- // This logic runs at origin — data never leaves the server
189
+ // This logic runs at origin, data never leaves the server
190
190
  return {
191
191
  content: [{ type: "text", text: `Found 51 occurrences of ${target_error}` }],
192
192
  };
@@ -325,13 +325,13 @@ await bridge.connect();
325
325
 
326
326
  **Supported JSON-RPC methods:**
327
327
 
328
- - `initialize` — Returns server capabilities and info
329
- - `tools/list` — Lists available tools
330
- - `tools/call` — Calls a tool (with ZK-Receipt verification)
331
- - `resources/list` — Lists available resources
332
- - `resources/read` — Reads a resource
333
- - `prompts/list` — Lists available prompts
334
- - `prompts/get` — Gets a specific prompt
328
+ - `initialize`: Returns server capabilities and info
329
+ - `tools/list`: Lists available tools
330
+ - `tools/call`: Calls a tool (with ZK-Receipt verification)
331
+ - `resources/list`: Lists available resources
332
+ - `resources/read`: Reads a resource
333
+ - `prompts/list`: Lists available prompts
334
+ - `prompts/get`: Gets a specific prompt
335
335
 
336
336
  ---
337
337
 
@@ -344,13 +344,13 @@ await bridge.connect();
344
344
  │ Layer 1: Guardian AST (Pre-Execution Static Analysis) │
345
345
  │ 14-function WASI allowlist • 128 import cap • Blocks │
346
346
  │ require, import(), fs, eval, fetch, __proto__ │
347
- ├───────────────────────────────────────────────────────────┐
347
+ ├───────────────────────────────────────────────────────────┤
348
348
  │ Layer 2: WASI Sandbox (V8 Isolate) │
349
349
  │ 25 poisoned globals (incl. Date, TypedArrays) • │
350
350
  │ CPU Fuel limits • 5s timeout • maxHeapMb (64MB default) │
351
351
  │ Object.freeze() on 11 core prototypes • allowEnv allowlist │
352
352
  ├───────────────────────────────────────────────────────────┤
353
- │ Layer 3: Taint Analyzer (IFC — Static) │
353
+ │ Layer 3: Taint Analyzer (IFC, Static) │
354
354
  │ Acorn AST 3-pass analysis blocks PII side-channels: │
355
355
  │ charCodeAt, boolean inference, arithmetic derivation │
356
356
  ├───────────────────────────────────────────────────────────┤
@@ -363,8 +363,9 @@ await bridge.connect();
363
363
  │ Blocks raw row export • maxOutputRows (default: 10) • │
364
364
  │ Conditional error: detailed (dev) vs opaque (production) │
365
365
  ├───────────────────────────────────────────────────────────┤
366
- │ Layer 6: ZK-Receipt (Integrity & Replay Mitigation) │
367
- │ SHA-256 ImageID + HMAC-SHA256 Seal (Kyber768-derived) • │
366
+ │ Layer 6: ZK-Receipt (Groth16 BN254 & Replay Mitigation) │
367
+ │ Version 2: 144-byte binary journal + Groth16 curve points │
368
+ │ Version 1: HMAC-SHA256 session commitment (Kyber768) │
368
369
  │ output_hash cross-verification • Balanced-brace extractor │
369
370
  └───────────────────────────────────────────────────────────┘
370
371
  ```
@@ -408,7 +409,7 @@ const server = new LiopServer(info, {
408
409
 
409
410
  To avoid false positive triggers caused by HMAC-SHA256 ZK-Receipt signatures or transport wrapper frames (such as `{ content: [{ type: "text", text: "..." }] }`), the PII Shield and Aggregation-First engines scan only the unwrapped business data (via `unwrapForAggregationPolicyScan`). Cryptographic seals and protocol routing structures are isolated and excluded from compliance scans.
410
411
 
411
- ### 📊 3-Tier Query Budget (NIST SP 800-226)
412
+ ### 3-Tier Query Budget (NIST SP 800-226)
412
413
 
413
414
  To prevent advanced statistical differentiation or database reconstruction attacks, the SDK implements a tiered, session-based budget engine:
414
415
 
@@ -418,27 +419,27 @@ To prevent advanced statistical differentiation or database reconstruction attac
418
419
 
419
420
  If an injected payload queries a field beyond its budget limit, the preflight static analysis immediately blocks execution.
420
421
 
421
- ### 🛡️ K-Anonymity on Small Datasets
422
+ ### K-Anonymity on Small Datasets
422
423
 
423
424
  When operating on high-privacy datasets, if the source records count is **less than 10**, the SDK forces a strict K-Anonymity restriction:
424
425
  - Rejects any output that contains nested objects or arrays.
425
426
  - Restricts the returned structure to a maximum of **3 scalar keys** (e.g., simple aggregate counts or statistics).
426
427
  - Prevents structural data leakage in low-entropy datasets.
427
428
 
428
- ### ❄️ Sandbox Poisoned Globals & Date Workaround
429
+ ### Sandbox Poisoned Globals & Date Workaround
429
430
 
430
431
  For maximum host security, the WASI sandbox enforces a poisoned environment that strips dangerous globals and prevents timing side-channels:
431
432
  - **Poisoned/Disabled**: `Date` (Date.now, parse, etc. throw an exception to prevent timing analysis), `eval`, `Function`, `setTimeout`, `setInterval`, `Buffer`, `ArrayBuffer`, and all `TypedArrays`.
432
433
  - **Date Workaround**: To perform date checks, use lexicographical string comparison on ISO 8601 strings (e.g., `record.date >= "2026-01-01"`).
433
434
 
434
- ### 🧹 Recursive In-Memory Numerical Sanitization
435
+ ### Recursive In-Memory Numerical Sanitization
435
436
 
436
437
  To mitigate timing channels, statistical differentiation, and floats side-channels, the SDK executes a recursive sanitization pipeline before the PII scanner runs:
437
438
  - Positive floating-point numbers are recursively rounded to exactly **4 decimal places**.
438
439
  - Negative values are safely clamped to **0** (via `sanitizeOutput()`).
439
440
  - This operation runs entirely in-memory and recursively on all fields, preserving data structure immutability without expensive and fragile serialization-deserialization cycles.
440
441
 
441
- ### 🌐 Environment Isolation & allowEnv Allowlist
442
+ ### Environment Isolation & allowEnv Allowlist
442
443
 
443
444
  For robust sandboxing, the WASI execution path isolates host environment variables. Propagation can be enabled explicitly:
444
445
  ```typescript
@@ -451,11 +452,57 @@ To block arbitrary command execution (e.g., Shellshock) and prevent exposure of
451
452
  - **Unix/Linux Allowlist**: `HOME`, `LOGNAME`, `PATH`, `SHELL`, `TERM`, `USER`.
452
453
  Variables starting with shell functions `()` are dropped.
453
454
 
454
- ### 🔒 ZK-Receipt Replay & Tampering Mitigation
455
+ ### Sovereign Tri-Modal ZK-Receipts & Hardware Attestation
456
+
457
+ LIOP ZK-Receipts provide cryptographic evidence that a computation was executed honestly under zero-trust bounds. The protocol implements three complementary cryptographic modes:
458
+ - **Mode 0 (`HMAC_LEGACY`, v1)**: Session commitments sealed with the ML-KEM-768 quantum-resistant shared key.
459
+ - **Mode 2 (`GROTH16`, v2)**: Compact Zero-Knowledge SNARK proofs over the BN254 pairing-friendly elliptic curve packing a 144-byte binary journal (~252 bytes total).
460
+ - **Mode 3 (`GROTH16_PQC_HYBRID`, v2.1)**: Dual-layer receipts combining Groth16 BN254 mathematical proofs with an ML-DSA-65 post-quantum digital signature conforming to NIST FIPS 204 (~5.6 KB total).
461
+
462
+ - **144-Byte Binary Journal Layout**:
463
+ - `guest_image_id` (32 bytes): Sovereign enclave guest runtime image identifier
464
+ - `logic_digest` (32 bytes): SHA-256 fingerprint of the executed JavaScript/WASM logic
465
+ - `dataset_digest` (32 bytes): SHA-256 fingerprint of the origin dataset at execution time
466
+ - `output_digest` (32 bytes): SHA-256 fingerprint of the sanitized computation result
467
+ - `fuel_consumed` (8 bytes uint64 BE): Quantized instruction-level AST fuel units consumed
468
+ - `execution_timestamp` (8 bytes uint64 BE): Epoch timestamp in milliseconds
469
+ - **Tampering & Replay Mitigation**: The client computes the local SHA-256 hash of the received output and asserts strict equality with `journal.outputDigest`. Any modified bit in either the journal, curve proof, or post-quantum signature causes immediate rejection.
470
+ - **Enclave Policy Invariant (`ZK_BLOCKING`)**: Tier 1 Sovereign Enclaves configure `zkMode: "required"`, rejecting queries if a valid Groth16 proof cannot be synthesized or if mock proofs are supplied. When `pqcSign: true` is configured, the enclave emits a Version 2.1 hybrid receipt co-signed with ML-DSA-65.
471
+
472
+ ```typescript
473
+ import { LiopServer } from "@nekzus/liop/server";
474
+ import { LiopVerifier, verifyTeeAttestationDetailed } from "@nekzus/liop";
475
+
476
+ // 1. Enclave configuration with ZK_BLOCKING and PQC signing
477
+ const server = new LiopServer({ name: "bank-enclave", version: "1.0.0" });
478
+ server.tool(
479
+ "calculate_payroll_aggregate",
480
+ "Aggregates payroll without egressing employee identities",
481
+ { payload: z.string() },
482
+ async () => ({ content: [{ type: "text", text: "ok" }] }),
483
+ {
484
+ zkMode: "required", // Enforces Groth16 proof generation (ZK_BLOCKING)
485
+ pqcSign: true, // Enables ML-DSA-65 digital signature (Receipt v2.1)
486
+ circuitName: "sum",
487
+ }
488
+ );
489
+
490
+ // 2. Client verification via LiopVerifier
491
+ const verifier = new LiopVerifier();
492
+ const isValid = await verifier.verifyZkReceipt(
493
+ Buffer.from(logicPayload),
494
+ remoteImageIdHex,
495
+ rawReceiptBuffer,
496
+ { zkPolicy: "required" }
497
+ );
455
498
 
456
- LIOP ZK-Receipts provide cryptographic evidence that a computation was executed honestly under zero-trust bounds. To defeat **Man-in-the-Middle (MITM) reply tampering and replay attacks** (re-using old signatures on new query data):
457
- - The verification pipeline computes the SHA-256 hash of the received business output (`expectedOutput`) and strictly asserts its equivalence with `Journal.output_hash` signed inside the ZK-Receipt (via `verifyZkReceipt`).
458
- - **Balanced-Brace Proxy Extractor**: If the tool call was delegated to a proxied tool (`__liop_proxy_tool`), the verifier invokes an in-process balanced-brace state machine to safely isolate proxy arguments from the response metadata, preventing false validation failures.
499
+ // 3. Pre-flight Hardware TEE Attestation (AMD SEV-SNP / AWS Nitro Enclaves)
500
+ const teeStatus = await verifyTeeAttestationDetailed(
501
+ attestationBytes,
502
+ expectedNonce,
503
+ { requireHardwareSigned: true }
504
+ );
505
+ ```
459
506
 
460
507
  ---
461
508
 
@@ -470,7 +517,7 @@ The following shows a complete Logic-Injection-on-Origin execution cycle (handle
470
517
  4. Code executes inside a V8 isolate with CPU fuel limits (no Node.js globals)
471
518
  5. Taint Analyzer blocks PII side-channel derivation (charCodeAt, boolean inference)
472
519
  6. PII Shield scans output for forbidden data and keys
473
- 7. ZK-Receipt generated (SHA-256 ImageID + HMAC-SHA256 seal)
520
+ 7. ZK-Receipt generated (Tri-modal: HMAC v1, Groth16 v2, or Groth16 + ML-DSA-65 v2.1)
474
521
  8. Result + receipt returned to the LLM (raw data never exposed)
475
522
  ```
476
523
 
@@ -499,7 +546,7 @@ Node.js is single-threaded. Heavy operations like Kyber768 decryption, AES-GCM a
499
546
  This SDK dispatches all heavy computation to OS-level threads via [`piscina`](https://github.com/piscinajs/piscina), achieving Rust-like concurrency. On server or verifier initialization, background warmup tasks are automatically dispatched to pre-warm the pool workers, eliminating V8/WASI cold-start overhead (~820k fuel units) for subsequent calls:
500
547
 
501
548
  ```typescript
502
- // Automatic — no configuration needed
549
+ // Automatic, no configuration needed
503
550
  // When a Logic-Injection-on-Origin payload is received:
504
551
  // 1. Main thread receives JSON-RPC request
505
552
  // 2. Worker thread: AST inspection + PQC decryption + Sandbox execution
@@ -572,7 +619,7 @@ Navigate to **`http://localhost:16000`** in your browser:
572
619
 
573
620
  * **Live 7-Phase Streaming:** Visualizes Bootstrap, DHT Discovery, ML-KEM-768 Handshake, AES-256-GCM Sealing, WASI Sandbox Execution, ZK-Receipt Verification, and Output Aggregation via real-time Server-Sent Events (SSE).
574
621
  * **Tri-Tab Results Panel:** Switch between `Aggregated Output` (sanitized JSON), `Fuel & Telemetry` (WASI fuel metering, token economy comparison banner), and `Crypto Proofs` (ImageID, Dataset Hash, and HMAC-SHA256 signature with instant copy).
575
- * **Token Economy Dashboard:** Live comparison showing **98.9% – 99.6% token reduction** and **99.6% network bandwidth savings** over traditional MCP context-pulling.
622
+ * **Token Economy Dashboard:** Live comparison showing **98.9% to 99.6% token reduction** and **99.6% network bandwidth savings** over traditional MCP context-pulling.
576
623
  * **REST Telemetry Endpoint:** Query session analytics programmatically at `GET http://localhost:16000/api/telemetry`.
577
624
  * **Built-in Scenario Presets:** Ready-to-run micro-modules for High-Frequency Trading (HFT Level 2 order books), Banking transaction analysis, Medical Vault HIPAA records, and Edge IoT industrial sensor telemetry.
578
625
  * **Dual Dark Modes:** Toggle between Obsidian OLED (`#000000`) and Slate Navy (`#0f172a`) interfaces.
@@ -619,7 +666,7 @@ This package is continuously tested across multiple platforms and Node.js versio
619
666
  - **Multi-OS matrix:** Ubuntu, Windows, macOS
620
667
  - **Node.js versions:** 20.x, 22.x
621
668
  - **Code quality:** Enforced by [Biome.js](https://biomejs.dev/) (linting + formatting)
622
- - **Security:** Verified 6-layer defense-in-depth architecture — see [Security Architecture](https://nekzus-32.mintlify.app/typescript-sdk/security)
669
+ - **Security:** Verified 6-layer defense-in-depth architecture (see [Security Architecture](https://nekzus-32.mintlify.app/typescript-sdk/security))
623
670
 
624
671
  > To run tests locally or contribute, clone the [repository](https://github.com/Nekzus/LIOP) and follow the [Contributing Guide](https://github.com/Nekzus/LIOP/blob/main/CONTRIBUTING.md).
625
672
 
@@ -639,12 +686,12 @@ The codebase undergoes regular dependencies audits. As of June 2026, the SDK is
639
686
 
640
687
  ## Related
641
688
 
642
- - [LIOP Documentation](https://nekzus-32.mintlify.app/) — Full conceptual and API documentation
643
- - [LIOP Specification](https://github.com/Nekzus/LIOP/blob/main/protocol/SPECIFICATION.md) — Technical specification
644
- - [LIOP Manifesto](https://github.com/Nekzus/LIOP/blob/main/MANIFESTO.md) — Project philosophy
645
- - [Contributing Guide](https://github.com/Nekzus/LIOP/blob/main/CONTRIBUTING.md) — How to contribute
646
- - [Rust Mesh Node](https://github.com/Nekzus/LIOP/tree/main/servers/liop-node) — Native high-performance backend
647
- - [LIOP CLI](https://github.com/Nekzus/LIOP/tree/main/tools/liop-cli) — Developer diagnostics
689
+ - [LIOP Documentation](https://nekzus-32.mintlify.app/): Full conceptual and API documentation
690
+ - [LIOP Specification](https://github.com/Nekzus/LIOP/blob/main/protocol/SPECIFICATION.md): Technical specification
691
+ - [LIOP Manifesto](https://github.com/Nekzus/LIOP/blob/main/MANIFESTO.md): Project philosophy
692
+ - [Contributing Guide](https://github.com/Nekzus/LIOP/blob/main/CONTRIBUTING.md): How to contribute
693
+ - [Rust Mesh Node](https://github.com/Nekzus/LIOP/tree/main/servers/liop-node): Native high-performance backend
694
+ - [LIOP CLI](https://github.com/Nekzus/LIOP/tree/main/tools/liop-cli): Developer diagnostics
648
695
 
649
696
  ---
650
697