Skip to main content
Glama

Image To Text

image_to_text

Extract text from images such as documents, screenshots, and signs using OCR, returning results as plain text or JSON.

Instructions

Extract text from image using OCR (Optical Character Recognition).

Reads text from images like documents, screenshots, signs, etc.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "image": "<image>",
      "model": "<model>"
    },
    "name": "image_to_text"
  }
}

Input Schema

NameRequiredDescriptionDefault
imageYesImage file (base64 encoded or URL)
modelYesOCR model (e.g., 'Nanonets_Ocr_S_F16')
formatNoOutput format: 'text' or 'json'text
languageNoLanguage code for OCR (e.g., 'en', 'es', 'fr') - optional
webhook_urlNoHTTPS URL for deAPI to call when this job finishes. Notifies your own systems; the tool still returns the result here
webhook_secretNo32-255 char key deAPI signs the callback with (HMAC-SHA256). Needs webhook_url. A secret given in chat stays in the transcript
return_result_in_responseNoReturn the extracted text inline in 'result'. Set to False to get only a download URL

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.6.3

TDQS

B3.2/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are supplied, so the description carries the full behavioral burden, and it discloses almost nothing: it does not say the tool runs as an asynchronous job (implied by webhook_url/check_job_status siblings), does not mention cost or credit consumption, and does not note that a valid OCR model name must be obtained first. The rich schema and output schema cover some ground, but the description itself adds only the bare OCR behavior already in the title.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two short sentences with the core action front-loaded and no filler. The second sentence largely restates the first with example inputs, which is mildly redundant but still useful for scoping.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With 7 parameters, an asynchronous webhook path, a model-discovery dependency, and a price sibling, the definition should do more than state 'OCR'. The output schema offsets the need to explain return values, but the absence of async-job, cost, and model-selection context leaves real gaps for an agent deciding how to call this correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so every parameter including image, model, format, language, webhook fields, and return_result_in_response is already documented in the schema. The description adds no extra meaning such as accepted image size limits, base64 encoding constraints, or language fallback behavior, so baseline 3 applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description names a specific verb and resource ('Extract text from image') and specifies the mechanism (OCR), so the tool's function is unambiguous. It does not distinguish itself from the sibling price variant (image_to_text_price) or note the relationship to check_job_status, so it stops short of a 5.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The clause 'Reads text from images like documents, screenshots, signs, etc.' implies the applicable input types, which gives some usage context. However there is no explicit when-to-use/when-not guidance, no mention of the price sibling for cost estimation, and no pointer to get_available_models despite a required 'model' parameter.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.