@wenathlan/saddle 1.8.18 → 2.0.2

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 (802) hide show
  1. package/Dockerfile +1339 -0
  2. package/README.md +33 -12
  3. package/alternatives.ts +1218 -0
  4. package/biome.json +153 -0
  5. package/boards.json +1517 -0
  6. package/compute.ts +3144 -0
  7. package/cores.json +1801 -0
  8. package/dist/acquisition.d.ts +359 -0
  9. package/dist/acquisition.d.ts.map +1 -0
  10. package/dist/acquisition.js +629 -0
  11. package/dist/acquisition.js.map +1 -0
  12. package/dist/alternatives.d.ts +509 -0
  13. package/dist/alternatives.d.ts.map +1 -0
  14. package/dist/alternatives.js +951 -0
  15. package/dist/alternatives.js.map +1 -0
  16. package/dist/automation.d.ts +426 -0
  17. package/dist/automation.d.ts.map +1 -0
  18. package/dist/automation.js +561 -0
  19. package/dist/automation.js.map +1 -0
  20. package/dist/browser.d.ts +562 -0
  21. package/dist/browser.d.ts.map +1 -0
  22. package/dist/browser.js +1057 -0
  23. package/dist/browser.js.map +1 -0
  24. package/dist/capacitor.config.d.ts +13 -0
  25. package/dist/capacitor.config.d.ts.map +1 -0
  26. package/dist/capacitor.config.js +26 -0
  27. package/dist/capacitor.config.js.map +1 -0
  28. package/dist/cli.d.ts +17 -0
  29. package/dist/cli.d.ts.map +1 -0
  30. package/dist/cli.js +111 -0
  31. package/dist/cli.js.map +1 -0
  32. package/dist/communication.d.ts +192 -0
  33. package/dist/communication.d.ts.map +1 -0
  34. package/dist/communication.js +418 -0
  35. package/dist/communication.js.map +1 -0
  36. package/dist/compute.d.ts +1161 -0
  37. package/dist/compute.d.ts.map +1 -0
  38. package/dist/compute.js +2273 -0
  39. package/dist/compute.js.map +1 -0
  40. package/dist/distribution.d.ts +529 -0
  41. package/dist/distribution.d.ts.map +1 -0
  42. package/dist/distribution.js +811 -0
  43. package/dist/distribution.js.map +1 -0
  44. package/dist/execution.d.ts +530 -0
  45. package/dist/execution.d.ts.map +1 -0
  46. package/dist/execution.js +761 -0
  47. package/dist/execution.js.map +1 -0
  48. package/dist/format.d.ts +19 -0
  49. package/dist/format.d.ts.map +1 -0
  50. package/dist/format.js +60 -0
  51. package/dist/format.js.map +1 -0
  52. package/dist/foundation.d.ts +176 -0
  53. package/dist/foundation.d.ts.map +1 -0
  54. package/dist/foundation.js +309 -0
  55. package/dist/foundation.js.map +1 -0
  56. package/dist/index.d.ts +733 -123
  57. package/dist/index.d.ts.map +1 -1
  58. package/dist/index.js +1018 -123
  59. package/dist/index.js.map +1 -1
  60. package/dist/integration.d.ts +236 -0
  61. package/dist/integration.d.ts.map +1 -0
  62. package/dist/integration.js +236 -0
  63. package/dist/integration.js.map +1 -0
  64. package/dist/intelligence.d.ts +94 -0
  65. package/dist/intelligence.d.ts.map +1 -0
  66. package/dist/intelligence.js +145 -0
  67. package/dist/intelligence.js.map +1 -0
  68. package/dist/{isolation/contracts.d.ts → isolation.d.ts} +12 -1
  69. package/dist/isolation.d.ts.map +1 -0
  70. package/dist/{isolation/contracts.js → isolation.js} +13 -1
  71. package/dist/isolation.js.map +1 -0
  72. package/dist/media.d.ts +344 -0
  73. package/dist/media.d.ts.map +1 -0
  74. package/dist/media.js +986 -0
  75. package/dist/media.js.map +1 -0
  76. package/dist/modes.d.ts +359 -0
  77. package/dist/modes.d.ts.map +1 -0
  78. package/dist/modes.js +134 -0
  79. package/dist/modes.js.map +1 -0
  80. package/dist/{library/public.d.ts → operations.d.ts} +15 -1
  81. package/dist/operations.d.ts.map +1 -0
  82. package/dist/{library/public.js → operations.js} +18 -7
  83. package/dist/operations.js.map +1 -0
  84. package/dist/orchestrator.d.ts +1339 -0
  85. package/dist/orchestrator.d.ts.map +1 -0
  86. package/dist/orchestrator.js +4308 -0
  87. package/dist/orchestrator.js.map +1 -0
  88. package/dist/performance.d.ts +416 -0
  89. package/dist/performance.d.ts.map +1 -0
  90. package/dist/performance.js +827 -0
  91. package/dist/performance.js.map +1 -0
  92. package/dist/quantum.d.ts +810 -0
  93. package/dist/quantum.d.ts.map +1 -0
  94. package/dist/quantum.js +2073 -0
  95. package/dist/quantum.js.map +1 -0
  96. package/dist/render.d.ts +381 -0
  97. package/dist/render.d.ts.map +1 -0
  98. package/dist/render.js +1073 -0
  99. package/dist/render.js.map +1 -0
  100. package/dist/scheduler.d.ts +596 -0
  101. package/dist/scheduler.d.ts.map +1 -0
  102. package/dist/scheduler.js +1259 -0
  103. package/dist/scheduler.js.map +1 -0
  104. package/dist/security.d.ts +501 -0
  105. package/dist/security.d.ts.map +1 -0
  106. package/dist/security.js +1170 -0
  107. package/dist/security.js.map +1 -0
  108. package/dist/server.d.ts +21 -0
  109. package/dist/server.d.ts.map +1 -0
  110. package/dist/{server/node.js → server.js} +16 -2
  111. package/dist/server.js.map +1 -0
  112. package/dist/tiers.d.ts +1002 -0
  113. package/dist/tiers.d.ts.map +1 -0
  114. package/dist/tiers.js +2165 -0
  115. package/dist/tiers.js.map +1 -0
  116. package/dist/virtual.d.ts +641 -0
  117. package/dist/virtual.d.ts.map +1 -0
  118. package/dist/virtual.js +1285 -0
  119. package/dist/virtual.js.map +1 -0
  120. package/dist/virtualcpu.d.ts +316 -0
  121. package/dist/virtualcpu.d.ts.map +1 -0
  122. package/dist/virtualcpu.js +1180 -0
  123. package/dist/virtualcpu.js.map +1 -0
  124. package/dist/virtualgpu.d.ts +345 -0
  125. package/dist/virtualgpu.d.ts.map +1 -0
  126. package/dist/virtualgpu.js +1000 -0
  127. package/dist/virtualgpu.js.map +1 -0
  128. package/dist/virtualization.d.ts +607 -0
  129. package/dist/virtualization.d.ts.map +1 -0
  130. package/dist/virtualization.js +1187 -0
  131. package/dist/virtualization.js.map +1 -0
  132. package/dist/virtualmemory.d.ts +818 -0
  133. package/dist/virtualmemory.d.ts.map +1 -0
  134. package/dist/virtualmemory.js +1796 -0
  135. package/dist/virtualmemory.js.map +1 -0
  136. package/dist/webscrape.d.ts +720 -0
  137. package/dist/webscrape.d.ts.map +1 -0
  138. package/dist/webscrape.js +2697 -0
  139. package/dist/webscrape.js.map +1 -0
  140. package/docker.config +769 -0
  141. package/docs/CONVERSA.txt +1523 -0
  142. package/docs/alternatives.md +499 -0
  143. package/docs/architecture-1.8.19.md +76 -0
  144. package/docs/architecture-1.8.19.mmd +33 -0
  145. package/docs/architecture-1.8.19.png +0 -0
  146. package/docs/architecture.md +355 -0
  147. package/docs/brancharchive-2026-08-18.md +18 -0
  148. package/docs/browser.md +7 -0
  149. package/docs/consolidation.md +70 -0
  150. package/docs/e2ugh-engine.md +528 -0
  151. package/{dist/examples/localjob.js → docs/example-localjob.ts} +3 -3
  152. package/{dist/examples/publicapi.js → docs/example-publicapi.ts} +2 -2
  153. package/docs/hardware.md +342 -0
  154. package/docs/optimization.md +126 -0
  155. package/docs/performance.md +499 -0
  156. package/docs/planning.1.8.18.md +94 -0
  157. package/docs/planning.1.8.19.md +49 -0
  158. package/docs/releasenotes-1.8.19.md +35 -0
  159. package/docs/research-1.8.19-virtual-browser.md +27 -0
  160. package/docs/security.md +454 -0
  161. package/docs/todo-1.8.18.md +12 -0
  162. package/docs/todo-1.8.19.md +241 -0
  163. package/docs/viability.md +777 -0
  164. package/docs/virtualization.md +335 -0
  165. package/docs/web-duplicatecleanup.md +9 -0
  166. package/docs/web-ideas.md +106 -0
  167. package/docs/workflowimprovements-2026-08-19.md +70 -0
  168. package/gpumonitor.cpp +1543 -0
  169. package/gpus.json +2408 -0
  170. package/index.ts +1478 -0
  171. package/media.ts +1337 -0
  172. package/mttg.config +1549 -0
  173. package/orchestrator.ts +5462 -0
  174. package/package.json +304 -56
  175. package/passage.config +1331 -0
  176. package/performance.ts +1049 -0
  177. package/processors.json +2217 -0
  178. package/qemu.config +1062 -0
  179. package/qemubridge.py +1340 -0
  180. package/quantum.ts +2393 -0
  181. package/render.ts +1325 -0
  182. package/scheduler.ts +1600 -0
  183. package/security.ts +1449 -0
  184. package/tiers.ts +2871 -0
  185. package/tsconfig.json +29 -0
  186. package/virtualcpu.ts +1273 -0
  187. package/virtualgpu.ts +1181 -0
  188. package/virtualhardware.c +1011 -0
  189. package/virtualhardware.json +739 -0
  190. package/virtualization.ts +1628 -0
  191. package/virtualizationcore.cpp +4635 -0
  192. package/virtualmemory.ts +2303 -0
  193. package/vm.config.json +1910 -0
  194. package/{extension → web/extension}/manifest.json +1 -1
  195. package/web/readme.md +382 -0
  196. package/web/tsconfig.json +25 -0
  197. package/dist/adapters/forge.d.ts +0 -17
  198. package/dist/adapters/forge.d.ts.map +0 -1
  199. package/dist/adapters/forge.js +0 -19
  200. package/dist/adapters/forge.js.map +0 -1
  201. package/dist/adapters/forgejo.d.ts +0 -49
  202. package/dist/adapters/forgejo.d.ts.map +0 -1
  203. package/dist/adapters/forgejo.js +0 -8
  204. package/dist/adapters/forgejo.js.map +0 -1
  205. package/dist/adapters/github.d.ts +0 -12
  206. package/dist/adapters/github.d.ts.map +0 -1
  207. package/dist/adapters/github.js +0 -20
  208. package/dist/adapters/github.js.map +0 -1
  209. package/dist/adapters/gitlab.d.ts +0 -17
  210. package/dist/adapters/gitlab.d.ts.map +0 -1
  211. package/dist/adapters/gitlab.js +0 -10
  212. package/dist/adapters/gitlab.js.map +0 -1
  213. package/dist/adapters/huggingface.d.ts +0 -17
  214. package/dist/adapters/huggingface.d.ts.map +0 -1
  215. package/dist/adapters/huggingface.js +0 -6
  216. package/dist/adapters/huggingface.js.map +0 -1
  217. package/dist/adapters/socket.d.ts +0 -11
  218. package/dist/adapters/socket.d.ts.map +0 -1
  219. package/dist/adapters/socket.js +0 -17
  220. package/dist/adapters/socket.js.map +0 -1
  221. package/dist/adapters/transport.d.ts +0 -7
  222. package/dist/adapters/transport.d.ts.map +0 -1
  223. package/dist/adapters/transport.js +0 -36
  224. package/dist/adapters/transport.js.map +0 -1
  225. package/dist/ai/chunk.d.ts +0 -2
  226. package/dist/ai/chunk.d.ts.map +0 -1
  227. package/dist/ai/chunk.js +0 -36
  228. package/dist/ai/chunk.js.map +0 -1
  229. package/dist/ai/llmstxt.d.ts +0 -6
  230. package/dist/ai/llmstxt.d.ts.map +0 -1
  231. package/dist/ai/llmstxt.js +0 -12
  232. package/dist/ai/llmstxt.js.map +0 -1
  233. package/dist/ai/provenance.d.ts +0 -22
  234. package/dist/ai/provenance.d.ts.map +0 -1
  235. package/dist/ai/provenance.js +0 -25
  236. package/dist/ai/provenance.js.map +0 -1
  237. package/dist/ai/rag.d.ts +0 -26
  238. package/dist/ai/rag.d.ts.map +0 -1
  239. package/dist/ai/rag.js +0 -22
  240. package/dist/ai/rag.js.map +0 -1
  241. package/dist/ai/tokens.d.ts +0 -15
  242. package/dist/ai/tokens.d.ts.map +0 -1
  243. package/dist/ai/tokens.js +0 -9
  244. package/dist/ai/tokens.js.map +0 -1
  245. package/dist/api/auth.d.ts +0 -16
  246. package/dist/api/auth.d.ts.map +0 -1
  247. package/dist/api/auth.js +0 -19
  248. package/dist/api/auth.js.map +0 -1
  249. package/dist/api/contracts.d.ts +0 -28
  250. package/dist/api/contracts.d.ts.map +0 -1
  251. package/dist/api/contracts.js +0 -14
  252. package/dist/api/contracts.js.map +0 -1
  253. package/dist/api/control.d.ts +0 -10
  254. package/dist/api/control.d.ts.map +0 -1
  255. package/dist/api/control.js +0 -35
  256. package/dist/api/control.js.map +0 -1
  257. package/dist/api/http.d.ts +0 -7
  258. package/dist/api/http.d.ts.map +0 -1
  259. package/dist/api/http.js +0 -12
  260. package/dist/api/http.js.map +0 -1
  261. package/dist/api/rate.d.ts +0 -28
  262. package/dist/api/rate.d.ts.map +0 -1
  263. package/dist/api/rate.js +0 -36
  264. package/dist/api/rate.js.map +0 -1
  265. package/dist/api/security.d.ts +0 -12
  266. package/dist/api/security.d.ts.map +0 -1
  267. package/dist/api/security.js +0 -56
  268. package/dist/api/security.js.map +0 -1
  269. package/dist/api/service.d.ts +0 -5
  270. package/dist/api/service.d.ts.map +0 -1
  271. package/dist/api/service.js +0 -70
  272. package/dist/api/service.js.map +0 -1
  273. package/dist/apps/registry.d.ts +0 -33
  274. package/dist/apps/registry.d.ts.map +0 -1
  275. package/dist/apps/registry.js +0 -24
  276. package/dist/apps/registry.js.map +0 -1
  277. package/dist/binary/archive.d.ts +0 -27
  278. package/dist/binary/archive.d.ts.map +0 -1
  279. package/dist/binary/archive.js +0 -46
  280. package/dist/binary/archive.js.map +0 -1
  281. package/dist/binary/build.d.ts +0 -29
  282. package/dist/binary/build.d.ts.map +0 -1
  283. package/dist/binary/build.js +0 -17
  284. package/dist/binary/build.js.map +0 -1
  285. package/dist/binary/transform.d.ts +0 -70
  286. package/dist/binary/transform.d.ts.map +0 -1
  287. package/dist/binary/transform.js +0 -105
  288. package/dist/binary/transform.js.map +0 -1
  289. package/dist/bot/adapter.d.ts +0 -5
  290. package/dist/bot/adapter.d.ts.map +0 -1
  291. package/dist/bot/adapter.js +0 -11
  292. package/dist/bot/adapter.js.map +0 -1
  293. package/dist/bot/bot.d.ts +0 -28
  294. package/dist/bot/bot.d.ts.map +0 -1
  295. package/dist/bot/bot.js +0 -52
  296. package/dist/bot/bot.js.map +0 -1
  297. package/dist/bot/commands.d.ts +0 -8
  298. package/dist/bot/commands.d.ts.map +0 -1
  299. package/dist/bot/commands.js +0 -19
  300. package/dist/bot/commands.js.map +0 -1
  301. package/dist/bot/permissions.d.ts +0 -13
  302. package/dist/bot/permissions.d.ts.map +0 -1
  303. package/dist/bot/permissions.js +0 -16
  304. package/dist/bot/permissions.js.map +0 -1
  305. package/dist/browser/actions.d.ts +0 -33
  306. package/dist/browser/actions.d.ts.map +0 -1
  307. package/dist/browser/actions.js +0 -44
  308. package/dist/browser/actions.js.map +0 -1
  309. package/dist/browser/agent.d.ts +0 -21
  310. package/dist/browser/agent.d.ts.map +0 -1
  311. package/dist/browser/agent.js +0 -13
  312. package/dist/browser/agent.js.map +0 -1
  313. package/dist/browser/context.d.ts +0 -43
  314. package/dist/browser/context.d.ts.map +0 -1
  315. package/dist/browser/context.js +0 -54
  316. package/dist/browser/context.js.map +0 -1
  317. package/dist/browser/fingerprint.d.ts +0 -4
  318. package/dist/browser/fingerprint.d.ts.map +0 -1
  319. package/dist/browser/fingerprint.js +0 -12
  320. package/dist/browser/fingerprint.js.map +0 -1
  321. package/dist/browser/index.d.ts +0 -11
  322. package/dist/browser/index.d.ts.map +0 -1
  323. package/dist/browser/index.js +0 -11
  324. package/dist/browser/index.js.map +0 -1
  325. package/dist/browser/playwright.d.ts +0 -11
  326. package/dist/browser/playwright.d.ts.map +0 -1
  327. package/dist/browser/playwright.js +0 -24
  328. package/dist/browser/playwright.js.map +0 -1
  329. package/dist/browser/recorder.d.ts +0 -21
  330. package/dist/browser/recorder.d.ts.map +0 -1
  331. package/dist/browser/recorder.js +0 -58
  332. package/dist/browser/recorder.js.map +0 -1
  333. package/dist/browser/session.d.ts +0 -14
  334. package/dist/browser/session.d.ts.map +0 -1
  335. package/dist/browser/session.js +0 -21
  336. package/dist/browser/session.js.map +0 -1
  337. package/dist/browser/snapshot.d.ts +0 -69
  338. package/dist/browser/snapshot.d.ts.map +0 -1
  339. package/dist/browser/snapshot.js +0 -133
  340. package/dist/browser/snapshot.js.map +0 -1
  341. package/dist/captcha/contract.d.ts +0 -35
  342. package/dist/captcha/contract.d.ts.map +0 -1
  343. package/dist/captcha/contract.js +0 -17
  344. package/dist/captcha/contract.js.map +0 -1
  345. package/dist/captcha/evidence.d.ts +0 -10
  346. package/dist/captcha/evidence.d.ts.map +0 -1
  347. package/dist/captcha/evidence.js +0 -9
  348. package/dist/captcha/evidence.js.map +0 -1
  349. package/dist/captcha/guard.d.ts +0 -23
  350. package/dist/captcha/guard.d.ts.map +0 -1
  351. package/dist/captcha/guard.js +0 -12
  352. package/dist/captcha/guard.js.map +0 -1
  353. package/dist/cli/main.d.ts +0 -4
  354. package/dist/cli/main.d.ts.map +0 -1
  355. package/dist/cli/main.js +0 -46
  356. package/dist/cli/main.js.map +0 -1
  357. package/dist/core/errors.d.ts +0 -84
  358. package/dist/core/errors.d.ts.map +0 -1
  359. package/dist/core/errors.js +0 -54
  360. package/dist/core/errors.js.map +0 -1
  361. package/dist/core/events.d.ts +0 -9
  362. package/dist/core/events.d.ts.map +0 -1
  363. package/dist/core/events.js +0 -21
  364. package/dist/core/events.js.map +0 -1
  365. package/dist/core/hash.d.ts +0 -10
  366. package/dist/core/hash.d.ts.map +0 -1
  367. package/dist/core/hash.js +0 -82
  368. package/dist/core/hash.js.map +0 -1
  369. package/dist/core/ids.d.ts +0 -10
  370. package/dist/core/ids.d.ts.map +0 -1
  371. package/dist/core/ids.js +0 -15
  372. package/dist/core/ids.js.map +0 -1
  373. package/dist/delivery/manifest.d.ts +0 -35
  374. package/dist/delivery/manifest.d.ts.map +0 -1
  375. package/dist/delivery/manifest.js +0 -68
  376. package/dist/delivery/manifest.js.map +0 -1
  377. package/dist/deploy/index.d.ts +0 -6
  378. package/dist/deploy/index.d.ts.map +0 -1
  379. package/dist/deploy/index.js +0 -6
  380. package/dist/deploy/index.js.map +0 -1
  381. package/dist/dispatch/resumable.d.ts +0 -102
  382. package/dist/dispatch/resumable.d.ts.map +0 -1
  383. package/dist/dispatch/resumable.js +0 -64
  384. package/dist/dispatch/resumable.js.map +0 -1
  385. package/dist/dispatch/workflow.d.ts +0 -6
  386. package/dist/dispatch/workflow.d.ts.map +0 -1
  387. package/dist/dispatch/workflow.js +0 -37
  388. package/dist/dispatch/workflow.js.map +0 -1
  389. package/dist/domain/artifacts.d.ts +0 -12
  390. package/dist/domain/artifacts.d.ts.map +0 -1
  391. package/dist/domain/artifacts.js +0 -14
  392. package/dist/domain/artifacts.js.map +0 -1
  393. package/dist/domain/jobs.d.ts +0 -12
  394. package/dist/domain/jobs.d.ts.map +0 -1
  395. package/dist/domain/jobs.js +0 -20
  396. package/dist/domain/jobs.js.map +0 -1
  397. package/dist/domain/providers.d.ts +0 -10
  398. package/dist/domain/providers.d.ts.map +0 -1
  399. package/dist/domain/providers.js +0 -8
  400. package/dist/domain/providers.js.map +0 -1
  401. package/dist/domain/runtime.d.ts +0 -14
  402. package/dist/domain/runtime.d.ts.map +0 -1
  403. package/dist/domain/runtime.js +0 -10
  404. package/dist/domain/runtime.js.map +0 -1
  405. package/dist/domain/sessions.d.ts +0 -12
  406. package/dist/domain/sessions.d.ts.map +0 -1
  407. package/dist/domain/sessions.js +0 -57
  408. package/dist/domain/sessions.js.map +0 -1
  409. package/dist/examples/localjob.d.ts +0 -2
  410. package/dist/examples/localjob.d.ts.map +0 -1
  411. package/dist/examples/localjob.js.map +0 -1
  412. package/dist/examples/publicapi.d.ts +0 -2
  413. package/dist/examples/publicapi.d.ts.map +0 -1
  414. package/dist/examples/publicapi.js.map +0 -1
  415. package/dist/extension/build.d.ts +0 -9
  416. package/dist/extension/build.d.ts.map +0 -1
  417. package/dist/extension/build.js +0 -85
  418. package/dist/extension/build.js.map +0 -1
  419. package/dist/extension/content.d.ts +0 -6
  420. package/dist/extension/content.d.ts.map +0 -1
  421. package/dist/extension/content.js +0 -135
  422. package/dist/extension/content.js.map +0 -1
  423. package/dist/extension/index.d.ts +0 -7
  424. package/dist/extension/index.d.ts.map +0 -1
  425. package/dist/extension/index.js +0 -7
  426. package/dist/extension/index.js.map +0 -1
  427. package/dist/extension/pagebridge.d.ts +0 -6
  428. package/dist/extension/pagebridge.d.ts.map +0 -1
  429. package/dist/extension/pagebridge.js +0 -42
  430. package/dist/extension/pagebridge.js.map +0 -1
  431. package/dist/extension/permissions.d.ts +0 -26
  432. package/dist/extension/permissions.d.ts.map +0 -1
  433. package/dist/extension/permissions.js +0 -28
  434. package/dist/extension/permissions.js.map +0 -1
  435. package/dist/extension/popup.d.ts +0 -5
  436. package/dist/extension/popup.d.ts.map +0 -1
  437. package/dist/extension/popup.js +0 -26
  438. package/dist/extension/popup.js.map +0 -1
  439. package/dist/extension/protocol.d.ts +0 -58
  440. package/dist/extension/protocol.d.ts.map +0 -1
  441. package/dist/extension/protocol.js +0 -101
  442. package/dist/extension/protocol.js.map +0 -1
  443. package/dist/extension/serviceworker.d.ts +0 -25
  444. package/dist/extension/serviceworker.d.ts.map +0 -1
  445. package/dist/extension/serviceworker.js +0 -102
  446. package/dist/extension/serviceworker.js.map +0 -1
  447. package/dist/extension/worker.d.ts +0 -28
  448. package/dist/extension/worker.d.ts.map +0 -1
  449. package/dist/extension/worker.js +0 -22
  450. package/dist/extension/worker.js.map +0 -1
  451. package/dist/format/check.d.ts +0 -8
  452. package/dist/format/check.d.ts.map +0 -1
  453. package/dist/format/check.js +0 -38
  454. package/dist/format/check.js.map +0 -1
  455. package/dist/isolation/contracts.d.ts.map +0 -1
  456. package/dist/isolation/contracts.js.map +0 -1
  457. package/dist/library/public.d.ts.map +0 -1
  458. package/dist/library/public.js.map +0 -1
  459. package/dist/mcp/browser.d.ts +0 -9
  460. package/dist/mcp/browser.d.ts.map +0 -1
  461. package/dist/mcp/browser.js +0 -13
  462. package/dist/mcp/browser.js.map +0 -1
  463. package/dist/mcp/server.d.ts +0 -35
  464. package/dist/mcp/server.d.ts.map +0 -1
  465. package/dist/mcp/server.js +0 -40
  466. package/dist/mcp/server.js.map +0 -1
  467. package/dist/mcp/transport.d.ts +0 -7
  468. package/dist/mcp/transport.d.ts.map +0 -1
  469. package/dist/mcp/transport.js +0 -17
  470. package/dist/mcp/transport.js.map +0 -1
  471. package/dist/memory/bridge.d.ts +0 -14
  472. package/dist/memory/bridge.d.ts.map +0 -1
  473. package/dist/memory/bridge.js +0 -16
  474. package/dist/memory/bridge.js.map +0 -1
  475. package/dist/memory/engine.d.ts +0 -38
  476. package/dist/memory/engine.d.ts.map +0 -1
  477. package/dist/memory/engine.js +0 -109
  478. package/dist/memory/engine.js.map +0 -1
  479. package/dist/memory/modes.d.ts +0 -43
  480. package/dist/memory/modes.d.ts.map +0 -1
  481. package/dist/memory/modes.js +0 -66
  482. package/dist/memory/modes.js.map +0 -1
  483. package/dist/memory/objects.d.ts +0 -21
  484. package/dist/memory/objects.d.ts.map +0 -1
  485. package/dist/memory/objects.js +0 -20
  486. package/dist/memory/objects.js.map +0 -1
  487. package/dist/memory/planner.d.ts +0 -66
  488. package/dist/memory/planner.d.ts.map +0 -1
  489. package/dist/memory/planner.js +0 -108
  490. package/dist/memory/planner.js.map +0 -1
  491. package/dist/memory/targets.d.ts +0 -78
  492. package/dist/memory/targets.d.ts.map +0 -1
  493. package/dist/memory/targets.js +0 -29
  494. package/dist/memory/targets.js.map +0 -1
  495. package/dist/memory/transforms.d.ts +0 -19
  496. package/dist/memory/transforms.d.ts.map +0 -1
  497. package/dist/memory/transforms.js +0 -14
  498. package/dist/memory/transforms.js.map +0 -1
  499. package/dist/modes/matrix.d.ts +0 -23
  500. package/dist/modes/matrix.d.ts.map +0 -1
  501. package/dist/modes/matrix.js +0 -18
  502. package/dist/modes/matrix.js.map +0 -1
  503. package/dist/modes/modes.d.ts +0 -33
  504. package/dist/modes/modes.d.ts.map +0 -1
  505. package/dist/modes/modes.js +0 -15
  506. package/dist/modes/modes.js.map +0 -1
  507. package/dist/modes/resolve.d.ts +0 -96
  508. package/dist/modes/resolve.d.ts.map +0 -1
  509. package/dist/modes/resolve.js +0 -48
  510. package/dist/modes/resolve.js.map +0 -1
  511. package/dist/observability/metrics.d.ts +0 -14
  512. package/dist/observability/metrics.d.ts.map +0 -1
  513. package/dist/observability/metrics.js +0 -18
  514. package/dist/observability/metrics.js.map +0 -1
  515. package/dist/packager/manifest.d.ts +0 -66
  516. package/dist/packager/manifest.d.ts.map +0 -1
  517. package/dist/packager/manifest.js +0 -94
  518. package/dist/packager/manifest.js.map +0 -1
  519. package/dist/packager/publish.d.ts +0 -51
  520. package/dist/packager/publish.d.ts.map +0 -1
  521. package/dist/packager/publish.js +0 -18
  522. package/dist/packager/publish.js.map +0 -1
  523. package/dist/packager/targetcli.d.ts +0 -7
  524. package/dist/packager/targetcli.d.ts.map +0 -1
  525. package/dist/packager/targetcli.js +0 -22
  526. package/dist/packager/targetcli.js.map +0 -1
  527. package/dist/persistence/adapter.d.ts +0 -5
  528. package/dist/persistence/adapter.d.ts.map +0 -1
  529. package/dist/persistence/adapter.js +0 -11
  530. package/dist/persistence/adapter.js.map +0 -1
  531. package/dist/persistence/drizzle.d.ts +0 -2
  532. package/dist/persistence/drizzle.d.ts.map +0 -1
  533. package/dist/persistence/drizzle.js +0 -12
  534. package/dist/persistence/drizzle.js.map +0 -1
  535. package/dist/persistence/memory.d.ts +0 -2
  536. package/dist/persistence/memory.d.ts.map +0 -1
  537. package/dist/persistence/memory.js +0 -27
  538. package/dist/persistence/memory.js.map +0 -1
  539. package/dist/persistence/migrations.d.ts +0 -19
  540. package/dist/persistence/migrations.d.ts.map +0 -1
  541. package/dist/persistence/migrations.js +0 -13
  542. package/dist/persistence/migrations.js.map +0 -1
  543. package/dist/persistence/prisma.d.ts +0 -2
  544. package/dist/persistence/prisma.d.ts.map +0 -1
  545. package/dist/persistence/prisma.js +0 -25
  546. package/dist/persistence/prisma.js.map +0 -1
  547. package/dist/persistence/schema.d.ts +0 -63
  548. package/dist/persistence/schema.d.ts.map +0 -1
  549. package/dist/persistence/schema.js +0 -28
  550. package/dist/persistence/schema.js.map +0 -1
  551. package/dist/persistence/sql.d.ts +0 -3
  552. package/dist/persistence/sql.d.ts.map +0 -1
  553. package/dist/persistence/sql.js +0 -37
  554. package/dist/persistence/sql.js.map +0 -1
  555. package/dist/protocol/blocks.d.ts +0 -10
  556. package/dist/protocol/blocks.d.ts.map +0 -1
  557. package/dist/protocol/blocks.js +0 -26
  558. package/dist/protocol/blocks.js.map +0 -1
  559. package/dist/protocol/json.d.ts +0 -6
  560. package/dist/protocol/json.d.ts.map +0 -1
  561. package/dist/protocol/json.js +0 -6
  562. package/dist/protocol/json.js.map +0 -1
  563. package/dist/protocol/ndjson.d.ts +0 -3
  564. package/dist/protocol/ndjson.d.ts.map +0 -1
  565. package/dist/protocol/ndjson.js +0 -20
  566. package/dist/protocol/ndjson.js.map +0 -1
  567. package/dist/protocol/sse.d.ts +0 -7
  568. package/dist/protocol/sse.d.ts.map +0 -1
  569. package/dist/protocol/sse.js +0 -25
  570. package/dist/protocol/sse.js.map +0 -1
  571. package/dist/proxy/pool.d.ts +0 -9
  572. package/dist/proxy/pool.d.ts.map +0 -1
  573. package/dist/proxy/pool.js +0 -27
  574. package/dist/proxy/pool.js.map +0 -1
  575. package/dist/queue/idempotency.d.ts +0 -10
  576. package/dist/queue/idempotency.d.ts.map +0 -1
  577. package/dist/queue/idempotency.js +0 -13
  578. package/dist/queue/idempotency.js.map +0 -1
  579. package/dist/queue/persistent.d.ts +0 -14
  580. package/dist/queue/persistent.d.ts.map +0 -1
  581. package/dist/queue/persistent.js +0 -66
  582. package/dist/queue/persistent.js.map +0 -1
  583. package/dist/queue/queue.d.ts +0 -7
  584. package/dist/queue/queue.d.ts.map +0 -1
  585. package/dist/queue/queue.js +0 -55
  586. package/dist/queue/queue.js.map +0 -1
  587. package/dist/queue/saga.d.ts +0 -5
  588. package/dist/queue/saga.d.ts.map +0 -1
  589. package/dist/queue/saga.js +0 -20
  590. package/dist/queue/saga.js.map +0 -1
  591. package/dist/release/assets.d.ts +0 -144
  592. package/dist/release/assets.d.ts.map +0 -1
  593. package/dist/release/assets.js +0 -157
  594. package/dist/release/assets.js.map +0 -1
  595. package/dist/release/evidence.d.ts +0 -92
  596. package/dist/release/evidence.d.ts.map +0 -1
  597. package/dist/release/evidence.js +0 -148
  598. package/dist/release/evidence.js.map +0 -1
  599. package/dist/release/verify.d.ts +0 -12
  600. package/dist/release/verify.d.ts.map +0 -1
  601. package/dist/release/verify.js +0 -112
  602. package/dist/release/verify.js.map +0 -1
  603. package/dist/runners/chain.d.ts +0 -125
  604. package/dist/runners/chain.d.ts.map +0 -1
  605. package/dist/runners/chain.js +0 -95
  606. package/dist/runners/chain.js.map +0 -1
  607. package/dist/runners/health.d.ts +0 -36
  608. package/dist/runners/health.d.ts.map +0 -1
  609. package/dist/runners/health.js +0 -26
  610. package/dist/runners/health.js.map +0 -1
  611. package/dist/runners/heartbeat.d.ts +0 -23
  612. package/dist/runners/heartbeat.d.ts.map +0 -1
  613. package/dist/runners/heartbeat.js +0 -29
  614. package/dist/runners/heartbeat.js.map +0 -1
  615. package/dist/runners/inprocess.d.ts +0 -17
  616. package/dist/runners/inprocess.d.ts.map +0 -1
  617. package/dist/runners/inprocess.js +0 -20
  618. package/dist/runners/inprocess.js.map +0 -1
  619. package/dist/runners/scheduler.d.ts +0 -5
  620. package/dist/runners/scheduler.d.ts.map +0 -1
  621. package/dist/runners/scheduler.js +0 -19
  622. package/dist/runners/scheduler.js.map +0 -1
  623. package/dist/runtime/abort.d.ts +0 -8
  624. package/dist/runtime/abort.d.ts.map +0 -1
  625. package/dist/runtime/abort.js +0 -13
  626. package/dist/runtime/abort.js.map +0 -1
  627. package/dist/runtime/compatibility.d.ts +0 -37
  628. package/dist/runtime/compatibility.d.ts.map +0 -1
  629. package/dist/runtime/compatibility.js +0 -10
  630. package/dist/runtime/compatibility.js.map +0 -1
  631. package/dist/runtime/detect.d.ts +0 -13
  632. package/dist/runtime/detect.d.ts.map +0 -1
  633. package/dist/runtime/detect.js +0 -18
  634. package/dist/runtime/detect.js.map +0 -1
  635. package/dist/runtime/engine.d.ts +0 -20
  636. package/dist/runtime/engine.d.ts.map +0 -1
  637. package/dist/runtime/engine.js +0 -61
  638. package/dist/runtime/engine.js.map +0 -1
  639. package/dist/runtime/retry.d.ts +0 -19
  640. package/dist/runtime/retry.d.ts.map +0 -1
  641. package/dist/runtime/retry.js +0 -54
  642. package/dist/runtime/retry.js.map +0 -1
  643. package/dist/runtime/worker.d.ts +0 -10
  644. package/dist/runtime/worker.d.ts.map +0 -1
  645. package/dist/runtime/worker.js +0 -25
  646. package/dist/runtime/worker.js.map +0 -1
  647. package/dist/scrape/cache.d.ts +0 -45
  648. package/dist/scrape/cache.d.ts.map +0 -1
  649. package/dist/scrape/cache.js +0 -45
  650. package/dist/scrape/cache.js.map +0 -1
  651. package/dist/scrape/crawl.d.ts +0 -47
  652. package/dist/scrape/crawl.d.ts.map +0 -1
  653. package/dist/scrape/crawl.js +0 -114
  654. package/dist/scrape/crawl.js.map +0 -1
  655. package/dist/scrape/extract.d.ts +0 -63
  656. package/dist/scrape/extract.d.ts.map +0 -1
  657. package/dist/scrape/extract.js +0 -47
  658. package/dist/scrape/extract.js.map +0 -1
  659. package/dist/scrape/normalize.d.ts +0 -52
  660. package/dist/scrape/normalize.d.ts.map +0 -1
  661. package/dist/scrape/normalize.js +0 -102
  662. package/dist/scrape/normalize.js.map +0 -1
  663. package/dist/scrape/robots.d.ts +0 -37
  664. package/dist/scrape/robots.d.ts.map +0 -1
  665. package/dist/scrape/robots.js +0 -71
  666. package/dist/scrape/robots.js.map +0 -1
  667. package/dist/scrape/schema.d.ts +0 -23
  668. package/dist/scrape/schema.d.ts.map +0 -1
  669. package/dist/scrape/schema.js +0 -92
  670. package/dist/scrape/schema.js.map +0 -1
  671. package/dist/scrape/scraper.d.ts +0 -6
  672. package/dist/scrape/scraper.d.ts.map +0 -1
  673. package/dist/scrape/scraper.js +0 -46
  674. package/dist/scrape/scraper.js.map +0 -1
  675. package/dist/scrape/semantic.d.ts +0 -25
  676. package/dist/scrape/semantic.d.ts.map +0 -1
  677. package/dist/scrape/semantic.js +0 -27
  678. package/dist/scrape/semantic.js.map +0 -1
  679. package/dist/server/node.d.ts +0 -7
  680. package/dist/server/node.d.ts.map +0 -1
  681. package/dist/server/node.js.map +0 -1
  682. package/dist/sessions/file.d.ts +0 -25
  683. package/dist/sessions/file.d.ts.map +0 -1
  684. package/dist/sessions/file.js +0 -13
  685. package/dist/sessions/file.js.map +0 -1
  686. package/dist/sessions/replay.d.ts +0 -9
  687. package/dist/sessions/replay.d.ts.map +0 -1
  688. package/dist/sessions/replay.js +0 -70
  689. package/dist/sessions/replay.js.map +0 -1
  690. package/dist/sessions/store.d.ts +0 -25
  691. package/dist/sessions/store.d.ts.map +0 -1
  692. package/dist/sessions/store.js +0 -13
  693. package/dist/sessions/store.js.map +0 -1
  694. package/dist/storage/adapter.d.ts +0 -5
  695. package/dist/storage/adapter.d.ts.map +0 -1
  696. package/dist/storage/adapter.js +0 -11
  697. package/dist/storage/adapter.js.map +0 -1
  698. package/dist/storage/cache.d.ts +0 -23
  699. package/dist/storage/cache.d.ts.map +0 -1
  700. package/dist/storage/cache.js +0 -79
  701. package/dist/storage/cache.js.map +0 -1
  702. package/dist/storage/checksum.d.ts +0 -3
  703. package/dist/storage/checksum.d.ts.map +0 -1
  704. package/dist/storage/checksum.js +0 -19
  705. package/dist/storage/checksum.js.map +0 -1
  706. package/dist/storage/chunked.d.ts +0 -21
  707. package/dist/storage/chunked.d.ts.map +0 -1
  708. package/dist/storage/chunked.js +0 -67
  709. package/dist/storage/chunked.js.map +0 -1
  710. package/dist/storage/content.d.ts +0 -24
  711. package/dist/storage/content.d.ts.map +0 -1
  712. package/dist/storage/content.js +0 -44
  713. package/dist/storage/content.js.map +0 -1
  714. package/dist/storage/filehosting.d.ts +0 -2
  715. package/dist/storage/filehosting.d.ts.map +0 -1
  716. package/dist/storage/filehosting.js +0 -24
  717. package/dist/storage/filehosting.js.map +0 -1
  718. package/dist/storage/githubcontents.d.ts +0 -2
  719. package/dist/storage/githubcontents.d.ts.map +0 -1
  720. package/dist/storage/githubcontents.js +0 -29
  721. package/dist/storage/githubcontents.js.map +0 -1
  722. package/dist/storage/index.d.ts +0 -12
  723. package/dist/storage/index.d.ts.map +0 -1
  724. package/dist/storage/index.js +0 -12
  725. package/dist/storage/index.js.map +0 -1
  726. package/dist/storage/local.d.ts +0 -2
  727. package/dist/storage/local.d.ts.map +0 -1
  728. package/dist/storage/local.js +0 -72
  729. package/dist/storage/local.js.map +0 -1
  730. package/dist/storage/memory.d.ts +0 -6
  731. package/dist/storage/memory.d.ts.map +0 -1
  732. package/dist/storage/memory.js +0 -36
  733. package/dist/storage/memory.js.map +0 -1
  734. package/dist/storage/pool.d.ts +0 -95
  735. package/dist/storage/pool.d.ts.map +0 -1
  736. package/dist/storage/pool.js +0 -202
  737. package/dist/storage/pool.js.map +0 -1
  738. package/dist/storage/s3compatible.d.ts +0 -3
  739. package/dist/storage/s3compatible.d.ts.map +0 -1
  740. package/dist/storage/s3compatible.js +0 -70
  741. package/dist/storage/s3compatible.js.map +0 -1
  742. package/dist/storage/sync.d.ts +0 -47
  743. package/dist/storage/sync.d.ts.map +0 -1
  744. package/dist/storage/sync.js +0 -75
  745. package/dist/storage/sync.js.map +0 -1
  746. package/dist/surfaces/adapters.d.ts +0 -97
  747. package/dist/surfaces/adapters.d.ts.map +0 -1
  748. package/dist/surfaces/adapters.js +0 -50
  749. package/dist/surfaces/adapters.js.map +0 -1
  750. package/dist/surfaces/controls.d.ts +0 -18
  751. package/dist/surfaces/controls.d.ts.map +0 -1
  752. package/dist/surfaces/controls.js +0 -45
  753. package/dist/surfaces/controls.js.map +0 -1
  754. package/dist/surfaces/manifest.d.ts +0 -68
  755. package/dist/surfaces/manifest.d.ts.map +0 -1
  756. package/dist/surfaces/manifest.js +0 -42
  757. package/dist/surfaces/manifest.js.map +0 -1
  758. package/dist/surfaces/n8n.d.ts +0 -25
  759. package/dist/surfaces/n8n.d.ts.map +0 -1
  760. package/dist/surfaces/n8n.js +0 -31
  761. package/dist/surfaces/n8n.js.map +0 -1
  762. package/dist/surfaces/operations.d.ts +0 -32
  763. package/dist/surfaces/operations.d.ts.map +0 -1
  764. package/dist/surfaces/operations.js +0 -53
  765. package/dist/surfaces/operations.js.map +0 -1
  766. package/dist/surfaces/requirements.d.ts +0 -29
  767. package/dist/surfaces/requirements.d.ts.map +0 -1
  768. package/dist/surfaces/requirements.js +0 -50
  769. package/dist/surfaces/requirements.js.map +0 -1
  770. package/dist/surfaces/targets.d.ts +0 -196
  771. package/dist/surfaces/targets.d.ts.map +0 -1
  772. package/dist/surfaces/targets.js +0 -27
  773. package/dist/surfaces/targets.js.map +0 -1
  774. package/dist/webhook/delivery.d.ts +0 -18
  775. package/dist/webhook/delivery.d.ts.map +0 -1
  776. package/dist/webhook/delivery.js +0 -36
  777. package/dist/webhook/delivery.js.map +0 -1
  778. package/dist/webhook/receiver.d.ts +0 -26
  779. package/dist/webhook/receiver.d.ts.map +0 -1
  780. package/dist/webhook/receiver.js +0 -24
  781. package/dist/webhook/receiver.js.map +0 -1
  782. package/dist/webhook/signature.d.ts +0 -3
  783. package/dist/webhook/signature.d.ts.map +0 -1
  784. package/dist/webhook/signature.js +0 -7
  785. package/dist/webhook/signature.js.map +0 -1
  786. package/dist/workflow/manifest.d.ts +0 -22
  787. package/dist/workflow/manifest.d.ts.map +0 -1
  788. package/dist/workflow/manifest.js +0 -21
  789. package/dist/workflow/manifest.js.map +0 -1
  790. package/dist/workflow/registry.d.ts +0 -7
  791. package/dist/workflow/registry.d.ts.map +0 -1
  792. package/dist/workflow/registry.js +0 -18
  793. package/dist/workflow/registry.js.map +0 -1
  794. package/dist/workflow/templates.d.ts +0 -6
  795. package/dist/workflow/templates.d.ts.map +0 -1
  796. package/dist/workflow/templates.js +0 -18
  797. package/dist/workflow/templates.js.map +0 -1
  798. package/dist/workflow/triggers.d.ts +0 -64
  799. package/dist/workflow/triggers.d.ts.map +0 -1
  800. package/dist/workflow/triggers.js +0 -99
  801. package/dist/workflow/triggers.js.map +0 -1
  802. /package/{extension/README.md → docs/extension.md} +0 -0
