README: the engine is the flux-klein.js npm package
Browse filesCo-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DGtw9KfFunZUshHNBE9jSq
README.md
CHANGED
|
@@ -16,7 +16,16 @@ hand-written WGSL (WebGPU), the distilled text encoder and BFL's distilled VAE t
|
|
| 16 |
onnxruntime-web. The page streams these files straight into the browser and keeps them in the
|
| 17 |
origin private file system, so a second visit starts in seconds.
|
| 18 |
|
| 19 |
-
This repo holds **weights only**. The engine
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 20 |
|
| 21 |
## Layout
|
| 22 |
|
|
|
|
| 16 |
onnxruntime-web. The page streams these files straight into the browser and keeps them in the
|
| 17 |
origin private file system, so a second visit starts in seconds.
|
| 18 |
|
| 19 |
+
This repo holds **weights only**. The engine is the
|
| 20 |
+
[flux-klein.js](https://github.com/radames/flux-klein.js) npm package (the WGSL transformer, the
|
| 21 |
+
ONNX text encoder and VAE, the OPFS cache); the demo page lives in the Space. The package fetches
|
| 22 |
+
from this repo by default:
|
| 23 |
+
|
| 24 |
+
```js
|
| 25 |
+
import { createFluxKlein } from "flux-klein.js";
|
| 26 |
+
const klein = await createFluxKlein(); // base: https://huggingface.co/radames/flux2-klein-edge-web/resolve/main
|
| 27 |
+
const { rgba, width, height } = await klein.generate({ prompt: "a red bicycle", width: 256, height: 256 });
|
| 28 |
+
```
|
| 29 |
|
| 30 |
## Layout
|
| 31 |
|