ExAthena.Chat.Ollama (ExAthena v0.15.0)

Copy Markdown View Source

Talks to a local Ollama daemon's native HTTP API for chat-time helpers.

Right now: one function, list_models/1, which hits GET /api/tags and returns the installed model names sorted alphabetically. The tags endpoint lives on the bare host (not under /v1), so we strip the OpenAI prefix ExAthena adds internally.

Summary

Functions

list_models(opts \\ [])

@spec list_models(keyword()) ::
  {:ok, [String.t()]}
  | {:error, :ollama_unreachable | :unexpected_response | {:http, integer()}}