dsh-h3-image 0.2.4 → 0.2.6

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 CHANGED
@@ -22,30 +22,26 @@
22
22
 
23
23
  - Apple Silicon Mac(M1 及以上;Intel Mac 和 Windows/Linux 跑不了,`h3_status` 会直接拦下告诉你,不会跑到一半崩掉)。
24
24
  - **建议 48GB 及以上统一内存**;32GB 会先警告、你确认了才继续,低于 32GB 直接拒绝。
25
- - 安装期留约 60GB 磁盘(从零安装实测峰值;装完引擎会自删源分片,稳态约 53GB——见下面资源占用)。
25
+ - 安装期留约 60GB 磁盘(从零安装实测峰值;装完引擎会自删源分片,之后大约占 53GB——见下面资源占用)。
26
26
  - DSH ≥ 0.2.2-rc.1,Node ≥ 22.19。
27
27
 
28
- ### 资源占用(实测,从零安装 2026-11-12/13)
28
+ ### 资源占用(实测)
29
29
 
30
- 下面每个数字都是在一台 275GB 内存的机器上从零装一遍实测出来的(没有任何可复用的旧文件),不是估算。
30
+ 数据由 M5 Ultra 256G 设备从零开始安装实测,所需时间因机器及网络情况而不同,仅做参考。
31
31
 
32
32
  | 项目 | 实测 |
33
33
  | --- | --- |
34
- | 磁盘峰值(安装全程最多占) | 58.6 GB:DiT 分片 21.5 + 文本编码器 28.2 + 在途源分片 5.4 + venv 1.1 |
35
- | 磁盘稳态(装完之后) | 53.2 GB(引擎转换完会自删源分片) |
36
- | 建 venv | ~18 s(本机有合适的独立 Python 就直接用,没有就如实说没有) |
37
- | 引擎 clone + pip install | ~72 s |
38
- | 单个 transformer 分片(下载 5.5 GB + Q8 转换 + 删除) | ~4–5 分钟 |
39
- | 续传段(7 个分片 + 28.2 GB 文本编码器) | 41 分钟 |
40
- | 第一次出图 | 30 s(引擎实际耗时 10.8 s;1 MP,6 步) |
41
- | 生图内存峰值(引擎 metrics) | 27.5 GB / 张 @ 1 MP |
42
- | 运行期间宿主已用内存 | 274 GB——含常驻推理服务;插件自己占的就是上面那 27.5 GB |
43
-
44
- 中断的步骤可以接着来:被杀的下载从 `.part` 继续(Range 请求),下完的分片绝不重下——上面那次从零安装的续传过程全程有日志可对账。
34
+ | 安装期间磁盘 | 峰值约 60 GB |
35
+ | 装完后磁盘 | 约 53 GB(源分片转换完会自动删掉) |
36
+ | 单张图内存(1 MP) | 约 27.5 GB |
37
+ | 每个权重分片(下载 + 转换) | 约 4–5 分钟,看你的网速 |
38
+ | 第一次出图 | 约 30 秒 |
39
+
40
+ 中断的步骤可以接着来:下到一半断了从 `.part` 继续,下完的分片不会重下。内存那行是引擎自己报的单张图占用。
45
41
 
46
42
  ### 许可——下载权重前必读
47
43
 
48
- 本插件的**代码**是 MIT。插件不打包、不托管、不再分发模型——模型和它的许可条款跟插件无关,插件只是个带许可确认环节的下载器和运行器。安装向导会从 Hugging Face 官方仓库按钉定版本下载权重,下载任何字节之前**先展示两份协议的要点和全文直链**(权重:MiniMax H3 Image 社区许可;量化文本编码器:MiniMax H3 社区许可,各来自自己的上游仓库),并**点名不支持的地区(欧盟、英国、韩国、美国)**;协议原件会随下载存到你的模型目录里。要你自己确认接受,插件绝不代你点。上游引擎是 Apache-2.0。详见 [THIRD_PARTY_NOTICES.md](THIRD_PARTY_NOTICES.md)。
44
+ 本插件的**代码**是 MIT。插件不打包、不托管、不再分发模型——模型和它的许可条款跟插件无关,插件只是个带许可确认环节的下载器和运行器。安装向导会从 Hugging Face 官方仓库按固定版本下载权重,下载任何字节之前**先展示两份协议的要点和全文链接**(权重:MiniMax H3 Image 社区许可;量化文本编码器:MiniMax H3 社区许可,各来自自己的上游仓库),并**点名不支持的地区(欧盟、英国、韩国、美国)**;协议原件会随下载存到你的模型目录里。要你自己确认接受,插件绝不代你点。上游引擎是 Apache-2.0。详见 [THIRD_PARTY_NOTICES.md](THIRD_PARTY_NOTICES.md)。
49
45
 
50
46
  ### 安装(DSH)
51
47
 
@@ -65,7 +61,7 @@ npm test # 单测(纯检查逻辑)
65
61
  npm run release # 门禁 + pack + tarball 扫描