@@ -0,0 +1,810 @@
1
+ /**
2
+ * quantum.ts — classical quantum-simulation layer for saddle v18.
3
+ *
4
+ * the module is a 100 percent classical software statevector simulator:
5
+ * no hardware, no photons, no qpu. the engine "supports" quantum the same
6
+ * way it virtualizes cores, memory and gpus — as one more virtualization
7
+ * layer: every "qubit" is a pair of float64 lanes inside a 2^n amplitude
8
+ * vector (interleaved re/im), every "gate" is an in-place index-pair
9
+ * transformation and every "measurement" is a crypto-seeded collapse of
10
+ * that vector.
11
+ *
12
+ * contexts (22):
13
+ * 01 version anchors (algorithm dates, simulator envelope)
14
+ * 02 error catcher (quantumerror envelope)
15
+ * 03 complex math kernel (2x2 unitary type + gate matrices)
16
+ * 04 quantumsim statevector core (1-20 qubits, Disposable)
17
+ * 05 multi-qubit gate kernels (cnot, cz, toffoli, swap, ccz)
18
+ * 06 canonical circuits (bellstate, ghzstate)
19
+ * 07 grover search (grover2 provable, grover3 statistical)
20
+ * 08 deutsch oracle discrimination (deutsch)
21
+ * 09 quantum teleportation sketch (qteleport)
22
+ * 10 bb84 stations (alice, bob, eve over a simulated channel)
23
+ * 11 bb84 protocol runner (runbb84: sifting, qber, intercept detection)
24
+ * 12 e91 entangled pairs + chsh (rune91)
25
+ * 13 qrng (quantuminspiredrandom, honest anu fallback)
26
+ * 14 dnavault codec (goldman 2013 ternary rotation, framing, strands)
27
+ * 15 dnavault decode (checksum verification, redundancy, roundtrip)
28
+ * 16 dnavault capacity planner (215 pb/g, planodefault)
29
+ * 17 optical 5d quartz planner (360 tb/disc, femtosecond write plan)
30
+ * 18 holographic note (microsoft hsd) and storage compare
31
+ * 19 qram bucket brigade (giovannetti 2008, o(log n) routing, n=8)
32
+ * 20 shor plan (honest: theoretical 7-qubit circuit, never executed)
33
+ * 21 registry (quantumregistry capability catalog)
34
+ * 22 self check (quantumselfcheck: every claim, machine-verified)
35
+ *
36
+ * rules: lowercase identifiers, english jsdoc third person, no emoji,
37
+ * try/catch catcher on every fallible path, node:* built-ins only
38
+ * (node:crypto for all randomness), zero runtime dependencies, no
39
+ * filesystem, network or process coupling beyond the optional,
40
+ * always-fallback anu qrng fetch. ascii only.
41
+ */
42
+ /**
43
+ * frozen quantum layer anchors. every algorithm keeps its literature
44
+ * year so the registry can cite primary sources instead of folklore.
45
+ */
46
+ export declare const quantumversions: {
47
+ readonly date: '2026-08-23';
48
+ readonly simulator: 'statevector';
49
+ readonly precision: 'float64 interleaved re/im';
50
+ readonly maxqubits: 20;
51
+ readonly amplitudelanes: 2097152;
52
+ readonly grover: '1996 stoc';
53
+ readonly deutschjozsa: '1992 proc r soc a';
54
+ readonly bb84: '1984 bangalore proceedings';
55
+ readonly e91: '1991 prl 67 661';
56
+ readonly teleportation: '1993 prl 70 1895';
57
+ readonly qram: '2008 prl 100 160501';
58
+ };
59
+ /**
60
+ * quantum layer failure envelope. every guard in this module throws it
61
+ * instead of a bare error so callers can branch on the code.
62
+ */
63
+ export declare class quantumerror extends Error {
64
+ readonly code: string;
65
+ readonly detail?: string;
66
+ constructor(params: {
67
+ code: string;
68
+ message: string;
69
+ detail?: string;
70
+ });
71
+ }
72
+ /**
73
+ * a 2x2 complex unitary with rows and columns interleaved as
74
+ * [u00re, u00im, u01re, u01im, u10re, u10im, u11re, u11im].
75
+ * gate matrices are plain float tuples so the hot loop stays monomorphic.
76
+ */
77
+ export type gate2x2 = readonly [number, number, number, number, number, number, number, number];
78
+ /** hadamard matrix ((1/sqrt 2) [[1,1],[1,1]]). */
79
+ export declare const hmatrix: gate2x2;
80
+ /** pauli x matrix [[0,1],[1,0]]. */
81
+ export declare const xmatrix: gate2x2;
82
+ /** pauli y matrix [[0,-i],[i,0]]. */
83
+ export declare const ymatrix: gate2x2;
84
+ /** pauli z matrix diag(1,-1). */
85
+ export declare const zmatrix: gate2x2;
86
+ /** phase gate s = diag(1, i). */
87
+ export declare const smatrix: gate2x2;
88
+ /** inverse phase gate sdg = diag(1, -i). */
89
+ export declare const sdgmatrix: gate2x2;
90
+ /** t gate = diag(1, exp(i pi/4)). */
91
+ export declare const tmatrix: gate2x2;
92
+ /** inverse t gate = diag(1, exp(-i pi/4)). */
93
+ export declare const tdgmatrix: gate2x2;
94
+ /**
95
+ * builds the rotation-x matrix rx(theta) =
96
+ * [[cos(t/2), -i sin(t/2)], [-i sin(t/2), cos(t/2)]].
97
+ */
98
+ export declare function rxmatrix(theta: number): gate2x2;
99
+ /**
100
+ * builds the rotation-y matrix ry(theta) =
101
+ * [[cos(t/2), -sin(t/2)], [sin(t/2), cos(t/2)]]; ry(2a)|0> equals the
102
+ * polarization state cos(a)|0> + sin(a)|1>, which the e91 context uses
103
+ * to prepare and measure at arbitrary analyzer angles.
104
+ */
105
+ export declare function rymatrix(theta: number): gate2x2;
106
+ /**
107
+ * builds the rotation-z matrix rz(theta) = diag(e^{-i t/2}, e^{i t/2}).
108
+ */
109
+ export declare function rzmatrix(theta: number): gate2x2;
110
+ /**
111
+ * pure-software statevector simulator. the state is one Float64Array of
112
+ * 2 * 2^n lanes holding interleaved real and imaginary parts; qubit q is
113
+ * bit q of the basis index (qubit 0 is the least significant bit), so
114
+ * for a single-qubit gate on qubit q the kernel iterates every index i
115
+ * with bit q = 0, takes j = i | 2^q and replaces the pair by
116
+ * u @ [amp(i), amp(j)] exactly as specified. the class is Disposable and
117
+ * meant to be used with `using` so amplitude memory is logically freed
118
+ * even though the gc owns it.
119
+ */
120
+ export declare class quantumsim implements Disposable {
121
+ #private;
122
+ constructor(nqubits: number);
123
+ /** number of qubits of the register. */
124
+ get nqubits(): number;
125
+ /** hilbert space dimension 2^n. */
126
+ get dim(): number;
127
+ /** true once Symbol.dispose released the state. */
128
+ get disposed(): boolean;
129
+ /** hadamard on qubit q. */
130
+ h(q: number): this;
131
+ /** pauli x (bit flip) on qubit q. */
132
+ x(q: number): this;
133
+ /** pauli y on qubit q. */
134
+ y(q: number): this;
135
+ /** pauli z (phase flip) on qubit q. */
136
+ z(q: number): this;
137
+ /** phase gate s = sqrt(z) on qubit q. */
138
+ s(q: number): this;
139
+ /** inverse phase gate on qubit q. */
140
+ sdg(q: number): this;
141
+ /** t = pi/8 gate on qubit q. */
142
+ t(q: number): this;
143
+ /** inverse t gate on qubit q. */
144
+ tdg(q: number): this;
145
+ /** rotation-x by theta radians on qubit q. */
146
+ rx(theta: number, q: number): this;
147
+ /** rotation-y by theta radians on qubit q. */
148
+ ry(theta: number, q: number): this;
149
+ /** rotation-z by theta radians on qubit q. */
150
+ rz(theta: number, q: number): this;
151
+ /**
152
+ * cnot: for every index i with control bit 1 and target bit 0,
153
+ * swaps amplitudes i and i|2^target; each pair is visited once.
154
+ */
155
+ cnot(control: number, target: number): this;
156
+ /**
157
+ * cz: flips the sign of every amplitude whose control and target
158
+ * bits are both 1.
159
+ */
160
+ cz(control: number, target: number): this;
161
+ /**
162
+ * toffoli (ccnot): swaps amplitude pairs only when both control bits
163
+ * are 1 and the target bit is 0.
164
+ */
165
+ toffoli(control1: number, control2: number, target: number): this;
166
+ /**
167
+ * swap: exchanges qubits a and b by visiting each index pair once
168
+ * (bit a = 0 with bit b = 1 maps to its complement bit a = 1, bit
169
+ * b = 0), so no pair is touched twice.
170
+ */
171
+ swap(a: number, b: number): this;
172
+ /**
173
+ * measures qubit q in the computational basis, collapsing the state.
174
+ * returns the observed classical bit.
175
+ */
176
+ measure(q: number): 0 | 1;
177
+ /**
178
+ * measures the full register in the computational basis and returns
179
+ * the observed basis index (qubit 0 in bit 0).
180
+ */
181
+ measureall(): number;
182
+ /**
183
+ * returns the [p0, p1] distribution of qubit q without collapsing;
184
+ * p1 = sum of |amplitude|^2 over indices with bit q set.
185
+ */
186
+ probs(q: number): [number, number];
187
+ /**
188
+ * returns the full |amplitude|^2 distribution over all 2^n basis
189
+ * states as a fresh Float64Array (index order: qubit 0 in bit 0).
190
+ */
191
+ probabilities(): Float64Array;
192
+ /** returns the complex amplitude of one basis index as [re, im]. */
193
+ amplitude(index: number): readonly [number, number];
194
+ /** returns a detached readonly snapshot copy of the state lanes. */
195
+ state(): Readonly<Float64Array>;
196
+ /** euclidean norm of the state vector (should stay within 1e-12 of 1). */
197
+ norm(): number;
198
+ /** renormalizes the state to unit norm (fixes float drift). */
199
+ normalize(): this;
200
+ /** resets the register to |0...0>. */
201
+ reset(): this;
202
+ /** releases the amplitude lanes; any further gate call throws. */
203
+ [Symbol.dispose](): void;
204
+ }
205
+ /**
206
+ * applies cnot(control, target) to sim; functional spelling of the
207
+ * quantumsim method for composition outside the class.
208
+ */
209
+ export declare function cnot(sim: quantumsim, control: number, target: number): quantumsim;
210
+ /**
211
+ * applies cz(control, target) to sim; the grover oracle for two qubits
212
+ * is exactly this gate on the |11> amplitude.
213
+ */
214
+ export declare function cz(sim: quantumsim, control: number, target: number): quantumsim;
215
+ /**
216
+ * applies toffoli(control1, control2, target) to sim, the universal
217
+ * reversible gate of toffoli 1980 as used in every compiled oracle.
218
+ */
219
+ export declare function toffoli(sim: quantumsim, control1: number, control2: number, target: number): quantumsim;
220
+ /**
221
+ * applies swap(a, b) to sim.
222
+ */
223
+ export declare function swap(sim: quantumsim, a: number, b: number): quantumsim;
224
+ /**
225
+ * ccz: three-qubit phase flip, composed as toffoli conjugated by
226
+ * hadamard on the target; used as the grover oracle and diffuser core.
227
+ */
228
+ export declare function ccz(sim: quantumsim, control1: number, control2: number, target: number): quantumsim;
229
+ /**
230
+ * proof bundle for a canonical circuit: the ready simulator plus the
231
+ * documented expected distribution so callers can assert outcomes.
232
+ */
233
+ export type circuitproof = {
234
+ readonly sim: quantumsim;
235
+ readonly name: string;
236
+ readonly expectedprobs: readonly number[];
237
+ readonly reference: string;
238
+ readonly note: string;
239
+ };
240
+ /**
241
+ * builds the bell state (|00> + |11>)/sqrt(2) with h(0) then cnot(0,1);
242
+ * measurement of either qubit is a perfect coin and both always agree.
243
+ * expected distribution: [0.5, 0, 0.5, 0].
244
+ * reference: einstein-podolsky-rosen 1935; bell 1964; chapter 1 of
245
+ * nielsen and chuang, quantum computation and quantum information
246
+ * (2000).
247
+ */
248
+ export declare function bellstate(): circuitproof;
249
+ /**
250
+ * builds an n-qubit ghz state (|0...0> + |1...1>)/sqrt(2) by h(0) plus
251
+ * a cnot fanout; expected distribution carries mass 0.5 on index 0 and
252
+ * index 2^n - 1 only. reference: greenberger-horne-zeilinger 1989.
253
+ */
254
+ export declare function ghzstate(n?: number): circuitproof;
255
+ /**
256
+ * grover2: exhaustive-search winner |11> on 2 qubits with exactly one
257
+ * oracle call. the circuit is the task-pinned sequence
258
+ * h,h -> cz -> h,h -> x,x -> cz -> h,h whose unique fixed point is
259
+ * amplitude -1 on |11>, so prob(11) = 1 up to 1e-12 float noise.
260
+ * expected distribution: [0, 0, 0, 1].
261
+ * reference: grover, a fast quantum mechanical algorithm for database
262
+ * search, stoc 1996 (arxiv:quant-ph/9605043).
263
+ */
264
+ export declare function grover2(): circuitproof;
265
+ /**
266
+ * grover3: search over 8 items for winner |111> with two iterations of
267
+ * oracle ccz + diffuser (h x3, x x3, ccz, x x3, h x3). theory gives
268
+ * success sin^2(5 * asin(1/sqrt 8)) = 0.9461, comfortably above 0.9.
269
+ * reference: grover 1996; boyer, brassard, hoefer, tapp 1998 iteration
270
+ * counting for m = 1 marked item of n = 8.
271
+ */
272
+ export declare function grover3(): circuitproof;
273
+ /**
274
+ * deutsch verdict of the single-bit oracle f: 'constant' when f(0) =
275
+ * f(1), 'balanced' when f(0) != f(1); one oracle call decides it.
276
+ */
277
+ export type deutschverdict = 'constant' | 'balanced';
278
+ /**
279
+ * deutsch algorithm on 2 qubits (input qubit 0, ancilla qubit 1 in
280
+ * |->). the oracle is built from the truth table of f exactly as the
281
+ * four possible (x, y) -> (x, y xor f(x)) unitaries: identity, x on
282
+ * the ancilla, cnot(0,1) for f(x) = x, and x + cnot for f(x) = not x.
283
+ * phase kickback leaves qubit 0 in |0> for constant f and |1> for
284
+ * balanced f, so a single measurement decides the promise problem.
285
+ * reference: deutsch 1985; deutsch and jozsa, rapid solution of
286
+ * problems by quantum computation, proc r soc lond a 439, 553 (1992).
287
+ */
288
+ export declare function deutsch(f: (x: 0 | 1) => 0 | 1): {
289
+ sim: quantumsim;
290
+ verdict: deutschverdict;
291
+ measured: 0 | 1;
292
+ expected: deutschverdict;
293
+ reference: string;
294
+ };
295
+ /**
296
+ * qteleport: teleports the state of qubit 0 to qubit 2 through a bell
297
+ * pair on qubits 1 and 2 (h(1), cnot(1,2)), the bell-basis measurement
298
+ * cnot(0,1) + h(0), then the classical corrections x/z on qubit 2
299
+ * conditioned on the two outcomes. the simulator runs the whole loop so
300
+ * the fidelity is exactly 1 for any of the three prepared inputs; the
301
+ * fidelity is read off the two amplitudes that survive the bell
302
+ * measurement (index m1*2 + m0 and its +4 partner on qubit 2).
303
+ * reference: bennett, brassard, crepeau, jozsa, peres, wootters,
304
+ * teleporting an unknown quantum state via dual classical and
305
+ * einstein-podolsky-rosen channels, prl 70, 1895 (1993).
306
+ */
307
+ export declare function qteleport(input?: 'zero' | 'one' | 'plus'): {
308
+ sim: quantumsim;
309
+ outcome0: 0 | 1;
310
+ outcome1: 0 | 1;
311
+ fidelity: number;
312
+ input: 'zero' | 'one' | 'plus';
313
+ reference: string;
314
+ };
315
+ /**
316
+ * basis 0 is rectilinear (z, states |0>/|1>) and basis 1 is diagonal
317
+ * (x, states |+>/|->); the mapping matches the polarization bases of
318
+ * the 1984 protocol.
319
+ */
320
+ export type bb84basis = 0 | 1;
321
+ /**
322
+ * alice station: draws random key bits and random bases from
323
+ * node:crypto and prepares one 1-qubit quantumsim photon per bit
324
+ * (x for bit 1, extra h when the basis is diagonal).
325
+ */
326
+ export declare class alice {
327
+ #private;
328
+ constructor(count: number);
329
+ /** alice's raw key bits. */
330
+ get bits(): readonly number[];
331
+ /** alice's basis string (0 rectilinear, 1 diagonal). */
332
+ get bases(): readonly number[];
333
+ /**
334
+ * prepares the photon burst; each photon is a real 1-qubit state so
335
+ * the channel, eve and bob all act on amplitudes, not on labels.
336
+ */
337
+ prepare(): quantumsim[];
338
+ }
339
+ /**
340
+ * bob station: measures each incoming photon in his own random bases
341
+ * (h before the z measurement when diagonal), collapsing the photon.
342
+ */
343
+ export declare class bob {
344
+ #private;
345
+ constructor(count: number);
346
+ /** bob's basis string. */
347
+ get bases(): readonly number[];
348
+ /** bob's raw measurement outcomes. */
349
+ get outcomes(): readonly number[];
350
+ /**
351
+ * measures the whole burst and stores the classical outcomes;
352
+ * measuring a diagonal-basis photon in the rectilinear basis
353
+ * genuinely yields a coin flip, which is where intercept-resend
354
+ * damage shows up.
355
+ */
356
+ measure(photons: readonly quantumsim[]): readonly number[];
357
+ }
358
+ /**
359
+ * eve station: intercept-resend attacker. she measures every photon in
360
+ * her own random basis (collapsing it) and resends a fresh photon
361
+ * prepared in that basis with the bit she saw. on sifted bits where
362
+ * alice and bob used the same basis, eve chose the wrong basis half
363
+ * the time and bob then errs half of those, so the qber lands at 25
364
+ * percent against 0 percent on a clean channel.
365
+ * reference: the intercept-resend attack is exercise material of every
366
+ * bb84 treatment since bennett-brassard 1984.
367
+ */
368
+ export declare class eve {
369
+ #private;
370
+ /** bases eve used (for audits). */
371
+ get bases(): readonly number[];
372
+ /** bits eve extracted (for audits). */
373
+ get bits(): readonly number[];
374
+ /** taps the burst and returns the resent photons. */
375
+ intercept(photons: readonly quantumsim[]): quantumsim[];
376
+ }
377
+ /**
378
+ * bb84 quantum channel: a photon pipeline that alice fills, an optional
379
+ * eve taps (counted), and bob drains. no network, no localhost — the
380
+ * channel is an in-memory queue standing in for fiber.
381
+ */
382
+ export declare class bb84channel {
383
+ #private;
384
+ /** sends a photon burst onto the channel. */
385
+ send(photons: readonly quantumsim[]): void;
386
+ /**
387
+ * taps the channel: the operator receives the in-flight burst and its
388
+ * return value replaces it (intercept-resend); taps are counted.
389
+ */
390
+ tap(operator: (photons: readonly quantumsim[]) => quantumsim[]): quantumsim[];
391
+ /** drains the channel for the receiver. */
392
+ receive(): quantumsim[];
393
+ /** number of taps observed on the channel (informational). */
394
+ get tapped(): number;
395
+ }
396
+ /**
397
+ * runbb84 result: the sifted keys (sample bits removed), the
398
+ * full-channel qber, and the sampling-based eavesdropper verdict.
399
+ */
400
+ export type bb84result = {
401
+ readonly keyalice: readonly number[];
402
+ readonly keybob: readonly number[];
403
+ readonly qber: number;
404
+ readonly detected: boolean;
405
+ readonly siftedlen: number;
406
+ readonly sampledlen: number;
407
+ readonly sampledqber: number;
408
+ readonly threshold: number;
409
+ readonly reference: string;
410
+ };
411
+ /**
412
+ * runs the complete bb84 flow over the simulated channel: alice
413
+ * prepares, the optional eve taps, bob measures, both sides sift on
414
+ * equal bases, the qber is computed over the full sifted key and the
415
+ * detection verdict comes from comparing a public sample of up to 128
416
+ * sifted bits (abort threshold 11 percent, the one-way bb84
417
+ * reconciliation bound of the shor-preskill lineage).
418
+ * reference: bennett and brassard, quantum cryptography: public key
419
+ * distribution and coin tossing, proc ieee int conf on computers,
420
+ * systems and signal processing, bangalore 1984, pp. 175-179.
421
+ */
422
+ export declare function runbb84(options?: {
423
+ eve?: boolean;
424
+ bits?: number;
425
+ }): bb84result;
426
+ /**
427
+ * e91 run result: the chsh s value, the key bits extracted from
428
+ * matched analyzer settings and the eavesdropper verdict.
429
+ */
430
+ export type e91result = {
431
+ readonly s: number;
432
+ readonly classicalbound: number;
433
+ readonly quantumbound: number;
434
+ readonly detected: boolean;
435
+ readonly keylen: number;
436
+ readonly qber: number;
437
+ readonly pairs: number;
438
+ readonly chshpairs: number;
439
+ readonly reference: string;
440
+ };
441
+ /**
442
+ * rune91: ekert-1991 entanglement-based key distribution on |phi+>
443
+ * pairs. each round is half the time a key round (both parties pick
444
+ * 0 or 45 degrees; equal angles give perfectly correlated bits on a
445
+ * clean source) and half the time a chsh round (alice 0 or 45 degrees,
446
+ * bob 22.5 or 67.5 degrees). the chsh statistic
447
+ * s = e(0,22.5) - e(0,67.5) + e(45,22.5) + e(45,67.5) converges to
448
+ * 2 sqrt(2) = 2.8284 for the entangled source and cannot exceed the
449
+ * classical bound 2 once eve collapses the pairs, which is exactly the
450
+ * e91 security test (bell-inequality violation as the eavesdropper
451
+ * detector). an intercept-resend eve also pushes the matched-angle key
452
+ * qber to 25 percent.
453
+ * reference: ekert, quantum cryptography based on bell's theorem,
454
+ * prl 67, 661 (1991); clauser-horne-shimony-holt 1969 prl 23 880;
455
+ * bell 1964; aspect, dalibard, roger 1982.
456
+ */
457
+ export declare function rune91(options?: {
458
+ eve?: boolean;
459
+ pairs?: number;
460
+ }): e91result;
461
+ /**
462
+ * quantuminspiredrandom: draws count integers in [min, max) from the
463
+ * node crypto CSPRNG via randomInt (node rejection-samples internally,
464
+ * so the stream is unbiased). this is a classical CSPRNG standing in
465
+ * for a QRNG photon source; the API shape matches hardware QRNG
466
+ * services (count + integer range in, uniform integers out) so the
467
+ * integration seam is already quantum-ready. no physics is claimed.
468
+ */
469
+ export declare function quantuminspiredrandom(count: number, options?: {
470
+ min?: number;
471
+ max?: number;
472
+ }): number[];
473
+ /**
474
+ * anuqrng: optional asynchronous fetch of the australian national
475
+ * university quantum random numbers service (api.quantumnumbers.io,
476
+ * successor of qrng.anu.edu.au), which digitizes vacuum fluctuations.
477
+ * the planner is honest: without network egress or an api key the call
478
+ * fails fast (abort timeout 2500 ms default) and the function falls
479
+ * back to the same CSPRNG as quantuminspiredrandom, reporting
480
+ * source: 'csprng'. anu values are 64-bit unsigned integers folded
481
+ * into the requested range with one modulo (bias below 2^-32 for any
482
+ * practical span, documented here rather than hidden).
483
+ */
484
+ export declare function anuqrng(count: number, options?: {
485
+ apikey?: string;
486
+ timeoutms?: number;
487
+ min?: number;
488
+ max?: number;
489
+ }): Promise<{
490
+ values: number[];
491
+ source: 'anu' | 'csprng';
492
+ note: string;
493
+ }>;
494
+ /**
495
+ * convenience bytes draw used by the self check and available to
496
+ * integrators: crypto.randomBytes surfaced under the qrng banner with
497
+ * the same honesty note as quantuminspiredrandom.
498
+ */
499
+ export declare function quantuminspiredbytes(count: number): Uint8Array;
500
+ /**
501
+ * dnavault codec constants: 4 strands addressed by blockindex mod 4,
502
+ * each block synthesized twice (on its home strand and the next one)
503
+ * so decoding survives the loss of any single strand; every byte maps
504
+ * to 6 ternary digits (3^6 = 729 > 256) and every digit to one
505
+ * nucleotide through the goldman rotation next = (digit + 1 + previous)
506
+ * mod 4, which makes consecutive repeats impossible (homopolymer run
507
+ * length 1, stricter than the standard run-length <= 3 synthesis
508
+ * constraint). reference: goldman et al., towards practical,
509
+ * high-capacity, low-maintenance information storage in synthesized
510
+ * dna, nature 494, 77-80 (2013), doi:10.1038/nature11875.
511
+ */
512
+ export declare const dnavaultspec: {
513
+ readonly strandcount: 4;
514
+ readonly redundancy: 2;
515
+ readonly blockpayloadbytes: 32;
516
+ readonly blockframebytes: 35;
517
+ readonly nucleotidesperblock: 210;
518
+ readonly tritsperbyte: 6;
519
+ readonly maxinputbytes: 65536;
520
+ readonly homopolymerrunmax: 1;
521
+ readonly rule: 'next = (digit + 1 + previous) mod 4, digit in {0,1,2}';
522
+ readonly reference: 'goldman et al. 2013 nature 494 77-80 doi:10.1038/nature11875';
523
+ };
524
+ /**
525
+ * dnavaultencode result: the four strand oligo strings, the block
526
+ * count and the nucleotide accounting for the capacity planner.
527
+ */
528
+ export type dnavaultencoderesult = {
529
+ readonly strands: readonly string[];
530
+ readonly blocks: number;
531
+ readonly oligos: number;
532
+ readonly nucleotides: number;
533
+ readonly redundancy: number;
534
+ readonly homopolymerrunmax: number;
535
+ readonly reference: string;
536
+ };
537
+ /**
538
+ * encodes bytes into four dna strands with real goldman-2013 rules:
539
+ * a 4-byte big-endian length prefix, 32-byte payload blocks framed as
540
+ * [index u16 be][payload 32][checksum u8 of index + payload], ternary
541
+ * rotation encoding per byte, dual-strand placement (blockindex mod 4
542
+ * and (blockindex + 1) mod 4). the archive planner guard caps input at
543
+ * 64 kib; real synthesis runs are planned, not executed, here.
544
+ */
545
+ export declare function dnavaultencode(bytes: Uint8Array): dnavaultencoderesult;
546
+ /**
547
+ * decodes strands back to bytes: every 210-nucleotide oligo is
548
+ * de-rotated to a 35-byte frame, checksum-verified, deduplicated by
549
+ * block index and reassembled in order. oligos failing checksum or
550
+ * carrying invalid letters are dropped silently because every block
551
+ * exists on two strands; a genuinely missing index throws.
552
+ */
553
+ export declare function dnavaultdecode(strands: readonly string[]): Uint8Array;
554
+ /**
555
+ * dnavault capacity anchors: the widely quoted 215 petabytes per gram
556
+ * of dna figure (church 2012 science era synthesis estimates, echoed
557
+ * by the nature 2013 news coverage around goldman et al.) anchors the
558
+ * physical planner; the codec rates above are what this module
559
+ * actually charges.
560
+ */
561
+ export declare const dnacapacityspec: {
562
+ readonly bytespergram: 215000000000000000;
563
+ readonly densityquote: '215 petabytes per gram of dna';
564
+ readonly densityreference: 'church, gao, kosuri 2012 science 337 1628 era estimates; nature news 2013';
565
+ readonly synthesispitch: 'archive planner only; no oligo is ordered or synthesized';
566
+ };
567
+ /**
568
+ * dnavault capacity estimate for an archive of sizebytes: dna grams at
569
+ * the 215 pb/g density, oligo and nucleotide counts at this codec's
570
+ * real rates, and the storage overhead ratio.
571
+ */
572
+ export declare function dnacapacity(sizebytes: number): {
573
+ grams: number;
574
+ oligos: number;
575
+ nucleotides: number;
576
+ overhead: number;
577
+ density: string;
578
+ reference: string;
579
+ };
580
+ /**
581
+ * planodefault: the default dna archive plan for a payload of
582
+ * sizebytes — dna mass in grams (215 pb/g density), number of oligo
583
+ * strands to synthesize, and the codec overhead fraction. this is the
584
+ * planner entry point for the storage tier; nothing is written.
585
+ */
586
+ export declare function planodefault(sizebytes: number): {
587
+ grams: number;
588
+ strands: number;
589
+ overhead: number;
590
+ storage: string;
591
+ reference: string;
592
+ };
593
+ /**
594
+ * opticalvault anchors: 5d femtosecond-laser nanostructuring of fused
595
+ * quartz as demonstrated by the university of southampton
596
+ * optoelectronics research centre (zhang, kazansky et al., 2013-2016):
597
+ * 360 tb per disc headline capacity, survival to 1000 c and the quoted
598
+ * 13.8-billion-year room-temperature stability. the five dimensions
599
+ * are three spatial coordinates plus nanograting orientation and
600
+ * retardance. the write parameters below are planning defaults for the
601
+ * femtosecond pass, not device constants.
602
+ */
603
+ export declare const opticalvaultspec: {
604
+ readonly bytesperdisc: 360000000000000;
605
+ readonly layersperdisc: 100;
606
+ readonly logicalbitsperdot: 4;
607
+ readonly redundancycopies: 3;
608
+ readonly stabilityc: 1000;
609
+ readonly lifetimeyearsroom: 13800000000;
610
+ readonly pulsedurationfs: 280;
611
+ readonly wavelengthnm: 1030;
612
+ readonly layerspacingum: 4.5;
613
+ readonly medium: 'fused quartz';
614
+ readonly dimensions: 'x, y, z + nanograting orientation + retardance';
615
+ readonly reference: 'zhang, gecavicius, beresna, kazansky 2013 cleo; southampton orc 2013-2016 (360 tb/disc, 13.8 billion years at room temperature)';
616
+ };
617
+ /**
618
+ * opticalplan: recording plan for a 5d quartz archive of sizebytes:
619
+ * disc count at 360 tb per disc with three-copy redundancy, layer and
620
+ * nanograting dot counts at 4 logical bits per dot, and the
621
+ * femtosecond write pass description. pure planner output.
622
+ */
623
+ export declare function opticalplan(sizebytes: number): {
624
+ discs: number;
625
+ layers: number;
626
+ dots: number;
627
+ redundancy: number;
628
+ lifetimeyearsroom: number;
629
+ stabilityc: number;
630
+ writeplan: {
631
+ pulsedurationfs: number;
632
+ wavelengthnm: number;
633
+ layerspacingum: number;
634
+ dimensions: string;
635
+ };
636
+ reference: string;
637
+ note: string;
638
+ };
639
+ /**
640
+ * holographic storage note for the storage tier compare: microsoft
641
+ * research announced the holographic storage device (hsd) program in
642
+ * 2024 — page-oriented holograms in a photosensitive wafer cartridge,
643
+ * about 1.4 tb per 12-centimeter disc form factor with a multi-terabyte
644
+ * roadmap. this module keeps it as a comparison note only; the
645
+ * concrete planners shipped here are dna and 5d quartz.
646
+ */
647
+ export declare const holographicnote: {
648
+ readonly vendor: 'microsoft research';
649
+ readonly program: 'hsd (holographic storage device), announced 2024';
650
+ readonly capacity: 'about 1.4 tb per 12-cm disc, multi-terabyte roadmap';
651
+ readonly medium: 'photosensitive holographic wafer cartridges';
652
+ readonly position: 'comparison note; no planner shipped for this tier';
653
+ };
654
+ /**
655
+ * storagecompare: one-line planner comparison across the three
656
+ * quantum-adjacent storage tiers this module knows about.
657
+ */
658
+ export declare function storagecompare(sizebytes: number): readonly {
659
+ tier: string;
660
+ units: string;
661
+ massorunits: string;
662
+ lifetime: string;
663
+ reference: string;
664
+ }[];
665
+ /**
666
+ * qramcell: one bucket-brigade memory slot addressed by its index.
667
+ */
668
+ export interface qramcell {
669
+ readonly address: number;
670
+ readonly value: number;
671
+ }
672
+ /**
673
+ * qramreadresult: the value plus the routing trace that proves the
674
+ * o(log n) switch activity of the bucket-brigade tree.
675
+ */
676
+ export interface qramreadresult {
677
+ readonly address: number;
678
+ readonly value: number;
679
+ readonly hops: number;
680
+ readonly path: readonly number[];
681
+ readonly switchesactive: number;
682
+ readonly classicalwritelines: number;
683
+ }
684
+ /**
685
+ * qrambucketbrigade: classical simulation of the giovannetti-lloyd-
686
+ * maccone bucket-brigade qram. a classical ram read energizes n word
687
+ * lines; the bucket brigade routes one bus down a binary switch tree so
688
+ * only log2(n) switches per read must flip (and, in the quantum
689
+ * version, only o(log n) qubits must be active, which is what makes
690
+ * quantum-addressed lookup of a superposition affordable). the switch
691
+ * tree is simulated hop by hop and the read result carries the trace.
692
+ * reference: giovannetti, lloyd, maccone, quantum random access memory,
693
+ * prl 100, 160501 (2008); giovannetti, lloyd, maccone, architectures
694
+ * for a quantum random access memory, pra 78, 052310 (2008).
695
+ */
696
+ export declare class qrambucketbrigade {
697
+ #private;
698
+ constructor(cells: number);
699
+ /** number of addressable cells. */
700
+ get cellscount(): number;
701
+ /** address width in bits (the tree depth). */
702
+ get addressbits(): number;
703
+ /** switch count of the tree (inner nodes; n - 1 for n cells). */
704
+ get switchcount(): number;
705
+ /** classical write into one cell (energizes one word line). */
706
+ write(address: number, value: number): void;
707
+ /** lists the cells as an address/value table. */
708
+ cells(): readonly qramcell[];
709
+ /**
710
+ * routes one read down the bucket-brigade tree: at level l the switch
711
+ * forwards along address bit (addressbits - 1 - l); the bus ends at
712
+ * the leaf and the trace records every switch node id visited
713
+ * (root id 1, children 2i and 2i + 1).
714
+ */
715
+ read(address: number): qramreadresult;
716
+ }
717
+ /**
718
+ * qramdemo: the n=8 showcase — 3 switch levels, 7 switches, every read
719
+ * routes 3 hops against 8 classical word lines, plus a note of what
720
+ * the quantum version would query in one shot (a superposed address
721
+ * returning a superposed memory word).
722
+ */
723
+ export declare function qramdemo(): {
724
+ reads: readonly qramreadresult[];
725
+ levels: number;
726
+ switches: number;
727
+ hops: number;
728
+ classicalwritelines: number;
729
+ reference: string;
730
+ };
731
+ /**
732
+ * shorcircuitplan: the honest factoring plan. the module ships the
733
+ * theoretical 7-qubit order-finding circuit for n = 15 (3 counting
734
+ * qubits + 4 work qubits, base a in {7, 11}, period 4,
735
+ * gcd(7^2 - 1, 15) = 3 and gcd(7^2 + 1, 15) = 5) and refuses to run it.
736
+ */
737
+ export type shorcircuitplan = {
738
+ readonly n: number;
739
+ readonly executable: false;
740
+ readonly qubits: number;
741
+ readonly countingqubits: number;
742
+ readonly workqubits: number;
743
+ readonly bases: readonly number[];
744
+ readonly expectedperiod: number;
745
+ readonly factors: readonly number[];
746
+ readonly stages: readonly string[];
747
+ readonly gatesestimate: number;
748
+ readonly reason: string;
749
+ readonly references: readonly string[];
750
+ };
751
+ /**
752
+ * shorplan(n): returns the theoretical shor circuit for the
753
+ * factorization and never runs it. honesty clause: compiled
754
+ * controlled-modular-exponentiation networks for any semiprime beyond
755
+ * toy size grow past the 20-qubit statevector budget of this
756
+ * simulator (numbers above 15 need more than 20 clean qubits plus
757
+ * ancillas before scheduling even starts in js), and the 2013
758
+ * "oversimplifying quantum factoring" literature shows compressed
759
+ * order-finding circuits for 15 can factor without any genuine quantum
760
+ * advantage — so the module plans, cites and stops.
761
+ * references: shor 1994 focs / siam j comput 26 1484 (1997);
762
+ * vedal, barenco, ekert 1996 pra 54 147; vandersypen et al. 2001
763
+ * nature 414 883 (the 7-qubit nmr run of 15); smolin, gambetta,
764
+ * smith 2013 pra 87 030302 "oversimplifying quantum factoring".
765
+ */
766
+ export declare function shorplan(n: number): shorcircuitplan;
767
+ /**
768
+ * quantumregistry: the capability catalog of this module for the engine
769
+ * integrator: simulator envelope, provable algorithms, key-exchange
770
+ * protocols, storage tiers, randomness sources and primary citations.
771
+ */
772
+ export declare const quantumregistry: Readonly<{
773
+ readonly simulator: "statevector";
774
+ readonly precision: "float64 interleaved re/im";
775
+ readonly maxqubits: 20;
776
+ readonly algorithms: readonly ["bellstate", "ghzstate", "grover2", "grover3", "deutsch", "qteleport", "shorplan (plan only)"];
777
+ readonly protocols: readonly ["bb84", "e91"];
778
+ readonly storage: readonly ["dna goldman 2013", "optical 5d quartz", "holographic note", "qram bucket brigade"];
779
+ readonly random: readonly ["csprng (node:crypto)", "anu qrng (optional, fallback)"];
780
+ readonly sources: readonly ["goldman et al. 2013 nature 494 77-80 doi:10.1038/nature11875", "church, gao, kosuri 2012 science 337 1628 (215 pb/g era)", "grover 1996 stoc arxiv:quant-ph/9605043", "deutsch-jozsa 1992 proc r soc lond a 439 553", "bennett-brassard 1984 bangalore proceedings 175-179", "ekert 1991 prl 67 661; chsh 1969 prl 23 880; bell 1964", "bennett et al. 1993 prl 70 1895 (teleportation)", "giovannetti-lloyd-maccone 2008 prl 100 160501 (qram)", "shor 1994/1997; vandersypen 2001 nature 414 883; smolin-gambetta-smith 2013", "zhang-kazansky et al. 2013-2016 southampton orc (5d quartz)", "microsoft research hsd 2024 announcement", "anu quantum numbers, api.quantumnumbers.io"];
781
+ }>;
782
+ /** registry type alias for integrators that want the frozen shape. */
783
+ export type quantumregistrytype = typeof quantumregistry;
784
+ /**
785
+ * one machine-verified claim row: name, pass flag and a detail line
786
+ * with the measured numbers.
787
+ */
788
+ export type quantumcheckrow = {
789
+ readonly name: string;
790
+ readonly pass: boolean;
791
+ readonly detail: string;
792
+ };
793
+ /**
794
+ * quantumselfcheck: runs every documented claim of this module against
795
+ * the real simulator — bell/grover/deutsch/teleport statistics, bb84
796
+ * with and without an eavesdropper, the e91 chsh violation, the dna
797
+ * roundtrip including strand loss, the qrng range, the qram routing
798
+ * depth, the shor honesty clause, the 20-qubit envelope guard and the
799
+ * using/disposal guard. returns the row table plus pass counts so the
800
+ * integrator can gate ci on it. randomness is live node:crypto, so the
801
+ * protocol rows carry the statistical margins described in their
802
+ * circuit references.
803
+ */
804
+ export declare function quantumselfcheck(): {
805
+ rows: readonly quantumcheckrow[];
806
+ passed: number;
807
+ failed: number;
808
+ reference: string;
809
+ };
810
+ //# sourceMappingURL=quantum.d.ts.map