Liking cljdoc? Tell your friends :D

vaelii.agents.llm.provider

Which backend a turn runs against: :stub (the default), :ollama or :anthropic, resolved lazily, with an unreachable backend falling back to the stub. Every fn here that can build a stub reads that stub's own opts (vaelii.agents.llm.stub/provider) from opts's :stub, and hands a backend opts without it. See docs/llm.md § Choosing one.

Which backend a turn runs against: `:stub` (the default), `:ollama` or `:anthropic`,
resolved lazily, with an unreachable backend falling back to the stub.  Every fn here
that can build a stub reads that stub's own opts (`vaelii.agents.llm.stub/provider`)
from `opts`'s `:stub`, and hands a backend `opts` without it.  See docs/llm.md
§ Choosing one.
raw docstring

active-kindclj

(active-kind)
(active-kind opts)

The kind (provider) would hand back now.

The kind `(provider)` would hand back now.
sourceraw docstring

available?clj

(available? kind)
(available? kind opts)

Can this backend serve a turn now? :stub always can; :ollama probes the host named by opts's :host alone, so the probe keeps its own short deadline whatever :timeout-ms a turn allows; :anthropic looks for opts's :credential, then the environment's. Never throws: an unreachable or unloadable backend answers false.

Can this backend serve a turn now?  `:stub` always can; `:ollama` probes the host
named by `opts`'s `:host` alone, so the probe keeps its own short deadline whatever
`:timeout-ms` a turn allows; `:anthropic` looks for `opts`'s `:credential`, then the
environment's.  Never throws: an unreachable or unloadable backend answers false.
sourceraw docstring

buildclj

(build kind)
(build kind opts)

Build the named backend with opts, without probing it, or nil when it cannot be built. A constructor that throws is logged.

Build the named backend with `opts`, without probing it, or nil when it cannot be
built.  A constructor that throws is logged.
sourceraw docstring

configuredclj

(configured)

The backend named by VAELII_LLM_PROVIDER / -Dvaelii.llm.provider, or nil.

The backend named by `VAELII_LLM_PROVIDER` / `-Dvaelii.llm.provider`, or nil.
sourceraw docstring

generation-providerclj

(generation-provider)
(generation-provider kind)
(generation-provider kind opts)

provider for a generation turn, one that writes new content: a backend with a generation-provider constructor is built through it, any other through provider's.

`provider` for a generation turn, one that writes new content: a
backend with a `generation-provider` constructor is built through it, any other
through `provider`'s.
sourceraw docstring

providerclj

(provider)
(provider kind)
(provider kind opts)

The Provider to run a turn against: kind (default the configured one, else :stub) when it is available and builds, else a stub built from :stub. Never throws; a caller that must know which it got asks available? first.

The `Provider` to run a turn against: `kind` (default the configured one, else
`:stub`) when it is available and builds, else a stub built from `:stub`.  Never throws; a
caller that must know which it got asks `available?` first.
sourceraw docstring

warmclj

(warm)
(warm kind)

Run the backend's own warm and return what it reports, or nil when the backend has none (the stub, Anthropic) or it throws. See docs/llm.md § The local backend.

Run the backend's own `warm` and return what it reports, or nil when the backend has
none (the stub, Anthropic) or it throws.  See docs/llm.md § The local backend.
sourceraw docstring

cljdoc builds & hosts documentation for Clojure/Script libraries

Keyboard shortcuts
Ctrl+kJump to recent docs
←Move to previous article
→Move to next article
Ctrl+/Jump to the search field
× close