getModelOrNull

suspend fun getModelOrNull(name: String, pullIfMissing: Boolean = false): OllamaModelCard?(source)

Returns a model card by its model name, on null if no such model exists on the server.

Parameters

name

the name of the model to get the model card for

pullIfMissing

true if you want to pull the model from the Ollama registry, false otherwise