Skip to content

ModelPackage

ModelPackage = object

Provider-neutral descriptor for a developer-supplied/custom local model made available to an IndeRun local-model provider family (for example, the ONNX Runtime family). It describes model identity, format, task support, source, files, integrity, licensing, and resource expectations. It is bootstrap/configuration metadata resolved before execution; it is not part of the public TaskRequest/TaskResult surface, and it must not carry raw secrets.

[property: string]: unknown

optional files?: Files

Files that make up the model package, expressed as source-relative names/paths. The provider adapter and model source resolve these to concrete bytes per platform.


format: Format

Model packaging format the target runtime family must understand. ‘onnx’ is a plain ONNX graph, ‘ort’ is an ONNX Runtime optimized/mobile format, ‘genai’ is an ONNX Runtime GenAI model package, ‘coreai’ is an Apple Core AI .aimodel asset (iOS/macOS 27+).


id: string

Stable application-scoped identifier for the model package.


optional integrity?: Integrity

Optional integrity metadata used to validate resolved files before load.


optional license?: License

Optional license/source metadata for the model, for developer transparency. Free-form.


optional limits?: Limits

Optional known resource expectations, used by capability checks to reject on constrained devices before load.


optional runtime?: Runtime

Optional runtime compatibility expectations. Fields are advisory hints for capability checks; the provider adapter owns exact enforcement.


optional source?: Source

Where the model files are obtained from. Availability of each source type is platform-dependent; see the ONNX Runtime provider-family specification for the per-platform support matrix.


optional speech?: SpeechModelPackage

What a text_to_speech model package adds: the pipeline that turns text into PCM, the graphs it runs, its text frontend and the voices it offers. Required when ‘tasks’ contains ‘text_to_speech’.


optional tasks?: string[]

IndeRun task kinds this model package can serve (for example ‘text_to_text’). Used by dynamic capability checks and route matching.


optional variant?: string

Optional concrete artifact variant of this logical model (for example ‘onnx-int8’, ‘coreai-fp16’). ‘id’ names the model, ‘variant’ the bytes.


optional version?: string

Optional application-defined version for the model package, used for cache invalidation and compatibility checks.