Protected ReadonlynamespacePrefixes this class's error messages, like edgeAi.
Encode an image on the box for model, returning an ImageEmbeddingRef
to reuse across prompts. The ref is only valid for model.
OptionalabortSignal: AbortSignalLoad a model onto the box (starts/keeps it resident). Rejects if it fails.
Run a one-shot prompt against a loaded model and return the full response.
Optionalimage: string | ImageBytesOptionalabortSignal: AbortSignalTranscribe complete audio with a loaded speech model and return the whole
transcript. Takes only a finished buffer: a feed has no result until it ends,
so there would be nothing to return.
Run a prompt and stream the generated tokens as they arrive (SSE).
Optionalimage: string | ImageBytesOptionalabortSignal: AbortSignalTranscribe audio with a loaded speech model, streaming results as they are
decoded. Consume with for await; call cancel() to stop early.
audio may be a finished buffer or a feed that produces samples over time; a
feed is sent as the request body arrives rather than being collected first.
Tokenise prompt on the box with model's tokenizer.
OptionalabortSignal: AbortSignalStaticnewCreate the ViviAiInterface for the box's edge AI, an EdgeAi when there is connection info.
If the feature is not enabled or the info is undefined then a stub is returned that will error.
TODO IGNT-895: Make sure the returned stub properly returns an error state
The
edgeAinamespace on a BoxApplet. Talks directly to the box over HTTP. Obtained viaapplet.edgeAi.