66
62
  ```
67
63
 
68
- 两道发布门禁会在 CI 和 `prepack` 时自动跑:`scripts/check-release-safety.mjs` 扫源码**和**发布包(不含本机路径/用户名、不含 macOS 垃圾文件、不含密钥),`scripts/check-version-consistency.mjs` 核对 package.json、CHANGELOG、locale、钉定版本四处一致。
64
+ 两个发布检查在 CI 和 `prepack` 里自动跑,你不用记着手动跑:`check-release-safety` 保证源码和发出去的包里不含本机路径、用户名、macOS 垃圾文件和密钥;`check-version-consistency` 保证 package.json、CHANGELOG、两个 locale 里的版本号一致,`lib/pinned.js` 里钉的版本号格式合法。
69
65
 
70
66
  ---
71
67
 
@@ -81,7 +77,7 @@ The current version ships the full local pipeline: the read-only environment che
81
77
 
82
78
  | Tool | Purpose |
83
79
  | --- | --- |
84
- | `h3_status` | Read-only health check: platform, unified memory, venv, engine commit, weights, text encoder, free disk — each red item carries a fix hint. |
80
+ | `h3_status` | Read-only health check: platform, unified memory, venv, engine version, weights, text encoder, free disk — each red item carries a fix hint. |
85
81
  | `h3_setup` | The one-time setup wizard as a resumable state machine: `check → venv → engine → license → weights → smoke`. Long steps (engine install, ~59 GB of downloads + conversion) run as detached background jobs — submit returns a `job_id` in seconds, `action=poll` reads progress from the engine's own on-disk state, and an interrupted download resumes from `.part` on re-run. A dead job is reported `interrupted`, never "done". `action=license` shows the community license; acceptance is recorded only by you. `action=reset` clears the local state record. |
86
82
  | `h3_image` | Text-to-image: one engine subprocess per call, internal deadline, one generation at a time (a second call gets an immediate `busy`), PNG verified before it is reported, output lands in your session workspace. |
87
83
 
@@ -89,26 +85,22 @@ The current version ships the full local pipeline: the read-only environment che
89
85
 
90
86
  - Apple Silicon Mac (M1 or later; Intel Macs and Windows/Linux are not supported — `h3_status` declines them up front instead of crashing halfway).
91
87
  - **48 GB+ unified memory recommended**; 32 GB machines are warned-then-confirmed, below 32 GB is refused.
92
- - ~60 GB free disk during setup (measured peak on a from-zero install; the steady state after the engine deletes source shards is ~53 GB — see the resource ledger below).
88
+ - ~60 GB free disk during setup (measured peak on a from-zero install; the steady state after the engine deletes source shards is ~53 GB — see the resource usage below).
93
89
  - DSH ≥ 0.2.2-rc.1, Node ≥ 22.19.
94
90
 
95
- ### Resource usage (measured, from-scratch install 2026-11-12/13)
91
+ ### Resource usage (measured)
96
92
 
97
- Every number below comes from one from-zero acceptance run on a 275 GB Apple Silicon machine (no reuse candidates, fresh venv/engine/weights) — not from estimates.
93
+ Measured on an M5 Ultra with 256 GB of unified memory, from a from-scratch install. Times vary with your machine and your network, so treat them as a reference.
98
94
 
99
95
  | Item | Measured |
100
96
  | --- | --- |
101
- | Disk peak (incremental, whole setup) | 58.6 GB (54.6 GiB): DiT pack 21.5 + text encoder 28.2 + one in-flight source shard 5.4 + venv 1.1 |
102
- | Disk steady state (post-setup) | 53.2 GB (source shards deleted by the engine after conversion) |
103
- | venv creation | ~18 s (reuses a suitable standalone CPython when found; reports a miss otherwise) |
104
- | Engine clone + pip install | ~72 s |
105
- | Weights: per transformer shard (download 5.5 GB + Q8 convert + delete) | ~4–5 min |
106
- | Weights: resume segment (7 shards + 28.2 GB text encoder) | 41 min |
107
- | Smoke generation | 30 s wall / 10.8 s engine time (1 MP, 6 steps) |
108
- | Generation peak memory (engine metrics) | 27.5 GB per image at 1 MP |
109
- | Host memory in use during the run | 274 GB — includes a resident inference server; the plugin's own footprint is the 27.5 GB above |
110
-
111
- Interrupted steps resume: a killed download continues from its `.part` (Range requests), and finished shards are never re-fetched — verified by the acceptance run's resume audit (zero re-downloads of completed shards).
97
+ | Disk during setup | ~60 GB at peak |
98
+ | Disk after setup | ~53 GB (source shards are deleted once converted) |
99
+ | Memory per image (1 MP) | ~27.5 GB |
100
+ | Per weight shard (download + convert) | ~4–5 min, depends on your connection |
101
+ | First image | ~30 s |
102
+
103
+ Interrupted steps resume: a killed download continues from its `.part`, and finished shards are never re-downloaded. The memory figure is the per-image footprint the engine reports itself.
112
104
 
113
105
  ### Licenses — read before downloading weights
114
106
 
@@ -132,8 +124,8 @@ npm test # unit tests (pure check logic)
132
124
  npm run release # gates + pack + tarball scan
133
125
  ```
