---
title: "vision.answer@1 · OpenVibe.Services"
canonical: "https://openvibe.services/docs/contracts/vision.answer"
updated: null
---

# vision.answer@1 · OpenVibe.Services

HTML: [vision.answer@1 · OpenVibe.Services](https://openvibe.services/docs/contracts/vision.answer)

# VisionAnswer `vision.answer@1`

Generated at 2026-11-13 06:25:48 UTC from [`openvibe-contracts v0.419.0`](https://github.com/OpenVibers/OpenVibe.Contracts/tree/v0.419.0) and [`openvibe-sdk v0.161.0`](https://github.com/OpenVibers/OpenVibe.SDK/tree/v0.161.0).

- Version: 1.0.0
- Owner: vision
- Visibility: first-party
- Status: active
- Compatibility: backward
- Schema: [`https://openvibe.network/contracts/vision/answer.v1.json`](/docs/contracts/vision.answer.json)

vision.answer@1: one saved answer on OpenVibe.Vision. It names the engine, model, provider and route that actually answered (never a model hint), the reason it was chosen, the cost OpenVibe.AI reported, the measured latency and the confidence. No image bytes are stored: only a sha256 and the declared media type.

## Fields

| Field | Type | Required | Description | Constraints |
| --- | --- | --- | --- | --- |
| `id` | string | yes |  | - `pattern ^vis_[0-9A-HJKMNP-TV-Z]{26}$` |
| `task` | enum | yes |  | - `one of "ask", "describe", "identify", "count", "translate", "ocr", "compare"` |
| `question` | string \| null |  |  | - `maxLength 2000` |
| `mode` | enum | yes |  | - `one of "auto", "local", "ai"` |
| `source` | enum | yes |  | - `one of "upload", "url", "data"` |
| `source_url` | string \| null |  |  | - `format uri` |
| `image_sha256` | string | yes |  | - `pattern ^[0-9a-f]{64}$` |
| `image_mime` | string | yes |  | - `pattern ^image/[a-z0-9.+-]+$` |
| `image_bytes` | integer | yes |  | - `minimum 1`<br>- `maximum 20971520` |
| `text` | string \| null |  |  | - `maxLength 20000` |
| `answer` | object | yes | Engine details, OCR words, provenance and any compare rows; never an image. |  |
| `model` | string \| null |  |  |  |
| `provider` | string \| null |  |  |  |
| `route` | string \| null |  |  |  |
| `reason` | string \| null |  |  |  |
| `engine` | string \| null |  |  |  |
| `confidence` | number \| null |  |  | - `minimum 0`<br>- `maximum 1` |
| `cost_usd` | number | yes |  | - `minimum 0` |
| `latency_ms` | integer | yes |  | - `minimum 0` |
| `created_at` | string | yes |  | - `format date-time` |

## Examples

From the contract's own test fixtures: valid ones validate, rejected ones must fail.

 Valid: one

~~~~
{
  "id": "vis_01J8Z3Q4R5S6T7V8W9X0Y1Z2A4",
  "task": "ask",
  "mode": "auto",
  "source": "upload",
  "image_sha256": "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
  "image_mime": "image/png",
  "image_bytes": 1024,
  "text": "A desk with a keyboard and a mug.",
  "answer": {
    "engine": "local",
    "route": "local.ocr"
  },
  "model": "tesseract",
  "provider": "local",
  "route": "local.ocr",
  "reason": "the local OCR reader answered the read task; no model was called",
  "cost_usd": 0,
  "latency_ms": 42,
  "created_at": "2026-10-29T10:00:00.000Z"
}
~~~~

Rejected: one

~~~~
{
  "id": "vis_short",
  "task": "ask",
  "mode": "auto",
  "source": "upload",
  "cost_usd": 0,
  "latency_ms": 0,
  "created_at": "2026-10-29T10:00:00.000Z",
  "answer": {}
}
~~~~

## Validate

~~~~
const contracts = require('openvibe-contracts');
contracts.validate('vision.answer@1', value);   // { valid, errors: [{ path, message }] }
~~~~
