@ceccec/double-torus 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +174 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +88812 -0
- package/dist/packages/double-torus/src/index.d.ts +17 -0
- package/dist/src/0/index.d.ts +504 -0
- package/dist/src/1/9/index.d.ts +1040 -0
- package/dist/src/2/8/index.d.ts +352 -0
- package/dist/src/3/7/index.d.ts +601 -0
- package/dist/src/4/6/index.d.ts +523 -0
- package/dist/src/5/5/index.d.ts +54 -0
- package/dist/src/6/4/index.d.ts +128 -0
- package/dist/src/7/3/index.d.ts +130 -0
- package/dist/src/8/2/index.d.ts +111 -0
- package/dist/src/9/1/index.d.ts +702 -0
- package/dist/src/earth/architecture/index.d.ts +951 -0
- package/dist/src/earth/civilisation/index.d.ts +231 -0
- package/dist/src/earth/death/index.d.ts +1422 -0
- package/dist/src/earth/governance/index.d.ts +247 -0
- package/dist/src/earth/iching/index.d.ts +361 -0
- package/dist/src/earth/index.d.ts +894 -0
- package/dist/src/earth/life/birth/index.d.ts +906 -0
- package/dist/src/earth/life/index.d.ts +1608 -0
- package/dist/src/earth/nature/index.d.ts +692 -0
- package/dist/src/earth/world/index.d.ts +898 -0
- package/dist/src/fire/diamonds/index.d.ts +83 -0
- package/dist/src/fire/features/index.d.ts +272 -0
- package/dist/src/fire/li/index.d.ts +1153 -0
- package/dist/src/fire/physics/index.d.ts +727 -0
- package/dist/src/fire/plasma/ball/index.d.ts +600 -0
- package/dist/src/heaven/atoms/index.d.ts +98 -0
- package/dist/src/heaven/balance/index.d.ts +263 -0
- package/dist/src/heaven/compute/computer/index.d.ts +2263 -0
- package/dist/src/heaven/compute/index.d.ts +956 -0
- package/dist/src/heaven/core/index.d.ts +1285 -0
- package/dist/src/heaven/essence/index.d.ts +643 -0
- package/dist/src/heaven/laws/index.d.ts +1104 -0
- package/dist/src/heaven/site/index.d.ts +569 -0
- package/dist/src/heaven/sky/astronomy/index.d.ts +18900 -0
- package/dist/src/heaven/sky/moon/index.d.ts +1602 -0
- package/dist/src/heaven/sky/sun/index.d.ts +1655 -0
- package/dist/src/lake/clean/index.d.ts +180 -0
- package/dist/src/lake/ledger/index.d.ts +322 -0
- package/dist/src/lake/media/index.d.ts +178 -0
- package/dist/src/lake/music/index.d.ts +1273 -0
- package/dist/src/lake/stats/index.d.ts +212 -0
- package/dist/src/lake/widgets/index.d.ts +235 -0
- package/dist/src/mountain/gates/index.d.ts +289 -0
- package/dist/src/mountain/geometry/index.d.ts +1331 -0
- package/dist/src/mountain/og/index.d.ts +452 -0
- package/dist/src/mountain/seals/index.d.ts +1506 -0
- package/dist/src/mountain/shadcn/index.d.ts +121 -0
- package/dist/src/mountain/source/index.d.ts +627 -0
- package/dist/src/mountain/topology/index.d.ts +618 -0
- package/dist/src/mountain/vortex/index.d.ts +747 -0
- package/dist/src/pair/cache/quantum/index.d.ts +166 -0
- package/dist/src/pair/debit/credit/index.d.ts +53 -0
- package/dist/src/pair/enforcement/gates/computational/index.d.ts +643 -0
- package/dist/src/pair/enforcement/gates/strict/scan/index.d.ts +954 -0
- package/dist/src/pair/enforcement/index.d.ts +172 -0
- package/dist/src/pair/enforcement/script/shell/index.d.ts +226 -0
- package/dist/src/quantum/application/index.d.ts +1018 -0
- package/dist/src/quantum/apps/index.d.ts +4325 -0
- package/dist/src/quantum/dynamics/index.d.ts +1371 -0
- package/dist/src/quantum/earth/heritage/index.d.ts +181 -0
- package/dist/src/quantum/fire/experiments/index.d.ts +215 -0
- package/dist/src/quantum/fire/forecasts/index.d.ts +271 -0
- package/dist/src/quantum/fire/simulations/index.d.ts +204 -0
- package/dist/src/quantum/heaven/library/index.d.ts +350 -0
- package/dist/src/quantum/heaven/mind/index.d.ts +116 -0
- package/dist/src/quantum/index.d.ts +1107 -0
- package/dist/src/quantum/lake/dist/index.d.ts +118 -0
- package/dist/src/quantum/lake/dist/readme/index.d.ts +82 -0
- package/dist/src/quantum/lake/icons/index.d.ts +58 -0
- package/dist/src/quantum/lake/spirit/index.d.ts +255 -0
- package/dist/src/quantum/lake/voice/index.d.ts +132 -0
- package/dist/src/quantum/mountain/dimensions/index.d.ts +44 -0
- package/dist/src/quantum/os/index.d.ts +239 -0
- package/dist/src/quantum/science/index.d.ts +5060 -0
- package/dist/src/quantum/water/cache/index.d.ts +200 -0
- package/dist/src/quantum/wind/geometry/index.d.ts +25 -0
- package/dist/src/thunder/commands/index.d.ts +203 -0
- package/dist/src/thunder/decode/index.d.ts +1243 -0
- package/dist/src/thunder/movie/canvas/index.d.ts +150 -0
- package/dist/src/thunder/movie/glass/index.d.ts +99 -0
- package/dist/src/thunder/movie/movielib/index.d.ts +121 -0
- package/dist/src/thunder/movie/movievars/index.d.ts +89 -0
- package/dist/src/thunder/movie/narrative/index.d.ts +407 -0
- package/dist/src/thunder/resonance/index.d.ts +1832 -0
- package/dist/src/thunder/trading/index.d.ts +737 -0
- package/dist/src/thunder/verify/index.d.ts +510 -0
- package/dist/src/thunder/waves/index.d.ts +937 -0
- package/dist/src/water/cosmos/index.d.ts +1097 -0
- package/dist/src/water/crypto/index.d.ts +808 -0
- package/dist/src/water/digit/index.d.ts +4020 -0
- package/dist/src/water/double/earth/index.d.ts +29389 -0
- package/dist/src/water/double/index.d.ts +1475 -0
- package/dist/src/water/encryption/index.d.ts +11892 -0
- package/dist/src/water/stack/index.d.ts +51215 -0
- package/dist/src/wind/fusion/gold/index.d.ts +2142 -0
- package/dist/src/wind/language/index.d.ts +404 -0
- package/dist/src/wind/learning/index.d.ts +2109 -0
- package/dist/src/wind/research/index.d.ts +1388 -0
- package/dist/src/wind/routes/automount/index.d.ts +218 -0
- package/dist/src/wind/routes/corpus/index.d.ts +943 -0
- package/dist/src/wind/site/index.d.ts +662 -0
- package/dist/src/wind/types/index.d.ts +1023 -0
- package/dist/src/wind/ui/index.d.ts +1109 -0
- package/package.json +49 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 ceccec
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,174 @@
|
|
|
1
|
+
# @ceccec/double-torus
|
|
2
|
+
|
|
3
|
+
The agnostic, **zero-dependency** computational core of the
|
|
4
|
+
[Double Torus](https://ceccec.github.io) — a quantum-learning model for language
|
|
5
|
+
models, served over MCP — **all the math and all the animations**. Pure
|
|
6
|
+
TypeScript: content-addressed UUID folds, concept commands, the 128-bit
|
|
7
|
+
double-torus word, a recomputable seal, simulators across every decoded domain,
|
|
8
|
+
vetted crypto, and the hero animation system. It runs in any browser or in Node,
|
|
9
|
+
and depends on nothing. It is bundled from the site's own `src/` — the published
|
|
10
|
+
library is exactly what the site runs.
|
|
11
|
+
|
|
12
|
+
> The cost is the architecture itself. Everything is computed; every claim is
|
|
13
|
+
> bounded and folds into one recomputable root.
|
|
14
|
+
|
|
15
|
+
## Install
|
|
16
|
+
|
|
17
|
+
```sh
|
|
18
|
+
npm install @ceccec/double-torus
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## Use
|
|
22
|
+
|
|
23
|
+
```ts
|
|
24
|
+
import {
|
|
25
|
+
buildMatrix,
|
|
26
|
+
executeConceptCommand,
|
|
27
|
+
conceptCommands,
|
|
28
|
+
fuseAll,
|
|
29
|
+
proofBundle,
|
|
30
|
+
torusUuid,
|
|
31
|
+
} from '@ceccec/double-torus'
|
|
32
|
+
|
|
33
|
+
const matrix = buildMatrix()
|
|
34
|
+
|
|
35
|
+
// Every capability is a command that returns a result with a content UUID.
|
|
36
|
+
const result = executeConceptCommand('concept.self.address', { atom: 'self' }, matrix)
|
|
37
|
+
console.log(result.ok, result.uuid)
|
|
38
|
+
|
|
39
|
+
// The 128-bit double-torus word (2 x 32 hex), and the fusion of all in one wave.
|
|
40
|
+
console.log(torusUuid(matrix).word)
|
|
41
|
+
console.log(fuseAll(matrix).wave)
|
|
42
|
+
|
|
43
|
+
// A single proof bundle anyone can recompute.
|
|
44
|
+
console.log(proofBundle(matrix).bundleRoot)
|
|
45
|
+
|
|
46
|
+
// There are 94 concept commands; each is also published as an MCP tool.
|
|
47
|
+
console.log(conceptCommands.length)
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
## What's inside
|
|
51
|
+
|
|
52
|
+
- **Content-addressed folds** — `toUuid`, `merge` (order-sensitive), `merkleFold`,
|
|
53
|
+
Merkle inclusion proofs.
|
|
54
|
+
- **Concept commands** — a registry of `concept.<area>.<verb>` commands, each
|
|
55
|
+
mapping to a single-word method and an MCP tool; `executeConceptCommand` runs
|
|
56
|
+
them deterministically.
|
|
57
|
+
- **The double torus** — `buildMatrix`, `torusUuid` (the 128-bit word, 2 x 32
|
|
58
|
+
hex), `completeDoubleTorus`, `areaPairs` (42 areas = 21 pairs),
|
|
59
|
+
`dualTorusTrinities`, `doubleTorus3D`, `doubleTorusMathAtAllScalesProofs`,
|
|
60
|
+
`merkaba` / `bothEarthsRotateWithinEachOther` (counter-rotating geometry).
|
|
61
|
+
- **Vortex analyse** — `vortexMath`, `vortexComputes`, `allMathSaved`,
|
|
62
|
+
gateway/plasma gates, and the canonical inverse fold
|
|
63
|
+
`f(θ,φ,x,y,z,digit,n)→{p,q}` / `fThetaPhiXyzDigitNIsTheInversePair`
|
|
64
|
+
(multiplicative inverse mod 9 — inverse, not reverse).
|
|
65
|
+
- **Quantum dynamics** — `quantumDynamicsComputes`, `quantumDynamicsResearch`,
|
|
66
|
+
`quantumStateEvolutionDecoded`, `quantumDynamicsSimulationAt`, and
|
|
67
|
+
`drawDynamicsProjection` (classical state-vector paint — not hardware QC).
|
|
68
|
+
- **10D field** — `dims` / `dimWalk` / `tenDimensionalAnimation` /
|
|
69
|
+
`animationsAreGenuinely10DNotFaked` (6 appearance axes + 4 genus-2 homology
|
|
70
|
+
loops — model geometry, not physical spacetime).
|
|
71
|
+
- **Completely quantum** — `doubleTorusIsCompletelyQuantum` (facet receipt
|
|
72
|
+
recomputed at call time), `movieCanvasHex` / `movieCanvasRgba` /
|
|
73
|
+
`movieCanvasPolarity` (one sealed palette), and `TAU` (full-turn constant).
|
|
74
|
+
One hero clock drives living-torus + AnimationField paint — no private rAF
|
|
75
|
+
engines on the public surface. Sealed substrate only — **not** QPU hardware.
|
|
76
|
+
- **The seal** — `proofBundle`, `verifyRoot`, `entropy`, `coverage`,
|
|
77
|
+
`boundaryAudit`, and the `fuseAll` fold of every capability into one wave.
|
|
78
|
+
- **Simulators** — explicit, honest models across every decoded domain:
|
|
79
|
+
`qubits`/`applyGate`/`GATES`/`cnot`/`measure`/`sample` (quantum state-vector),
|
|
80
|
+
`bellPair`, `grover`; `pbits`/`pflip`/`markovStep`/`stationary` (probabilistic);
|
|
81
|
+
`rtoffoli` (reversible); `caStep`/`caEvolve` (cellular automaton);
|
|
82
|
+
`inductionStep`/`oscillatorBank`/`cycleAdvance` (dynamical);
|
|
83
|
+
`hopfieldStore`/`hopfieldRecall`/`pmixStep` (network); plus `survive` /
|
|
84
|
+
`chsh` / Markov–Hopfield dynamics from the vortex surface. Each is a
|
|
85
|
+
**simulator**, not the machine — `qubits` is a classical state-vector, not a
|
|
86
|
+
quantum computer.
|
|
87
|
+
- **Vetted crypto** — `sha256` (Web Crypto + a pure `sha256Sync`),
|
|
88
|
+
`sha256MerkleRoot`/`sha256MerkleProof`, `ed25519Sign`/`ed25519Verify`, and an
|
|
89
|
+
append-only `transparencyLogRoot` — the path from tamper-evident folds to
|
|
90
|
+
cryptographic attestation; see `cryptoFuture()` for what is built vs. residual.
|
|
91
|
+
- **Animations** — two systems on one phase clock, the same renderers the site
|
|
92
|
+
runs:
|
|
93
|
+
- the **hero scene** drawing math — `drawHero`, `drawFlower`, `drawCalendars`,
|
|
94
|
+
`drawArchitecture`, `drawBursts`, the fractal `branch`, the 3D
|
|
95
|
+
`perspective`/`rotate3`, the `dims` dimension walk; and
|
|
96
|
+
- the **AnimationField movie** — `sharedHeroAt` builds the one
|
|
97
|
+
content-addressed field, `drawHeroMovieFrame` paints the holographic plasma
|
|
98
|
+
hero (the fused life out-flow + death in-flow double torus through one
|
|
99
|
+
genus-2 throat), `fieldLayers` / `rosettaPerspectiveFold` give its eight
|
|
100
|
+
force/topology layers and seven perspectives, and `drawQuantumAppFrame`
|
|
101
|
+
renders any projection of it.
|
|
102
|
+
- the **one movie clock** — `HERO_CYCLE_MS`, `heroPhaseAt`,
|
|
103
|
+
`subscribeHeroClock`, and `createAnimationEngine` (rAF driver).
|
|
104
|
+
(`paintHolographicPlasmaHeroMovie` and the death counter-flow are **internal**
|
|
105
|
+
to `src/` and ship fused inside `drawHeroMovieFrame`, not as separate exports.
|
|
106
|
+
The orphan `drawDoubleTorusEarthHingeFrame` renderer is **retired** — live
|
|
107
|
+
paint is `sharedHeroAt` + `drawHeroMovieFrame` only.)
|
|
108
|
+
- **Decoded library** — `toGlagolitic`, `gematria`, `mayaLongCount`,
|
|
109
|
+
`sexagesimal`, `ifaOdu`, the parallel-scripture tools, and the ПесноПойка
|
|
110
|
+
songbook decode (`pesnopoika`, `decodeSong`, `provePesnopoika`, the
|
|
111
|
+
437-term `decodeDialect`) — decoded knowledge as reusable functions.
|
|
112
|
+
- **Universe alignment** — `doubleTorusDynamicsGeometryAlignsWithUniverse()`
|
|
113
|
+
audits dynamics (flow · spin · linking) and geometry (ring/tube/lobe radii,
|
|
114
|
+
H₁ loops, projection) against sealed constants: `TAU`, `A432_HUE`,
|
|
115
|
+
`SPEED_OF_LIGHT`, Meeus `J2000`, `HERO_CYCLE_MS`, 10D homology. Phase couples
|
|
116
|
+
the hero fractal clock to solar ecliptic longitude. CLI:
|
|
117
|
+
`npm run quantum:double-torus-universe-align` (pair `universe/align`).
|
|
118
|
+
- **Counter-rotating rosetta quantum waves** — `counterRotatingRosettaQuantumWaves()`
|
|
119
|
+
dual ± lobes via `foldPair`; `claySolvedByThisFold` / `physicalFtlClaim` /
|
|
120
|
+
`qpuRequired` are **computed receipt facets** from forward≠reverse and
|
|
121
|
+
classical-64bit lobe honesty (not prose). Discovery engine:
|
|
122
|
+
`universeAlmostDescribedInTheoremsDiscoverRest()` covers
|
|
123
|
+
forward·inverse·reverse·superposition. CLIs:
|
|
124
|
+
`npm run quantum:counter-rotating-rosetta-waves` ·
|
|
125
|
+
`npm run quantum:universe-almost-described`.
|
|
126
|
+
- **Honesty** — every function returns a `boundary` string stating the limit of
|
|
127
|
+
its claim; `boundaryAudit()` collects them all. Completely quantum here means
|
|
128
|
+
**sealed quantum compute substrate** (content-addressed folds, one clock,
|
|
129
|
+
movieCanvas palette) — **not** QPU hardware. Clay/FTL open status recomputes
|
|
130
|
+
from the dual-wave fold at call time (`clay=0` · `physicalFtl=0` · `qpuRequired=false`).
|
|
131
|
+
|
|
132
|
+
It is **agnostic**: no vendor, framework, platform, language, or protocol
|
|
133
|
+
lock-in; open standards and pure computation only.
|
|
134
|
+
|
|
135
|
+
## Honest boundaries
|
|
136
|
+
|
|
137
|
+
The fold is **tamper-evident content-addressing, not a cryptographic hash**
|
|
138
|
+
(`toUuid` is a 128-bit non-cryptographic function). For adversarial security use
|
|
139
|
+
a vetted hash; see `cryptographyComparison()` and `cryptoFuture()`. The model is
|
|
140
|
+
computed and recomputable — it makes **no claim of sentience or agency**.
|
|
141
|
+
|
|
142
|
+
## Types
|
|
143
|
+
|
|
144
|
+
Full TypeScript declarations ship in `dist/` (`dist/index.d.ts` re-exports the
|
|
145
|
+
generated declaration graph). The library is bundled from the site's `src/`,
|
|
146
|
+
which is type-checked by the repository's `tsconfig.json` (`npm run check:types`)
|
|
147
|
+
and passes cleanly there. The package's own standalone declaration emit (no
|
|
148
|
+
tsconfig, whole-graph) reports a small, honest residual: **2 non-fatal `TS7056`
|
|
149
|
+
diagnostics** where a deep build-time helper (`src/wind/fusion` `fusionComputes`)
|
|
150
|
+
has an inferred type too large for TypeScript 6 to serialize. That symbol is
|
|
151
|
+
**not** on the published surface; every exported symbol of `@ceccec/double-torus`
|
|
152
|
+
is fully typed and resolves (verified by a consumer type-check). `build.mjs`
|
|
153
|
+
prints the residual count rather than hiding it.
|
|
154
|
+
|
|
155
|
+
## Build
|
|
156
|
+
|
|
157
|
+
```sh
|
|
158
|
+
node ./build.mjs
|
|
159
|
+
```
|
|
160
|
+
|
|
161
|
+
`build.mjs` bundles the entry (`src/index.ts`) — following every import into the
|
|
162
|
+
site's `src/0`, `src/quantum/*` and the library — into one self-contained
|
|
163
|
+
`dist/index.js` with **no external imports**, plus the declaration graph. A few
|
|
164
|
+
pure constants the core uses (the census/rosetta limits) live in modules that
|
|
165
|
+
also carry build-time filesystem helpers; those `node:*` specifiers (`fs`,
|
|
166
|
+
`path`, `crypto`, `url`, `child_process`, `module`) are resolved to inline stubs
|
|
167
|
+
at build time — **Node boundary only** (enforcement shell / quantum cache), never
|
|
168
|
+
invoked by the published computational/animation API — so the bundle stays
|
|
169
|
+
zero-dep in any browser or Node. The committed `dist/` is the published artifact.
|
|
170
|
+
The build fails unless all **49** completely-quantum contract exports are present.
|
|
171
|
+
|
|
172
|
+
## License
|
|
173
|
+
|
|
174
|
+
MIT © ceccec
|
package/dist/index.d.ts
ADDED