InferenceEngineProvider class abstract

A pluggable inference engine (MediaPipe .task, LiteRT-LM .litertlm, or a third-party .onnx/.gguf engine).

Implemented in an engine package (e.g. flutter_gemma_mediapipe) and passed to FlutterGemma.initialize via inferenceEngines:. Core selects an engine by probing: the first registered engine (highest priority) whose canHandle returns true for the active model spec wins. There is NO central file-type map — a third-party engine self-selects with zero core changes.

Constructors

InferenceEngineProvider()

Properties

hashCode int
The hash code for this object.
no setterinherited
name String
Human-readable name for diagnostics / error messages (e.g. 'MediaPipe').
no setter
priority int
Selection precedence on overlap. Core engines use 0; a third party raises this to take precedence for a spec both could handle.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

canHandle(InferenceModelSpec spec) bool
Whether this engine can run spec. Probed by the registry.
createModel(InferenceModelSpec spec, RuntimeConfig config) Future<InferenceModel>
Build a runtime InferenceModel for spec + config.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited