SyniRuntimeFFI class

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

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

Static Methods

engineFree(SyniEngineNative engine) → void
engineLoadModel(SyniEngineNative engine, String modelPath) bool
Replaces the model on an existing engine. Returns true on success.
engineNew() SyniEngineNative
engineNewWithModel(String modelPath) SyniEngineNative
Returns nullptr on failure (e.g. file not found, invalid GGUF).
engineRunJson(SyniEngineNative engine, SyniPreset preset, int seed, String requestJson) String?
Runs a synchronous inference. Returns the JSON response as a Dart string, or null on failure. The native string buffer is freed internally — callers do not need to call stringFree.
engineRunStreamJson(SyniEngineNative engine, SyniPreset preset, int seed, String requestJson, bool onChunk(String chunk)) String?
Streaming inference. Same shape as engineRunJson but fires onChunk for each emitted token chunk. Returns the final accumulated JSON.
initialize() DynamicLibrary
Force-load the native library and resolve function pointers.
stringFree(Pointer<Utf8> ptr) → void
Free a string that was allocated by syni_string_free (rare — usually the high-level methods handle this for callers).
version() String?
Runtime semver string, or null if the call failed.