Spaces:
Running
Running
Upload README.md with huggingface_hub
Browse files
README.md
CHANGED
|
@@ -14,11 +14,24 @@ Fully client-side OCR: text detection + CTC recognition + reading order +
|
|
| 14 |
orientation, running on [onnxruntime-web](https://onnxruntime.ai/docs/get-started/web)
|
| 15 |
(WebGPU when available, wasm otherwise). No server, no data leaves your machine.
|
| 16 |
|
| 17 |
-
-
|
|
|
|
|
|
|
| 18 |
(ONNX exports of [datalab-to/indra-ocr](https://huggingface.co/datalab-to/indra-ocr) v3.1.1)
|
| 19 |
-
|
| 20 |
-
|
|
|
|
|
|
|
|
|
|
| 21 |
|
| 22 |
-
|
| 23 |
-
|
| 24 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 14 |
orientation, running on [onnxruntime-web](https://onnxruntime.ai/docs/get-started/web)
|
| 15 |
(WebGPU when available, wasm otherwise). No server, no data leaves your machine.
|
| 16 |
|
| 17 |
+
- **Try an example** — draws a page in-page and runs it, or drop your own image.
|
| 18 |
+
- Models stream once from
|
| 19 |
+
[tomngdev/indra-ocr-onnx](https://huggingface.co/tomngdev/indra-ocr-onnx)
|
| 20 |
(ONNX exports of [datalab-to/indra-ocr](https://huggingface.co/datalab-to/indra-ocr) v3.1.1)
|
| 21 |
+
and are cached by the browser.
|
| 22 |
+
- Everything else — app + `indra-ocr-web` library — is bundled **into the single
|
| 23 |
+
`index.html`**, so the page makes no relative requests and works from any URL
|
| 24 |
+
it is served at. The only external loads are absolute: the onnxruntime-web
|
| 25 |
+
module (CDN, pinned via an import map) and the model downloads (Hub).
|
| 26 |
|
| 27 |
+
## Rebuild
|
| 28 |
+
|
| 29 |
+
```bash
|
| 30 |
+
node space/build.mjs # in the indra-ocr-web repo; bundles app.mjs + library via esbuild
|
| 31 |
+
```
|
| 32 |
+
|
| 33 |
+
The importable library (for your own pages) lives in the model repo:
|
| 34 |
+
`indra-ocr-web.mjs` + `src/` on
|
| 35 |
+
[tomngdev/indra-ocr-onnx](https://huggingface.co/tomngdev/indra-ocr-onnx) — note
|
| 36 |
+
the Hub serves `.mjs` as `text/plain`, so host those files yourself (or bundle
|
| 37 |
+
them) rather than importing them from the Hub.
|