@jokerized/decksmith 0.7.0 → 0.8.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/README.md +23 -4
- package/dist/cli.js +599 -179
- package/dist/index.js +593 -176
- package/dist/mcp.js +534 -166
- package/dist/types/emit/archetypes/equation-morph.d.ts +40 -0
- package/dist/types/emit/archetypes/equation-walk.d.ts +60 -1
- package/dist/types/emit/tex.d.ts +39 -0
- package/dist/types/index.d.ts +4 -1
- package/dist/types/plan/prompt.d.ts +0 -12
- package/dist/types/render/capture.d.ts +24 -0
- package/dist/types/render/timing.d.ts +16 -0
- package/dist/types/verify/budget.d.ts +8 -1
- package/dist/types/verify/fidelity.d.ts +19 -0
- package/dist/types/verify/index.d.ts +17 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -13,13 +13,19 @@ source.
|
|
|
13
13
|
|
|
14
14
|
## Prerequisites
|
|
15
15
|
|
|
16
|
-
- Node 22 or later, and nothing else to **generate** a deck. `ingest
|
|
17
|
-
`unpack`
|
|
18
|
-
|
|
19
|
-
Node image.
|
|
16
|
+
- Node 22 or later, and nothing else to **generate** a deck. `ingest` of a file, `build`,
|
|
17
|
+
`pack` and `unpack` run in plain Node. `build` also opens each stop in Chrome when it can
|
|
18
|
+
find one, and warns `not_measured` when it cannot. Decide your deployment on that line —
|
|
19
|
+
a service that turns papers into decks runs in a plain Node image.
|
|
20
20
|
- A Chromium build and ffmpeg to **render or check** one. `verify` drives the HyperFrames
|
|
21
21
|
gates in a headless browser, and the MP4 encode is ffmpeg's. Both arrive with the
|
|
22
22
|
hyperframes toolchain during `npm install`; there is nothing to install by hand.
|
|
23
|
+
- On Linux, Chrome's sandbox needs unprivileged user namespaces, and Ubuntu 23.10 and later
|
|
24
|
+
deny them by default. DeckSmith then opens its own pages, the gates' view of a deck and a
|
|
25
|
+
caption band, without the sandbox, as HyperFrames' render always does, and prints a
|
|
26
|
+
`chrome:` line saying so. `ingest` of a URL refuses instead, because that page comes from
|
|
27
|
+
the web. `sudo sysctl -w kernel.apparmor_restrict_unprivileged_userns=0`, or an AppArmor
|
|
28
|
+
profile for Chrome, gives the sandbox back.
|
|
23
29
|
- Three commands reach outside for their own reasons: `plan` runs the Codex CLI, `narrate`
|
|
24
30
|
runs edge-tts over the network, and `illustrate` asks an image backend or that same Codex
|
|
25
31
|
account for pictures — and draws its own when neither will.
|
|
@@ -1199,6 +1205,19 @@ mechanically rather than free-hand.
|
|
|
1199
1205
|
root timeline holds only a dummy tween spanning the deck.
|
|
1200
1206
|
- KaTeX renders with `output: "html"`. The default also emits a hidden MathML mirror that
|
|
1201
1207
|
the layout inspector reads as overlapping text.
|
|
1208
|
+
- No TeX reaches a `katex.render` call that KaTeX has not already parsed in Node, with
|
|
1209
|
+
`throwOnError` and the deck's own options (`src/emit/tex.ts`). A formula that fails gets
|
|
1210
|
+
a repair only where it cannot change what the formula says — a missing `\right.`, an
|
|
1211
|
+
unclosed brace, a dropped `\label`, a paper's undefined macro drawn as its name — and the
|
|
1212
|
+
repair is printed at `plan` and again at `build`. One no repair saves is shown as its
|
|
1213
|
+
source in plain text by `equation-walk`, and costs the beat, by name, in
|
|
1214
|
+
`equation-morph`. Until this existed the first parser a formula met was the browser at
|
|
1215
|
+
`verify`, after the deck had been built and narrated: 26 of 92 failed HypePaper builds
|
|
1216
|
+
in the week to 2026-10-07, 25 of them from `wrapTerms` cutting a `\left`/`\right` pair or
|
|
1217
|
+
a superscript in half.
|
|
1218
|
+
- `equation-walk` measures its display after fonts and fits it to its box: smaller down to
|
|
1219
|
+
the 40px floor, then broken after top-level relations and operators. One that still does
|
|
1220
|
+
not fit fails `fidelity` as `math_unfit`, with the formula in the message.
|
|
1202
1221
|
- No `Date.now()`, no `Math.random()`, no network at render time *in the composition*.
|
|
1203
1222
|
Two renders of an image-free deck must be byte-identical. `deck.html` is exempt: it is
|
|
1204
1223
|
presented, never rendered, and its subtitle loop legitimately reads a clock.
|