Skip to contents

Returns TRUE if the local Ollama daemon is reachable (i.e. responds to a GET /api/tags request within a short timeout). This is used internally to decide whether to fall back to TF-IDF when the caller requests method = "ollama".

Usage

ollama_available()

Value

Logical(1).

Configuration

Set the OLLAMA_BASE_URL environment variable to override the default endpoint (http://localhost:11434).

Examples

if (FALSE) { # \dontrun{
if (ollama_available()) {
  result <- embed_nodes(nodes, method = "ollama")
}
} # }