Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

sandbox-ocr

БесплатноБез исполняемых скриптовНе проверен

Read the text in an image from a Code node or CodeAct action, with tesseract.js running on the host

nodetool-aiот nodetool-ai★ 674 звезды на GitHub

Об этом скилле

OCR in the sandbox

Specifier: @nodetool-ai/sandbox-ocr. Import it at the top of the body.

tesseract.js runs a WASM engine, spawns workers, and downloads its language data on first use — none of which the guest can do. This pack is a host module: the import resolves to a generated facade over NodeTool's own implementation.

recognize — image bytes to text

import { recognize } from "@nodetool-ai/sandbox-ocr";

const { text, confidence, words } = await recognize(
  await workspace.readBytes("receipt.png")
);
const total = words.find((w) => /^\d+[.,]\d{2}$/.test(w.text));
return { text, confidence, total: total?.text ?? null };

One call gives you all three readings:

  • text — the whole page as one string.
  • confidence — the page mean, 0–100.
  • words — {text, confidence, bbox: {x, y, width, height}} per word, in reading order, with the box in image pixels.

Pass { language: "eng+deu" } for anything other than English; the codes are Tesseract's, +-joined. The data file for a language it has not seen before is downloaded the first time you ask for it, so that call is slower.

Get the bytes from workspace.readBytes, from await response.bytes(), or from an asset with assetToSandbox.

Gotchas

  • recognize is async, and the first call to it pays for engine startup.
  • 10 MB per image. Larger input is refused by name.
  • 20 000 words per page.
  • Straight, sharp scans read best. Use image.rotate and image.adjust to deskew and raise contrast before you hand the bytes over.

Установить sandbox-ocr в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

Вложенные файлы

package.json

FAQ

Что делает скилл sandbox-ocr?

Read the text in an image from a Code node or CodeAct action, with tesseract.js running on the host

Как установить скилл sandbox-ocr?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл sandbox-ocr запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить sandbox-ocr с