LiteRtLmClient class
gRPC client wrapper for LiteRT-LM server communication
Constructors
Properties
- conversationId → String?
-
Current conversation ID
no setter
- hashCode → int
-
The hash code for this object.
no setterinherited
- isInitialized → bool
-
Whether the client is connected and model is initialized
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
chat(
String text, {String? conversationId}) → Stream< String> - Send a chat message and get streaming response
-
chatWithImage(
String text, Uint8List imageBytes, {String? conversationId}) → Stream< String> - Send a multimodal chat message (text + image)
-
closeConversation(
{String? conversationId}) → Future< void> - Close current conversation
-
connect(
{String host = 'localhost', int? port}) → Future< void> - Connect to the gRPC server
-
createConversation(
{String? systemMessage}) → Future< String> - Create a new conversation
-
disconnect(
) → Future< void> - Disconnect from server
-
healthCheck(
) → Future< bool> - Health check
-
initialize(
{required String modelPath, String backend = 'gpu', int maxTokens = 2048}) → Future< void> - Initialize the model
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
shutdown(
) → Future< void> - Shutdown the model engine
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited