org.llm4s.llmconnect.caching.CachingLLMClient
See theCachingLLMClient companion class
Attributes
-
Companion
-
class
-
Source
-
CachingLLMClient.scala
-
Graph
-
-
Supertypes
-
trait Matchable
class Any
-
Self type
-
Members list
A client that answers a prompt semantically close to an earlier one from its cache, and asks baseClient otherwise.
A client that answers a prompt semantically close to an earlier one from its cache, and asks baseClient otherwise.
Value parameters
-
baseClient
-
the client asked on a cache miss
-
config
-
the similarity threshold, the entries' time to live and how many are kept
-
embeddingClient
-
embeds each prompt: an EmbeddingClient, or any EmbeddingProvider
-
embeddingModel
-
the embedding model embeddingClient is asked for
-
tracing
-
receives a cache_hit or cache_miss event per call
Attributes
-
Source
-
CachingLLMClient.scala