Classify Image
Classify Image
Section titled “Classify Image”Label an image entirely in your browser with an installed image-classification model (MobileNet on TensorFlow.js, ViT on transformers.js). No cloud call, no cost, no data leaving the device.
What it does
Section titled “What it does”Loads the image you provide, runs it through the selected on-device classifier, and returns the predicted labels with confidence scores — filtered by a threshold and capped to the top results.
When to use it
Section titled “When to use it”Tag or route images by content: sort uploads, flag categories, or branch a workflow on what an image contains — all offline and private.
Inputs and settings
Section titled “Inputs and settings”| Setting | Notes |
|---|---|
| Model | Any installed image-classification model, across engines. Download one from the picker if the list is empty. |
| Image | Image URL, data URL, or $binary from a previous node. |
| Confidence threshold | Drop predictions scoring below this value (default 0.1). |
| Top-K results | Keep at most this many labels (default 5). |
Outputs
Section titled “Outputs”Returns { predictions, top, score }:
predictions— array of{ label, score }, highest first, after threshold and top-K.top— the highest-scoring label (ornullif none pass the threshold).score— that label’s score.
Before you run
Section titled “Before you run”Install an image-classification model from the picker or the Local AI page. The first run loads the model into memory; later runs are fast.
Troubleshooting
Section titled “Troubleshooting”- Empty picker — no image-classification model is installed; add one first.
- No predictions — lower the confidence threshold, or try a stronger model (ViT over MobileNet).
- Slow first run — the model is loading/downloading; it stays warm for the session.