ray0rf1re commited on
Commit
a7a028f
·
verified ·
1 Parent(s): ac888a9

Deploy from GitHub hypernix-ai/hypernix-ai-space@53174eb

Browse files
.gitattributes CHANGED
@@ -33,3 +33,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
33
  *.zip filter=lfs diff=lfs merge=lfs -text
34
  *.zst filter=lfs diff=lfs merge=lfs -text
35
  *tfevents* filter=lfs diff=lfs merge=lfs -text
 
 
33
  *.zip filter=lfs diff=lfs merge=lfs -text
34
  *.zst filter=lfs diff=lfs merge=lfs -text
35
  *tfevents* filter=lfs diff=lfs merge=lfs -text
36
+ assets/banner.png filter=lfs diff=lfs merge=lfs -text
README.md CHANGED
@@ -1,10 +1,83 @@
1
  ---
2
- title: README
3
- emoji: 🌖
4
- colorFrom: green
5
- colorTo: green
6
  sdk: static
7
- pinned: false
 
8
  ---
9
 
10
- Edit this `README.md` markdown file to author your organization card.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
+ title: Hyprnyx
3
+ emoji: 🔺
4
+ colorFrom: red
5
+ colorTo: gray
6
  sdk: static
7
+ pinned: true
8
+ short_description: hypernix-pip — train, quantise and serve models anywhere
9
  ---
10
 
