Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
71 changes: 60 additions & 11 deletions .speakeasy/in.openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11697,6 +11697,30 @@ components:
required:
- 'data'
type: 'object'
ExtractionAsset:
additionalProperties: false
description: 'An image or PDF sent once and referenced by its key in the `assets` map. `data_base64` is the file in standard base64 with no `data:` prefix. PDF is read by document models only.'
properties:
data_base64:
minLength: 1
pattern: '^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$'
type: 'string'
format:
enum:
- 'png'
- 'jpg'
- 'jpeg'
- 'pdf'
type: 'string'
type:
enum:
- 'image'
- 'document'
type: 'string'
required:
- 'format'
- 'data_base64'
type: 'object'
ExtractionDateAnswer:
properties:
confidence:
Expand All @@ -11710,10 +11734,11 @@ components:
format: 'double'
type: 'number'
source:
description: 'Set to `image` when the answer was read from an image rather than the state text.'
description: 'Set to `image` or `document` when the answer was read from an image or a PDF rather than the state text.'
enum:
- 'state'
- 'image'
- 'document'
type: 'string'
span:
description: 'Unicode code point offsets [start, end) into the state text: index code points (not UTF-16 code units or UTF-8 bytes), so an emoji or accented letter counts once.'
Expand All @@ -11739,6 +11764,7 @@ components:
- 'value'
type: 'object'
ExtractionDateField:
additionalProperties: false
properties:
instructions:
description: 'What the field should contain.'
Expand Down Expand Up @@ -11769,10 +11795,11 @@ components:
format: 'double'
type: 'number'
source:
description: 'Set to `image` when the answer was read from an image rather than the state text.'
description: 'Set to `image` or `document` when the answer was read from an image or a PDF rather than the state text.'
enum:
- 'state'
- 'image'
- 'document'
type: 'string'
span:
description: 'Unicode code point offsets [start, end) into the state text: index code points (not UTF-16 code units or UTF-8 bytes), so an emoji or accented letter counts once.'
Expand All @@ -11798,6 +11825,7 @@ components:
- 'value'
type: 'object'
ExtractionDatetimeField:
additionalProperties: false
properties:
instructions:
description: 'What the field should contain.'
Expand Down Expand Up @@ -11829,10 +11857,11 @@ components:
format: 'double'
type: 'number'
source:
description: 'Set to `image` when the answer was read from an image rather than the state text.'
description: 'Set to `image` or `document` when the answer was read from an image or a PDF rather than the state text.'
enum:
- 'state'
- 'image'
- 'document'
type: 'string'
span:
description: 'Unicode code point offsets [start, end) into the state text: index code points (not UTF-16 code units or UTF-8 bytes), so an emoji or accented letter counts once.'
Expand Down Expand Up @@ -11862,6 +11891,7 @@ components:
- 'value'
type: 'object'
ExtractionDurationField:
additionalProperties: false
properties:
decimals:
description: 'Decimal places kept in `value`.'
Expand Down Expand Up @@ -11941,10 +11971,11 @@ components:
- type: 'string'
type: 'array'
source:
description: 'Set to `image` when the answer was read from an image rather than the state text.'
description: 'Set to `image` or `document` when the answer was read from an image or a PDF rather than the state text.'
enum:
- 'state'
- 'image'
- 'document'
type: 'string'
spell_confidence:
description: 'Confidence in the spelling of text read from an image.'
Expand All @@ -11965,6 +11996,7 @@ components:
- 'value'
type: 'object'
ExtractionEstimateField:
additionalProperties: false
properties:
instructions:
description: 'What the field should contain.'
Expand Down Expand Up @@ -12058,10 +12090,11 @@ components:
- type: 'string'
type: 'array'
source:
description: 'Set to `image` when the answer was read from an image rather than the state text.'
description: 'Set to `image` or `document` when the answer was read from an image or a PDF rather than the state text.'
enum:
- 'state'
- 'image'
- 'document'
type: 'string'
spell_confidence:
description: 'Confidence in the spelling of text read from an image.'
Expand Down Expand Up @@ -12089,6 +12122,7 @@ components:
- 'value'
type: 'object'
ExtractionForecastField:
additionalProperties: false
properties:
horizon:
description: 'Number of forecast steps.'
Expand Down Expand Up @@ -12206,6 +12240,12 @@ components:
confidence:
format: 'double'
type: 'number'
confidences:
description: 'One confidence per item of `value`, in the same order.'
items:
format: 'double'
type: 'number'
type: 'array'
guess:
description: 'The most likely value even when `value` is null because `p_null` crossed the threshold.'
items:
Expand All @@ -12219,10 +12259,11 @@ components:
format: 'double'
type: 'number'
source:
description: 'Set to `image` when the answer was read from an image rather than the state text.'
description: 'Set to `image` or `document` when the answer was read from an image or a PDF rather than the state text.'
enum:
- 'state'
- 'image'
- 'document'
type: 'string'
spans:
items:
Expand Down Expand Up @@ -12255,6 +12296,7 @@ components:
- 'value'
type: 'object'
ExtractionListField:
additionalProperties: false
properties:
decimals:
description: 'Decimal places kept in `value`.'
Expand Down Expand Up @@ -12298,10 +12340,11 @@ components:
format: 'double'
type: 'number'
source:
description: 'Set to `image` when the answer was read from an image rather than the state text.'
description: 'Set to `image` or `document` when the answer was read from an image or a PDF rather than the state text.'
enum:
- 'state'
- 'image'
- 'document'
type: 'string'
span:
description: 'Unicode code point offsets [start, end) into the state text: index code points (not UTF-16 code units or UTF-8 bytes), so an emoji or accented letter counts once.'
Expand All @@ -12328,6 +12371,7 @@ components:
- 'value'
type: 'object'
ExtractionNumberField:
additionalProperties: false
properties:
decimals:
description: 'Decimal places kept in `value`.'
Expand Down Expand Up @@ -12355,11 +12399,12 @@ components:
- 'type'
type: 'object'
ExtractionsRequest:
additionalProperties: false
properties:
assets:
additionalProperties:
$ref: '#/components/schemas/DecisionsImageAsset'
description: 'Images keyed by reference string, as in TypeSafe''s API. Write a reference wherever the image belongs in `state`, `instructions`, or `criteria`; every asset must be referenced at least once. Jev reads a reference as a whole string value or inside longer text. Other Decisions models read a whole-string reference wherever they read an `image_url` part and reject a reference inside longer text.'
$ref: '#/components/schemas/ExtractionAsset'
description: 'Assets keyed by reference string. Write a reference wherever the asset belongs in `state` or a field `instructions`; every asset must be referenced at least once. A `state` that is exactly the sole asset''s key carries no text of its own and is read as file-only. A model that reads either text or a document per request, not both (ScaleDown Extract with a PDF), needs that form: any other text around the key is state text and is rejected with 400.'
type: 'object'
fields:
additionalProperties:
Expand Down Expand Up @@ -12500,10 +12545,11 @@ components:
format: 'double'
type: 'number'
source:
description: 'Set to `image` when the answer was read from an image rather than the state text.'
description: 'Set to `image` or `document` when the answer was read from an image or a PDF rather than the state text.'
enum:
- 'state'
- 'image'
- 'document'
type: 'string'
span:
description: 'Unicode code point offsets [start, end) into the state text: index code points (not UTF-16 code units or UTF-8 bytes), so an emoji or accented letter counts once.'
Expand All @@ -12529,6 +12575,7 @@ components:
- 'value'
type: 'object'
ExtractionTextField:
additionalProperties: false
properties:
instructions:
description: 'What the field should contain.'
Expand Down Expand Up @@ -12559,10 +12606,11 @@ components:
format: 'double'
type: 'number'
source:
description: 'Set to `image` when the answer was read from an image rather than the state text.'
description: 'Set to `image` or `document` when the answer was read from an image or a PDF rather than the state text.'
enum:
- 'state'
- 'image'
- 'document'
type: 'string'
span:
description: 'Unicode code point offsets [start, end) into the state text: index code points (not UTF-16 code units or UTF-8 bytes), so an emoji or accented letter counts once.'
Expand All @@ -12588,6 +12636,7 @@ components:
- 'value'
type: 'object'
ExtractionTimeField:
additionalProperties: false
properties:
instructions:
description: 'What the field should contain.'
Expand Down
Loading