All Bundles

Chat

Ollama chat client

Derived from: EndPoint

Operations

Code example:

chat := Chat->New("llama3");
chat->Send("How many people like in San Pablo, CA?")->PrintLine();
chat->Send("How of the population identify as Latino??")->PrintLine();
chat->Send("Thanks, what are the major landmarks?")->PrintLine();
chat->Send("Goodbye?")->PrintLine();

New

Constructor

New(model:String)
Parameters
NameTypeDescription
modelStringmodel name (i.e. llama3, llava)

Send

Chat response from the model given an input

method : public : Send(message:String) ~ String
Parameters
NameTypeDescription
messageStringchat message

Return
TypeDescription
Stringchat response

Chat response from the model given an input

method : public : Send(message:String, image:File) ~ String
Parameters
NameTypeDescription
messageStringchat message
imageFileimage file

Return
TypeDescription
Stringchat response

Chat response from the model given an input

method : public : Send(message:String, images:File[]) ~ String
Parameters
NameTypeDescription
messageStringchat query
imagesFileimage files

Return
TypeDescription
Stringchat response