11
+ <p align="center">
12
+ <img src="assets/banner.png" alt="Hyprnyx — train, quantise and serve models on the hardware you have" width="900" />
13
+ </p>
14
+
15
+ <p align="center">
16
+ <a href="https://pypi.org/project/hypernix/"><img alt="PyPI" src="https://img.shields.io/badge/pip_install-hypernix-c8192e?style=for-the-badge&logo=pypi&logoColor=white" /></a>
17
+ <a href="https://github.com/trail-b1az3r/HyperNix-pip"><img alt="GitHub" src="https://img.shields.io/badge/GitHub-HyperNix--pip-1a1a1a?style=for-the-badge&logo=github&logoColor=white" /></a>
18
+ <a href="https://trail-b1az3r.github.io/HyperNix-pip/"><img alt="Docs" src="https://img.shields.io/badge/Docs-hypernix-2d2d2d?style=for-the-badge&logo=readthedocs&logoColor=white" /></a>
19
+ </p>
20
+
21
+ <p align="center">
22
+ <b>👋 Hi, we're Hyprnyx.</b> We build <a href="https://github.com/trail-b1az3r/HyperNix-pip"><code>hypernix-pip</code></a>, the end-to-end toolkit for training, quantising and serving AI models — on new hardware and on old.
23
+ </p>
24
+
25
+ ---
26
+
27
+ ## What we build
28
+
29
+ <table>
30
+ <tr>
31
+ <td width="33%" valign="top">
32
+ <h3>🔥 Train</h3>
33
+ VRAM managers, Abbicus curricula, STML context folding and Pressure Cooker V5 with QAT — tuned so a GTX&nbsp;1080 still finishes the run.<br/><br/>
34
+ <code>hypernix train run</code> · <code>brew</code> · <code>fusebox</code>
35
+ </td>
36
+ <td width="33%" valign="top">
37
+ <h3>🔺 Quantise</h3>
38
+ Every llama.cpp type, HyperNix hybrids and sub-bit tiers down to <code>IQ0.25</code>, plus multi-quant bundles and embedded drafts. No llama.cpp binary needed.<br/><br/>
39
+ <code>hyprslug</code> · <code>steamroller</code> · <code>dflash2</code>
40
+ </td>
41
+ <td width="33%" valign="top">
42
+ <h3>🛰️ Serve</h3>
43
+ The T1 API server with a built-in runner, daily-rotating v2.1 keys, conceal mode and HyperLink for your phone — managed from anywhere with <code>waiter</code>.<br/><br/>
44
+ <code>hypernix-t1</code> · <code>waiter</code> · <code>gkey</code>
45
+ </td>
46
+ </tr>
47
+ </table>
48
+
49
+ ```bash
50
+ pip install hypernix
51
+ hypernix all --repo-id hyper-nix.1 --quants fp16 q4_k_m # download → GGUF
52
+ hyprslug model.f16.gguf IQ0.5_XXXL # sub-bit, no llama.cpp
53
+ hypernix-t1 create && hypernix-t1 start # your own API server
54
+ ```
55
+
56
+ ---
57
+
58
+ ## Models
59
+
60
+ The HyperNix family, trained with the toolkit it ships with. Published under [ray0rf1re](https://huggingface.co/ray0rf1re) for now.
61
+
62
+ | Model | What it is |
63
+ |---|---|
64
+ | [**HyperNix.3-mini**](https://huggingface.co/ray0rf1re/HyperNix.3-mini) | The newest; the default the T1 built-in runner serves |
65
+ | [**hyper-Nix.2**](https://huggingface.co/ray0rf1re/hyper-Nix.2) | Second-generation HyperNix |
66
+ | [**hyper-nix.1**](https://huggingface.co/ray0rf1re/hyper-nix.1) | Where it started: the model hypernix-pip was written to convert |
67
+
68
+ ---
69
+
70
+ ## Principles
71
+
72
+ **Old hardware is real hardware.** A Pascal card, an 8 GB GPU, an Intel Mac on torch 1.13. If a feature only works on the newest GPU, it isn't finished.
73
+
74
+ **Measure, then say it.** Parameter counts come from the tensor table, not the filename. When a setting costs throughput, the tool prints how much.
75
+
76
+ **Safe by default.** Checkpoints are never unpickled, keys stay in the key store, downloaded code is never executed.
77
+
78
+ ---
79
+
80
+ <p align="center">
81
+ <a href="https://huggingface.co/spaces/hypernix-ai/README">Open the full page →</a><br/>
82
+ <sub>Hyprnyx · hypernix-ai · hypernix-pip is released under the HOS / LLU licence</sub>
83
+ </p>
assets/banner.png ADDED

Git LFS Details

  • SHA256: f2346281f13513819896e1590d5d5336f4cde048c77bf63f887c2a084506693d
  • Pointer size: 131 Bytes
  • Size of remote file: 151 kB
assets/banner.svg ADDED
assets/hypernix-favicon.svg ADDED
assets/hypernix-icon-ondark.svg ADDED
assets/hypernix-icon.svg ADDED
assets/hypernix-lockup-dark.svg ADDED
assets/hypernix-lockup-light.svg ADDED
index.html ADDED
@@ -0,0 +1,713 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!doctype html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8" />
5
+ <meta name="viewport" content="width=device-width, initial-scale=1" />
6
+ <meta name="color-scheme" content="dark light" />
7
+ <title>Hyprnyx · hypernix-ai</title>
8
+ <meta name="description" content="Hyprnyx (hypernix-ai): hypernix-pip, the end-to-end toolkit for training, quantising and serving AI models on modern and old hardware." />
9
+ <link rel="icon" type="image/svg+xml" href="assets/hypernix-favicon.svg" />
10
+ <link rel="preconnect" href="https://fonts.googleapis.com" />
11
+ <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
12
+ <!-- Separate links: one family failing to resolve must not take the others with it. -->
13
+ <link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Google+Sans+Flex:opsz,wght@6..144,400..800&display=swap" />
14
+ <link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Inter:wght@400..800&family=JetBrains+Mono:wght@400;500;700&display=swap" />
15
+ <link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Material+Symbols+Rounded:opsz,wght,FILL,GRAD@20..48,300..500,0..1,0&display=block" />
16
+ <style>
17
+ /* Colours: the HyperNix site (docs/src/index.css) and logo spec.
18
+ Shapes and motion: Material 3. */
19
+ :root {
20
+ --font: "Google Sans Flex", "Google Sans", "Inter", -apple-system, "Segoe UI", Roboto, sans-serif;
21
+ --mono: "JetBrains Mono", "SF Mono", ui-monospace, Menlo, monospace;
22
+
23
+ --bg: #0d0d0d;
24
+ --surface: #111111;
25
+ --surface-c-low: #141414;
26
+ --surface-c: #161616;
27
+ --surface-c-high: #1a1a1a;
28
+ --surface-c-highest: #222222;
29
+ --outline: #252525;
30
+ --outline-strong: #2f2f2f;
31
+ --on-surface: #f5f5f4;
32
+ --on-surface-var: #a3a3a3;
33
+ --muted: #8f8f8f;
34
+ --faint: #7a7a7a;
35
+ --primary: #c8192e;
36
+ --primary-hover: #dc2238;
37
+ --on-primary: #ffffff;
38
+ --primary-text: #ff5b6c;
39
+ --primary-container: rgba(200, 25, 46, 0.16);
40
+ --on-primary-container: #ffb3bb;
41
+ --ok: #34c759;
42
+ --bar-1: #f2f2f0;
43
+ --bar-2: #8f8f8f;
44
+ --glow: rgba(200, 25, 46, 0.22);
45
+ --elev-1: 0 1px 2px rgba(0, 0, 0, 0.5), 0 1px 3px 1px rgba(0, 0, 0, 0.3);
46
+ --elev-2: 0 1px 2px rgba(0, 0, 0, 0.5), 0 2px 6px 2px rgba(0, 0, 0, 0.35);
47
+ --elev-3: 0 4px 8px 3px rgba(0, 0, 0, 0.35), 0 1px 3px rgba(0, 0, 0, 0.5);
48
+ }
49
+ @media (prefers-color-scheme: light) {
50
+ :root:not([data-theme="dark"]) {
51
+ --bg: #f8f8f6;
52
+ --surface: #ffffff;
53
+ --surface-c-low: #f4f4f2;
54
+ --surface-c: #efefec;
55
+ --surface-c-high: #e9e9e6;
56
+ --surface-c-highest: #e2e2de;
57
+ --outline: #dcdcd7;
58
+ --outline-strong: #c9c9c3;
59
+ --on-surface: #141414;
60
+ --on-surface-var: #4a4a4c;
61
+ --muted: #5f5f62;
62
+ --faint: #77777b;
63
+ --primary-text: #b3142a;
64
+ --primary-container: #fde3e6;
65
+ --on-primary-container: #7a0c19;
66
+ --ok: #1f8f43;
67
+ --bar-1: #141414;
68
+ --bar-2: #6b6b6b;
69
+ --glow: rgba(200, 25, 46, 0.12);
70
+ --elev-1: 0 1px 2px rgba(0, 0, 0, 0.12), 0 1px 3px 1px rgba(0, 0, 0, 0.06);
71
+ --elev-2: 0 1px 2px rgba(0, 0, 0, 0.12), 0 2px 6px 2px rgba(0, 0, 0, 0.07);
72
+ --elev-3: 0 4px 8px 3px rgba(0, 0, 0, 0.08), 0 1px 3px rgba(0, 0, 0, 0.12);
73
+ }
74
+ }
75
+ :root[data-theme="light"] {
76
+ --bg: #f8f8f6;
77
+ --surface: #ffffff;
78
+ --surface-c-low: #f4f4f2;
79
+ --surface-c: #efefec;
80
+ --surface-c-high: #e9e9e6;
81
+ --surface-c-highest: #e2e2de;
82
+ --outline: #dcdcd7;
83
+ --outline-strong: #c9c9c3;
84
+ --on-surface: #141414;
85
+ --on-surface-var: #4a4a4c;
86
+ --muted: #5f5f62;
87
+ --faint: #77777b;
88
+ --primary-text: #b3142a;
89
+ --primary-container: #fde3e6;
90
+ --on-primary-container: #7a0c19;
91
+ --ok: #1f8f43;
92
+ --bar-1: #141414;
93
+ --bar-2: #6b6b6b;
94
+ --glow: rgba(200, 25, 46, 0.12);
95
+ --elev-1: 0 1px 2px rgba(0, 0, 0, 0.12), 0 1px 3px 1px rgba(0, 0, 0, 0.06);
96
+ --elev-2: 0 1px 2px rgba(0, 0, 0, 0.12), 0 2px 6px 2px rgba(0, 0, 0, 0.07);
97
+ --elev-3: 0 4px 8px 3px rgba(0, 0, 0, 0.08), 0 1px 3px rgba(0, 0, 0, 0.12);
98
+ }
99
+
100
+ * { box-sizing: border-box; margin: 0; padding: 0; }
101
+ html { scroll-behavior: smooth; }
102
+ body {
103
+ font-family: var(--font);
104
+ background: var(--bg);
105
+ color: var(--on-surface);
106
+ line-height: 1.55;
107
+ -webkit-font-smoothing: antialiased;
108
+ overflow-x: hidden;
109
+ }
110
+ a { color: inherit; text-decoration: none; }
111
+ code, pre, .mono { font-family: var(--mono); }
112
+ ::selection { background: var(--primary); color: #fff; }
113
+ :focus-visible { outline: 3px solid var(--primary-text); outline-offset: 2px; border-radius: 12px; }
114
+ .ms {
115
+ font-family: "Material Symbols Rounded";
116
+ font-weight: 400;
117
+ font-style: normal;
118
+ font-size: 22px;
119
+ line-height: 1;
120
+ letter-spacing: normal;
121
+ text-transform: none;
122
+ white-space: nowrap;
123
+ direction: ltr;
124
+ font-feature-settings: "liga";
125
+ -webkit-font-smoothing: antialiased;
126
+ font-variation-settings: "FILL" 0, "wght" 400, "GRAD" 0, "opsz" 24;
127
+ display: inline-block;
128
+ width: 1em;
129
+ overflow: hidden;
130
+ flex: none;
131
+ }
132
+ .ms.fill { font-variation-settings: "FILL" 1, "wght" 400, "GRAD" 0, "opsz" 24; }
133
+
134
+ .wrap { max-width: 1180px; margin: 0 auto; padding: 0 24px; }
135
+
136
+ /* ── Top app bar ─────────────────────────────────────────────── */
137
+ .appbar {
138
+ position: sticky;
139
+ top: 0;
140
+ z-index: 20;
141
+ background: color-mix(in srgb, var(--bg) 82%, transparent);
142
+ backdrop-filter: blur(16px) saturate(1.4);
143
+ -webkit-backdrop-filter: blur(16px) saturate(1.4);
144
+ border-bottom: 1px solid transparent;
145
+ transition: border-color 0.2s;
146
+ }
147
+ .appbar.scrolled { border-bottom-color: var(--outline); }
148
+ .appbar .wrap { display: flex; align-items: center; gap: 12px; height: 64px; }
149
+ .brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 20px; letter-spacing: -0.3px; }
150
+ .brand svg { width: 30px; height: 30px; }
151
+ .handle {
152
+ font-family: var(--mono);
153
+ font-size: 12px;
154
+ font-weight: 500;
155
+ color: var(--muted);
156
+ padding: 4px 10px;
157
+ border-radius: 8px;
158
+ background: var(--surface-c);
159
+ }
160
+ .grow { flex: 1; }
161
+ .tabs { display: flex; gap: 4px; }
162
+ .tab {
163
+ position: relative;
164
+ height: 40px;
165
+ padding: 0 14px;
166
+ border-radius: 20px;
167
+ display: inline-flex;
168
+ align-items: center;
169
+ font-weight: 500;
170
+ font-size: 14px;
171
+ color: var(--on-surface-var);
172
+ transition: background 0.15s, color 0.15s;
173
+ }
174
+ .tab:hover { background: var(--surface-c); color: var(--on-surface); }
175
+ .icon-btn {
176
+ width: 40px;
177
+ height: 40px;
178
+ border-radius: 20px;
179
+ display: grid;
180
+ place-items: center;
181
+ color: var(--on-surface-var);
182
+ background: none;
183
+ border: none;
184
+ cursor: pointer;
185
+ transition: background 0.15s;
186
+ }
187
+ .icon-btn:hover { background: var(--surface-c-high); color: var(--on-surface); }
188
+
189
+ /* ── Buttons & chips (Material 3) ────────────────────────────── */
190
+ .btn {
191
+ display: inline-flex;
192
+ align-items: center;
193
+ gap: 8px;
194
+ height: 40px;
195
+ padding: 0 24px 0 16px;
196
+ border-radius: 20px;
197
+ font: 500 14px/1 var(--font);
198
+ letter-spacing: 0.1px;
199
+ border: none;
200
+ cursor: pointer;
201
+ position: relative;
202
+ overflow: hidden;
203
+ transition: box-shadow 0.2s, background 0.15s, transform 0.1s;
204
+ white-space: nowrap;
205
+ }
206
+ .btn .ms { font-size: 18px; }
207
+ .btn::after { content: ""; position: absolute; inset: 0; background: currentColor; opacity: 0; transition: opacity 0.15s; }
208
+ .btn:hover::after { opacity: 0.08; }
209
+ .btn:active::after { opacity: 0.12; }
210
+ .btn.filled { background: var(--primary); color: var(--on-primary); }
211
+ .btn.filled:hover { box-shadow: var(--elev-1); }
212
+ .btn.tonal { background: var(--primary-container); color: var(--on-primary-container); }
213
+ .btn.outlined { background: transparent; color: var(--primary-text); box-shadow: inset 0 0 0 1px var(--outline-strong); }
214
+ .btn.text { background: transparent; color: var(--primary-text); padding: 0 12px; }
215
+ .chip {
216
+ display: inline-flex;
217
+ align-items: center;
218
+ gap: 8px;
219
+ height: 32px;
220
+ padding: 0 16px 0 8px;
221
+ border-radius: 8px;
222
+ border: 1px solid var(--outline-strong);
223
+ font-size: 14px;
224
+ font-weight: 500;
225
+ color: var(--on-surface-var);
226
+ background: transparent;
227
+ cursor: pointer;
228
+ transition: background 0.15s, border-color 0.15s;
229
+ }
230
+ .chip .ms { font-size: 18px; color: var(--primary-text); }
231
+ .chip:hover { background: var(--surface-c); color: var(--on-surface); }
232
+
233
+ /* ── Hero: a search page, because that is what the org is for ── */
234
+ .hero { position: relative; padding: 72px 0 56px; text-align: center; }
235
+ .hero::before {
236
+ content: "";
237
+ position: absolute;
238
+ inset: -120px 0 0;
239
+ background:
240
+ radial-gradient(520px 260px at 50% 20%, var(--glow), transparent 70%),
241
+ radial-gradient(800px 300px at 50% 0%, color-mix(in srgb, var(--glow) 50%, transparent), transparent 70%);
242
+ pointer-events: none;
243
+ z-index: -1;
244
+ }
245
+ .mark { width: 84px; height: 84px; margin: 0 auto 18px; filter: drop-shadow(0 14px 30px var(--glow)); animation: float 6s ease-in-out infinite; }
246
+ @keyframes float { 50% { transform: translateY(-6px); } }
247
+ .wordmark {
248
+ font-size: clamp(52px, 9vw, 92px);
249
+ font-weight: 750;
250
+ letter-spacing: -0.045em;
251
+ line-height: 1;
252
+ }
253
+ /* The logo's progression, dark → grey → red, run across the name. */
254
+ .wordmark .l1 { color: var(--bar-1); }
255
+ /* Tight tracking welds "rn" into an "m"; give that pair room. */
256
+ .wordmark .l2 { color: var(--bar-2); letter-spacing: 0.02em; margin: 0 0.03em; }
257
+ .wordmark .l3 { color: var(--primary); }
258
+ .tagline { margin: 14px auto 0; max-width: 600px; font-size: 17px; color: var(--on-surface-var); }
259
+ .search {
260
+ margin: 34px auto 0;
261
+ max-width: 640px;
262
+ height: 56px;
263
+ border-radius: 28px;
264
+ display: flex;
265
+ align-items: center;
266
+ gap: 12px;
267
+ padding: 0 8px 0 20px;
268
+ background: var(--surface-c-high);
269
+ box-shadow: var(--elev-1);
270
+ border: 1px solid var(--outline);
271
+ text-align: left;
272
+ transition: box-shadow 0.2s, background 0.2s;
273
+ }
274
+ .search:hover { box-shadow: var(--elev-3); background: var(--surface-c-highest); }
275
+ .search .ms { color: var(--muted); }
276
+ .search code { flex: 1; font-size: 16px; color: var(--on-surface); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
277
+ .search code .p { color: var(--primary-text); }
278
+ .search-actions { display: flex; gap: 2px; }
279
+ .quick { margin-top: 22px; display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
280
+ .meta-line { margin-top: 26px; font-size: 13px; color: var(--faint); display: flex; gap: 18px; justify-content: center; flex-wrap: wrap; }
281
+ .meta-line span { display: inline-flex; align-items: center; gap: 6px; }
282
+ .meta-line .ms { font-size: 16px; }
283
+ .dot-ok { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 4px color-mix(in srgb, var(--ok) 20%, transparent); }
284
+
285
+ /* ── Sections & cards ────────────────────────────────────────── */
286
+ section.block { padding: 40px 0; }
287
+ .eyebrow { font-family: var(--mono); font-size: 12px; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; color: var(--primary-text); }
288
+ h2 { font-size: clamp(26px, 3.4vw, 34px); font-weight: 650; letter-spacing: -0.025em; line-height: 1.15; margin-top: 6px; }
289
+ .lede { color: var(--on-surface-var); margin-top: 8px; max-width: 64ch; }
290
+ .grid { display: grid; gap: 16px; margin-top: 26px; }
291
+ .g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
292
+ .g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
293
+ .g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
294
+ .card {
295
+ position: relative;
296
+ border-radius: 28px;
297
+ padding: 24px;
298
+ background: var(--surface-c-low);
299
+ border: 1px solid var(--outline);
300
+ transition: box-shadow 0.25s, transform 0.25s, background 0.25s;
301
+ overflow: hidden;
302
+ }
303
+ a.card:hover, .card.lift:hover { box-shadow: var(--elev-2); transform: translateY(-2px); background: var(--surface-c); }
304
+ .card.elevated { background: var(--surface-c); border-color: transparent; box-shadow: var(--elev-1); }
305
+ .icon-tile {
306
+ width: 48px;
307
+ height: 48px;
308
+ border-radius: 16px;
309
+ display: grid;
310
+ place-items: center;
311
+ background: var(--primary-container);
312
+ color: var(--on-primary-container);
313
+ margin-bottom: 18px;
314
+ }
315
+ .icon-tile .ms { font-size: 26px; }
316
+ .card h3 { font-size: 19px; font-weight: 600; letter-spacing: -0.01em; }
317
+ .card p { color: var(--on-surface-var); margin-top: 6px; font-size: 14.5px; }
318
+ .card .foot { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 16px; }
319
+ .pill {
320
+ display: inline-flex;
321
+ align-items: center;
322
+ height: 26px;
323
+ padding: 0 10px;
324
+ border-radius: 13px;
325
+ font-family: var(--mono);
326
+ font-size: 12px;
327
+ background: var(--surface-c-highest);
328
+ color: var(--on-surface-var);
329
+ }
330
+ .pill.red { background: var(--primary-container); color: var(--on-primary-container); }
331
+
332
+ .stat { text-align: left; }
333
+ .stat .v { font-size: 34px; font-weight: 700; letter-spacing: -0.03em; line-height: 1.1; }
334
+ .stat .v small { font-size: 18px; color: var(--muted); font-weight: 500; }
335
+ .stat .l { color: var(--muted); font-size: 13.5px; margin-top: 4px; }
336
+
337
+ /* Model list: Material list items inside a card. */
338
+ .list { margin-top: 26px; border-radius: 28px; overflow: hidden; border: 1px solid var(--outline); background: var(--surface-c-low); }
339
+ .li {
340
+ display: flex;
341
+ align-items: center;
342
+ gap: 16px;
343
+ padding: 16px 20px;
344
+ border-top: 1px solid var(--outline);
345
+ transition: background 0.15s;
346
+ }
347
+ .li:first-child { border-top: none; }
348
+ .li:hover { background: var(--surface-c); }
349
+ .avatar {
350
+ width: 44px;
351
+ height: 44px;
352
+ border-radius: 14px;
353
+ display: grid;
354
+ place-items: center;
355
+ background: var(--surface-c-highest);
356
+ color: var(--primary-text);
357
+ flex: none;
358
+ }
359
+ .li .t { font-weight: 600; font-size: 16px; }
360
+ .li .s { color: var(--muted); font-size: 13.5px; }
361
+ .li .trail { color: var(--faint); }
362
+
363
+ /* Code card with tabs. */
364
+ .code-card { border-radius: 28px; overflow: hidden; background: #0a0a0b; border: 1px solid #222; box-shadow: var(--elev-2); margin-top: 26px; }
365
+ .code-tabs { display: flex; gap: 4px; padding: 10px 12px 0; border-bottom: 1px solid #1f1f1f; overflow-x: auto; }
366
+ .code-tab {
367
+ height: 40px;
368
+ padding: 0 16px;
369
+ border: none;
370
+ background: none;
371
+ color: #8f8f8f;
372
+ font: 500 14px var(--font);
373
+ border-bottom: 3px solid transparent;
374
+ border-radius: 6px 6px 0 0;
375
+ cursor: pointer;
376
+ white-space: nowrap;
377
+ }
378
+ .code-tab:hover { color: #f5f5f4; background: #151517; }
379
+ .code-tab[aria-selected="true"] { color: #f5f5f4; border-bottom-color: var(--primary); }
380
+ .code-body { position: relative; }
381
+ .code-body pre { padding: 22px 24px; overflow-x: auto; font-size: 13.5px; line-height: 1.75; color: #e8e8e6; }
382
+ .code-body .c { color: #6e6e74; }
383
+ .code-body .k { color: #ff5b6c; }
384
+ .code-body .s { color: #8ce8f2; }
385
+ .code-body .copy { position: absolute; top: 12px; right: 12px; color: #a3a3a3; }
386
+ .code-body .copy:hover { background: #1d1d21; color: #fff; }
387
+
388
+ .tool { display: flex; gap: 14px; align-items: flex-start; padding: 18px; border-radius: 20px; }
389
+ .tool .ms { color: var(--primary-text); margin-top: 2px; }
390
+ .tool b { font-family: var(--mono); font-weight: 600; font-size: 14px; }
391
+ .tool p { margin-top: 2px; font-size: 13.5px; }
392
+
393
+ .principle h3 { display: flex; align-items: center; gap: 10px; }
394
+ .principle h3 .ms { color: var(--primary-text); }
395
+
396
+ .links { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 22px; }
397
+
398
+ footer { padding: 40px 0 56px; border-top: 1px solid var(--outline); margin-top: 40px; color: var(--faint); font-size: 13.5px; }
399
+ footer .wrap { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }
400
+ footer svg { width: 22px; height: 22px; }
401
+
402
+ .snack {
403
+ position: fixed;
404
+ left: 50%;
405
+ bottom: 24px;
406
+ transform: translate(-50%, 140%);
407
+ background: var(--on-surface);
408
+ color: var(--bg);
409
+ padding: 14px 20px;
410
+ border-radius: 8px;
411
+ font-size: 14px;
412
+ box-shadow: var(--elev-3);
413
+ transition: transform 0.3s cubic-bezier(0.2, 0, 0, 1), visibility 0s 0.3s;
414
+ visibility: hidden;
415
+ z-index: 40;
416
+ }
417
+ .snack.show { transform: translate(-50%, 0); visibility: visible; transition: transform 0.3s cubic-bezier(0.2, 0, 0, 1); }
418
+
419
+ .reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.6s cubic-bezier(0.2, 0, 0, 1), transform 0.6s cubic-bezier(0.2, 0, 0, 1); }
420
+ .reveal.in { opacity: 1; transform: none; }
421
+ @media (prefers-reduced-motion: reduce) {
422
+ .reveal { opacity: 1; transform: none; transition: none; }
423
+ .mark { animation: none; }
424
+ html { scroll-behavior: auto; }
425
+ }
426
+
427
+ @media (max-width: 960px) {
428
+ .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
429
+ .g3 { grid-template-columns: 1fr 1fr; }
430
+ .tabs { display: none; }
431
+ }
432
+ @media (max-width: 640px) {
433
+ .wrap { padding: 0 16px; }
434
+ .g3, .g2 { grid-template-columns: 1fr; }
435
+ .hero { padding: 48px 0 32px; }
436
+ .search code { font-size: 14px; }
437
+ .handle { display: none; }
438
+ .card { border-radius: 24px; padding: 20px; }
439
+ .li { padding: 14px 16px; }
440
+ .li .trail { display: none; }
441
+ }
442
+ </style>
443
+ </head>
444
+ <body>
445
+ <svg width="0" height="0" style="position:absolute" aria-hidden="true">
446
+ <symbol id="logo" viewBox="0 0 64 64">
447
+ <path d="M6,52 L16,40 L42,40 L32,52 Z" fill="var(--bar-1)" />
448
+ <path d="M12,34 L22,22 L48,22 L38,34 Z" fill="var(--bar-2)" />
449
+ <path d="M18,16 L28,4 L54,4 L44,16 Z" fill="#c8192e" />
450
+ </symbol>
451
+ </svg>
452
+
453
+ <header class="appbar" id="appbar">
454
+ <div class="wrap">
455
+ <a class="brand" href="#top" aria-label="Hyprnyx home">
456
+ <svg><use href="#logo" /></svg>
457
+ Hyprnyx
458
+ </a>
459
+ <span class="handle">hypernix-ai</span>
460
+ <span class="grow"></span>
461
+ <nav class="tabs" aria-label="Sections">
462
+ <a class="tab" href="#build">What we build</a>
463
+ <a class="tab" href="#models">Models</a>
464
+ <a class="tab" href="#start">Get started</a>
465
+ <a class="tab" href="#principles">Principles</a>
466
+ </nav>
467
+ <button class="icon-btn" id="theme" aria-label="Switch theme" title="Switch theme"><span class="ms">dark_mode</span></button>
468
+ <a class="btn filled" href="https://huggingface.co/hypernix-ai" target="_blank" rel="noopener"><span class="ms">add</span>Follow</a>
469
+ </div>
470
+ </header>
471
+
472
+ <main id="top">
473
+ <section class="hero">
474
+ <div class="wrap">
475
+ <svg class="mark" aria-hidden="true"><use href="#logo" /></svg>
476
+ <h1 class="wordmark" aria-label="Hyprnyx"><span class="l1">Hyp</span><span class="l2">rn</span><span class="l3">yx</span></h1>
477
+ <p class="tagline">We make the tools that train, quantise and serve AI models on the hardware you already have — down to a GTX&nbsp;1080 and an Intel Mac.</p>
478
+
479
+ <div class="search" role="group" aria-label="Install hypernix-pip">
480
+ <span class="ms">terminal</span>
481
+ <code id="install-cmd"><span class="p">$</span> pip install hypernix</code>
482
+ <div class="search-actions">
483
+ <button class="icon-btn" data-copy="pip install hypernix" aria-label="Copy install command" title="Copy"><span class="ms">content_copy</span></button>
484
+ <a class="icon-btn" href="https://pypi.org/project/hypernix/" target="_blank" rel="noopener" aria-label="hypernix on PyPI" title="PyPI"><span class="ms">arrow_outward</span></a>
485
+ </div>
486
+ </div>
487
+
488
+ <div class="quick">
489
+ <a class="chip" href="https://github.com/trail-b1az3r/HyperNix-pip" target="_blank" rel="noopener"><span class="ms">code</span>Source</a>
490
+ <a class="chip" href="https://trail-b1az3r.github.io/HyperNix-pip/" target="_blank" rel="noopener"><span class="ms">menu_book</span>Docs</a>
491
+ <a class="chip" href="#models"><span class="ms">deployed_code</span>Models</a>
492
+ <a class="chip" href="https://github.com/trail-b1az3r/HyperNix-pip/blob/main/wiki/T1-API.md" target="_blank" rel="noopener"><span class="ms">dns</span>T1 API</a>
493
+ <a class="chip" href="https://github.com/trail-b1az3r/HyperNix-pip/blob/main/wiki/HyprSlug.md" target="_blank" rel="noopener"><span class="ms">compress</span>hyprslug</a>
494
+ </div>
495
+
496
+ <div class="meta-line">
497
+ <span><i class="dot-ok"></i>hypernix-pip 0.72.7.post1</span>
498
+ <span><span class="ms">code_blocks</span>Python 3.12 – 3.15</span>
499
+ <span><span class="ms">computer</span>Linux · macOS · Windows</span>
500
+ </div>
501
+ </div>
502
+ </section>
503
+
504
+ <section class="block" id="build">
505
+ <div class="wrap">
506
+ <div class="eyebrow reveal">What we build</div>
507
+ <h2 class="reveal">One toolkit, from snapshot to server</h2>
508
+ <p class="lede reveal">hypernix-pip started as the converter that turned HyperNix.1 into GGUF. It is now the whole path: download, train, quantise, serve — each step a command you can run on its own.</p>
509
+ <div class="grid g3">
510
+ <a class="card lift reveal" href="https://github.com/trail-b1az3r/HyperNix-pip/blob/main/wiki/Model-Training-Guide.md" target="_blank" rel="noopener">
511
+ <div class="icon-tile"><span class="ms">model_training</span></div>
512
+ <h3>Train on what you have</h3>
513
+ <p>Ovens, fridges and freezers for VRAM, Abbicus curricula, STML context folding, Pressure Cooker V5 with QAT and multi-token prediction — tuned so a Pascal card still finishes the run.</p>
514
+ <div class="foot"><span class="pill">train run</span><span class="pill">brew</span><span class="pill">fusebox</span></div>
515
+ </a>
516
+ <a class="card lift reveal" href="https://github.com/trail-b1az3r/HyperNix-pip/blob/main/wiki/Quantization.md" target="_blank" rel="noopener">
517
+ <div class="icon-tile"><span class="ms">layers</span></div>
518
+ <h3>Quantise below one bit</h3>
519
+ <p>Every llama.cpp type, HyperNix hybrids, and sub-bit tiers down to IQ0.25 — plus multi-quant bundles and speculative-decoding drafts. No llama.cpp binary required.</p>
520
+ <div class="foot"><span class="pill red">IQ0.5_XXXL</span><span class="pill">hyprslug</span><span class="pill">steamroller</span></div>
521
+ </a>
522
+ <a class="card lift reveal" href="https://github.com/trail-b1az3r/HyperNix-pip/blob/main/wiki/T1-API.md" target="_blank" rel="noopener">
523
+ <div class="icon-tile"><span class="ms">dns</span></div>
524
+ <h3>Serve it yourself</h3>
525
+ <p>The T1 API server with a built-in llama.cpp runner, keys that change every day, conceal mode, HyperLink on your phone, and <span class="mono">waiter</span> to manage it all from any machine.</p>
526
+ <div class="foot"><span class="pill">hypernix-t1</span><span class="pill">waiter</span><span class="pill">gkey</span></div>
527
+ </a>
528
+ </div>
529
+
530
+ <div class="grid g4">
531
+ <div class="card elevated stat reveal"><div class="v">0.72<small>.7</small></div><div class="l">current hypernix-pip release</div></div>
532
+ <div class="card elevated stat reveal"><div class="v">40+</div><div class="l">console commands, one pip install</div></div>
533
+ <div class="card elevated stat reveal"><div class="v">12</div><div class="l">HyperNix extension tiers, INT8 → IQ0.25</div></div>
534
+ <div class="card elevated stat reveal"><div class="v">11</div><div class="l">model families by short name</div></div>
535
+ </div>
536
+ </div>
537
+ </section>
538
+
539
+ <section class="block" id="models">
540
+ <div class="wrap">
541
+ <div class="eyebrow reveal">Models</div>
542
+ <h2 class="reveal">The HyperNix family</h2>
543
+ <p class="lede reveal">Small models, trained with the toolkit they ship with. Published under <a class="mono" style="color:var(--primary-text)" href="https://huggingface.co/ray0rf1re" target="_blank" rel="noopener">ray0rf1re</a> today; every one is a short name in <span class="mono">hypernix chat --repo-id</span>.</p>
544
+ <div class="list reveal">
545
+ <a class="li" href="https://huggingface.co/ray0rf1re/HyperNix.3-mini" target="_blank" rel="noopener">
546
+ <span class="avatar"><span class="ms fill">bolt</span></span>
547
+ <span class="grow"><div class="t">HyperNix.3-mini</div><div class="s">The default the T1 built-in runner serves · text generation</div></span>
548
+ <span class="pill red">latest</span>
549
+ <span class="ms trail">chevron_right</span>
550
+ </a>
551
+ <a class="li" href="https://huggingface.co/ray0rf1re/hyper-Nix.2" target="_blank" rel="noopener">
552
+ <span class="avatar"><span class="ms">auto_awesome</span></span>
553
+ <span class="grow"><div class="t">hyper-Nix.2</div><div class="s">Second-generation HyperNix</div></span>
554
+ <span class="ms trail">chevron_right</span>
555
+ </a>
556
+ <a class="li" href="https://huggingface.co/ray0rf1re/hyper-nix.1" target="_blank" rel="noopener">
557
+ <span class="avatar"><span class="ms">history_edu</span></span>
558
+ <span class="grow"><div class="t">hyper-nix.1</div><div class="s">Where it started — the model hypernix-pip was written to convert</div></span>
559
+ <span class="ms trail">chevron_right</span>
560
+ </a>
561
+ </div>
562
+ </div>
563
+ </section>
564
+
565
+ <section class="block" id="start">
566
+ <div class="wrap">
567
+ <div class="eyebrow reveal">Get started</div>
568
+ <h2 class="reveal">Three commands to anywhere</h2>
569
+ <div class="code-card reveal">
570
+ <div class="code-tabs" role="tablist" aria-label="Examples">
571
+ <button class="code-tab" role="tab" aria-selected="true" data-tab="0">Model → GGUF</button>
572
+ <button class="code-tab" role="tab" aria-selected="false" data-tab="1">Sub-bit quant</button>
573
+ <button class="code-tab" role="tab" aria-selected="false" data-tab="2">Train</button>
574
+ <button class="code-tab" role="tab" aria-selected="false" data-tab="3">T1 server</button>
575
+ </div>
576
+ <div class="code-body">
577
+ <button class="icon-btn copy" aria-label="Copy example" title="Copy"><span class="ms">content_copy</span></button>
578
+ <pre data-panel="0"><span class="c"># Install, then download → convert → quantise in one run</span>
579
+ <span class="k">pip</span> install hypernix
580
+ <span class="k">hypernix</span> all --repo-id <span class="s">hyper-nix.1</span> --quants fp16 q4_k_m q8_0
581
+ <span class="k">hypernix</span> verify ./hypernix-gguf/HyperNix.q4_k_m.gguf</pre>
582
+ <pre data-panel="1" hidden><span class="c"># Any llama.cpp type or a HyperNix tier, no llama.cpp binary needed</span>
583
+ <span class="k">hyprslug</span> model.f16.gguf <span class="s">Q4_K_M</span> -o model.q4_k_m.gguf
584
+ <span class="k">hyprslug</span> model.f16.gguf <span class="s">IQ0.5_XXXL</span> --quantize-embeddings
585
+ <span class="k">hnx-bundle</span> build model.f16.gguf <span class="s">Q4_K_M,Q6_K,Q8_0</span> -o model.bundle.gguf</pre>
586
+ <pre data-panel="2" hidden><span class="c"># A fresh model, trained with an exponential curriculum and STML</span>
587
+ <span class="k">hypernix</span> train init --out-dir ./snap --hidden-size 512 --num-hidden-layers 8
588
+ <span class="k">hypernix</span> train run --model-dir ./snap --dataset data.txt --out-dir ./out \
589
+ --use-turbo-abbicus --use-stml --thermal-target <span class="s">78</span>
590
+ <span class="k">tvtop-max</span> <span class="c"># watch it: modules, architecture, Pressure Cooker, logs</span></pre>
591
+ <pre data-panel="3" hidden><span class="c"># Your own API server, a model on it, and a client anywhere</span>
592
+ <span class="k">pip</span> install <span class="s">"hypernix[t1api]"</span>
593
+ <span class="k">hypernix-t1</span> create &amp;&amp; <span class="k">hypernix-t1</span> start
594
+ <span class="k">hypernix-t1</span> built-in-runner start <span class="s">HyperNix.3-mini</span>
595
+ <span class="k">gkey</span> create -v <span class="s">v2.1</span> --level 4
596
+ <span class="k">waiter</span> serv -ArEK <span class="s">"T2C_…"</span> -I https://myserver.ts.net</pre>
597
+ </div>
598
+ </div>
599
+
600
+ <div class="grid g4">
601
+ <div class="card tool reveal"><span class="ms">monitoring</span><div><b>tvtop-max</b><p>The machine and the run on it, in one dashboard.</p></div></div>
602
+ <div class="card tool reveal"><span class="ms">forum</span><div><b>hyped-pro</b><p>The OpenTUI chat client with tools and agents.</p></div></div>
603
+ <div class="card tool reveal"><span class="ms">key</span><div><b>gkey</b><p>Keys, quotas and daily-rotating v2.1 kits.</p></div></div>
604
+ <div class="card tool reveal"><span class="ms">science</span><div><b>brew</b><p>Custom architectures from presets, to GGUF.</p></div></div>
605
+ <div class="card tool reveal"><span class="ms">speed</span><div><b>dflash2</b><p>A draft model inside the GGUF it speeds up.</p></div></div>
606
+ <div class="card tool reveal"><span class="ms">thermostat</span><div><b>fusebox</b><p>Holds a GPU at the temperature you choose.</p></div></div>
607
+ <div class="card tool reveal"><span class="ms">public</span><div><b>gather</b><p>Crawls a site into a corpus, robots-aware.</p></div></div>
608
+ <div class="card tool reveal"><span class="ms">phone_iphone</span><div><b>HyperLink</b><p>Your T1 server, from your phone.</p></div></div>
609
+ </div>
610
+ </div>
611
+ </section>
612
+
613
+ <section class="block" id="principles">
614
+ <div class="wrap">
615
+ <div class="eyebrow reveal">Principles</div>
616
+ <h2 class="reveal">How we work</h2>
617
+ <div class="grid g3">
618
+ <div class="card principle reveal">
619
+ <h3><span class="ms">memory</span>Old hardware is real hardware</h3>
620
+ <p>A GTX 1080, an 8 GB card, an Intel Mac on torch 1.13. If a feature only works on the newest GPU, it isn't finished.</p>
621
+ </div>
622
+ <div class="card principle reveal">
623
+ <h3><span class="ms">fact_check</span>Measure, then say it</h3>
624
+ <p>Parameter counts are summed from the tensor table, not guessed from a filename. When a lever costs throughput, the tool prints how much.</p>
625
+ </div>
626
+ <div class="card principle reveal">
627
+ <h3><span class="ms">shield</span>Safe by default</h3>
628
+ <p>Checkpoints are never unpickled, keys stay in the key store, downloaded code is never run, and every opt-in is in the security checklist.</p>
629
+ </div>
630
+ </div>
631
+ <div class="links reveal">
632
+ <a class="btn filled" href="https://github.com/trail-b1az3r/HyperNix-pip" target="_blank" rel="noopener"><span class="ms">code</span>hypernix-pip on GitHub</a>
633
+ <a class="btn tonal" href="https://trail-b1az3r.github.io/HyperNix-pip/" target="_blank" rel="noopener"><span class="ms">menu_book</span>Documentation</a>
634
+ <a class="btn outlined" href="https://pypi.org/project/hypernix/" target="_blank" rel="noopener"><span class="ms">inventory_2</span>PyPI</a>
635
+ <a class="btn text" href="https://github.com/trail-b1az3r/HyperNix-pip/blob/main/wiki/Changelog.md" target="_blank" rel="noopener">Changelog<span class="ms">arrow_forward</span></a>
636
+ </div>
637
+ </div>
638
+ </section>
639
+ </main>
640
+
641
+ <footer>
642
+ <div class="wrap">
643
+ <svg aria-hidden="true"><use href="#logo" /></svg>
644
+ <span>Hyprnyx · <span class="mono">hypernix-ai</span></span>
645
+ <span class="grow"></span>
646
+ <span>hypernix-pip is released under the HOS / LLU licence.</span>
647
+ </div>
648
+ </footer>
649
+
650
+ <div class="snack" id="snack" role="status" aria-live="polite">Copied</div>
651
+
652
+ <script>
653
+ (function () {
654
+ var root = document.documentElement;
655
+ var themeBtn = document.getElementById("theme");
656
+ var media = window.matchMedia("(prefers-color-scheme: light)");
657
+ function stored() { try { return localStorage.getItem("hnx-theme"); } catch (e) { return null; } }
658
+ function current() { return root.dataset.theme || (media.matches ? "light" : "dark"); }
659
+ function paint() { themeBtn.querySelector(".ms").textContent = current() === "light" ? "dark_mode" : "light_mode"; }
660
+ var saved = stored();
661
+ if (saved === "light" || saved === "dark") root.dataset.theme = saved;
662
+ paint();
663
+ media.addEventListener("change", paint);
664
+ themeBtn.addEventListener("click", function () {
665
+ var next = current() === "light" ? "dark" : "light";
666
+ root.dataset.theme = next;
667
+ try { localStorage.setItem("hnx-theme", next); } catch (e) {}
668
+ paint();
669
+ });
670
+
671
+ var bar = document.getElementById("appbar");
672
+ window.addEventListener("scroll", function () { bar.classList.toggle("scrolled", window.scrollY > 8); }, { passive: true });
673
+
674
+ var snack = document.getElementById("snack");
675
+ var timer;
676
+ function copy(text) {
677
+ var done = function () {
678
+ snack.classList.add("show");
679
+ clearTimeout(timer);
680
+ timer = setTimeout(function () { snack.classList.remove("show"); }, 1800);
681
+ };
682
+ if (navigator.clipboard && navigator.clipboard.writeText) navigator.clipboard.writeText(text).then(done, done);
683
+ else done();
684
+ }
685
+ document.querySelectorAll("[data-copy]").forEach(function (b) {
686
+ b.addEventListener("click", function () { copy(b.getAttribute("data-copy")); });
687
+ });
688
+
689
+ var tabs = document.querySelectorAll(".code-tab");
690
+ var panels = document.querySelectorAll(".code-body pre");
691
+ tabs.forEach(function (t) {
692
+ t.addEventListener("click", function () {
693
+ tabs.forEach(function (x) { x.setAttribute("aria-selected", String(x === t)); });
694
+ panels.forEach(function (p) { p.hidden = p.getAttribute("data-panel") !== t.getAttribute("data-tab"); });
695
+ });
696
+ });
697
+ document.querySelector(".code-body .copy").addEventListener("click", function () {
698
+ var open = document.querySelector(".code-body pre:not([hidden])");
699
+ copy(open.textContent.split("\n").filter(function (l) { return l.trim() && l.trim().charAt(0) !== "#"; }).join("\n"));
700
+ });
701
+
702
+ if ("IntersectionObserver" in window) {
703
+ var io = new IntersectionObserver(function (entries) {
704
+ entries.forEach(function (e) { if (e.isIntersecting) { e.target.classList.add("in"); io.unobserve(e.target); } });
705
+ }, { rootMargin: "0px 0px -40px 0px" });
706
+ document.querySelectorAll(".reveal").forEach(function (el) { io.observe(el); });
707
+ } else {
708
+ document.querySelectorAll(".reveal").forEach(function (el) { el.classList.add("in"); });
709
+ }
710
+ })();
711
+ </script>
712
+ </body>
713
+ </html>