org.llm4s.llmconnect
package org.llm4s.llmconnect
Members list
Packages
package org.llm4s.llmconnect.caching
package org.llm4s.llmconnect.config
package org.llm4s.llmconnect.encoding
package org.llm4s.llmconnect.extractors
package org.llm4s.llmconnect.model
package org.llm4s.llmconnect.provider
package org.llm4s.llmconnect.streaming
package org.llm4s.llmconnect.utils
Type members
Classlikes
Attributes
- Companion
- object
- Supertypes
-
class Objecttrait Matchableclass Any
object EmbeddingClient
Attributes
- Companion
- class
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
EmbeddingClient.type
trait LLMClient
Core interface for interacting with Large Language Model providers.
Core interface for interacting with Large Language Model providers.
Abstracts communication with various LLM APIs (OpenAI, Azure OpenAI, Anthropic, etc.), providing a unified interface for completion requests, streaming responses, and token management. Implementations handle provider-specific authentication, message formatting, and tool calling.
Attributes
- Supertypes
-
class Objecttrait Matchableclass Any
- Known subtypes
-
class CachingLLMClientclass AnthropicClientclass DeepSeekClientclass GeminiClientclass OllamaClientclass OpenAIClientclass OpenRouterClientclass ZaiClientShow all
object LLMClientRetry
Stateless helper functions for retrying LLM completion and streaming calls.
Stateless helper functions for retrying LLM completion and streaming calls.
Retries only on recoverable errors (e.g. rate limit, timeout). Fails immediately on non-recoverable errors.
'''Retry delay precedence''' (honors upstream backpressure):
- If the error provides a provider retry-delay hint (e.g. RateLimitError.retryDelay, ServiceError.retryDelay) and it is present and positive, that value is used so we do not retry before the server is ready.
- Otherwise we fall back to local exponential backoff (baseDelay * 2^attempt) to avoid tight retry loops.
- The chosen delay is always capped at 30 seconds so waits remain bounded.
Attributes
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
LLMClientRetry.type
object LLMConnect
Attributes
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
LLMConnect.type
In this article