134
126
 
135
- Two release gates run in CI and on `prepack`:
136
- `scripts/check-release-safety.mjs` (no machine fingerprints, no AppleDouble,
137
- no secrets — in source **and** in the built tarball) and
138
- `scripts/check-version-consistency.mjs` (package.json ↔ CHANGELOG ↔ locales ↔
139
- pinned revisions).
127
+ The two release checks also run in CI and on `prepack`, so you don't have to remember
128
+ them: `check-release-safety` makes sure the source and the published package are free of
129
+ local paths, usernames, macOS junk files and secrets; `check-version-consistency` checks
130
+ that the version in package.json, CHANGELOG and both locale files agree, and that the
131
+ pinned revisions in `lib/pinned.js` are well-formed.
package/locale/en.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "meta": {
3
3
  "title": "H3 Image (local MLX)",
4
- "description": "Unofficial third-party plugin, not affiliated with MiniMax. In Apple Silicon, fully local text-to-image with the open-source MiniMax H3-Image (MLX engine). A one-time setup wizard downloads the pinned engine and weights to your machine (the MiniMax community license and its region terms are shown before any download; you accept it yourself), then generation runs offline — no keys, no accounts, no egress. Long setup steps are background jobs that survive restarts and resume where they stopped. Requires Apple Silicon with 48 GB+ unified memory (32 GB is not guaranteed) and ~60 GB free disk during setup; Intel Macs and other platforms are declined up front. Current version (0.2.4): read-only environment check, one-click setup wizard, and local generation (the community license must be explicitly accepted by you before the first image)."
4
+ "description": "Unofficial third-party plugin, not affiliated with MiniMax. On Apple Silicon, fully local text-to-image with the open-source MiniMax H3-Image (MLX engine). A one-time setup wizard downloads a fixed version of the engine and weights to your machine (the MiniMax community license and its region terms are shown before any download; you accept it yourself), then generation runs offline — no keys, no accounts, no network access. Long setup steps are background jobs that survive restarts and resume where they stopped. Requires Apple Silicon with 48 GB+ unified memory (32 GB is not guaranteed) and ~60 GB free disk during setup; Intel Macs and other platforms are declined up front. Current version (0.2.6): read-only environment check, setup wizard, and local generation (the community license must be explicitly accepted by you before the first image)."
5
5
  }
6
6
  }
package/locale/zh.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "meta": {
3
3
  "title": "H3 本地生图(MLX)",
4
- "description": "非官方第三方插件,与 MiniMax 无关联。在 Apple Silicon 上用开源 MiniMax H3-Image(MLX 引擎)做完全本地文生图。一键安装向导一次性把钉定版本的引擎与权重下载到本机(下载前展示 MiniMax 社区许可及地域条款,由你本人确认接受);之后生图全程离线——零密钥、零账号、零出网。安装中的长步骤是后台任务,宿主重启不丢、断点续传。需 Apple Silicon、48GB 及以上统一内存(32GB 不保证)、安装期约 60GB 可用磁盘;Intel Mac 与其他平台在检查阶段即明确拒绝。当前版本(0.2.4):只读环境体检 + 一键安装向导 + 本地产图(社区许可需你本人显式确认接受后才会出图)。"
4
+ "description": "非官方第三方插件,与 MiniMax 无关联。在 Apple Silicon 上用开源 MiniMax H3-Image(MLX 引擎)做完全本地文生图。安装向导一次性把固定版本的引擎与权重下载到本机(下载前展示 MiniMax 社区许可及地域条款,由你本人确认接受);之后生图全程离线——不用密钥、不用账号、不联网。安装中的长步骤是后台任务,DSH 重启不丢、断点续传。需 Apple Silicon、48GB 及以上统一内存(32GB 不保证)、安装期约 60GB 可用磁盘;Intel Mac 与其他平台在检查阶段即明确拒绝。当前版本(0.2.6):只读环境体检 + 安装向导 + 本地产图(社区许可需你本人确认接受后才会出图)。"
5
5
  }
6
6
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dsh-h3-image",
3
- "version": "0.2.4",
3
+ "version": "0.2.6",
4
4
  "description": "在 Apple Silicon 上用开源 MiniMax H3-Image(MLX 引擎)做完全本地文生图的 DeepSeek Harness 插件:一键安装向导 + 零出网本地生图。Fully local MiniMax H3-Image text-to-image on Apple Silicon MLX — a DeepSeek Harness plugin with a one-time setup wizard and zero-egress generation.",
5
5
  "type": "module",
6
6
  "main": "./lib/index.js",