Index

A B C D E F G H I J K L M N O P Q R S T U V W 
All Classes and Interfaces|All Packages|Constant Field Values|Serialized Form

A

ABSOLUTE_DIRECTORY_PATH - Static variable in interface dev.langchain4j.data.document.Document
Common metadata key for the absolute path of the directory from which the document was loaded.
add(Embedding) - Method in interface dev.langchain4j.store.embedding.EmbeddingStore
Adds a given embedding to the store.
add(Embedding, Embedded) - Method in interface dev.langchain4j.store.embedding.EmbeddingStore
Adds a given embedding and the corresponding content that has been embedded to the store.
add(ChatMessage) - Method in interface dev.langchain4j.memory.ChatMemory
Adds a message to the chat memory.
add(TokenUsage) - Method in class dev.langchain4j.model.output.TokenUsage
Adds the token usage of two responses together.
add(String, Embedding) - Method in interface dev.langchain4j.store.embedding.EmbeddingStore
Adds a given embedding to the store.
addAll(List<Embedding>) - Method in interface dev.langchain4j.store.embedding.EmbeddingStore
Adds multiple embeddings to the store.
addAll(List<Embedding>, List<Embedded>) - Method in interface dev.langchain4j.store.embedding.EmbeddingStore
Adds multiple embeddings and their corresponding contents that have been embedded to the store.
addAll(List<String>, List<Embedding>, List<Embedded>) - Method in interface dev.langchain4j.store.embedding.EmbeddingStore
Adds multiple embeddings and their corresponding contents that have been embedded to the store.
addBooleanProperty(String) - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema.Builder
Adds a single boolean property to the properties of this JSON object.
addBooleanProperty(String, String) - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema.Builder
Adds a single boolean property with a description to the properties of this JSON object.
addContent(Content) - Method in class dev.langchain4j.data.message.UserMessage.Builder
 
addEnumProperty(String, List<String>) - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema.Builder
Adds a single enum property to the properties of this JSON object.
addEnumProperty(String, List<String>, String) - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema.Builder
Adds a single enum property with a description to the properties of this JSON object.
addIntegerProperty(String) - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema.Builder
Adds a single integer property to the properties of this JSON object.
addIntegerProperty(String, String) - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema.Builder
Adds a single integer property with a description to the properties of this JSON object.
additionalParams() - Method in class dev.langchain4j.web.search.WebSearchRequest
Get the additional parameters for the search request.
additionalParams(Map<String, Object>) - Method in class dev.langchain4j.web.search.WebSearchRequest.Builder
Set the additional parameters for the search request.
additionalProperties() - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema
 
additionalProperties(Boolean) - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema.Builder
 
addNumberProperty(String) - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema.Builder
Adds a single number property to the properties of this JSON object.
addNumberProperty(String, String) - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema.Builder
Adds a single number property with a description to the properties of this JSON object.
addProperties(Map<String, JsonSchemaElement>) - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema.Builder
Adds all properties in the parameter Map to the properties of this JSON object.
addProperty(String, JsonSchemaElement) - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema.Builder
Adds a single property to the properties of this JSON object.
addStringProperty(String) - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema.Builder
Adds a single string property to the properties of this JSON object.
addStringProperty(String, String) - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema.Builder
Adds a single string property with a description to the properties of this JSON object.
aggregate(Map<Query, Collection<List<Content>>>) - Method in interface dev.langchain4j.rag.content.aggregator.ContentAggregator
Aggregates all Contents retrieved by all ContentRetrievers using all Querys.
aggregate(Map<Query, Collection<List<Content>>>) - Method in class dev.langchain4j.rag.content.aggregator.DefaultContentAggregator
 
aggregate(Map<Query, Collection<List<Content>>>) - Method in class dev.langchain4j.rag.content.aggregator.ReRankingContentAggregator
 
AI - Enum constant in enum class dev.langchain4j.data.message.ChatMessageType
A message from the AI.
aiMessage() - Method in class dev.langchain4j.model.chat.response.ChatResponse
 
aiMessage(ToolExecutionRequest...) - Static method in class dev.langchain4j.data.message.AiMessage
Create a new AiMessage with the given tool execution requests.
aiMessage(AiMessage) - Method in class dev.langchain4j.model.chat.response.ChatResponse.Builder
 
aiMessage(String) - Static method in class dev.langchain4j.data.message.AiMessage
Create a new AiMessage with the given text.
aiMessage(String, List<ToolExecutionRequest>) - Static method in class dev.langchain4j.data.message.AiMessage
Create a new AiMessage with the given text and tool execution requests.
aiMessage(List<ToolExecutionRequest>) - Static method in class dev.langchain4j.data.message.AiMessage
Create a new AiMessage with the given tool execution requests.
AiMessage - Class in dev.langchain4j.data.message
Represents a response message from an AI (language model).
AiMessage(String) - Constructor for class dev.langchain4j.data.message.AiMessage
Create a new AiMessage with the given text.
AiMessage(String, List<ToolExecutionRequest>) - Constructor for class dev.langchain4j.data.message.AiMessage
Create a new AiMessage with the given text and tool execution requests.
AiMessage(List<ToolExecutionRequest>) - Constructor for class dev.langchain4j.data.message.AiMessage
Create a new AiMessage with the given tool execution requests.
AiMessage.Builder - Class in dev.langchain4j.data.message
 
AMAZON_BEDROCK - Enum constant in enum class dev.langchain4j.model.ModelProvider
 
and(Filter) - Method in interface dev.langchain4j.store.embedding.filter.Filter
 
and(Filter, Filter) - Static method in interface dev.langchain4j.store.embedding.filter.Filter
 
And - Class in dev.langchain4j.store.embedding.filter.logical
 
And(Filter, Filter) - Constructor for class dev.langchain4j.store.embedding.filter.logical.And
 
ANTHROPIC - Enum constant in enum class dev.langchain4j.model.ModelProvider
 
anyOf() - Method in class dev.langchain4j.model.chat.request.json.JsonAnyOfSchema
 
anyOf(JsonSchemaElement...) - Method in class dev.langchain4j.model.chat.request.json.JsonAnyOfSchema.Builder
 
anyOf(List<JsonSchemaElement>) - Method in class dev.langchain4j.model.chat.request.json.JsonAnyOfSchema.Builder
 
apply(Object) - Method in class dev.langchain4j.model.input.PromptTemplate
Applies a value to a template containing a single variable.
apply(Map<String, Object>) - Method in class dev.langchain4j.model.input.PromptTemplate
Applies multiple values to a template containing multiple variables.
areNotNullOrBlank(String...) - Static method in class dev.langchain4j.internal.Utils
Are all the given strings not null and not blank?
arguments() - Method in class dev.langchain4j.agent.tool.ToolExecutionRequest
Returns the arguments of the tool.
arguments(String) - Method in class dev.langchain4j.agent.tool.ToolExecutionRequest.Builder
Sets the arguments.
attributes() - Method in class dev.langchain4j.data.message.CustomMessage
Returns the message attributes.
attributes() - Method in class dev.langchain4j.model.chat.listener.ChatModelErrorContext
 
attributes() - Method in class dev.langchain4j.model.chat.listener.ChatModelRequestContext
 
attributes() - Method in class dev.langchain4j.model.chat.listener.ChatModelResponseContext
 
audio() - Method in class dev.langchain4j.data.message.AudioContent
Get the Audio.
Audio - Class in dev.langchain4j.data.audio
 
AUDIO - Enum constant in enum class dev.langchain4j.data.message.ContentType
Audio content.
Audio.Builder - Class in dev.langchain4j.data.audio
Builder for Audio.
AudioContent - Class in dev.langchain4j.data.message
 
AudioContent(Audio) - Constructor for class dev.langchain4j.data.message.AudioContent
Create a new AudioContent from the given Audio.
AudioContent(String) - Constructor for class dev.langchain4j.data.message.AudioContent
Create a new AudioContent from the given url.
AudioContent(String, String) - Constructor for class dev.langchain4j.data.message.AudioContent
Create a new AudioContent from the given base64 data and mime type.
AudioContent(URI) - Constructor for class dev.langchain4j.data.message.AudioContent
Create a new AudioContent from the given url.
augment(AugmentationRequest) - Method in class dev.langchain4j.rag.DefaultRetrievalAugmentor
 
augment(AugmentationRequest) - Method in interface dev.langchain4j.rag.RetrievalAugmentor
Augments the ChatMessage provided in the AugmentationRequest with retrieved Contents.
AugmentationRequest - Class in dev.langchain4j.rag
Represents a request for ChatMessage augmentation.
AugmentationRequest(ChatMessage, Metadata) - Constructor for class dev.langchain4j.rag.AugmentationRequest
 
AugmentationResult - Class in dev.langchain4j.rag
Represents the result of a ChatMessage augmentation.
AugmentationResult(ChatMessage, List<Content>) - Constructor for class dev.langchain4j.rag.AugmentationResult
 
AugmentationResult.AugmentationResultBuilder - Class in dev.langchain4j.rag
 
AuthenticationException - Exception Class in dev.langchain4j.exception
 
AuthenticationException(String) - Constructor for exception class dev.langchain4j.exception.AuthenticationException
 
AuthenticationException(String, Throwable) - Constructor for exception class dev.langchain4j.exception.AuthenticationException
 
AuthenticationException(Throwable) - Constructor for exception class dev.langchain4j.exception.AuthenticationException
 
AUTO - Enum constant in enum class dev.langchain4j.data.message.ImageContent.DetailLevel
Auto detail.
AUTO - Enum constant in enum class dev.langchain4j.model.chat.request.ToolChoice
The chat model can choose whether to use tools, which ones to use, and how many.
AZURE_OPEN_AI - Enum constant in enum class dev.langchain4j.model.ModelProvider
 

B

backoffExp(double) - Method in class dev.langchain4j.internal.RetryUtils.RetryPolicy.Builder
Sets the backoff exponent.
base64Data() - Method in class dev.langchain4j.data.audio.Audio
Get the base64 data of the audio.
base64Data() - Method in class dev.langchain4j.data.image.Image
Get the base64 data of the image.
base64Data() - Method in class dev.langchain4j.data.pdf.PdfFile
Get the base64 data of the rich format document.
base64Data() - Method in class dev.langchain4j.data.video.Video
Get the base64 data of the video.
base64Data(String) - Method in class dev.langchain4j.data.audio.Audio.Builder
Set the base64 data of the audio.
base64Data(String) - Method in class dev.langchain4j.data.image.Image.Builder
Set the base64 data of the image.
base64Data(String) - Method in class dev.langchain4j.data.pdf.PdfFile.Builder
Set the base64 data of the PDF document.
base64Data(String) - Method in class dev.langchain4j.data.video.Video.Builder
Set the base64 data of the video.
between(Embedding, Embedding) - Static method in class dev.langchain4j.store.embedding.CosineSimilarity
Calculates cosine similarity between two vectors.
BlankDocumentException - Exception Class in dev.langchain4j.data.document
 
BlankDocumentException() - Constructor for exception class dev.langchain4j.data.document.BlankDocumentException
 
build() - Method in class dev.langchain4j.agent.tool.ToolExecutionRequest.Builder
Returns a ToolExecutionRequest built from the parameters previously set.
build() - Method in class dev.langchain4j.agent.tool.ToolSpecification.Builder
Returns a ToolSpecification built from the parameters previously set.
build() - Method in class dev.langchain4j.data.audio.Audio.Builder
Build the Audio.
build() - Method in class dev.langchain4j.data.image.Image.Builder
Build the Image.
build() - Method in class dev.langchain4j.data.message.AiMessage.Builder
 
build() - Method in class dev.langchain4j.data.message.UserMessage.Builder
 
build() - Method in class dev.langchain4j.data.pdf.PdfFile.Builder
Build the PdfFile.
build() - Method in class dev.langchain4j.data.video.Video.Builder
Build the Video.
build() - Method in class dev.langchain4j.internal.RetryUtils.RetryPolicy.Builder
Builds a RetryPolicy.
build() - Method in class dev.langchain4j.model.chat.request.ChatRequest.Builder
 
build() - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters.Builder
 
build() - Method in class dev.langchain4j.model.chat.request.json.JsonAnyOfSchema.Builder
 
build() - Method in class dev.langchain4j.model.chat.request.json.JsonArraySchema.Builder
 
build() - Method in class dev.langchain4j.model.chat.request.json.JsonBooleanSchema.Builder
 
build() - Method in class dev.langchain4j.model.chat.request.json.JsonEnumSchema.Builder
 
build() - Method in class dev.langchain4j.model.chat.request.json.JsonIntegerSchema.Builder
 
build() - Method in class dev.langchain4j.model.chat.request.json.JsonNumberSchema.Builder
 
build() - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema.Builder
 
build() - Method in class dev.langchain4j.model.chat.request.json.JsonReferenceSchema.Builder
 
build() - Method in class dev.langchain4j.model.chat.request.json.JsonSchema.Builder
 
build() - Method in class dev.langchain4j.model.chat.request.json.JsonStringSchema.Builder
 
build() - Method in class dev.langchain4j.model.chat.request.ResponseFormat.Builder
 
build() - Method in class dev.langchain4j.model.chat.response.ChatResponse.Builder
 
build() - Method in class dev.langchain4j.model.chat.response.ChatResponseMetadata.Builder
 
build() - Method in class dev.langchain4j.rag.AugmentationResult.AugmentationResultBuilder
 
build() - Method in class dev.langchain4j.rag.content.aggregator.ReRankingContentAggregator.ReRankingContentAggregatorBuilder
 
build() - Method in class dev.langchain4j.rag.content.injector.DefaultContentInjector.DefaultContentInjectorBuilder
 
build() - Method in class dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever.EmbeddingStoreContentRetrieverBuilder
 
build() - Method in class dev.langchain4j.rag.content.retriever.WebSearchContentRetriever.WebSearchContentRetrieverBuilder
 
build() - Method in class dev.langchain4j.rag.DefaultRetrievalAugmentor.DefaultRetrievalAugmentorBuilder
 
build() - Method in class dev.langchain4j.rag.query.router.LanguageModelQueryRouter.LanguageModelQueryRouterBuilder
 
build() - Method in class dev.langchain4j.rag.query.transformer.CompressingQueryTransformer.CompressingQueryTransformerBuilder
 
build() - Method in class dev.langchain4j.rag.query.transformer.ExpandingQueryTransformer.ExpandingQueryTransformerBuilder
 
build() - Method in class dev.langchain4j.store.embedding.EmbeddingSearchRequest.EmbeddingSearchRequestBuilder
 
build() - Method in class dev.langchain4j.store.embedding.EmbeddingStoreIngestor.Builder
Builds the EmbeddingStoreIngestor.
build() - Method in class dev.langchain4j.web.search.WebSearchRequest.Builder
Build the web search request.
builder() - Static method in class dev.langchain4j.agent.tool.ToolExecutionRequest
Creates builder to build ToolExecutionRequest.
builder() - Static method in class dev.langchain4j.agent.tool.ToolSpecification
Creates builder to build ToolSpecification.
builder() - Static method in class dev.langchain4j.data.audio.Audio
Create a new Audio.Builder.
builder() - Static method in class dev.langchain4j.data.image.Image
Create a new Image.Builder.
builder() - Static method in class dev.langchain4j.data.message.AiMessage
 
builder() - Static method in class dev.langchain4j.data.message.UserMessage
 
builder() - Static method in class dev.langchain4j.data.pdf.PdfFile
Create a new PdfFile.Builder.
builder() - Static method in class dev.langchain4j.data.video.Video
Create a new Video.Builder.
builder() - Static method in class dev.langchain4j.model.chat.request.ChatRequest
 
builder() - Static method in interface dev.langchain4j.model.chat.request.ChatRequestParameters
 
builder() - Static method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters
 
builder() - Static method in class dev.langchain4j.model.chat.request.json.JsonAnyOfSchema
 
builder() - Static method in class dev.langchain4j.model.chat.request.json.JsonArraySchema
 
builder() - Static method in class dev.langchain4j.model.chat.request.json.JsonBooleanSchema
 
builder() - Static method in class dev.langchain4j.model.chat.request.json.JsonEnumSchema
 
builder() - Static method in class dev.langchain4j.model.chat.request.json.JsonIntegerSchema
 
builder() - Static method in class dev.langchain4j.model.chat.request.json.JsonNumberSchema
 
builder() - Static method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema
 
builder() - Static method in class dev.langchain4j.model.chat.request.json.JsonReferenceSchema
 
builder() - Static method in class dev.langchain4j.model.chat.request.json.JsonSchema
 
builder() - Static method in class dev.langchain4j.model.chat.request.json.JsonStringSchema
 
builder() - Static method in class dev.langchain4j.model.chat.request.ResponseFormat
 
builder() - Static method in class dev.langchain4j.model.chat.response.ChatResponse
 
builder() - Static method in class dev.langchain4j.model.chat.response.ChatResponseMetadata
 
builder() - Static method in class dev.langchain4j.rag.AugmentationResult
 
builder() - Static method in class dev.langchain4j.rag.content.aggregator.ReRankingContentAggregator
 
builder() - Static method in class dev.langchain4j.rag.content.injector.DefaultContentInjector
 
builder() - Static method in class dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever
 
builder() - Static method in class dev.langchain4j.rag.content.retriever.WebSearchContentRetriever
 
builder() - Static method in class dev.langchain4j.rag.DefaultRetrievalAugmentor
 
builder() - Static method in class dev.langchain4j.rag.query.router.LanguageModelQueryRouter
 
builder() - Static method in class dev.langchain4j.rag.query.transformer.CompressingQueryTransformer
 
builder() - Static method in class dev.langchain4j.rag.query.transformer.ExpandingQueryTransformer
 
builder() - Static method in class dev.langchain4j.store.embedding.EmbeddingSearchRequest
 
builder() - Static method in class dev.langchain4j.store.embedding.EmbeddingStoreIngestor
Creates a new EmbeddingStoreIngestor builder.
builder() - Static method in class dev.langchain4j.web.search.WebSearchRequest
Create a new builder instance.
Builder() - Constructor for class dev.langchain4j.data.audio.Audio.Builder
Create a new Audio.Builder.
Builder() - Constructor for class dev.langchain4j.data.image.Image.Builder
Create a new Image.Builder.
Builder() - Constructor for class dev.langchain4j.data.message.AiMessage.Builder
 
Builder() - Constructor for class dev.langchain4j.data.message.UserMessage.Builder
 
Builder() - Constructor for class dev.langchain4j.data.pdf.PdfFile.Builder
Create a new PdfFile.Builder.
Builder() - Constructor for class dev.langchain4j.data.video.Video.Builder
Create a new Video.Builder.
Builder() - Constructor for class dev.langchain4j.internal.RetryUtils.RetryPolicy.Builder
Construct a RetryPolicy.Builder.
Builder() - Constructor for class dev.langchain4j.model.chat.request.ChatRequest.Builder
 
Builder() - Constructor for class dev.langchain4j.model.chat.request.DefaultChatRequestParameters.Builder
 
Builder() - Constructor for class dev.langchain4j.model.chat.request.json.JsonAnyOfSchema.Builder
 
Builder() - Constructor for class dev.langchain4j.model.chat.request.json.JsonArraySchema.Builder
 
Builder() - Constructor for class dev.langchain4j.model.chat.request.json.JsonBooleanSchema.Builder
 
Builder() - Constructor for class dev.langchain4j.model.chat.request.json.JsonEnumSchema.Builder
 
Builder() - Constructor for class dev.langchain4j.model.chat.request.json.JsonIntegerSchema.Builder
 
Builder() - Constructor for class dev.langchain4j.model.chat.request.json.JsonNumberSchema.Builder
 
Builder() - Constructor for class dev.langchain4j.model.chat.request.json.JsonObjectSchema.Builder
 
Builder() - Constructor for class dev.langchain4j.model.chat.request.json.JsonReferenceSchema.Builder
 
Builder() - Constructor for class dev.langchain4j.model.chat.request.json.JsonSchema.Builder
 
Builder() - Constructor for class dev.langchain4j.model.chat.request.json.JsonStringSchema.Builder
 
Builder() - Constructor for class dev.langchain4j.model.chat.request.ResponseFormat.Builder
 
Builder() - Constructor for class dev.langchain4j.model.chat.response.ChatResponse.Builder
 
Builder() - Constructor for class dev.langchain4j.model.chat.response.ChatResponseMetadata.Builder
 
Builder() - Constructor for class dev.langchain4j.store.embedding.EmbeddingStoreIngestor.Builder
Creates a new EmbeddingStoreIngestor builder.

C

Capability - Enum Class in dev.langchain4j.model.chat
Represents a capability of a ChatModel or StreamingChatModel.
chat(ChatMessage...) - Method in interface dev.langchain4j.model.chat.ChatModel
 
chat(ChatRequest) - Method in interface dev.langchain4j.model.chat.ChatModel
This is the main API to interact with the chat model.
chat(ChatRequest, StreamingChatResponseHandler) - Method in interface dev.langchain4j.model.chat.StreamingChatModel
This is the main API to interact with the chat model.
chat(String) - Method in interface dev.langchain4j.model.chat.ChatModel
 
chat(String, StreamingChatResponseHandler) - Method in interface dev.langchain4j.model.chat.StreamingChatModel
 
chat(List<ChatMessage>) - Method in interface dev.langchain4j.model.chat.ChatModel
 
chat(List<ChatMessage>, StreamingChatResponseHandler) - Method in interface dev.langchain4j.model.chat.StreamingChatModel
 
chatMemory() - Method in class dev.langchain4j.rag.query.Metadata
 
ChatMemory - Interface in dev.langchain4j.memory
Represents the memory (history) of a chat conversation.
chatMemoryId() - Method in class dev.langchain4j.rag.query.Metadata
 
ChatMemoryStore - Interface in dev.langchain4j.store.memory.chat
Represents a store for the ChatMemory state.
chatMessage() - Method in class dev.langchain4j.rag.AugmentationRequest
 
chatMessage() - Method in class dev.langchain4j.rag.AugmentationResult
 
chatMessage() - Method in class dev.langchain4j.rag.query.Metadata
 
chatMessage(ChatMessage) - Method in class dev.langchain4j.rag.AugmentationResult.AugmentationResultBuilder
 
ChatMessage - Interface in dev.langchain4j.data.message
Represents a chat message.
ChatMessageDeserializer - Class in dev.langchain4j.data.message
A deserializer for ChatMessage objects.
ChatMessageJsonCodec - Interface in dev.langchain4j.data.message
A codec for serializing and deserializing ChatMessage objects to and from JSON.
ChatMessageJsonCodecFactory - Interface in dev.langchain4j.spi.data.message
A factory for creating ChatMessageJsonCodec objects.
ChatMessageSerializer - Class in dev.langchain4j.data.message
 
ChatMessageSerializer() - Constructor for class dev.langchain4j.data.message.ChatMessageSerializer
 
ChatMessageType - Enum Class in dev.langchain4j.data.message
The type of content, e.g.
chatModel - Variable in class dev.langchain4j.rag.query.router.LanguageModelQueryRouter
 
chatModel - Variable in class dev.langchain4j.rag.query.transformer.CompressingQueryTransformer
 
chatModel - Variable in class dev.langchain4j.rag.query.transformer.ExpandingQueryTransformer
 
chatModel(ChatModel) - Method in class dev.langchain4j.rag.query.router.LanguageModelQueryRouter.LanguageModelQueryRouterBuilder
 
chatModel(ChatModel) - Method in class dev.langchain4j.rag.query.transformer.CompressingQueryTransformer.CompressingQueryTransformerBuilder
 
chatModel(ChatModel) - Method in class dev.langchain4j.rag.query.transformer.ExpandingQueryTransformer.ExpandingQueryTransformerBuilder
 
ChatModel - Interface in dev.langchain4j.model.chat
Represents a language model that has a chat API.
ChatModelErrorContext - Class in dev.langchain4j.model.chat.listener
The chat model error context.
ChatModelErrorContext(Throwable, ChatRequest, ModelProvider, Map<Object, Object>) - Constructor for class dev.langchain4j.model.chat.listener.ChatModelErrorContext
 
ChatModelListener - Interface in dev.langchain4j.model.chat.listener
A ChatModel listener that listens for requests, responses and errors.
ChatModelRequestContext - Class in dev.langchain4j.model.chat.listener
The chat model request context.
ChatModelRequestContext(ChatRequest, ModelProvider, Map<Object, Object>) - Constructor for class dev.langchain4j.model.chat.listener.ChatModelRequestContext
 
ChatModelResponseContext - Class in dev.langchain4j.model.chat.listener
The chat response context.
ChatModelResponseContext(ChatResponse, ChatRequest, ModelProvider, Map<Object, Object>) - Constructor for class dev.langchain4j.model.chat.listener.ChatModelResponseContext
 
chatRequest() - Method in class dev.langchain4j.model.chat.listener.ChatModelErrorContext
 
chatRequest() - Method in class dev.langchain4j.model.chat.listener.ChatModelRequestContext
 
chatRequest() - Method in class dev.langchain4j.model.chat.listener.ChatModelResponseContext
 
ChatRequest - Class in dev.langchain4j.model.chat.request
 
ChatRequest(ChatRequest.Builder) - Constructor for class dev.langchain4j.model.chat.request.ChatRequest
 
ChatRequest.Builder - Class in dev.langchain4j.model.chat.request
 
ChatRequestParameters - Interface in dev.langchain4j.model.chat.request
Represents common chat request parameters supported by most LLM providers.
ChatRequestValidationUtils - Class in dev.langchain4j.internal
 
ChatRequestValidationUtils() - Constructor for class dev.langchain4j.internal.ChatRequestValidationUtils
 
chatResponse() - Method in class dev.langchain4j.model.chat.listener.ChatModelResponseContext
 
ChatResponse - Class in dev.langchain4j.model.chat.response
 
ChatResponse(ChatResponse.Builder) - Constructor for class dev.langchain4j.model.chat.response.ChatResponse
 
ChatResponse.Builder - Class in dev.langchain4j.model.chat.response
 
ChatResponseMetadata - Class in dev.langchain4j.model.chat.response
Represents common chat response metadata supported by most LLM providers.
ChatResponseMetadata(ChatResponseMetadata.Builder<?>) - Constructor for class dev.langchain4j.model.chat.response.ChatResponseMetadata
 
ChatResponseMetadata.Builder<T> - Class in dev.langchain4j.model.chat.response
 
clear() - Method in interface dev.langchain4j.memory.ChatMemory
Clears the chat memory.
CodeExecutionEngine - Interface in dev.langchain4j.code
Interface for executing code.
comparisonValue() - Method in class dev.langchain4j.store.embedding.filter.comparison.ContainsString
 
comparisonValue() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsEqualTo
 
comparisonValue() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsGreaterThan
 
comparisonValue() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsGreaterThanOrEqualTo
 
comparisonValue() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsLessThan
 
comparisonValue() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsLessThanOrEqualTo
 
comparisonValue() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsNotEqualTo
 
comparisonValues() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsIn
 
comparisonValues() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsNotIn
 
CompressingQueryTransformer - Class in dev.langchain4j.rag.query.transformer
A QueryTransformer that leverages a ChatModel to condense a given Query along with a chat memory (previous conversation history) into a concise Query.
CompressingQueryTransformer(ChatModel) - Constructor for class dev.langchain4j.rag.query.transformer.CompressingQueryTransformer
 
CompressingQueryTransformer(ChatModel, PromptTemplate) - Constructor for class dev.langchain4j.rag.query.transformer.CompressingQueryTransformer
 
CompressingQueryTransformer.CompressingQueryTransformerBuilder - Class in dev.langchain4j.rag.query.transformer
 
containsKey(String) - Method in class dev.langchain4j.data.document.Metadata
Check whether this Metadata contains a given key.
containsString(String) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
ContainsString - Class in dev.langchain4j.store.embedding.filter.comparison
A filter that checks if the value of a metadata key contains a specific string.
ContainsString(String, String) - Constructor for class dev.langchain4j.store.embedding.filter.comparison.ContainsString
 
content() - Method in class dev.langchain4j.model.output.Response
Get the content.
content() - Method in class dev.langchain4j.web.search.WebSearchOrganicResult
Returns the content scraped from the web page.
Content - Interface in dev.langchain4j.data.message
Abstract base interface for message content.
Content - Interface in dev.langchain4j.rag.content
Represents content relevant to a user Query with the potential to enhance and ground the LLM's response.
CONTENT_FILTER - Enum constant in enum class dev.langchain4j.model.output.FinishReason
The call finished signalling a need for content filtering.
contentAggregator(ContentAggregator) - Method in class dev.langchain4j.rag.DefaultRetrievalAugmentor.DefaultRetrievalAugmentorBuilder
 
ContentAggregator - Interface in dev.langchain4j.rag.content.aggregator
Aggregates all Contents retrieved from all ContentRetrievers using all Querys.
contentInjector(ContentInjector) - Method in class dev.langchain4j.rag.DefaultRetrievalAugmentor.DefaultRetrievalAugmentorBuilder
 
ContentInjector - Interface in dev.langchain4j.rag.content.injector
Injects given Contents into a given UserMessage.
ContentMetadata - Enum Class in dev.langchain4j.rag.content
 
contentRetriever(ContentRetriever) - Method in class dev.langchain4j.rag.DefaultRetrievalAugmentor.DefaultRetrievalAugmentorBuilder
 
ContentRetriever - Interface in dev.langchain4j.rag.content.retriever
Retrieves Contents from an underlying data source using a given Query.
contents() - Method in class dev.langchain4j.data.message.UserMessage
The Contents of the message.
contents() - Method in class dev.langchain4j.rag.AugmentationResult
 
contents(List<Content>) - Method in class dev.langchain4j.data.message.UserMessage.Builder
 
contents(List<Content>) - Method in class dev.langchain4j.rag.AugmentationResult.AugmentationResultBuilder
 
ContentType - Enum Class in dev.langchain4j.data.message
The type of content, e.g.
copy() - Method in class dev.langchain4j.data.document.Metadata
Copies the metadata.
copy(List<T>) - Static method in class dev.langchain4j.internal.Utils
Returns an (unmodifiable) copy of the provided list.
copy(Map<K, V>) - Static method in class dev.langchain4j.internal.Utils
Returns an (unmodifiable) copy of the provided map.
copy(Set<T>) - Static method in class dev.langchain4j.internal.Utils
Returns an (unmodifiable) copy of the provided set.
copyIfNotNull(List<T>) - Static method in class dev.langchain4j.internal.Utils
Returns an (unmodifiable) copy of the provided list.
copyIfNotNull(Map<K, V>) - Static method in class dev.langchain4j.internal.Utils
Returns an (unmodifiable) copy of the provided map.
copyIfNotNull(Set<T>) - Static method in class dev.langchain4j.internal.Utils
Returns an (unmodifiable) copy of the provided set.
CosineSimilarity - Class in dev.langchain4j.store.embedding
Utility class for calculating cosine similarity between two vectors.
create() - Method in interface dev.langchain4j.spi.data.document.parser.DocumentParserFactory
 
create() - Method in interface dev.langchain4j.spi.data.document.splitter.DocumentSplitterFactory
 
create() - Method in interface dev.langchain4j.spi.data.message.ChatMessageJsonCodecFactory
Creates a new ChatMessageJsonCodec object.
create() - Method in interface dev.langchain4j.spi.json.JsonCodecFactory
Create a new Json.JsonCodec.
create() - Method in interface dev.langchain4j.spi.model.embedding.EmbeddingModelFactory
 
create(PromptTemplateFactory.Input) - Method in interface dev.langchain4j.spi.prompt.PromptTemplateFactory
Create a new prompt template.
createPrompt(ChatMessage, List<Content>) - Method in class dev.langchain4j.rag.content.injector.DefaultContentInjector
 
createPrompt(Query) - Method in class dev.langchain4j.rag.query.router.LanguageModelQueryRouter
 
createPrompt(Query) - Method in class dev.langchain4j.rag.query.transformer.ExpandingQueryTransformer
 
createPrompt(Query, String) - Method in class dev.langchain4j.rag.query.transformer.CompressingQueryTransformer
 
createVirtualThreadExecutor() - Static method in class dev.langchain4j.internal.VirtualThreadUtils
Creates a virtual thread per task executor, assuming virtual threads are supported.
createVirtualThreadExecutor(Supplier<ExecutorService>) - Static method in class dev.langchain4j.internal.VirtualThreadUtils
Creates a virtual thread per task executor using reflection.
CUSTOM - Enum constant in enum class dev.langchain4j.data.message.ChatMessageType
A custom message.
customMessage(Map<String, Object>) - Static method in class dev.langchain4j.data.message.CustomMessage
Creates a new custom message.
CustomMessage - Class in dev.langchain4j.data.message
Represents a custom message.
CustomMessage(Map<String, Object>) - Constructor for class dev.langchain4j.data.message.CustomMessage
Creates a new custom message.
CustomMimeTypesFileTypeDetector - Class in dev.langchain4j.internal
Utility class to guess the mime-type of a file from its path or URI.
CustomMimeTypesFileTypeDetector() - Constructor for class dev.langchain4j.internal.CustomMimeTypesFileTypeDetector
Create a file mime-type detector, using the internal default mappings, and fallback to JDK's built-in capabilities, when no suitable mapping is found.
CustomMimeTypesFileTypeDetector(Map<String, String>) - Constructor for class dev.langchain4j.internal.CustomMimeTypesFileTypeDetector
Create a file mime-type detector, using your own custom file extension to mime-type mappings, with a fallback to JDK's built-in capabilities, when no suitable mapping is found

D

DEFAULT - Static variable in interface dev.langchain4j.internal.ExceptionMapper
 
DEFAULT_DISPLAY_NAME - Static variable in class dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever
 
DEFAULT_FILTER - Static variable in class dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever
 
DEFAULT_MAX_RESULTS - Static variable in class dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever
 
DEFAULT_MIN_SCORE - Static variable in class dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever
 
DEFAULT_N - Static variable in class dev.langchain4j.rag.query.transformer.ExpandingQueryTransformer
 
DEFAULT_PROMPT_TEMPLATE - Static variable in class dev.langchain4j.rag.content.injector.DefaultContentInjector
 
DEFAULT_PROMPT_TEMPLATE - Static variable in class dev.langchain4j.rag.query.router.LanguageModelQueryRouter
 
DEFAULT_PROMPT_TEMPLATE - Static variable in class dev.langchain4j.rag.query.transformer.CompressingQueryTransformer
 
DEFAULT_PROMPT_TEMPLATE - Static variable in class dev.langchain4j.rag.query.transformer.ExpandingQueryTransformer
 
DEFAULT_QUERY_SELECTOR - Static variable in class dev.langchain4j.rag.content.aggregator.ReRankingContentAggregator
 
DEFAULT_RETRY_POLICY - Static variable in class dev.langchain4j.internal.RetryUtils
Default retry policy used by RetryUtils.withRetry(Callable).
DefaultChatRequestParameters - Class in dev.langchain4j.model.chat.request
 
DefaultChatRequestParameters(DefaultChatRequestParameters.Builder<?>) - Constructor for class dev.langchain4j.model.chat.request.DefaultChatRequestParameters
 
DefaultChatRequestParameters.Builder<T> - Class in dev.langchain4j.model.chat.request
 
DefaultContent - Class in dev.langchain4j.rag.content
A default implementation of a Content.
DefaultContent(TextSegment) - Constructor for class dev.langchain4j.rag.content.DefaultContent
 
DefaultContent(TextSegment, Map<ContentMetadata, Object>) - Constructor for class dev.langchain4j.rag.content.DefaultContent
 
DefaultContent(String) - Constructor for class dev.langchain4j.rag.content.DefaultContent
 
DefaultContentAggregator - Class in dev.langchain4j.rag.content.aggregator
Default implementation of ContentAggregator intended to be suitable for the majority of use cases.
DefaultContentAggregator() - Constructor for class dev.langchain4j.rag.content.aggregator.DefaultContentAggregator
 
DefaultContentInjector - Class in dev.langchain4j.rag.content.injector
Default implementation of ContentInjector intended to be suitable for the majority of use cases.
DefaultContentInjector() - Constructor for class dev.langchain4j.rag.content.injector.DefaultContentInjector
 
DefaultContentInjector(PromptTemplate) - Constructor for class dev.langchain4j.rag.content.injector.DefaultContentInjector
 
DefaultContentInjector(PromptTemplate, List<String>) - Constructor for class dev.langchain4j.rag.content.injector.DefaultContentInjector
 
DefaultContentInjector(List<String>) - Constructor for class dev.langchain4j.rag.content.injector.DefaultContentInjector
 
DefaultContentInjector.DefaultContentInjectorBuilder - Class in dev.langchain4j.rag.content.injector
 
DefaultDocument - Class in dev.langchain4j.data.document
A default implementation of a Document.
DefaultDocument(String) - Constructor for class dev.langchain4j.data.document.DefaultDocument
 
DefaultDocument(String, Metadata) - Constructor for class dev.langchain4j.data.document.DefaultDocument
 
DefaultExceptionMapper() - Constructor for class dev.langchain4j.internal.ExceptionMapper.DefaultExceptionMapper
 
DefaultQueryRouter - Class in dev.langchain4j.rag.query.router
Default implementation of QueryRouter intended to be suitable for the majority of use cases.
DefaultQueryRouter(ContentRetriever...) - Constructor for class dev.langchain4j.rag.query.router.DefaultQueryRouter
 
DefaultQueryRouter(Collection<ContentRetriever>) - Constructor for class dev.langchain4j.rag.query.router.DefaultQueryRouter
 
DefaultQueryTransformer - Class in dev.langchain4j.rag.query.transformer
Default implementation of QueryTransformer intended to be suitable for the majority of use cases.
DefaultQueryTransformer() - Constructor for class dev.langchain4j.rag.query.transformer.DefaultQueryTransformer
 
defaultRequestParameters() - Method in interface dev.langchain4j.model.chat.ChatModel
 
defaultRequestParameters() - Method in interface dev.langchain4j.model.chat.StreamingChatModel
 
DefaultRetrievalAugmentor - Class in dev.langchain4j.rag
The default implementation of RetrievalAugmentor intended to be suitable for the majority of use cases.
DefaultRetrievalAugmentor(QueryTransformer, QueryRouter, ContentAggregator, ContentInjector, Executor) - Constructor for class dev.langchain4j.rag.DefaultRetrievalAugmentor
 
DefaultRetrievalAugmentor.DefaultRetrievalAugmentorBuilder - Class in dev.langchain4j.rag
 
definitions() - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema
Used together with JsonReferenceSchema when recursion is required.
definitions(Map<String, JsonSchemaElement>) - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema.Builder
Used together with JsonReferenceSchema when recursion is required.
delayMillis(int) - Method in class dev.langchain4j.internal.RetryUtils.RetryPolicy.Builder
Sets the base delay in milliseconds.
deleteMessages(Object) - Method in interface dev.langchain4j.store.memory.chat.ChatMemoryStore
Deletes all messages for a specified chat memory.
deleteMessages(Object) - Method in class dev.langchain4j.store.memory.chat.InMemoryChatMemoryStore
 
delimiter() - Element in annotation interface dev.langchain4j.model.input.structured.StructuredPrompt
The delimiter to join the lines of the prompt template.
description() - Method in class dev.langchain4j.agent.tool.ToolSpecification
Returns the description of the tool.
description() - Method in class dev.langchain4j.model.chat.request.json.JsonAnyOfSchema
 
description() - Method in class dev.langchain4j.model.chat.request.json.JsonArraySchema
 
description() - Method in class dev.langchain4j.model.chat.request.json.JsonBooleanSchema
 
description() - Method in class dev.langchain4j.model.chat.request.json.JsonEnumSchema
 
description() - Method in class dev.langchain4j.model.chat.request.json.JsonIntegerSchema
 
description() - Method in class dev.langchain4j.model.chat.request.json.JsonNullSchema
 
description() - Method in class dev.langchain4j.model.chat.request.json.JsonNumberSchema
 
description() - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema
 
description() - Method in class dev.langchain4j.model.chat.request.json.JsonReferenceSchema
 
description() - Method in interface dev.langchain4j.model.chat.request.json.JsonSchemaElement
 
description() - Method in class dev.langchain4j.model.chat.request.json.JsonStringSchema
 
description(String) - Method in class dev.langchain4j.agent.tool.ToolSpecification.Builder
Sets the description.
description(String) - Method in class dev.langchain4j.model.chat.request.json.JsonAnyOfSchema.Builder
 
description(String) - Method in class dev.langchain4j.model.chat.request.json.JsonArraySchema.Builder
 
description(String) - Method in class dev.langchain4j.model.chat.request.json.JsonBooleanSchema.Builder
 
description(String) - Method in class dev.langchain4j.model.chat.request.json.JsonEnumSchema.Builder
 
description(String) - Method in class dev.langchain4j.model.chat.request.json.JsonIntegerSchema.Builder
 
description(String) - Method in class dev.langchain4j.model.chat.request.json.JsonNumberSchema.Builder
 
description(String) - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema.Builder
 
description(String) - Method in class dev.langchain4j.model.chat.request.json.JsonStringSchema.Builder
 
Description - Annotation Interface in dev.langchain4j.model.output.structured
Annotation to attach a description to a class field.
detailLevel() - Method in class dev.langchain4j.data.message.ImageContent
Get the DetailLevel.
dev.langchain4j - package dev.langchain4j
 
dev.langchain4j.agent.tool - package dev.langchain4j.agent.tool
 
dev.langchain4j.code - package dev.langchain4j.code
 
dev.langchain4j.data.audio - package dev.langchain4j.data.audio
 
dev.langchain4j.data.document - package dev.langchain4j.data.document
 
dev.langchain4j.data.embedding - package dev.langchain4j.data.embedding
 
dev.langchain4j.data.image - package dev.langchain4j.data.image
 
dev.langchain4j.data.message - package dev.langchain4j.data.message
 
dev.langchain4j.data.pdf - package dev.langchain4j.data.pdf
 
dev.langchain4j.data.segment - package dev.langchain4j.data.segment
 
dev.langchain4j.data.video - package dev.langchain4j.data.video
 
dev.langchain4j.exception - package dev.langchain4j.exception
 
dev.langchain4j.internal - package dev.langchain4j.internal
 
dev.langchain4j.memory - package dev.langchain4j.memory
 
dev.langchain4j.model - package dev.langchain4j.model
 
dev.langchain4j.model.chat - package dev.langchain4j.model.chat
 
dev.langchain4j.model.chat.listener - package dev.langchain4j.model.chat.listener
 
dev.langchain4j.model.chat.request - package dev.langchain4j.model.chat.request
 
dev.langchain4j.model.chat.request.json - package dev.langchain4j.model.chat.request.json
 
dev.langchain4j.model.chat.response - package dev.langchain4j.model.chat.response
 
dev.langchain4j.model.embedding - package dev.langchain4j.model.embedding
 
dev.langchain4j.model.image - package dev.langchain4j.model.image
 
dev.langchain4j.model.input - package dev.langchain4j.model.input
 
dev.langchain4j.model.input.structured - package dev.langchain4j.model.input.structured
 
dev.langchain4j.model.language - package dev.langchain4j.model.language
 
dev.langchain4j.model.moderation - package dev.langchain4j.model.moderation
 
dev.langchain4j.model.output - package dev.langchain4j.model.output
 
dev.langchain4j.model.output.structured - package dev.langchain4j.model.output.structured
 
dev.langchain4j.model.scoring - package dev.langchain4j.model.scoring
 
dev.langchain4j.rag - package dev.langchain4j.rag
 
dev.langchain4j.rag.content - package dev.langchain4j.rag.content
 
dev.langchain4j.rag.content.aggregator - package dev.langchain4j.rag.content.aggregator
 
dev.langchain4j.rag.content.injector - package dev.langchain4j.rag.content.injector
 
dev.langchain4j.rag.content.retriever - package dev.langchain4j.rag.content.retriever
 
dev.langchain4j.rag.query - package dev.langchain4j.rag.query
 
dev.langchain4j.rag.query.router - package dev.langchain4j.rag.query.router
 
dev.langchain4j.rag.query.transformer - package dev.langchain4j.rag.query.transformer
 
dev.langchain4j.spi - package dev.langchain4j.spi
 
dev.langchain4j.spi.data.document.parser - package dev.langchain4j.spi.data.document.parser
 
dev.langchain4j.spi.data.document.splitter - package dev.langchain4j.spi.data.document.splitter
 
dev.langchain4j.spi.data.message - package dev.langchain4j.spi.data.message
 
dev.langchain4j.spi.json - package dev.langchain4j.spi.json
 
dev.langchain4j.spi.model.embedding - package dev.langchain4j.spi.model.embedding
 
dev.langchain4j.spi.prompt - package dev.langchain4j.spi.prompt
 
dev.langchain4j.spi.prompt.structured - package dev.langchain4j.spi.prompt.structured
 
dev.langchain4j.store.embedding - package dev.langchain4j.store.embedding
 
dev.langchain4j.store.embedding.filter - package dev.langchain4j.store.embedding.filter
 
dev.langchain4j.store.embedding.filter.comparison - package dev.langchain4j.store.embedding.filter.comparison
 
dev.langchain4j.store.embedding.filter.logical - package dev.langchain4j.store.embedding.filter.logical
 
dev.langchain4j.store.memory.chat - package dev.langchain4j.store.memory.chat
 
dev.langchain4j.web.search - package dev.langchain4j.web.search
 
dimension - Variable in class dev.langchain4j.model.embedding.DimensionAwareEmbeddingModel
dimension of embedding
dimension() - Method in class dev.langchain4j.data.embedding.Embedding
Returns the dimension of the vector.
dimension() - Method in class dev.langchain4j.model.embedding.DimensionAwareEmbeddingModel
 
dimension() - Method in interface dev.langchain4j.model.embedding.EmbeddingModel
Returns the dimension of the Embedding produced by this embedding model.
DimensionAwareEmbeddingModel - Class in dev.langchain4j.model.embedding
A dimension aware embedding model
DimensionAwareEmbeddingModel() - Constructor for class dev.langchain4j.model.embedding.DimensionAwareEmbeddingModel
 
DisabledChatModel - Class in dev.langchain4j.model.chat
A ChatModel which throws a ModelDisabledException for all of its methods
DisabledChatModel() - Constructor for class dev.langchain4j.model.chat.DisabledChatModel
 
DisabledEmbeddingModel - Class in dev.langchain4j.model.embedding
An EmbeddingModel which throws a ModelDisabledException for all of its methods
DisabledEmbeddingModel() - Constructor for class dev.langchain4j.model.embedding.DisabledEmbeddingModel
 
DisabledImageModel - Class in dev.langchain4j.model.image
An ImageModel which throws a ModelDisabledException for all of its methods
DisabledImageModel() - Constructor for class dev.langchain4j.model.image.DisabledImageModel
 
DisabledLanguageModel - Class in dev.langchain4j.model.language
A LanguageModel which throws a ModelDisabledException for all of its methods
DisabledLanguageModel() - Constructor for class dev.langchain4j.model.language.DisabledLanguageModel
 
DisabledModerationModel - Class in dev.langchain4j.model.moderation
A ModerationModel which throws a ModelDisabledException for all of its methods
DisabledModerationModel() - Constructor for class dev.langchain4j.model.moderation.DisabledModerationModel
 
DisabledStreamingChatModel - Class in dev.langchain4j.model.chat
A StreamingChatModel which throws a ModelDisabledException for all of its methods
DisabledStreamingChatModel() - Constructor for class dev.langchain4j.model.chat.DisabledStreamingChatModel
 
DisabledStreamingLanguageModel - Class in dev.langchain4j.model.language
A StreamingLanguageModel which throws a ModelDisabledException for all of its methods
DisabledStreamingLanguageModel() - Constructor for class dev.langchain4j.model.language.DisabledStreamingLanguageModel
 
displayName(String) - Method in class dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever.EmbeddingStoreContentRetrieverBuilder
 
DO_NOT_ROUTE - Enum constant in enum class dev.langchain4j.rag.query.router.LanguageModelQueryRouter.FallbackStrategy
In this case, the Query will not be routed to any ContentRetriever, thus skipping the RAG flow.
doChat(ChatRequest) - Method in interface dev.langchain4j.model.chat.ChatModel
 
doChat(ChatRequest) - Method in class dev.langchain4j.model.chat.DisabledChatModel
 
doChat(ChatRequest, StreamingChatResponseHandler) - Method in class dev.langchain4j.model.chat.DisabledStreamingChatModel
 
doChat(ChatRequest, StreamingChatResponseHandler) - Method in interface dev.langchain4j.model.chat.StreamingChatModel
 
document(String) - Static method in interface dev.langchain4j.data.document.Document
Creates a new Document from the given text.
document(String, Metadata) - Static method in interface dev.langchain4j.data.document.Document
Creates a new Document from the given text.
Document - Interface in dev.langchain4j.data.document
Represents an unstructured piece of text that usually corresponds to a content of a single file.
DocumentLoader - Class in dev.langchain4j.data.document
Utility class for loading documents.
DocumentParser - Interface in dev.langchain4j.data.document
Defines the interface for parsing an InputStream into a Document.
DocumentParserFactory - Interface in dev.langchain4j.spi.data.document.parser
A factory for creating DocumentParser instances through SPI.
DocumentSource - Interface in dev.langchain4j.data.document
Defines the interface for a Document source.
documentSplitter(DocumentSplitter) - Method in class dev.langchain4j.store.embedding.EmbeddingStoreIngestor.Builder
Sets the document splitter.
DocumentSplitter - Interface in dev.langchain4j.data.document
Defines the interface for splitting a document into text segments.
DocumentSplitterFactory - Interface in dev.langchain4j.spi.data.document.splitter
A factory for creating DocumentSplitter instances through SPI.
documentTransformer(DocumentTransformer) - Method in class dev.langchain4j.store.embedding.EmbeddingStoreIngestor.Builder
Sets the document transformer.
DocumentTransformer - Interface in dev.langchain4j.data.document
Defines the interface for transforming a Document.
dynamicFilter(Function<Query, Filter>) - Method in class dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever.EmbeddingStoreContentRetrieverBuilder
 
dynamicMaxResults(Function<Query, Integer>) - Method in class dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever.EmbeddingStoreContentRetrieverBuilder
 
dynamicMinScore(Function<Query, Double>) - Method in class dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever.EmbeddingStoreContentRetrieverBuilder
 

E

edit(Image, Image, String) - Method in class dev.langchain4j.model.image.DisabledImageModel
 
edit(Image, Image, String) - Method in interface dev.langchain4j.model.image.ImageModel
Given an existing image, edit this image following the given prompt and apply the changes only to the part of the image specified by the given mask.
edit(Image, String) - Method in class dev.langchain4j.model.image.DisabledImageModel
 
edit(Image, String) - Method in interface dev.langchain4j.model.image.ImageModel
Given an existing image, edit this image following the given prompt.
embed(TextSegment) - Method in class dev.langchain4j.model.embedding.DisabledEmbeddingModel
 
embed(TextSegment) - Method in interface dev.langchain4j.model.embedding.EmbeddingModel
Embed the text content of a TextSegment.
embed(String) - Method in class dev.langchain4j.model.embedding.DisabledEmbeddingModel
 
embed(String) - Method in interface dev.langchain4j.model.embedding.EmbeddingModel
Embed a text.
embedAll(List<TextSegment>) - Method in class dev.langchain4j.model.embedding.DisabledEmbeddingModel
 
embedAll(List<TextSegment>) - Method in interface dev.langchain4j.model.embedding.EmbeddingModel
Embeds the text content of a list of TextSegments.
embedded() - Method in class dev.langchain4j.store.embedding.EmbeddingMatch
Returns the original content that was embedded.
embedding() - Method in class dev.langchain4j.store.embedding.EmbeddingMatch
Returns the embedding that has been matched.
Embedding - Class in dev.langchain4j.data.embedding
Represents a dense vector embedding of a text.
Embedding(float[]) - Constructor for class dev.langchain4j.data.embedding.Embedding
Creates a new Embedding.
EMBEDDING_ID - Enum constant in enum class dev.langchain4j.rag.content.ContentMetadata
 
embeddingId() - Method in class dev.langchain4j.store.embedding.EmbeddingMatch
The ID of the embedding assigned when adding this embedding to the store.
EmbeddingMatch<Embedded> - Class in dev.langchain4j.store.embedding
Represents a matched embedding along with its relevance score (derivative of cosine distance), ID, and original embedded content.
EmbeddingMatch(Double, String, Embedding, Embedded) - Constructor for class dev.langchain4j.store.embedding.EmbeddingMatch
Creates a new instance.
embeddingModel(EmbeddingModel) - Method in class dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever.EmbeddingStoreContentRetrieverBuilder
 
embeddingModel(EmbeddingModel) - Method in class dev.langchain4j.store.embedding.EmbeddingStoreIngestor.Builder
Sets the embedding model.
EmbeddingModel - Interface in dev.langchain4j.model.embedding
Represents a model that can convert a given text into an embedding (vector representation of the text).
EmbeddingModelFactory - Interface in dev.langchain4j.spi.model.embedding
A factory for creating EmbeddingModel instances through SPI.
EmbeddingSearchRequest - Class in dev.langchain4j.store.embedding
Represents a request to search in an EmbeddingStore.
EmbeddingSearchRequest(Embedding, Integer, Double, Filter) - Constructor for class dev.langchain4j.store.embedding.EmbeddingSearchRequest
Creates an instance of an EmbeddingSearchRequest.
EmbeddingSearchRequest.EmbeddingSearchRequestBuilder - Class in dev.langchain4j.store.embedding
 
EmbeddingSearchResult<Embedded> - Class in dev.langchain4j.store.embedding
Represents a result of a search in an EmbeddingStore.
EmbeddingSearchResult(List<EmbeddingMatch<Embedded>>) - Constructor for class dev.langchain4j.store.embedding.EmbeddingSearchResult
 
embeddingStore(EmbeddingStore<TextSegment>) - Method in class dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever.EmbeddingStoreContentRetrieverBuilder
 
embeddingStore(EmbeddingStore<TextSegment>) - Method in class dev.langchain4j.store.embedding.EmbeddingStoreIngestor.Builder
Sets the embedding store.
EmbeddingStore<Embedded> - Interface in dev.langchain4j.store.embedding
Represents a store for embeddings, also known as a vector database.
EmbeddingStoreContentRetriever - Class in dev.langchain4j.rag.content.retriever
A ContentRetriever that retrieves from an EmbeddingStore.
EmbeddingStoreContentRetriever(EmbeddingStore<TextSegment>, EmbeddingModel) - Constructor for class dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever
 
EmbeddingStoreContentRetriever(EmbeddingStore<TextSegment>, EmbeddingModel, int) - Constructor for class dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever
 
EmbeddingStoreContentRetriever(EmbeddingStore<TextSegment>, EmbeddingModel, Integer, Double) - Constructor for class dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever
 
EmbeddingStoreContentRetriever.EmbeddingStoreContentRetrieverBuilder - Class in dev.langchain4j.rag.content.retriever
 
EmbeddingStoreIngestor - Class in dev.langchain4j.store.embedding
The EmbeddingStoreIngestor represents an ingestion pipeline and is responsible for ingesting Documents into an EmbeddingStore.
EmbeddingStoreIngestor(DocumentTransformer, DocumentSplitter, TextSegmentTransformer, EmbeddingModel, EmbeddingStore<TextSegment>) - Constructor for class dev.langchain4j.store.embedding.EmbeddingStoreIngestor
Creates an instance of an EmbeddingStoreIngestor.
EmbeddingStoreIngestor.Builder - Class in dev.langchain4j.store.embedding
EmbeddingStoreIngestor builder.
ensureBetween(Double, double, double, String) - Static method in class dev.langchain4j.internal.ValidationUtils
Ensures that the given Double value is in [min, max].
ensureBetween(Integer, int, int, String) - Static method in class dev.langchain4j.internal.ValidationUtils
Ensures that the given Integer value is in [min, max].
ensureBetween(Long, long, long, String) - Static method in class dev.langchain4j.internal.ValidationUtils
Ensures that the given Long value is in [min, max].
ensureEq(Object, Object, String, Object...) - Static method in class dev.langchain4j.internal.ValidationUtils
Ensure that the two values are equal.
ensureGreaterThanZero(Double, String) - Static method in class dev.langchain4j.internal.ValidationUtils
Ensures that the given expression is true.
ensureGreaterThanZero(Integer, String) - Static method in class dev.langchain4j.internal.ValidationUtils
Ensures that the given expression is true.
ensureNotBlank(String, String) - Static method in class dev.langchain4j.internal.ValidationUtils
Ensures that the given string is not null and not blank.
ensureNotEmpty(Map<K, V>, String) - Static method in class dev.langchain4j.internal.ValidationUtils
Ensures that the given map is not null and not empty.
ensureNotEmpty(T[], String) - Static method in class dev.langchain4j.internal.ValidationUtils
Ensures that the given array is not null and not empty.
ensureNotEmpty(T, String) - Static method in class dev.langchain4j.internal.ValidationUtils
Ensures that the given collection is not null and not empty.
ensureNotNull(T, String) - Static method in class dev.langchain4j.internal.ValidationUtils
Ensures that the given object is not null.
ensureNotNull(T, String, Object...) - Static method in class dev.langchain4j.internal.ValidationUtils
Ensures that the given object is not null.
ensureTrailingForwardSlash(String) - Static method in class dev.langchain4j.internal.Utils
Appends a trailing '/' if the provided URL does not end with '/'
ensureTrue(boolean, String) - Static method in class dev.langchain4j.internal.ValidationUtils
Ensures that the given expression is true.
enumValues() - Method in class dev.langchain4j.model.chat.request.json.JsonEnumSchema
 
enumValues(String...) - Method in class dev.langchain4j.model.chat.request.json.JsonEnumSchema.Builder
 
enumValues(List<String>) - Method in class dev.langchain4j.model.chat.request.json.JsonEnumSchema.Builder
 
EPSILON - Static variable in class dev.langchain4j.store.embedding.CosineSimilarity
A small value to avoid division by zero.
equals(Object) - Method in class dev.langchain4j.agent.tool.ToolExecutionRequest
 
equals(Object) - Method in class dev.langchain4j.agent.tool.ToolSpecification
 
equals(Object) - Method in class dev.langchain4j.data.audio.Audio
 
equals(Object) - Method in class dev.langchain4j.data.document.DefaultDocument
 
equals(Object) - Method in class dev.langchain4j.data.document.Metadata
 
equals(Object) - Method in class dev.langchain4j.data.embedding.Embedding
 
equals(Object) - Method in class dev.langchain4j.data.image.Image
 
equals(Object) - Method in class dev.langchain4j.data.message.AiMessage
 
equals(Object) - Method in class dev.langchain4j.data.message.AudioContent
 
equals(Object) - Method in class dev.langchain4j.data.message.CustomMessage
 
equals(Object) - Method in class dev.langchain4j.data.message.ImageContent
 
equals(Object) - Method in class dev.langchain4j.data.message.PdfFileContent
 
equals(Object) - Method in class dev.langchain4j.data.message.SystemMessage
 
equals(Object) - Method in class dev.langchain4j.data.message.TextContent
 
equals(Object) - Method in class dev.langchain4j.data.message.ToolExecutionResultMessage
 
equals(Object) - Method in class dev.langchain4j.data.message.UserMessage
 
equals(Object) - Method in class dev.langchain4j.data.message.VideoContent
 
equals(Object) - Method in class dev.langchain4j.data.pdf.PdfFile
 
equals(Object) - Method in class dev.langchain4j.data.segment.TextSegment
 
equals(Object) - Method in class dev.langchain4j.data.video.Video
 
equals(Object) - Method in class dev.langchain4j.model.chat.request.ChatRequest
 
equals(Object) - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters
 
equals(Object) - Method in class dev.langchain4j.model.chat.request.json.JsonAnyOfSchema
 
equals(Object) - Method in class dev.langchain4j.model.chat.request.json.JsonArraySchema
 
equals(Object) - Method in class dev.langchain4j.model.chat.request.json.JsonBooleanSchema
 
equals(Object) - Method in class dev.langchain4j.model.chat.request.json.JsonEnumSchema
 
equals(Object) - Method in class dev.langchain4j.model.chat.request.json.JsonIntegerSchema
 
equals(Object) - Method in class dev.langchain4j.model.chat.request.json.JsonNumberSchema
 
equals(Object) - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema
 
equals(Object) - Method in class dev.langchain4j.model.chat.request.json.JsonReferenceSchema
 
equals(Object) - Method in class dev.langchain4j.model.chat.request.json.JsonSchema
 
equals(Object) - Method in class dev.langchain4j.model.chat.request.json.JsonStringSchema
 
equals(Object) - Method in class dev.langchain4j.model.chat.request.ResponseFormat
 
equals(Object) - Method in class dev.langchain4j.model.chat.response.ChatResponse
 
equals(Object) - Method in class dev.langchain4j.model.chat.response.ChatResponseMetadata
 
equals(Object) - Method in class dev.langchain4j.model.input.Prompt
 
equals(Object) - Method in class dev.langchain4j.model.moderation.Moderation
 
equals(Object) - Method in class dev.langchain4j.model.output.Response
 
equals(Object) - Method in class dev.langchain4j.model.output.TokenUsage
 
equals(Object) - Method in class dev.langchain4j.rag.content.DefaultContent
Compares this Content with another object for equality.
equals(Object) - Method in class dev.langchain4j.rag.query.Metadata
 
equals(Object) - Method in class dev.langchain4j.rag.query.Query
 
equals(Object) - Method in class dev.langchain4j.store.embedding.EmbeddingMatch
 
equals(Object) - Method in class dev.langchain4j.store.embedding.EmbeddingSearchRequest
 
equals(Object) - Method in class dev.langchain4j.store.embedding.filter.comparison.ContainsString
 
equals(Object) - Method in class dev.langchain4j.store.embedding.filter.comparison.IsEqualTo
 
equals(Object) - Method in class dev.langchain4j.store.embedding.filter.comparison.IsGreaterThan
 
equals(Object) - Method in class dev.langchain4j.store.embedding.filter.comparison.IsGreaterThanOrEqualTo
 
equals(Object) - Method in class dev.langchain4j.store.embedding.filter.comparison.IsIn
 
equals(Object) - Method in class dev.langchain4j.store.embedding.filter.comparison.IsLessThan
 
equals(Object) - Method in class dev.langchain4j.store.embedding.filter.comparison.IsLessThanOrEqualTo
 
equals(Object) - Method in class dev.langchain4j.store.embedding.filter.comparison.IsNotEqualTo
 
equals(Object) - Method in class dev.langchain4j.store.embedding.filter.comparison.IsNotIn
 
equals(Object) - Method in class dev.langchain4j.store.embedding.filter.logical.And
 
equals(Object) - Method in class dev.langchain4j.store.embedding.filter.logical.Not
 
equals(Object) - Method in class dev.langchain4j.store.embedding.filter.logical.Or
 
equals(Object) - Method in class dev.langchain4j.web.search.WebSearchInformationResult
 
equals(Object) - Method in class dev.langchain4j.web.search.WebSearchOrganicResult
 
equals(Object) - Method in class dev.langchain4j.web.search.WebSearchRequest
 
equals(Object) - Method in class dev.langchain4j.web.search.WebSearchResults
 
error() - Method in class dev.langchain4j.model.chat.listener.ChatModelErrorContext
 
estimateTokenCountInMessage(ChatMessage) - Method in interface dev.langchain4j.model.TokenCountEstimator
Estimates the count of tokens in the given message.
estimateTokenCountInMessages(Iterable<ChatMessage>) - Method in interface dev.langchain4j.model.TokenCountEstimator
Estimates the count of tokens in the given messages.
estimateTokenCountInText(String) - Method in interface dev.langchain4j.model.TokenCountEstimator
Estimates the count of tokens in the given text.
ExceptionMapper - Interface in dev.langchain4j.internal
 
ExceptionMapper.DefaultExceptionMapper - Class in dev.langchain4j.internal
 
Exceptions - Class in dev.langchain4j.internal
Utility methods for creating common exceptions.
execute(String) - Method in interface dev.langchain4j.code.CodeExecutionEngine
Execute the given code.
executor(Executor) - Method in class dev.langchain4j.rag.DefaultRetrievalAugmentor.DefaultRetrievalAugmentorBuilder
 
ExpandingQueryTransformer - Class in dev.langchain4j.rag.query.transformer
A QueryTransformer that utilizes a ChatModel to expand a given Query.
ExpandingQueryTransformer(ChatModel) - Constructor for class dev.langchain4j.rag.query.transformer.ExpandingQueryTransformer
 
ExpandingQueryTransformer(ChatModel, int) - Constructor for class dev.langchain4j.rag.query.transformer.ExpandingQueryTransformer
 
ExpandingQueryTransformer(ChatModel, PromptTemplate) - Constructor for class dev.langchain4j.rag.query.transformer.ExpandingQueryTransformer
 
ExpandingQueryTransformer(ChatModel, PromptTemplate, Integer) - Constructor for class dev.langchain4j.rag.query.transformer.ExpandingQueryTransformer
 
ExpandingQueryTransformer.ExpandingQueryTransformerBuilder - Class in dev.langchain4j.rag.query.transformer
 
Experimental - Annotation Interface in dev.langchain4j
Indicates that a class/constructor/method is experimental and might change in the future.
expression() - Method in class dev.langchain4j.store.embedding.filter.logical.Not
 

F

FAIL - Enum constant in enum class dev.langchain4j.rag.query.router.LanguageModelQueryRouter.FallbackStrategy
In this case, an original exception will be re-thrown, and the RAG flow will fail.
fallback(Query, Exception) - Method in class dev.langchain4j.rag.query.router.LanguageModelQueryRouter
 
fallbackStrategy - Variable in class dev.langchain4j.rag.query.router.LanguageModelQueryRouter
 
fallbackStrategy(LanguageModelQueryRouter.FallbackStrategy) - Method in class dev.langchain4j.rag.query.router.LanguageModelQueryRouter.LanguageModelQueryRouterBuilder
 
FILE_NAME - Static variable in interface dev.langchain4j.data.document.Document
Common metadata key for the name of the file from which the document was loaded.
filter() - Method in class dev.langchain4j.store.embedding.EmbeddingSearchRequest
 
filter(Filter) - Method in class dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever.EmbeddingStoreContentRetrieverBuilder
 
filter(Filter) - Method in class dev.langchain4j.store.embedding.EmbeddingSearchRequest.EmbeddingSearchRequestBuilder
 
Filter - Interface in dev.langchain4j.store.embedding.filter
This class represents a filter that can be applied during search in an EmbeddingStore.
FilterParser - Interface in dev.langchain4j.store.embedding.filter
Parses a filter expression string into a Filter object.
finishReason() - Method in class dev.langchain4j.model.chat.response.ChatResponse
 
finishReason() - Method in class dev.langchain4j.model.chat.response.ChatResponseMetadata
 
finishReason() - Method in class dev.langchain4j.model.output.Response
Get the finish reason.
finishReason(FinishReason) - Method in class dev.langchain4j.model.chat.response.ChatResponse.Builder
 
finishReason(FinishReason) - Method in class dev.langchain4j.model.chat.response.ChatResponseMetadata.Builder
 
FinishReason - Enum Class in dev.langchain4j.model.output
The reason why a model call finished.
firstChars(String, int) - Static method in class dev.langchain4j.internal.Utils
Returns the first numberOfChars characters of the given string.
flagged() - Method in class dev.langchain4j.model.moderation.Moderation
Returns true if the text was flagged.
flagged(String) - Static method in class dev.langchain4j.model.moderation.Moderation
Constructs a Moderation object that is flagged.
flaggedText() - Method in class dev.langchain4j.model.moderation.Moderation
Returns the text that was flagged.
format(Metadata) - Method in class dev.langchain4j.rag.content.injector.DefaultContentInjector
 
format(ChatMessage) - Method in class dev.langchain4j.rag.query.transformer.CompressingQueryTransformer
 
format(Content) - Method in class dev.langchain4j.rag.content.injector.DefaultContentInjector
 
format(String, String) - Method in class dev.langchain4j.rag.content.injector.DefaultContentInjector
 
format(List<ChatMessage>) - Method in class dev.langchain4j.rag.query.transformer.CompressingQueryTransformer
 
format(List<Content>) - Method in class dev.langchain4j.rag.content.injector.DefaultContentInjector
 
frequencyPenalty() - Method in class dev.langchain4j.model.chat.request.ChatRequest
 
frequencyPenalty() - Method in interface dev.langchain4j.model.chat.request.ChatRequestParameters
 
frequencyPenalty() - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters
 
frequencyPenalty(Double) - Method in class dev.langchain4j.model.chat.request.ChatRequest.Builder
 
frequencyPenalty(Double) - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters.Builder
 
from(float[]) - Static method in class dev.langchain4j.data.embedding.Embedding
Creates a new Embedding from the given vector.
from(T) - Static method in class dev.langchain4j.model.output.Response
Create a new Response.
from(T, TokenUsage) - Static method in class dev.langchain4j.model.output.Response
Create a new Response.
from(T, TokenUsage, FinishReason) - Static method in class dev.langchain4j.model.output.Response
Create a new Response.
from(T, TokenUsage, FinishReason, Map<String, Object>) - Static method in class dev.langchain4j.model.output.Response
Create a new Response.
from(ToolExecutionRequest...) - Static method in class dev.langchain4j.data.message.AiMessage
Create a new AiMessage with the given tool execution requests.
from(ToolExecutionRequest, String) - Static method in class dev.langchain4j.data.message.ToolExecutionResultMessage
Creates a ToolExecutionResultMessage from a ToolExecutionRequest and the result of the tool execution.
from(Audio) - Static method in class dev.langchain4j.data.message.AudioContent
Create a new AudioContent from the given Audio.
from(Image) - Static method in class dev.langchain4j.data.message.ImageContent
Create a new ImageContent from the given image.
from(Image, ImageContent.DetailLevel) - Static method in class dev.langchain4j.data.message.ImageContent
Create a new ImageContent from the given image.
from(ChatMessage, Object, List<ChatMessage>) - Static method in class dev.langchain4j.rag.query.Metadata
 
from(Content...) - Static method in class dev.langchain4j.data.message.UserMessage
Create a UserMessage from contents.
from(PdfFile) - Static method in class dev.langchain4j.data.message.PdfFileContent
Create a new PdfFileContent from the given PDF.
from(TextSegment) - Static method in interface dev.langchain4j.rag.content.Content
 
from(TextSegment, Map<ContentMetadata, Object>) - Static method in interface dev.langchain4j.rag.content.Content
 
from(Video) - Static method in class dev.langchain4j.data.message.VideoContent
Create a new VideoContent from the given video.
from(EmbeddingStore<TextSegment>) - Static method in class dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever
Creates an instance of an EmbeddingStoreContentRetriever from the specified EmbeddingStore and EmbeddingModel found through SPI (see EmbeddingModelFactory).
from(WebSearchEngine) - Static method in class dev.langchain4j.web.search.WebSearchTool
Creates a new WebSearchTool with the specified web search engine.
from(WebSearchInformationResult, List<WebSearchOrganicResult>) - Static method in class dev.langchain4j.web.search.WebSearchResults
Creates a new instance of WebSearchResults from the specified parameters.
from(Long) - Static method in class dev.langchain4j.web.search.WebSearchInformationResult
Creates a new WebSearchInformationResult with the specified total results.
from(Long, Integer, Map<String, Object>) - Static method in class dev.langchain4j.web.search.WebSearchInformationResult
Creates a new WebSearchInformationResult with the specified total results, page number, and metadata.
from(String) - Static method in interface dev.langchain4j.data.document.Document
Creates a new Document from the given text.
from(String) - Static method in class dev.langchain4j.data.message.AiMessage
Create a new AiMessage with the given text.
from(String) - Static method in class dev.langchain4j.data.message.AudioContent
Create a new AudioContent from the given url.
from(String) - Static method in class dev.langchain4j.data.message.ImageContent
Create a new ImageContent from the given url.
from(String) - Static method in class dev.langchain4j.data.message.PdfFileContent
Create a new PdfFileContent from the given url.
from(String) - Static method in class dev.langchain4j.data.message.SystemMessage
Creates a new system message.
from(String) - Static method in class dev.langchain4j.data.message.TextContent
Creates a new text content.
from(String) - Static method in class dev.langchain4j.data.message.UserMessage
Create a UserMessage from a text.
from(String) - Static method in class dev.langchain4j.data.message.VideoContent
Create a new VideoContent from the given url.
from(String) - Static method in class dev.langchain4j.data.segment.TextSegment
Creates a new text segment.
from(String) - Static method in class dev.langchain4j.model.input.Prompt
Create a new Prompt.
from(String) - Static method in class dev.langchain4j.model.input.PromptTemplate
Create a new PromptTemplate.
from(String) - Static method in interface dev.langchain4j.rag.content.Content
 
from(String) - Static method in class dev.langchain4j.rag.query.Query
 
from(String) - Static method in class dev.langchain4j.web.search.WebSearchRequest
Create a web search request with the given search terms.
from(String, Metadata) - Static method in interface dev.langchain4j.data.document.Document
Creates a new Document from the given text.
from(String, Metadata) - Static method in class dev.langchain4j.data.segment.TextSegment
Creates a new text segment.
from(String, Content...) - Static method in class dev.langchain4j.data.message.UserMessage
Create a UserMessage from a name and contents.
from(String, ImageContent.DetailLevel) - Static method in class dev.langchain4j.data.message.ImageContent
Create a new ImageContent from the given url and detail level.
from(String, Metadata) - Static method in class dev.langchain4j.rag.query.Query
 
from(String, Integer) - Static method in class dev.langchain4j.web.search.WebSearchRequest
Create a web search request with the given search terms and maximum number of results.
from(String, String) - Static method in class dev.langchain4j.data.document.Metadata
Constructs a Metadata object from a single key-value pair.
from(String, String) - Static method in class dev.langchain4j.data.message.AudioContent
Create a new AudioContent from the given base64 data and mime type.
from(String, String) - Static method in class dev.langchain4j.data.message.ImageContent
Create a new ImageContent from the given base64 data and mime type.
from(String, String) - Static method in class dev.langchain4j.data.message.PdfFileContent
Create a new PdfFileContent from the given base64 data and mime type.
from(String, String) - Static method in class dev.langchain4j.data.message.UserMessage
Create a UserMessage from a name and a text.
from(String, String) - Static method in class dev.langchain4j.data.message.VideoContent
Create a new VideoContent from the given base64 data and mime type.
from(String, String, ImageContent.DetailLevel) - Static method in class dev.langchain4j.data.message.ImageContent
Create a new ImageContent from the given base64 data and mime type.
from(String, String, String) - Static method in class dev.langchain4j.data.message.ToolExecutionResultMessage
Creates a ToolExecutionResultMessage from a ToolExecutionRequest and the result of the tool execution.
from(String, URI) - Static method in class dev.langchain4j.web.search.WebSearchOrganicResult
Creates a WebSearchOrganicResult object from the given title and URL.
from(String, URI, String, String) - Static method in class dev.langchain4j.web.search.WebSearchOrganicResult
Creates a WebSearchOrganicResult object from the given title, URL, snippet and/or content.
from(String, URI, String, String, Map<String, String>) - Static method in class dev.langchain4j.web.search.WebSearchOrganicResult
Creates a WebSearchOrganicResult object from the given title, URL, snippet and/or content, and result metadata.
from(String, List<ToolExecutionRequest>) - Static method in class dev.langchain4j.data.message.AiMessage
Create a new AiMessage with the given text and tool execution requests.
from(String, List<Content>) - Static method in class dev.langchain4j.data.message.UserMessage
Create a UserMessage from a name and contents.
from(URI) - Static method in class dev.langchain4j.data.message.AudioContent
Create a new AudioContent from the given url.
from(URI) - Static method in class dev.langchain4j.data.message.ImageContent
Create a new ImageContent from the given url.
from(URI) - Static method in class dev.langchain4j.data.message.PdfFileContent
Create a new PdfFileContent from the given url.
from(URI) - Static method in class dev.langchain4j.data.message.VideoContent
Create a new VideoContent from the given url.
from(URI, ImageContent.DetailLevel) - Static method in class dev.langchain4j.data.message.ImageContent
Create a new ImageContent from the given url and detail level.
from(List<ToolExecutionRequest>) - Static method in class dev.langchain4j.data.message.AiMessage
Create a new AiMessage with the given tool execution requests.
from(List<Content>) - Static method in class dev.langchain4j.data.message.UserMessage
Create a UserMessage from contents.
from(List<Float>) - Static method in class dev.langchain4j.data.embedding.Embedding
Creates a new Embedding from the given vector.
from(Map<String, ?>) - Static method in class dev.langchain4j.data.document.Metadata
Constructs a Metadata object from a map of key-value pairs.
from(Map<String, Object>) - Static method in class dev.langchain4j.data.message.CustomMessage
Creates a new custom message.
from(Map<String, Object>, WebSearchInformationResult, List<WebSearchOrganicResult>) - Static method in class dev.langchain4j.web.search.WebSearchResults
Creates a new instance of WebSearchResults from the specified parameters.
fromCosineSimilarity(double) - Static method in class dev.langchain4j.store.embedding.RelevanceScore
Converts cosine similarity into relevance score.
fromJson(String, Class<T>) - Static method in class dev.langchain4j.internal.Json
Convert the given JSON string to an object of the given class.
fromJson(String, Class<T>) - Method in interface dev.langchain4j.internal.Json.JsonCodec
Convert the given JSON string to an object of the given class.
fromJson(String, Type) - Static method in class dev.langchain4j.internal.Json
Convert the given JSON string to an object of the given type.
fromJson(String, Type) - Method in interface dev.langchain4j.internal.Json.JsonCodec
Convert the given JSON string to an object of the given type.
fromRelevanceScore(double) - Static method in class dev.langchain4j.store.embedding.CosineSimilarity
Converts relevance score into cosine similarity.
fuse(Collection<List<Content>>) - Static method in class dev.langchain4j.rag.content.aggregator.ReciprocalRankFuser
Fuses multiple List<Content> into a single List<Content> using the Reciprocal Rank Fusion (RRF) algorithm with k=60.
fuse(Collection<List<Content>>, int) - Static method in class dev.langchain4j.rag.content.aggregator.ReciprocalRankFuser
Fuses multiple List<Content> into a single List<Content> using the Reciprocal Rank Fusion (RRF) algorithm.
fuse(Map<Query, Collection<List<Content>>>) - Method in class dev.langchain4j.rag.content.aggregator.DefaultContentAggregator
 
fuse(Map<Query, Collection<List<Content>>>) - Method in class dev.langchain4j.rag.content.aggregator.ReRankingContentAggregator
 

G

generate(Prompt) - Method in class dev.langchain4j.model.language.DisabledLanguageModel
 
generate(Prompt) - Method in interface dev.langchain4j.model.language.LanguageModel
Generate a response to the given prompt.
generate(Prompt, StreamingResponseHandler<String>) - Method in class dev.langchain4j.model.language.DisabledStreamingLanguageModel
 
generate(Prompt, StreamingResponseHandler<String>) - Method in interface dev.langchain4j.model.language.StreamingLanguageModel
Generates a response from the model based on a prompt.
generate(String) - Method in class dev.langchain4j.model.image.DisabledImageModel
 
generate(String) - Method in interface dev.langchain4j.model.image.ImageModel
Given a prompt, generate an image.
generate(String) - Method in class dev.langchain4j.model.language.DisabledLanguageModel
 
generate(String) - Method in interface dev.langchain4j.model.language.LanguageModel
Generate a response to the given prompt.
generate(String, int) - Method in class dev.langchain4j.model.image.DisabledImageModel
 
generate(String, int) - Method in interface dev.langchain4j.model.image.ImageModel
Given a prompt, generate n images.
generate(String, StreamingResponseHandler<String>) - Method in class dev.langchain4j.model.language.DisabledStreamingLanguageModel
 
generate(String, StreamingResponseHandler<String>) - Method in interface dev.langchain4j.model.language.StreamingLanguageModel
Generates a response from the model based on a prompt.
generateIds(int) - Method in interface dev.langchain4j.store.embedding.EmbeddingStore
Generates list of UUID strings
generateUUIDFrom(String) - Static method in class dev.langchain4j.internal.Utils
Generates a UUID from a hash of the given input string.
geoLocation() - Method in class dev.langchain4j.web.search.WebSearchRequest
Get the desired geolocation for search results.
geoLocation(String) - Method in class dev.langchain4j.web.search.WebSearchRequest.Builder
Set the desired geolocation for search results.
getContentClass() - Method in enum class dev.langchain4j.data.message.ContentType
Returns the class of the content type.
getDouble(String) - Method in class dev.langchain4j.data.document.Metadata
Returns the Double value associated with the given key.
getFloat(String) - Method in class dev.langchain4j.data.document.Metadata
Returns the Float value associated with the given key.
getInteger(String) - Method in class dev.langchain4j.data.document.Metadata
Returns the Integer value associated with the given key.
getLong(String) - Method in class dev.langchain4j.data.document.Metadata
Returns the Long value associated with the given key.
getMessages(Object) - Method in interface dev.langchain4j.store.memory.chat.ChatMemoryStore
Retrieves messages for a specified chat memory.
getMessages(Object) - Method in class dev.langchain4j.store.memory.chat.InMemoryChatMemoryStore
 
getName() - Method in interface dev.langchain4j.spi.prompt.PromptTemplateFactory.Input
Get the name of the template.
getOrDefault(List<T>, List<T>) - Static method in class dev.langchain4j.internal.Utils
Returns the given list if it is not null and not empty, otherwise returns the given default list.
getOrDefault(Map<K, V>, Map<K, V>) - Static method in class dev.langchain4j.internal.Utils
Returns the given map if it is not null and not empty, otherwise returns the given default map.
getOrDefault(T, Supplier<T>) - Static method in class dev.langchain4j.internal.Utils
Returns the given value if it is not null, otherwise returns the value returned by the given supplier.
getOrDefault(T, T) - Static method in class dev.langchain4j.internal.Utils
Returns the given value if it is not null, otherwise returns the given default value.
getString(String) - Method in class dev.langchain4j.data.document.Metadata
Returns the String value associated with the given key.
getTemplate() - Method in interface dev.langchain4j.spi.prompt.PromptTemplateFactory.Input
Get the template string.
getUUID(String) - Method in class dev.langchain4j.data.document.Metadata
Returns the UUID value associated with the given key.
GITHUB_MODELS - Enum constant in enum class dev.langchain4j.model.ModelProvider
 
GOOGLE_AI_GEMINI - Enum constant in enum class dev.langchain4j.model.ModelProvider
 
GOOGLE_VERTEX_AI_GEMINI - Enum constant in enum class dev.langchain4j.model.ModelProvider
 

H

hashCode() - Method in class dev.langchain4j.agent.tool.ToolExecutionRequest
 
hashCode() - Method in class dev.langchain4j.agent.tool.ToolSpecification
 
hashCode() - Method in class dev.langchain4j.data.audio.Audio
 
hashCode() - Method in class dev.langchain4j.data.document.DefaultDocument
 
hashCode() - Method in class dev.langchain4j.data.document.Metadata
 
hashCode() - Method in class dev.langchain4j.data.embedding.Embedding
 
hashCode() - Method in class dev.langchain4j.data.image.Image
 
hashCode() - Method in class dev.langchain4j.data.message.AiMessage
 
hashCode() - Method in class dev.langchain4j.data.message.AudioContent
 
hashCode() - Method in class dev.langchain4j.data.message.CustomMessage
 
hashCode() - Method in class dev.langchain4j.data.message.ImageContent
 
hashCode() - Method in class dev.langchain4j.data.message.PdfFileContent
 
hashCode() - Method in class dev.langchain4j.data.message.SystemMessage
 
hashCode() - Method in class dev.langchain4j.data.message.TextContent
 
hashCode() - Method in class dev.langchain4j.data.message.ToolExecutionResultMessage
 
hashCode() - Method in class dev.langchain4j.data.message.UserMessage
 
hashCode() - Method in class dev.langchain4j.data.message.VideoContent
 
hashCode() - Method in class dev.langchain4j.data.pdf.PdfFile
 
hashCode() - Method in class dev.langchain4j.data.segment.TextSegment
 
hashCode() - Method in class dev.langchain4j.data.video.Video
 
hashCode() - Method in class dev.langchain4j.model.chat.request.ChatRequest
 
hashCode() - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters
 
hashCode() - Method in class dev.langchain4j.model.chat.request.json.JsonAnyOfSchema
 
hashCode() - Method in class dev.langchain4j.model.chat.request.json.JsonArraySchema
 
hashCode() - Method in class dev.langchain4j.model.chat.request.json.JsonBooleanSchema
 
hashCode() - Method in class dev.langchain4j.model.chat.request.json.JsonEnumSchema
 
hashCode() - Method in class dev.langchain4j.model.chat.request.json.JsonIntegerSchema
 
hashCode() - Method in class dev.langchain4j.model.chat.request.json.JsonNumberSchema
 
hashCode() - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema
 
hashCode() - Method in class dev.langchain4j.model.chat.request.json.JsonReferenceSchema
 
hashCode() - Method in class dev.langchain4j.model.chat.request.json.JsonSchema
 
hashCode() - Method in class dev.langchain4j.model.chat.request.json.JsonStringSchema
 
hashCode() - Method in class dev.langchain4j.model.chat.request.ResponseFormat
 
hashCode() - Method in class dev.langchain4j.model.chat.response.ChatResponse
 
hashCode() - Method in class dev.langchain4j.model.chat.response.ChatResponseMetadata
 
hashCode() - Method in class dev.langchain4j.model.input.Prompt
 
hashCode() - Method in class dev.langchain4j.model.moderation.Moderation
 
hashCode() - Method in class dev.langchain4j.model.output.Response
 
hashCode() - Method in class dev.langchain4j.model.output.TokenUsage
 
hashCode() - Method in class dev.langchain4j.rag.content.DefaultContent
Computes the hash code for this Content.
hashCode() - Method in class dev.langchain4j.rag.query.Metadata
 
hashCode() - Method in class dev.langchain4j.rag.query.Query
 
hashCode() - Method in class dev.langchain4j.store.embedding.EmbeddingMatch
 
hashCode() - Method in class dev.langchain4j.store.embedding.EmbeddingSearchRequest
 
hashCode() - Method in class dev.langchain4j.store.embedding.filter.comparison.ContainsString
 
hashCode() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsEqualTo
 
hashCode() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsGreaterThan
 
hashCode() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsGreaterThanOrEqualTo
 
hashCode() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsIn
 
hashCode() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsLessThan
 
hashCode() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsLessThanOrEqualTo
 
hashCode() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsNotEqualTo
 
hashCode() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsNotIn
 
hashCode() - Method in class dev.langchain4j.store.embedding.filter.logical.And
 
hashCode() - Method in class dev.langchain4j.store.embedding.filter.logical.Not
 
hashCode() - Method in class dev.langchain4j.store.embedding.filter.logical.Or
 
hashCode() - Method in class dev.langchain4j.web.search.WebSearchInformationResult
 
hashCode() - Method in class dev.langchain4j.web.search.WebSearchOrganicResult
 
hashCode() - Method in class dev.langchain4j.web.search.WebSearchRequest
 
hashCode() - Method in class dev.langchain4j.web.search.WebSearchResults
 
hasSingleText() - Method in class dev.langchain4j.data.message.UserMessage
Whether this message contains a single TextContent.
hasToolExecutionRequests() - Method in class dev.langchain4j.data.message.AiMessage
Check if the message has ToolExecutionRequests.
HIGH - Enum constant in enum class dev.langchain4j.data.message.ImageContent.DetailLevel
High detail.
HttpException - Exception Class in dev.langchain4j.exception
 
HttpException(int, String) - Constructor for exception class dev.langchain4j.exception.HttpException
 

I

id() - Method in class dev.langchain4j.agent.tool.ToolExecutionRequest
Returns the id of the tool.
id() - Method in class dev.langchain4j.data.message.ToolExecutionResultMessage
Returns the id of the tool.
id() - Method in interface dev.langchain4j.memory.ChatMemory
The ID of the ChatMemory.
id() - Method in class dev.langchain4j.model.chat.response.ChatResponse
 
id() - Method in class dev.langchain4j.model.chat.response.ChatResponseMetadata
 
id(String) - Method in class dev.langchain4j.agent.tool.ToolExecutionRequest.Builder
Sets the id.
id(String) - Method in class dev.langchain4j.model.chat.response.ChatResponse.Builder
 
id(String) - Method in class dev.langchain4j.model.chat.response.ChatResponseMetadata.Builder
 
idToRetriever - Variable in class dev.langchain4j.rag.query.router.LanguageModelQueryRouter
 
illegalArgument(String, Object...) - Static method in class dev.langchain4j.internal.Exceptions
Constructs an IllegalArgumentException with the given formatted result.
image() - Method in class dev.langchain4j.data.message.ImageContent
Get the Image.
Image - Class in dev.langchain4j.data.image
Represents an image as a URL or as a Base64-encoded string.
IMAGE - Enum constant in enum class dev.langchain4j.data.message.ContentType
Image content.
Image.Builder - Class in dev.langchain4j.data.image
Builder for Image.
ImageContent - Class in dev.langchain4j.data.message
Represents an image with a DetailLevel.
ImageContent(Image) - Constructor for class dev.langchain4j.data.message.ImageContent
Create a new ImageContent from the given image.
ImageContent(Image, ImageContent.DetailLevel) - Constructor for class dev.langchain4j.data.message.ImageContent
Create a new ImageContent from the given image.
ImageContent(String) - Constructor for class dev.langchain4j.data.message.ImageContent
Create a new ImageContent from the given url.
ImageContent(String, ImageContent.DetailLevel) - Constructor for class dev.langchain4j.data.message.ImageContent
Create a new ImageContent from the given url and detail level.
ImageContent(String, String) - Constructor for class dev.langchain4j.data.message.ImageContent
Create a new ImageContent from the given base64 data and mime type.
ImageContent(String, String, ImageContent.DetailLevel) - Constructor for class dev.langchain4j.data.message.ImageContent
Create a new ImageContent from the given base64 data and mime type.
ImageContent(URI) - Constructor for class dev.langchain4j.data.message.ImageContent
Create a new ImageContent from the given url.
ImageContent(URI, ImageContent.DetailLevel) - Constructor for class dev.langchain4j.data.message.ImageContent
Create a new ImageContent from the given url and detail level.
ImageContent.DetailLevel - Enum Class in dev.langchain4j.data.message
The detail level of an Image.
ImageModel - Interface in dev.langchain4j.model.image
Text to Image generator model.
ingest(Document) - Method in class dev.langchain4j.store.embedding.EmbeddingStoreIngestor
Ingests a specified document into an EmbeddingStore that was specified during the creation of this EmbeddingStoreIngestor.
ingest(Document...) - Method in class dev.langchain4j.store.embedding.EmbeddingStoreIngestor
Ingests specified documents into an EmbeddingStore that was specified during the creation of this EmbeddingStoreIngestor.
ingest(Document, EmbeddingStore<TextSegment>) - Static method in class dev.langchain4j.store.embedding.EmbeddingStoreIngestor
Ingests a specified Document into a specified EmbeddingStore.
ingest(List<Document>) - Method in class dev.langchain4j.store.embedding.EmbeddingStoreIngestor
Ingests specified documents into an EmbeddingStore that was specified during the creation of this EmbeddingStoreIngestor.
ingest(List<Document>, EmbeddingStore<TextSegment>) - Static method in class dev.langchain4j.store.embedding.EmbeddingStoreIngestor
Ingests specified Documents into a specified EmbeddingStore.
IngestionResult - Class in dev.langchain4j.store.embedding
Represents the result of a EmbeddingStoreIngestor ingestion process.
IngestionResult(TokenUsage) - Constructor for class dev.langchain4j.store.embedding.IngestionResult
 
inject(List<Content>, ChatMessage) - Method in interface dev.langchain4j.rag.content.injector.ContentInjector
Injects given Contents into a given ChatMessage.
inject(List<Content>, ChatMessage) - Method in class dev.langchain4j.rag.content.injector.DefaultContentInjector
 
InMemoryChatMemoryStore - Class in dev.langchain4j.store.memory.chat
Implementation of ChatMemoryStore that stores state of ChatMemory (chat messages) in-memory.
InMemoryChatMemoryStore() - Constructor for class dev.langchain4j.store.memory.chat.InMemoryChatMemoryStore
Constructs a new InMemoryChatMemoryStore.
inputStream() - Method in interface dev.langchain4j.data.document.DocumentSource
Provides an InputStream to read the content of the document.
inputTokenCount() - Method in class dev.langchain4j.model.output.TokenUsage
Returns the input token count, or null if unknown.
Internal - Annotation Interface in dev.langchain4j
Indicates that the annotated class is intended for internal use only within the library.
InternalServerException - Exception Class in dev.langchain4j.exception
 
InternalServerException(String) - Constructor for exception class dev.langchain4j.exception.InternalServerException
 
InternalServerException(String, Throwable) - Constructor for exception class dev.langchain4j.exception.InternalServerException
 
InternalServerException(Throwable) - Constructor for exception class dev.langchain4j.exception.InternalServerException
 
InvalidRequestException - Exception Class in dev.langchain4j.exception
 
InvalidRequestException(String) - Constructor for exception class dev.langchain4j.exception.InvalidRequestException
 
InvalidRequestException(String, Throwable) - Constructor for exception class dev.langchain4j.exception.InvalidRequestException
 
InvalidRequestException(Throwable) - Constructor for exception class dev.langchain4j.exception.InvalidRequestException
 
isBetween(double, double) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isBetween(float, float) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isBetween(int, int) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isBetween(long, long) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isBetween(String, String) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isEqualTo(double) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isEqualTo(float) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isEqualTo(int) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isEqualTo(long) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isEqualTo(String) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isEqualTo(UUID) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
IsEqualTo - Class in dev.langchain4j.store.embedding.filter.comparison
 
IsEqualTo(String, Object) - Constructor for class dev.langchain4j.store.embedding.filter.comparison.IsEqualTo
 
isGreaterThan(double) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isGreaterThan(float) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isGreaterThan(int) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isGreaterThan(long) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isGreaterThan(String) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
IsGreaterThan - Class in dev.langchain4j.store.embedding.filter.comparison
 
IsGreaterThan(String, Comparable<?>) - Constructor for class dev.langchain4j.store.embedding.filter.comparison.IsGreaterThan
 
isGreaterThanOrEqualTo(double) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isGreaterThanOrEqualTo(float) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isGreaterThanOrEqualTo(int) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isGreaterThanOrEqualTo(long) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isGreaterThanOrEqualTo(String) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
IsGreaterThanOrEqualTo - Class in dev.langchain4j.store.embedding.filter.comparison
 
IsGreaterThanOrEqualTo(String, Comparable<?>) - Constructor for class dev.langchain4j.store.embedding.filter.comparison.IsGreaterThanOrEqualTo
 
isIn(double...) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isIn(float...) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isIn(int...) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isIn(long...) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isIn(String...) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isIn(Collection<?>) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isIn(UUID...) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
IsIn - Class in dev.langchain4j.store.embedding.filter.comparison
 
IsIn(String, Collection<?>) - Constructor for class dev.langchain4j.store.embedding.filter.comparison.IsIn
 
isLessThan(double) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isLessThan(float) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isLessThan(int) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isLessThan(long) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isLessThan(String) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
IsLessThan - Class in dev.langchain4j.store.embedding.filter.comparison
 
IsLessThan(String, Comparable<?>) - Constructor for class dev.langchain4j.store.embedding.filter.comparison.IsLessThan
 
isLessThanOrEqualTo(double) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isLessThanOrEqualTo(float) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isLessThanOrEqualTo(int) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isLessThanOrEqualTo(long) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isLessThanOrEqualTo(String) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
IsLessThanOrEqualTo - Class in dev.langchain4j.store.embedding.filter.comparison
 
IsLessThanOrEqualTo(String, Comparable<?>) - Constructor for class dev.langchain4j.store.embedding.filter.comparison.IsLessThanOrEqualTo
 
isNotEqualTo(double) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isNotEqualTo(float) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isNotEqualTo(int) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isNotEqualTo(long) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isNotEqualTo(String) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isNotEqualTo(UUID) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
IsNotEqualTo - Class in dev.langchain4j.store.embedding.filter.comparison
 
IsNotEqualTo(String, Object) - Constructor for class dev.langchain4j.store.embedding.filter.comparison.IsNotEqualTo
 
isNotIn(double...) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isNotIn(float...) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isNotIn(int...) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isNotIn(long...) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isNotIn(String...) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isNotIn(Collection<?>) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
isNotIn(UUID...) - Method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
IsNotIn - Class in dev.langchain4j.store.embedding.filter.comparison
 
IsNotIn(String, Collection<?>) - Constructor for class dev.langchain4j.store.embedding.filter.comparison.IsNotIn
 
isNotNullOrBlank(String) - Static method in class dev.langchain4j.internal.Utils
Is the given string not null and not blank?
isNotNullOrEmpty(String) - Static method in class dev.langchain4j.internal.Utils
Is the given string not null and not empty ("")?
isNullOrBlank(String) - Static method in class dev.langchain4j.internal.Utils
Is the given string null or blank?
isNullOrEmpty(Iterable<?>) - Static method in class dev.langchain4j.internal.Utils
Is the iterable object null or empty?
isNullOrEmpty(String) - Static method in class dev.langchain4j.internal.Utils
Is the given string null or empty ("")?
isNullOrEmpty(Collection<?>) - Static method in class dev.langchain4j.internal.Utils
Is the collection null or empty?
isNullOrEmpty(Map<?, ?>) - Static method in class dev.langchain4j.internal.Utils
Is the map object null or empty?
isVirtualThread() - Static method in class dev.langchain4j.internal.VirtualThreadUtils
Checks if the current thread is a virtual thread.
isVirtualThreadsSupported() - Static method in class dev.langchain4j.internal.VirtualThreadUtils
Checks if virtual threads are supported in the current runtime environment.
items() - Method in class dev.langchain4j.model.chat.request.json.JsonArraySchema
 
items(JsonSchemaElement) - Method in class dev.langchain4j.model.chat.request.json.JsonArraySchema.Builder
 

J

JacocoIgnoreCoverageGenerated - Annotation Interface in dev.langchain4j.internal
Annotation to mark methods where JaCoCo coverage should be ignored.
jitterDelayMillis(int) - Method in class dev.langchain4j.internal.RetryUtils.RetryPolicy
This method returns the jitter delay in milliseconds after a given retry.
jitterScale(double) - Method in class dev.langchain4j.internal.RetryUtils.RetryPolicy.Builder
Sets the jitter scale.
join(StructuredPrompt) - Static method in class dev.langchain4j.model.input.structured.StructuredPrompt.Util
Joins the lines of the prompt template.
Json - Class in dev.langchain4j.internal
JSON helper class.
JSON - Enum constant in enum class dev.langchain4j.model.chat.request.ResponseFormatType
 
JSON - Static variable in class dev.langchain4j.model.chat.request.ResponseFormat
 
Json.JsonCodec - Interface in dev.langchain4j.internal
The abstract JSON codec interface.
JsonAnyOfSchema - Class in dev.langchain4j.model.chat.request.json
 
JsonAnyOfSchema(JsonAnyOfSchema.Builder) - Constructor for class dev.langchain4j.model.chat.request.json.JsonAnyOfSchema
 
JsonAnyOfSchema.Builder - Class in dev.langchain4j.model.chat.request.json
 
JsonArraySchema - Class in dev.langchain4j.model.chat.request.json
 
JsonArraySchema(JsonArraySchema.Builder) - Constructor for class dev.langchain4j.model.chat.request.json.JsonArraySchema
 
JsonArraySchema.Builder - Class in dev.langchain4j.model.chat.request.json
 
JsonBooleanSchema - Class in dev.langchain4j.model.chat.request.json
 
JsonBooleanSchema() - Constructor for class dev.langchain4j.model.chat.request.json.JsonBooleanSchema
 
JsonBooleanSchema(JsonBooleanSchema.Builder) - Constructor for class dev.langchain4j.model.chat.request.json.JsonBooleanSchema
 
JsonBooleanSchema.Builder - Class in dev.langchain4j.model.chat.request.json
 
JsonCodecFactory - Interface in dev.langchain4j.spi.json
A factory for creating Json.JsonCodec instances through SPI.
JsonEnumSchema - Class in dev.langchain4j.model.chat.request.json
 
JsonEnumSchema(JsonEnumSchema.Builder) - Constructor for class dev.langchain4j.model.chat.request.json.JsonEnumSchema
 
JsonEnumSchema.Builder - Class in dev.langchain4j.model.chat.request.json
 
JsonIntegerSchema - Class in dev.langchain4j.model.chat.request.json
 
JsonIntegerSchema() - Constructor for class dev.langchain4j.model.chat.request.json.JsonIntegerSchema
 
JsonIntegerSchema(JsonIntegerSchema.Builder) - Constructor for class dev.langchain4j.model.chat.request.json.JsonIntegerSchema
 
JsonIntegerSchema.Builder - Class in dev.langchain4j.model.chat.request.json
 
JsonNullSchema - Class in dev.langchain4j.model.chat.request.json
 
JsonNullSchema() - Constructor for class dev.langchain4j.model.chat.request.json.JsonNullSchema
 
JsonNumberSchema - Class in dev.langchain4j.model.chat.request.json
 
JsonNumberSchema() - Constructor for class dev.langchain4j.model.chat.request.json.JsonNumberSchema
 
JsonNumberSchema(JsonNumberSchema.Builder) - Constructor for class dev.langchain4j.model.chat.request.json.JsonNumberSchema
 
JsonNumberSchema.Builder - Class in dev.langchain4j.model.chat.request.json
 
jsonObjectOrReferenceSchemaFrom(Class<?>, String, boolean, Map<Class<?>, JsonSchemaElementUtils.VisitedClassMetadata>, boolean) - Static method in class dev.langchain4j.internal.JsonSchemaElementUtils
 
JsonObjectSchema - Class in dev.langchain4j.model.chat.request.json
 
JsonObjectSchema(JsonObjectSchema.Builder) - Constructor for class dev.langchain4j.model.chat.request.json.JsonObjectSchema
 
JsonObjectSchema.Builder - Class in dev.langchain4j.model.chat.request.json
 
JsonReferenceSchema - Class in dev.langchain4j.model.chat.request.json
Can reference JsonObjectSchema when recursion is required.
JsonReferenceSchema(JsonReferenceSchema.Builder) - Constructor for class dev.langchain4j.model.chat.request.json.JsonReferenceSchema
 
JsonReferenceSchema.Builder - Class in dev.langchain4j.model.chat.request.json
 
jsonSchema() - Method in class dev.langchain4j.model.chat.request.ResponseFormat
 
jsonSchema(JsonSchema) - Method in class dev.langchain4j.model.chat.request.ResponseFormat.Builder
 
JsonSchema - Class in dev.langchain4j.model.chat.request.json
 
JsonSchema.Builder - Class in dev.langchain4j.model.chat.request.json
 
jsonSchemaElement - Variable in class dev.langchain4j.internal.JsonSchemaElementUtils.VisitedClassMetadata
 
JsonSchemaElement - Interface in dev.langchain4j.model.chat.request.json
A base interface for a JSON schema element.
jsonSchemaElementFrom(Class<?>) - Static method in class dev.langchain4j.internal.JsonSchemaElementUtils
 
jsonSchemaElementFrom(Class<?>, Type, String, boolean, Map<Class<?>, JsonSchemaElementUtils.VisitedClassMetadata>) - Static method in class dev.langchain4j.internal.JsonSchemaElementUtils
 
JsonSchemaElementUtils - Class in dev.langchain4j.internal
 
JsonSchemaElementUtils() - Constructor for class dev.langchain4j.internal.JsonSchemaElementUtils
 
JsonSchemaElementUtils.VisitedClassMetadata - Class in dev.langchain4j.internal
 
JsonStringSchema - Class in dev.langchain4j.model.chat.request.json
 
JsonStringSchema() - Constructor for class dev.langchain4j.model.chat.request.json.JsonStringSchema
 
JsonStringSchema(JsonStringSchema.Builder) - Constructor for class dev.langchain4j.model.chat.request.json.JsonStringSchema
 
JsonStringSchema.Builder - Class in dev.langchain4j.model.chat.request.json
 

K

key() - Method in class dev.langchain4j.store.embedding.filter.comparison.ContainsString
 
key() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsEqualTo
 
key() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsGreaterThan
 
key() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsGreaterThanOrEqualTo
 
key() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsIn
 
key() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsLessThan
 
key() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsLessThanOrEqualTo
 
key() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsNotEqualTo
 
key() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsNotIn
 
knownDimension() - Method in class dev.langchain4j.model.embedding.DimensionAwareEmbeddingModel
When known (e.g., can be derived from the model name), returns the dimension of the Embedding produced by this embedding model.

L

LambdaStreamingResponseHandler - Class in dev.langchain4j.model
Utility class with lambda-based streaming response handlers.
LambdaStreamingResponseHandler() - Constructor for class dev.langchain4j.model.LambdaStreamingResponseHandler
 
LangChain4jException - Exception Class in dev.langchain4j.exception
 
LangChain4jException(String) - Constructor for exception class dev.langchain4j.exception.LangChain4jException
 
LangChain4jException(String, Throwable) - Constructor for exception class dev.langchain4j.exception.LangChain4jException
 
LangChain4jException(Throwable) - Constructor for exception class dev.langchain4j.exception.LangChain4jException
 
language() - Method in class dev.langchain4j.web.search.WebSearchRequest
Get the desired language for search results.
language(String) - Method in class dev.langchain4j.web.search.WebSearchRequest.Builder
Set the desired language for search results.
LanguageModel - Interface in dev.langchain4j.model.language
Represents a language model that has a simple text interface (as opposed to a chat interface).
LanguageModelQueryRouter - Class in dev.langchain4j.rag.query.router
A QueryRouter that utilizes a ChatModel to make a routing decision.
LanguageModelQueryRouter(ChatModel, Map<ContentRetriever, String>) - Constructor for class dev.langchain4j.rag.query.router.LanguageModelQueryRouter
 
LanguageModelQueryRouter(ChatModel, Map<ContentRetriever, String>, PromptTemplate, LanguageModelQueryRouter.FallbackStrategy) - Constructor for class dev.langchain4j.rag.query.router.LanguageModelQueryRouter
 
LanguageModelQueryRouter.FallbackStrategy - Enum Class in dev.langchain4j.rag.query.router
Strategy applied if the call to the LLM fails of if LLM does not return a valid response.
LanguageModelQueryRouter.LanguageModelQueryRouterBuilder - Class in dev.langchain4j.rag.query.router
 
left() - Method in class dev.langchain4j.store.embedding.filter.logical.And
 
left() - Method in class dev.langchain4j.store.embedding.filter.logical.Or
 
LENGTH - Enum constant in enum class dev.langchain4j.model.output.FinishReason
The call finished because the token length was reached.
listeners() - Method in interface dev.langchain4j.model.chat.ChatModel
 
listeners() - Method in interface dev.langchain4j.model.chat.StreamingChatModel
 
load(DocumentSource, DocumentParser) - Static method in class dev.langchain4j.data.document.DocumentLoader
Loads a document from the given source using the given parser.
loadFactories(Class<T>) - Static method in class dev.langchain4j.spi.ServiceHelper
Load all the services of a given type.
loadFactories(Class<T>, ClassLoader) - Static method in class dev.langchain4j.spi.ServiceHelper
Load all the services of a given type.
LOW - Enum constant in enum class dev.langchain4j.data.message.ImageContent.DetailLevel
Low detail.

M

mapException(Throwable) - Method in class dev.langchain4j.internal.ExceptionMapper.DefaultExceptionMapper
 
mapException(Throwable) - Method in interface dev.langchain4j.internal.ExceptionMapper
 
mapHttpStatusCode(Throwable, int) - Method in class dev.langchain4j.internal.ExceptionMapper.DefaultExceptionMapper
 
mappingException(Callable<T>) - Static method in interface dev.langchain4j.internal.ExceptionMapper
 
Markers - Class in dev.langchain4j.internal
 
matches() - Method in class dev.langchain4j.store.embedding.EmbeddingSearchResult
 
maxOutputTokens() - Method in class dev.langchain4j.model.chat.request.ChatRequest
 
maxOutputTokens() - Method in interface dev.langchain4j.model.chat.request.ChatRequestParameters
 
maxOutputTokens() - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters
 
maxOutputTokens(Integer) - Method in class dev.langchain4j.model.chat.request.ChatRequest.Builder
 
maxOutputTokens(Integer) - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters.Builder
 
maxResults() - Method in class dev.langchain4j.store.embedding.EmbeddingSearchRequest
 
maxResults() - Method in class dev.langchain4j.web.search.WebSearchRequest
Get the maximum number of results.
maxResults(Integer) - Method in class dev.langchain4j.rag.content.aggregator.ReRankingContentAggregator.ReRankingContentAggregatorBuilder
 
maxResults(Integer) - Method in class dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever.EmbeddingStoreContentRetrieverBuilder
 
maxResults(Integer) - Method in class dev.langchain4j.rag.content.retriever.WebSearchContentRetriever.WebSearchContentRetrieverBuilder
 
maxResults(Integer) - Method in class dev.langchain4j.store.embedding.EmbeddingSearchRequest.EmbeddingSearchRequestBuilder
 
maxResults(Integer) - Method in class dev.langchain4j.web.search.WebSearchRequest.Builder
Set the maximum number of results.
maxRetries(int) - Method in class dev.langchain4j.internal.RetryUtils.RetryPolicy.Builder
Sets the default maximum number of retries.
merge(Metadata) - Method in class dev.langchain4j.data.document.Metadata
Merges the current Metadata object with another Metadata object.
messageClass() - Method in enum class dev.langchain4j.data.message.ChatMessageType
Returns the class of the message type.
messageFromJson(String) - Static method in class dev.langchain4j.data.message.ChatMessageDeserializer
Deserializes a JSON string into a ChatMessage.
messageFromJson(String) - Method in interface dev.langchain4j.data.message.ChatMessageJsonCodec
Deserializes a JSON string to a ChatMessage object.
messages() - Method in interface dev.langchain4j.memory.ChatMemory
Retrieves messages from the chat memory.
messages() - Method in class dev.langchain4j.model.chat.request.ChatRequest
 
messages(ChatMessage...) - Method in class dev.langchain4j.model.chat.request.ChatRequest.Builder
 
messages(List<ChatMessage>) - Method in class dev.langchain4j.model.chat.request.ChatRequest.Builder
 
messagesFromJson(String) - Static method in class dev.langchain4j.data.message.ChatMessageDeserializer
Deserializes a JSON string into a list of ChatMessage.
messagesFromJson(String) - Method in interface dev.langchain4j.data.message.ChatMessageJsonCodec
Deserializes a JSON string to a list of ChatMessage objects.
messagesToJson(List<ChatMessage>) - Method in interface dev.langchain4j.data.message.ChatMessageJsonCodec
Serializes a list of ChatMessage objects to a JSON string.
messagesToJson(List<ChatMessage>) - Static method in class dev.langchain4j.data.message.ChatMessageSerializer
Serializes a list of chat messages into a JSON string.
messageToJson(ChatMessage) - Method in interface dev.langchain4j.data.message.ChatMessageJsonCodec
Serializes a ChatMessage object to a JSON string.
messageToJson(ChatMessage) - Static method in class dev.langchain4j.data.message.ChatMessageSerializer
Serializes a chat message into a JSON string.
metadata() - Method in class dev.langchain4j.data.document.DefaultDocument
 
metadata() - Method in interface dev.langchain4j.data.document.Document
Returns the metadata associated with this document.
metadata() - Method in interface dev.langchain4j.data.document.DocumentSource
Returns the metadata associated with the source of the document.
metadata() - Method in class dev.langchain4j.data.segment.TextSegment
Returns the metadata.
metadata() - Method in class dev.langchain4j.model.chat.response.ChatResponse
 
metadata() - Method in class dev.langchain4j.model.output.Response
Get the response metadata.
metadata() - Method in class dev.langchain4j.rag.AugmentationRequest
 
metadata() - Method in interface dev.langchain4j.rag.content.Content
 
metadata() - Method in class dev.langchain4j.rag.content.DefaultContent
 
metadata() - Method in class dev.langchain4j.rag.query.Query
 
metadata() - Method in class dev.langchain4j.web.search.WebSearchInformationResult
Gets the metadata.
metadata() - Method in class dev.langchain4j.web.search.WebSearchOrganicResult
Returns the result metadata associated with the search result.
metadata(ChatResponseMetadata) - Method in class dev.langchain4j.model.chat.response.ChatResponse.Builder
 
metadata(String, String) - Static method in class dev.langchain4j.data.document.Metadata
Constructs a Metadata object from a single key-value pair.
Metadata - Class in dev.langchain4j.data.document
Represents metadata of a Document or a TextSegment.
Metadata - Class in dev.langchain4j.rag.query
Represents metadata that may be useful or necessary for retrieval or augmentation purposes.
Metadata() - Constructor for class dev.langchain4j.data.document.Metadata
Construct a Metadata object with an empty map of key-value pairs.
Metadata(ChatMessage, Object, List<ChatMessage>) - Constructor for class dev.langchain4j.rag.query.Metadata
 
Metadata(Map<String, ?>) - Constructor for class dev.langchain4j.data.document.Metadata
Constructs a Metadata object from a map of key-value pairs.
MetadataFilterBuilder - Class in dev.langchain4j.store.embedding.filter
A helper class for building a Filter for Metadata key.
MetadataFilterBuilder(String) - Constructor for class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
metadataKey(String) - Static method in class dev.langchain4j.store.embedding.filter.MetadataFilterBuilder
 
metadataKeysToInclude(List<String>) - Method in class dev.langchain4j.rag.content.injector.DefaultContentInjector.DefaultContentInjectorBuilder
 
mimeType() - Method in class dev.langchain4j.data.audio.Audio
Get the mime type of the audio.
mimeType() - Method in class dev.langchain4j.data.image.Image
Get the mime type of the image.
mimeType() - Method in class dev.langchain4j.data.pdf.PdfFile
Get the mime type of the rich format document.
mimeType() - Method in class dev.langchain4j.data.video.Video
Get the mime type of the video.
mimeType(String) - Method in class dev.langchain4j.data.audio.Audio.Builder
Set the mime type of the audio.
mimeType(String) - Method in class dev.langchain4j.data.image.Image.Builder
Set the mime type of the image.
mimeType(String) - Method in class dev.langchain4j.data.pdf.PdfFile.Builder
Set the mime type of the PDF document.
mimeType(String) - Method in class dev.langchain4j.data.video.Video.Builder
Set the mime type of the video.
minScore() - Method in class dev.langchain4j.store.embedding.EmbeddingSearchRequest
 
minScore(Double) - Method in class dev.langchain4j.rag.content.aggregator.ReRankingContentAggregator.ReRankingContentAggregatorBuilder
 
minScore(Double) - Method in class dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever.EmbeddingStoreContentRetrieverBuilder
 
minScore(Double) - Method in class dev.langchain4j.store.embedding.EmbeddingSearchRequest.EmbeddingSearchRequestBuilder
 
MISTRAL_AI - Enum constant in enum class dev.langchain4j.model.ModelProvider
 
ModelDisabledException - Exception Class in dev.langchain4j.model
An exception thrown by a model that could be disabled by a user.
ModelDisabledException(String) - Constructor for exception class dev.langchain4j.model.ModelDisabledException
 
modelName() - Method in class dev.langchain4j.model.chat.request.ChatRequest
 
modelName() - Method in interface dev.langchain4j.model.chat.request.ChatRequestParameters
 
modelName() - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters
 
modelName() - Method in class dev.langchain4j.model.chat.response.ChatResponse
 
modelName() - Method in class dev.langchain4j.model.chat.response.ChatResponseMetadata
 
modelName(String) - Method in class dev.langchain4j.model.chat.request.ChatRequest.Builder
 
modelName(String) - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters.Builder
 
modelName(String) - Method in class dev.langchain4j.model.chat.response.ChatResponse.Builder
 
modelName(String) - Method in class dev.langchain4j.model.chat.response.ChatResponseMetadata.Builder
 
ModelNotFoundException - Exception Class in dev.langchain4j.exception
 
ModelNotFoundException(String) - Constructor for exception class dev.langchain4j.exception.ModelNotFoundException
 
ModelNotFoundException(String, Throwable) - Constructor for exception class dev.langchain4j.exception.ModelNotFoundException
 
ModelNotFoundException(Throwable) - Constructor for exception class dev.langchain4j.exception.ModelNotFoundException
 
modelProvider() - Method in class dev.langchain4j.model.chat.listener.ChatModelErrorContext
 
modelProvider() - Method in class dev.langchain4j.model.chat.listener.ChatModelRequestContext
 
modelProvider() - Method in class dev.langchain4j.model.chat.listener.ChatModelResponseContext
 
ModelProvider - Enum Class in dev.langchain4j.model
 
moderate(ChatMessage) - Method in class dev.langchain4j.model.moderation.DisabledModerationModel
 
moderate(ChatMessage) - Method in interface dev.langchain4j.model.moderation.ModerationModel
Moderates the given chat message.
moderate(TextSegment) - Method in class dev.langchain4j.model.moderation.DisabledModerationModel
 
moderate(TextSegment) - Method in interface dev.langchain4j.model.moderation.ModerationModel
Moderates the given text segment.
moderate(Prompt) - Method in class dev.langchain4j.model.moderation.DisabledModerationModel
 
moderate(Prompt) - Method in interface dev.langchain4j.model.moderation.ModerationModel
Moderates the given prompt.
moderate(String) - Method in class dev.langchain4j.model.moderation.DisabledModerationModel
 
moderate(String) - Method in interface dev.langchain4j.model.moderation.ModerationModel
Moderates the given text.
moderate(List<ChatMessage>) - Method in class dev.langchain4j.model.moderation.DisabledModerationModel
 
moderate(List<ChatMessage>) - Method in interface dev.langchain4j.model.moderation.ModerationModel
Moderates the given list of chat messages.
Moderation - Class in dev.langchain4j.model.moderation
Represents moderation status.
Moderation() - Constructor for class dev.langchain4j.model.moderation.Moderation
Construct a Moderation object that is not flagged.
Moderation(String) - Constructor for class dev.langchain4j.model.moderation.Moderation
Construct a Moderation object that is flagged.
ModerationModel - Interface in dev.langchain4j.model.moderation
Represents a model that can moderate text.

N

n - Variable in class dev.langchain4j.rag.query.transformer.ExpandingQueryTransformer
 
n(Integer) - Method in class dev.langchain4j.rag.query.transformer.ExpandingQueryTransformer.ExpandingQueryTransformerBuilder
 
name() - Element in annotation interface dev.langchain4j.agent.tool.Tool
Name of the tool.
name() - Method in class dev.langchain4j.agent.tool.ToolExecutionRequest
Returns the name of the tool.
name() - Method in class dev.langchain4j.agent.tool.ToolSpecification
Returns the name of the tool.
name() - Method in class dev.langchain4j.data.message.UserMessage
The name of the user.
name() - Method in class dev.langchain4j.model.chat.request.json.JsonSchema
 
name(String) - Method in class dev.langchain4j.agent.tool.ToolExecutionRequest.Builder
Sets the name.
name(String) - Method in class dev.langchain4j.agent.tool.ToolSpecification.Builder
Sets the name.
name(String) - Method in class dev.langchain4j.data.message.UserMessage.Builder
 
name(String) - Method in class dev.langchain4j.model.chat.request.json.JsonSchema.Builder
 
NonRetriableException - Exception Class in dev.langchain4j.exception
 
NonRetriableException(String) - Constructor for exception class dev.langchain4j.exception.NonRetriableException
 
NonRetriableException(String, Throwable) - Constructor for exception class dev.langchain4j.exception.NonRetriableException
 
NonRetriableException(Throwable) - Constructor for exception class dev.langchain4j.exception.NonRetriableException
 
normalize() - Method in class dev.langchain4j.data.embedding.Embedding
Normalize vector
not(Filter) - Static method in interface dev.langchain4j.store.embedding.filter.Filter
 
Not - Class in dev.langchain4j.store.embedding.filter.logical
 
Not(Filter) - Constructor for class dev.langchain4j.store.embedding.filter.logical.Not
 
notFlagged() - Static method in class dev.langchain4j.model.moderation.Moderation
Constructs a Moderation object that is not flagged.

O

OLLAMA - Enum constant in enum class dev.langchain4j.model.ModelProvider
 
onComplete(Response<T>) - Method in interface dev.langchain4j.model.StreamingResponseHandler
Invoked when the language model has finished streaming a response.
onCompleteResponse(ChatResponse) - Method in interface dev.langchain4j.model.chat.response.StreamingChatResponseHandler
Invoked when the model has finished streaming a response.
onError(ChatModelErrorContext) - Method in interface dev.langchain4j.model.chat.listener.ChatModelListener
This method is called when an error occurs during interaction with the model.
onError(Throwable) - Method in interface dev.langchain4j.model.chat.response.StreamingChatResponseHandler
This method is invoked when an error occurs during streaming.
onError(Throwable) - Method in interface dev.langchain4j.model.StreamingResponseHandler
This method is invoked when an error occurs during streaming.
onNext(String) - Method in interface dev.langchain4j.model.StreamingResponseHandler
Invoked each time the language model generates a new token in a textual response.
onPartialResponse(String) - Method in interface dev.langchain4j.model.chat.response.StreamingChatResponseHandler
Invoked each time the model generates a partial response (usually a single token) in a textual response.
onPartialResponse(Consumer<String>) - Static method in class dev.langchain4j.model.LambdaStreamingResponseHandler
 
onPartialResponseAndError(Consumer<String>, Consumer<Throwable>) - Static method in class dev.langchain4j.model.LambdaStreamingResponseHandler
 
onRequest(ChatModelRequestContext) - Method in interface dev.langchain4j.model.chat.listener.ChatModelListener
This method is called before the request is sent to the model.
onResponse(ChatModelResponseContext) - Method in interface dev.langchain4j.model.chat.listener.ChatModelListener
This method is called after the response is received from the model.
OPEN_AI - Enum constant in enum class dev.langchain4j.model.ModelProvider
 
options - Variable in class dev.langchain4j.rag.query.router.LanguageModelQueryRouter
 
or(Filter) - Method in interface dev.langchain4j.store.embedding.filter.Filter
 
or(Filter, Filter) - Static method in interface dev.langchain4j.store.embedding.filter.Filter
 
Or - Class in dev.langchain4j.store.embedding.filter.logical
 
Or(Filter, Filter) - Constructor for class dev.langchain4j.store.embedding.filter.logical.Or
 
OTHER - Enum constant in enum class dev.langchain4j.model.ModelProvider
 
OTHER - Enum constant in enum class dev.langchain4j.model.output.FinishReason
The call finished for some other reason.
outputTokenCount() - Method in class dev.langchain4j.model.output.TokenUsage
Returns the output token count, or null if unknown.
overrideWith(ChatRequestParameters) - Method in interface dev.langchain4j.model.chat.request.ChatRequestParameters
Creates a new ChatRequestParameters by combining the current parameters with the specified ones.
overrideWith(ChatRequestParameters) - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters.Builder
 
overrideWith(ChatRequestParameters) - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters
 

P

P - Annotation Interface in dev.langchain4j.agent.tool
Parameter of a Tool
pageNumber() - Method in class dev.langchain4j.web.search.WebSearchInformationResult
Gets the page number.
parameters() - Method in class dev.langchain4j.agent.tool.ToolSpecification
Returns the parameters of the tool.
parameters() - Method in class dev.langchain4j.model.chat.request.ChatRequest
 
parameters(ChatRequestParameters) - Method in class dev.langchain4j.model.chat.request.ChatRequest.Builder
 
parameters(JsonObjectSchema) - Method in class dev.langchain4j.agent.tool.ToolSpecification.Builder
Sets the parameters.
parse(InputStream) - Method in interface dev.langchain4j.data.document.DocumentParser
Parses a given InputStream into a Document.
parse(String) - Method in class dev.langchain4j.rag.query.router.LanguageModelQueryRouter
 
parse(String) - Method in class dev.langchain4j.rag.query.transformer.ExpandingQueryTransformer
 
parse(String) - Method in interface dev.langchain4j.store.embedding.filter.FilterParser
Parses a filter expression string into a Filter object.
PDF - Enum constant in enum class dev.langchain4j.data.message.ContentType
PDF file content.
pdfFile() - Method in class dev.langchain4j.data.message.PdfFileContent
Get the PdfFile.
PdfFile - Class in dev.langchain4j.data.pdf
 
PdfFile.Builder - Class in dev.langchain4j.data.pdf
Builder for PdfFile.
PdfFileContent - Class in dev.langchain4j.data.message
 
PdfFileContent(PdfFile) - Constructor for class dev.langchain4j.data.message.PdfFileContent
Create a new PdfFileContent from the given PDF file.
PdfFileContent(String) - Constructor for class dev.langchain4j.data.message.PdfFileContent
Create a new PdfFileContent from the given url.
PdfFileContent(String, String) - Constructor for class dev.langchain4j.data.message.PdfFileContent
Create a new PdfFileContent from the given base64 data and mime type.
PdfFileContent(URI) - Constructor for class dev.langchain4j.data.message.PdfFileContent
Create a new PdfFileContent from the given url.
presencePenalty() - Method in class dev.langchain4j.model.chat.request.ChatRequest
 
presencePenalty() - Method in interface dev.langchain4j.model.chat.request.ChatRequestParameters
 
presencePenalty() - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters
 
presencePenalty(Double) - Method in class dev.langchain4j.model.chat.request.ChatRequest.Builder
 
presencePenalty(Double) - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters.Builder
 
probeContentType(String) - Method in class dev.langchain4j.internal.CustomMimeTypesFileTypeDetector
 
probeContentType(URI) - Method in class dev.langchain4j.internal.CustomMimeTypesFileTypeDetector
Guess the mime-type of a given URI.
probeContentType(Path) - Method in class dev.langchain4j.internal.CustomMimeTypesFileTypeDetector
Guess the mime-type of a given path.
Prompt - Class in dev.langchain4j.model.input
Represents a prompt (an input text sent to the LLM).
Prompt(String) - Constructor for class dev.langchain4j.model.input.Prompt
Create a new Prompt.
promptTemplate - Variable in class dev.langchain4j.rag.query.router.LanguageModelQueryRouter
 
promptTemplate - Variable in class dev.langchain4j.rag.query.transformer.CompressingQueryTransformer
 
promptTemplate - Variable in class dev.langchain4j.rag.query.transformer.ExpandingQueryTransformer
 
promptTemplate(PromptTemplate) - Method in class dev.langchain4j.rag.content.injector.DefaultContentInjector.DefaultContentInjectorBuilder
 
promptTemplate(PromptTemplate) - Method in class dev.langchain4j.rag.query.router.LanguageModelQueryRouter.LanguageModelQueryRouterBuilder
 
promptTemplate(PromptTemplate) - Method in class dev.langchain4j.rag.query.transformer.CompressingQueryTransformer.CompressingQueryTransformerBuilder
 
promptTemplate(PromptTemplate) - Method in class dev.langchain4j.rag.query.transformer.ExpandingQueryTransformer.ExpandingQueryTransformerBuilder
 
PromptTemplate - Class in dev.langchain4j.model.input
Represents a template of a prompt that can be reused multiple times.
PromptTemplate(String) - Constructor for class dev.langchain4j.model.input.PromptTemplate
Create a new PromptTemplate.
PromptTemplateFactory - Interface in dev.langchain4j.spi.prompt
A factory for creating prompt templates.
PromptTemplateFactory.Input - Interface in dev.langchain4j.spi.prompt
Interface for input for the factory.
PromptTemplateFactory.Template - Interface in dev.langchain4j.spi.prompt
Interface for a prompt template.
properties() - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema
 
provider() - Method in interface dev.langchain4j.model.chat.ChatModel
 
provider() - Method in interface dev.langchain4j.model.chat.StreamingChatModel
 
put(String, double) - Method in class dev.langchain4j.data.document.Metadata
Adds a key-value pair to the metadata.
put(String, float) - Method in class dev.langchain4j.data.document.Metadata
Adds a key-value pair to the metadata.
put(String, int) - Method in class dev.langchain4j.data.document.Metadata
Adds a key-value pair to the metadata.
put(String, long) - Method in class dev.langchain4j.data.document.Metadata
Adds a key-value pair to the metadata.
put(String, String) - Method in class dev.langchain4j.data.document.Metadata
Adds a key-value pair to the metadata.
put(String, UUID) - Method in class dev.langchain4j.data.document.Metadata
Adds a key-value pair to the metadata.
putAll(Map<String, Object>) - Method in class dev.langchain4j.data.document.Metadata
 

Q

Query - Class in dev.langchain4j.rag.query
Represents a query from the user intended for retrieving relevant Contents.
Query(String) - Constructor for class dev.langchain4j.rag.query.Query
 
Query(String, Metadata) - Constructor for class dev.langchain4j.rag.query.Query
 
queryEmbedding() - Method in class dev.langchain4j.store.embedding.EmbeddingSearchRequest
 
queryEmbedding(Embedding) - Method in class dev.langchain4j.store.embedding.EmbeddingSearchRequest.EmbeddingSearchRequestBuilder
 
queryRouter(QueryRouter) - Method in class dev.langchain4j.rag.DefaultRetrievalAugmentor.DefaultRetrievalAugmentorBuilder
 
QueryRouter - Interface in dev.langchain4j.rag.query.router
Routes the given Query to one or multiple ContentRetrievers.
querySelector(Function<Map<Query, Collection<List<Content>>>, Query>) - Method in class dev.langchain4j.rag.content.aggregator.ReRankingContentAggregator.ReRankingContentAggregatorBuilder
 
queryTransformer(QueryTransformer) - Method in class dev.langchain4j.rag.DefaultRetrievalAugmentor.DefaultRetrievalAugmentorBuilder
 
QueryTransformer - Interface in dev.langchain4j.rag.query.transformer
Transforms the given Query into one or multiple Querys.
quoted(Object) - Static method in class dev.langchain4j.internal.Utils
Returns the given object's toString() surrounded by quotes.

R

randomUUID() - Static method in class dev.langchain4j.internal.Utils
Returns a random UUID.
RateLimitException - Exception Class in dev.langchain4j.exception
 
RateLimitException(String) - Constructor for exception class dev.langchain4j.exception.RateLimitException
 
RateLimitException(String, Throwable) - Constructor for exception class dev.langchain4j.exception.RateLimitException
 
RateLimitException(Throwable) - Constructor for exception class dev.langchain4j.exception.RateLimitException
 
rawDelayMs(int) - Method in class dev.langchain4j.internal.RetryUtils.RetryPolicy
This method returns the raw delay in milliseconds after a given retry.
readBytes(String) - Static method in class dev.langchain4j.internal.Utils
Reads the content as bytes from the given URL as a GET request for HTTP/HTTPS resources, and from files stored on the local filesystem.
ReciprocalRankFuser - Class in dev.langchain4j.rag.content.aggregator
Implementation of Reciprocal Rank Fusion.
ReciprocalRankFuser() - Constructor for class dev.langchain4j.rag.content.aggregator.ReciprocalRankFuser
 
recursionDetected - Variable in class dev.langchain4j.internal.JsonSchemaElementUtils.VisitedClassMetadata
 
reference - Variable in class dev.langchain4j.internal.JsonSchemaElementUtils.VisitedClassMetadata
 
reference() - Method in class dev.langchain4j.model.chat.request.json.JsonReferenceSchema
 
reference(String) - Method in class dev.langchain4j.model.chat.request.json.JsonReferenceSchema.Builder
 
RelevanceScore - Class in dev.langchain4j.store.embedding
Utility class for converting between cosine similarity and relevance score.
remove(String) - Method in class dev.langchain4j.data.document.Metadata
Removes the given key from the metadata.
remove(String) - Method in interface dev.langchain4j.store.embedding.EmbeddingStore
Removes a single embedding from the store by ID.
removeAll() - Method in interface dev.langchain4j.store.embedding.EmbeddingStore
Removes all embeddings from the store.
removeAll(Filter) - Method in interface dev.langchain4j.store.embedding.EmbeddingStore
Removes all embeddings that match the specified Filter from the store.
removeAll(Collection<String>) - Method in interface dev.langchain4j.store.embedding.EmbeddingStore
Removes all embeddings that match the specified IDs from the store.
render(Map<String, Object>) - Method in interface dev.langchain4j.spi.prompt.PromptTemplateFactory.Template
Render the template.
repeat(String, int) - Static method in class dev.langchain4j.internal.Utils
Returns a string consisting of the given string repeated times times.
required() - Element in annotation interface dev.langchain4j.agent.tool.P
Whether the parameter is required
required() - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema
 
required(String...) - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema.Builder
 
required(List<String>) - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema.Builder
 
REQUIRED - Enum constant in enum class dev.langchain4j.model.chat.request.ToolChoice
The chat model is required to use one or more tools.
reRankAndFilter(List<Content>, Query) - Method in class dev.langchain4j.rag.content.aggregator.ReRankingContentAggregator
 
RERANKED_SCORE - Enum constant in enum class dev.langchain4j.rag.content.ContentMetadata
 
ReRankingContentAggregator - Class in dev.langchain4j.rag.content.aggregator
A ContentAggregator that performs re-ranking using a ScoringModel, such as Cohere.
ReRankingContentAggregator(ScoringModel) - Constructor for class dev.langchain4j.rag.content.aggregator.ReRankingContentAggregator
 
ReRankingContentAggregator(ScoringModel, Function<Map<Query, Collection<List<Content>>>, Query>, Double) - Constructor for class dev.langchain4j.rag.content.aggregator.ReRankingContentAggregator
 
ReRankingContentAggregator(ScoringModel, Function<Map<Query, Collection<List<Content>>>, Query>, Double, Integer) - Constructor for class dev.langchain4j.rag.content.aggregator.ReRankingContentAggregator
 
ReRankingContentAggregator.ReRankingContentAggregatorBuilder - Class in dev.langchain4j.rag.content.aggregator
 
Response<T> - Class in dev.langchain4j.model.output
Represents the response from various types of models, including language, chat, embedding, and moderation models.
Response(T) - Constructor for class dev.langchain4j.model.output.Response
Create a new Response.
Response(T, TokenUsage, FinishReason) - Constructor for class dev.langchain4j.model.output.Response
Create a new Response.
Response(T, TokenUsage, FinishReason, Map<String, Object>) - Constructor for class dev.langchain4j.model.output.Response
Create a new Response.
RESPONSE_FORMAT_JSON_SCHEMA - Enum constant in enum class dev.langchain4j.model.chat.Capability
Indicates whether ChatModel or StreamingChatModel supports responding in JSON format according to the specified JSON schema.
responseFormat() - Method in class dev.langchain4j.model.chat.request.ChatRequest
 
responseFormat() - Method in interface dev.langchain4j.model.chat.request.ChatRequestParameters
 
responseFormat() - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters
 
responseFormat(JsonSchema) - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters.Builder
 
responseFormat(ResponseFormat) - Method in class dev.langchain4j.model.chat.request.ChatRequest.Builder
 
responseFormat(ResponseFormat) - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters.Builder
 
ResponseFormat - Class in dev.langchain4j.model.chat.request
 
ResponseFormat.Builder - Class in dev.langchain4j.model.chat.request
 
ResponseFormatType - Enum Class in dev.langchain4j.model.chat.request
 
results() - Method in class dev.langchain4j.web.search.WebSearchResults
Gets the list of organic search results.
RetriableException - Exception Class in dev.langchain4j.exception
 
RetriableException(String) - Constructor for exception class dev.langchain4j.exception.RetriableException
 
RetriableException(String, Throwable) - Constructor for exception class dev.langchain4j.exception.RetriableException
 
RetriableException(Throwable) - Constructor for exception class dev.langchain4j.exception.RetriableException
 
RetrievalAugmentor - Interface in dev.langchain4j.rag
Augments the provided ChatMessage with retrieved Contents.
retrieve(Query) - Method in interface dev.langchain4j.rag.content.retriever.ContentRetriever
Retrieves relevant Contents using a given Query.
retrieve(Query) - Method in class dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever
 
retrieve(Query) - Method in class dev.langchain4j.rag.content.retriever.WebSearchContentRetriever
 
retrieverToDescription(Map<ContentRetriever, String>) - Method in class dev.langchain4j.rag.query.router.LanguageModelQueryRouter.LanguageModelQueryRouterBuilder
 
RetryPolicy(int, int, double, double) - Constructor for class dev.langchain4j.internal.RetryUtils.RetryPolicy
Construct a RetryPolicy.
retryPolicyBuilder() - Static method in class dev.langchain4j.internal.RetryUtils
This method returns a RetryPolicy.Builder.
RetryUtils - Class in dev.langchain4j.internal
Utility class for retrying actions.
RetryUtils.RetryPolicy - Class in dev.langchain4j.internal
This class encapsulates a retry policy.
RetryUtils.RetryPolicy.Builder - Class in dev.langchain4j.internal
This class encapsulates a retry policy builder.
revisedPrompt() - Method in class dev.langchain4j.data.image.Image
Get the revised prompt of the image.
revisedPrompt(String) - Method in class dev.langchain4j.data.image.Image.Builder
Set the revised prompt of the image.
right() - Method in class dev.langchain4j.store.embedding.filter.logical.And
 
right() - Method in class dev.langchain4j.store.embedding.filter.logical.Or
 
rootElement() - Method in class dev.langchain4j.model.chat.request.json.JsonSchema
 
rootElement(JsonSchemaElement) - Method in class dev.langchain4j.model.chat.request.json.JsonSchema.Builder
 
route(Query) - Method in class dev.langchain4j.rag.query.router.DefaultQueryRouter
 
route(Query) - Method in class dev.langchain4j.rag.query.router.LanguageModelQueryRouter
 
route(Query) - Method in interface dev.langchain4j.rag.query.router.QueryRouter
Routes the given Query to one or multiple ContentRetrievers.
ROUTE_TO_ALL - Enum constant in enum class dev.langchain4j.rag.query.router.LanguageModelQueryRouter.FallbackStrategy
In this case, the Query will be routed to all ContentRetrievers.
runtime(String, Object...) - Static method in class dev.langchain4j.internal.Exceptions
Constructs an RuntimeException with the given formatted result.

S

safeSearch() - Method in class dev.langchain4j.web.search.WebSearchRequest
Get the safe search flag.
safeSearch(Boolean) - Method in class dev.langchain4j.web.search.WebSearchRequest.Builder
Set the safe search flag.
score() - Method in class dev.langchain4j.store.embedding.EmbeddingMatch
Returns the relevance score (derivative of cosine distance) of this embedding compared to a reference embedding during a search.
score(TextSegment, String) - Method in interface dev.langchain4j.model.scoring.ScoringModel
Scores a given TextSegment against a given query.
score(String, String) - Method in interface dev.langchain4j.model.scoring.ScoringModel
Scores a given text against a given query.
SCORE - Enum constant in enum class dev.langchain4j.rag.content.ContentMetadata
 
scoreAll(List<TextSegment>, String) - Method in interface dev.langchain4j.model.scoring.ScoringModel
Scores all provided TextSegments against a given query.
scoringModel(ScoringModel) - Method in class dev.langchain4j.rag.content.aggregator.ReRankingContentAggregator.ReRankingContentAggregatorBuilder
 
ScoringModel - Interface in dev.langchain4j.model.scoring
Represents a model capable of scoring a text against a query.
search(EmbeddingSearchRequest) - Method in interface dev.langchain4j.store.embedding.EmbeddingStore
Searches for the most similar (closest in the embedding space) Embeddings.
search(WebSearchRequest) - Method in interface dev.langchain4j.web.search.WebSearchEngine
Performs a search request on the web search engine and returns the search results.
search(String) - Method in interface dev.langchain4j.web.search.WebSearchEngine
Performs a search query on the web search engine and returns the search results.
searchInformation() - Method in class dev.langchain4j.web.search.WebSearchResults
Gets the information about the web search.
searchMetadata() - Method in class dev.langchain4j.web.search.WebSearchResults
Gets the metadata associated with the web search.
searchTerms() - Method in class dev.langchain4j.web.search.WebSearchRequest
Get the search terms.
searchTerms(String) - Method in class dev.langchain4j.web.search.WebSearchRequest.Builder
Set the search terms.
searchWeb(String) - Method in class dev.langchain4j.web.search.WebSearchTool
Runs a search query on the web search engine and returns a pretty-string representation of the search results.
SENSITIVE - Static variable in class dev.langchain4j.internal.Markers
 
ServiceHelper - Class in dev.langchain4j.spi
Utility wrapper around ServiceLoader.load().
singleText() - Method in class dev.langchain4j.data.message.UserMessage
Returns text from a single TextContent.
sleep(int) - Method in class dev.langchain4j.internal.RetryUtils.RetryPolicy
This method sleeps after a given retry.
snippet() - Method in class dev.langchain4j.web.search.WebSearchOrganicResult
Returns the snippet associated with the web page.
split(Document) - Method in interface dev.langchain4j.data.document.DocumentSplitter
Splits a single Document into a list of TextSegment objects.
splitAll(List<Document>) - Method in interface dev.langchain4j.data.document.DocumentSplitter
Splits a list of Documents into a list of TextSegment objects.
startIndex() - Method in class dev.langchain4j.web.search.WebSearchRequest
Get the start index for search results.
startIndex(Integer) - Method in class dev.langchain4j.web.search.WebSearchRequest.Builder
Set the start index for search results.
startPage() - Method in class dev.langchain4j.web.search.WebSearchRequest
Get the start page number for search results.
startPage(Integer) - Method in class dev.langchain4j.web.search.WebSearchRequest.Builder
Set the start page number for search results.
statusCode() - Method in exception class dev.langchain4j.exception.HttpException
 
STOP - Enum constant in enum class dev.langchain4j.model.output.FinishReason
The model call finished because the model decided the request was done.
stopSequences() - Method in class dev.langchain4j.model.chat.request.ChatRequest
 
stopSequences() - Method in interface dev.langchain4j.model.chat.request.ChatRequestParameters
 
stopSequences() - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters
 
stopSequences(String...) - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters.Builder
 
stopSequences(List<String>) - Method in class dev.langchain4j.model.chat.request.ChatRequest.Builder
 
stopSequences(List<String>) - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters.Builder
 
StreamingChatModel - Interface in dev.langchain4j.model.chat
Represents a language model that has a chat API and can stream a response one token at a time.
StreamingChatResponseHandler - Interface in dev.langchain4j.model.chat.response
Represents a handler for a StreamingChatModel response.
StreamingLanguageModel - Interface in dev.langchain4j.model.language
Represents a language model that has a simple text interface (as opposed to a chat interface) and can stream a response one token at a time.
StreamingResponseHandler<T> - Interface in dev.langchain4j.model
Represents a handler for streaming responses from a language model.
StructuredPrompt - Annotation Interface in dev.langchain4j.model.input.structured
Represents a structured prompt.
StructuredPrompt.Util - Class in dev.langchain4j.model.input.structured
Utility class for StructuredPrompt.
StructuredPromptFactory - Interface in dev.langchain4j.spi.prompt.structured
Represents a factory for structured prompts.
StructuredPromptProcessor - Class in dev.langchain4j.model.input.structured
Utility class for structured prompts.
sum(TokenUsage, TokenUsage) - Static method in class dev.langchain4j.model.output.TokenUsage
Adds two token usages.
sum(Integer, Integer) - Static method in class dev.langchain4j.model.output.TokenUsage
Sum two integers, returning null if both are null.
supportedCapabilities() - Method in interface dev.langchain4j.model.chat.ChatModel
 
supportedCapabilities() - Method in interface dev.langchain4j.model.chat.StreamingChatModel
 
SYSTEM - Enum constant in enum class dev.langchain4j.data.message.ChatMessageType
A message from the system, typically defined by a developer.
systemMessage(String) - Static method in class dev.langchain4j.data.message.SystemMessage
Creates a new system message.
SystemMessage - Class in dev.langchain4j.data.message
Represents a system message, typically defined by a developer.
SystemMessage(String) - Constructor for class dev.langchain4j.data.message.SystemMessage
Creates a new system message.

T

temperature() - Method in class dev.langchain4j.model.chat.request.ChatRequest
 
temperature() - Method in interface dev.langchain4j.model.chat.request.ChatRequestParameters
 
temperature() - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters
 
temperature(Double) - Method in class dev.langchain4j.model.chat.request.ChatRequest.Builder
 
temperature(Double) - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters.Builder
 
template() - Method in class dev.langchain4j.model.input.PromptTemplate
 
test(Object) - Method in class dev.langchain4j.store.embedding.filter.comparison.ContainsString
 
test(Object) - Method in class dev.langchain4j.store.embedding.filter.comparison.IsEqualTo
 
test(Object) - Method in class dev.langchain4j.store.embedding.filter.comparison.IsGreaterThan
 
test(Object) - Method in class dev.langchain4j.store.embedding.filter.comparison.IsGreaterThanOrEqualTo
 
test(Object) - Method in class dev.langchain4j.store.embedding.filter.comparison.IsIn
 
test(Object) - Method in class dev.langchain4j.store.embedding.filter.comparison.IsLessThan
 
test(Object) - Method in class dev.langchain4j.store.embedding.filter.comparison.IsLessThanOrEqualTo
 
test(Object) - Method in class dev.langchain4j.store.embedding.filter.comparison.IsNotEqualTo
 
test(Object) - Method in class dev.langchain4j.store.embedding.filter.comparison.IsNotIn
 
test(Object) - Method in interface dev.langchain4j.store.embedding.filter.Filter
Tests if a given object satisfies this Filter.
test(Object) - Method in class dev.langchain4j.store.embedding.filter.logical.And
 
test(Object) - Method in class dev.langchain4j.store.embedding.filter.logical.Not
 
test(Object) - Method in class dev.langchain4j.store.embedding.filter.logical.Or
 
text() - Method in class dev.langchain4j.data.document.DefaultDocument
 
text() - Method in interface dev.langchain4j.data.document.Document
Returns the text of this document.
text() - Method in class dev.langchain4j.data.message.AiMessage
Get the text of the message.
text() - Method in class dev.langchain4j.data.message.SystemMessage
Returns the message text.
text() - Method in class dev.langchain4j.data.message.TextContent
Returns the text.
text() - Method in class dev.langchain4j.data.message.ToolExecutionResultMessage
Returns the result of the tool execution.
text() - Method in class dev.langchain4j.data.segment.TextSegment
Returns the text.
text() - Method in class dev.langchain4j.model.input.Prompt
The text of the prompt.
text() - Method in class dev.langchain4j.rag.query.Query
 
text(String) - Method in class dev.langchain4j.data.message.AiMessage.Builder
 
TEXT - Enum constant in enum class dev.langchain4j.data.message.ContentType
Text content.
TEXT - Enum constant in enum class dev.langchain4j.model.chat.request.ResponseFormatType
 
TEXT - Static variable in class dev.langchain4j.model.chat.request.ResponseFormat
 
TextContent - Class in dev.langchain4j.data.message
Represents a text content.
TextContent(String) - Constructor for class dev.langchain4j.data.message.TextContent
Creates a new text content.
textSegment() - Method in interface dev.langchain4j.rag.content.Content
 
textSegment() - Method in class dev.langchain4j.rag.content.DefaultContent
 
textSegment(String) - Static method in class dev.langchain4j.data.segment.TextSegment
Creates a new text segment.
textSegment(String, Metadata) - Static method in class dev.langchain4j.data.segment.TextSegment
Creates a new text segment.
TextSegment - Class in dev.langchain4j.data.segment
Represents a semantically meaningful segment (chunk/piece/fragment) of a larger entity such as a document or chat conversation.
TextSegment(String, Metadata) - Constructor for class dev.langchain4j.data.segment.TextSegment
Creates a new text segment.
textSegmentTransformer(TextSegmentTransformer) - Method in class dev.langchain4j.store.embedding.EmbeddingStoreIngestor.Builder
Sets the text segment transformer.
TextSegmentTransformer - Interface in dev.langchain4j.data.segment
Defines the interface for transforming a TextSegment.
TimeoutException - Exception Class in dev.langchain4j.exception
 
TimeoutException(String) - Constructor for exception class dev.langchain4j.exception.TimeoutException
 
TimeoutException(String, Throwable) - Constructor for exception class dev.langchain4j.exception.TimeoutException
 
TimeoutException(Throwable) - Constructor for exception class dev.langchain4j.exception.TimeoutException
 
title() - Method in class dev.langchain4j.web.search.WebSearchOrganicResult
Returns the title of the web page.
toAiMessage() - Method in class dev.langchain4j.model.input.Prompt
Convert this prompt to an AiMessage.
toBuilder() - Method in class dev.langchain4j.model.chat.response.ChatResponseMetadata
 
toBuilder(ChatResponseMetadata.Builder<?>) - Method in class dev.langchain4j.model.chat.response.ChatResponseMetadata
 
toDocument() - Method in class dev.langchain4j.web.search.WebSearchOrganicResult
Converts this WebSearchOrganicResult to a Document.
toDocuments() - Method in class dev.langchain4j.web.search.WebSearchResults
Converts the organic search results to a list of documents.
toJson(Object) - Method in interface dev.langchain4j.internal.Json.JsonCodec
Convert the given object to JSON.
toJson(Object) - Static method in class dev.langchain4j.internal.Json
Convert the given object to JSON.
TokenCountEstimator - Interface in dev.langchain4j.model
Represents an interface for estimating the count of tokens in various text types such as a text, prompt, text segment, etc.
tokenUsage() - Method in class dev.langchain4j.model.chat.response.ChatResponse
 
tokenUsage() - Method in class dev.langchain4j.model.chat.response.ChatResponseMetadata
 
tokenUsage() - Method in class dev.langchain4j.model.output.Response
Get the token usage statistics.
tokenUsage() - Method in class dev.langchain4j.store.embedding.IngestionResult
 
tokenUsage(TokenUsage) - Method in class dev.langchain4j.model.chat.response.ChatResponse.Builder
 
tokenUsage(TokenUsage) - Method in class dev.langchain4j.model.chat.response.ChatResponseMetadata.Builder
 
TokenUsage - Class in dev.langchain4j.model.output
Represents the token usage of a response.
TokenUsage() - Constructor for class dev.langchain4j.model.output.TokenUsage
Creates a new TokenUsage instance with all fields set to null.
TokenUsage(Integer) - Constructor for class dev.langchain4j.model.output.TokenUsage
Creates a new TokenUsage instance with the given input token count.
TokenUsage(Integer, Integer) - Constructor for class dev.langchain4j.model.output.TokenUsage
Creates a new TokenUsage instance with the given input and output token counts.
TokenUsage(Integer, Integer, Integer) - Constructor for class dev.langchain4j.model.output.TokenUsage
Creates a new TokenUsage instance with the given input, output and total token counts.
toMap() - Method in class dev.langchain4j.data.document.Metadata
Get a copy of the metadata as a map of key-value pairs.
toMap(JsonSchemaElement) - Static method in class dev.langchain4j.internal.JsonSchemaElementUtils
 
toMap(JsonSchemaElement, boolean) - Static method in class dev.langchain4j.internal.JsonSchemaElementUtils
 
toMap(JsonSchemaElement, boolean, boolean) - Static method in class dev.langchain4j.internal.JsonSchemaElementUtils
 
toMap(Map<String, JsonSchemaElement>) - Static method in class dev.langchain4j.internal.JsonSchemaElementUtils
 
toMap(Map<String, JsonSchemaElement>, boolean) - Static method in class dev.langchain4j.internal.JsonSchemaElementUtils
 
Tool - Annotation Interface in dev.langchain4j.agent.tool
Java methods annotated with @Tool are considered tools/functions that language model can execute/call.
TOOL_EXECUTION - Enum constant in enum class dev.langchain4j.model.output.FinishReason
The call finished signalling a need for tool execution.
TOOL_EXECUTION_RESULT - Enum constant in enum class dev.langchain4j.data.message.ChatMessageType
A message from a tool.
toolChoice() - Method in class dev.langchain4j.model.chat.request.ChatRequest
 
toolChoice() - Method in interface dev.langchain4j.model.chat.request.ChatRequestParameters
 
toolChoice() - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters
 
toolChoice(ToolChoice) - Method in class dev.langchain4j.model.chat.request.ChatRequest.Builder
 
toolChoice(ToolChoice) - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters.Builder
 
ToolChoice - Enum Class in dev.langchain4j.model.chat.request
Specifies how ChatModel should use tools.
ToolExecutionRequest - Class in dev.langchain4j.agent.tool
Represents an LLM-generated request to execute a tool.
ToolExecutionRequest.Builder - Class in dev.langchain4j.agent.tool
ToolExecutionRequest builder static inner class.
toolExecutionRequests() - Method in class dev.langchain4j.data.message.AiMessage
Get the tool execution requests of the message.
toolExecutionRequests(List<ToolExecutionRequest>) - Method in class dev.langchain4j.data.message.AiMessage.Builder
 
toolExecutionResultMessage(ToolExecutionRequest, String) - Static method in class dev.langchain4j.data.message.ToolExecutionResultMessage
Creates a ToolExecutionResultMessage from a ToolExecutionRequest and the result of the tool execution.
toolExecutionResultMessage(String, String, String) - Static method in class dev.langchain4j.data.message.ToolExecutionResultMessage
Creates a ToolExecutionResultMessage from a ToolExecutionRequest and the result of the tool execution.
ToolExecutionResultMessage - Class in dev.langchain4j.data.message
Represents the result of a tool execution in response to a ToolExecutionRequest.
ToolExecutionResultMessage(String, String, String) - Constructor for class dev.langchain4j.data.message.ToolExecutionResultMessage
ToolMemoryId - Annotation Interface in dev.langchain4j.agent.tool
If a Tool method parameter is annotated with this annotation, memory id (parameter annotated with @MemoryId in AI Service) will be injected automatically.
toolName() - Method in class dev.langchain4j.data.message.ToolExecutionResultMessage
Returns the name of the tool.
ToolSpecification - Class in dev.langchain4j.agent.tool
Describes a tool that language model can execute.
ToolSpecification.Builder - Class in dev.langchain4j.agent.tool
ToolSpecification builder static inner class.
toolSpecificationFrom(Method) - Static method in class dev.langchain4j.agent.tool.ToolSpecifications
Returns the ToolSpecification for the given method annotated with @Tool.
toolSpecifications() - Method in class dev.langchain4j.model.chat.request.ChatRequest
 
toolSpecifications() - Method in interface dev.langchain4j.model.chat.request.ChatRequestParameters
 
toolSpecifications() - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters
 
toolSpecifications(ToolSpecification...) - Method in class dev.langchain4j.model.chat.request.ChatRequest.Builder
 
toolSpecifications(ToolSpecification...) - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters.Builder
 
toolSpecifications(List<ToolSpecification>) - Method in class dev.langchain4j.model.chat.request.ChatRequest.Builder
 
toolSpecifications(List<ToolSpecification>) - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters.Builder
 
ToolSpecifications - Class in dev.langchain4j.agent.tool
Utility methods for ToolSpecifications.
toolSpecificationsFrom(Class<?>) - Static method in class dev.langchain4j.agent.tool.ToolSpecifications
Returns ToolSpecifications for all methods annotated with @Tool within the specified class.
toolSpecificationsFrom(Object) - Static method in class dev.langchain4j.agent.tool.ToolSpecifications
Returns ToolSpecifications for all methods annotated with @Tool within the class of the specified object.
topK() - Method in class dev.langchain4j.model.chat.request.ChatRequest
 
topK() - Method in interface dev.langchain4j.model.chat.request.ChatRequestParameters
 
topK() - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters
 
topK(Integer) - Method in class dev.langchain4j.model.chat.request.ChatRequest.Builder
 
topK(Integer) - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters.Builder
 
topP() - Method in class dev.langchain4j.model.chat.request.ChatRequest
 
topP() - Method in interface dev.langchain4j.model.chat.request.ChatRequestParameters
 
topP() - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters
 
topP(Double) - Method in class dev.langchain4j.model.chat.request.ChatRequest.Builder
 
topP(Double) - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters.Builder
 
toPrompt(Object) - Static method in class dev.langchain4j.model.input.structured.StructuredPromptProcessor
Converts the given structured prompt to a prompt.
toPrompt(Object) - Method in interface dev.langchain4j.spi.prompt.structured.StructuredPromptFactory
Converts the given structured prompt to a prompt.
toString() - Method in class dev.langchain4j.agent.tool.ToolExecutionRequest
 
toString() - Method in class dev.langchain4j.agent.tool.ToolSpecification
 
toString() - Method in class dev.langchain4j.data.audio.Audio
 
toString() - Method in class dev.langchain4j.data.document.DefaultDocument
 
toString() - Method in class dev.langchain4j.data.document.Metadata
 
toString() - Method in class dev.langchain4j.data.embedding.Embedding
 
toString() - Method in class dev.langchain4j.data.image.Image
 
toString() - Method in class dev.langchain4j.data.message.AiMessage
 
toString() - Method in class dev.langchain4j.data.message.AudioContent
 
toString() - Method in class dev.langchain4j.data.message.CustomMessage
 
toString() - Method in class dev.langchain4j.data.message.ImageContent
 
toString() - Method in class dev.langchain4j.data.message.PdfFileContent
 
toString() - Method in class dev.langchain4j.data.message.SystemMessage
 
toString() - Method in class dev.langchain4j.data.message.TextContent
 
toString() - Method in class dev.langchain4j.data.message.ToolExecutionResultMessage
 
toString() - Method in class dev.langchain4j.data.message.UserMessage
 
toString() - Method in class dev.langchain4j.data.message.VideoContent
 
toString() - Method in class dev.langchain4j.data.pdf.PdfFile
 
toString() - Method in class dev.langchain4j.data.segment.TextSegment
 
toString() - Method in class dev.langchain4j.data.video.Video
 
toString() - Method in class dev.langchain4j.model.chat.request.ChatRequest
 
toString() - Method in class dev.langchain4j.model.chat.request.DefaultChatRequestParameters
 
toString() - Method in class dev.langchain4j.model.chat.request.json.JsonAnyOfSchema
 
toString() - Method in class dev.langchain4j.model.chat.request.json.JsonArraySchema
 
toString() - Method in class dev.langchain4j.model.chat.request.json.JsonBooleanSchema
 
toString() - Method in class dev.langchain4j.model.chat.request.json.JsonEnumSchema
 
toString() - Method in class dev.langchain4j.model.chat.request.json.JsonIntegerSchema
 
toString() - Method in class dev.langchain4j.model.chat.request.json.JsonNumberSchema
 
toString() - Method in class dev.langchain4j.model.chat.request.json.JsonObjectSchema
 
toString() - Method in class dev.langchain4j.model.chat.request.json.JsonReferenceSchema
 
toString() - Method in class dev.langchain4j.model.chat.request.json.JsonSchema
 
toString() - Method in class dev.langchain4j.model.chat.request.json.JsonStringSchema
 
toString() - Method in class dev.langchain4j.model.chat.request.ResponseFormat
 
toString() - Method in class dev.langchain4j.model.chat.response.ChatResponse
 
toString() - Method in class dev.langchain4j.model.chat.response.ChatResponseMetadata
 
toString() - Method in class dev.langchain4j.model.input.Prompt
 
toString() - Method in class dev.langchain4j.model.moderation.Moderation
 
toString() - Method in class dev.langchain4j.model.output.Response
 
toString() - Method in class dev.langchain4j.model.output.TokenUsage
 
toString() - Method in class dev.langchain4j.rag.content.DefaultContent
 
toString() - Method in class dev.langchain4j.rag.content.retriever.EmbeddingStoreContentRetriever
 
toString() - Method in class dev.langchain4j.rag.query.Metadata
 
toString() - Method in class dev.langchain4j.rag.query.Query
 
toString() - Method in class dev.langchain4j.store.embedding.EmbeddingMatch
 
toString() - Method in class dev.langchain4j.store.embedding.EmbeddingSearchRequest
 
toString() - Method in class dev.langchain4j.store.embedding.filter.comparison.ContainsString
 
toString() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsEqualTo
 
toString() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsGreaterThan
 
toString() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsGreaterThanOrEqualTo
 
toString() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsIn
 
toString() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsLessThan
 
toString() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsLessThanOrEqualTo
 
toString() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsNotEqualTo
 
toString() - Method in class dev.langchain4j.store.embedding.filter.comparison.IsNotIn
 
toString() - Method in class dev.langchain4j.store.embedding.filter.logical.And
 
toString() - Method in class dev.langchain4j.store.embedding.filter.logical.Not
 
toString() - Method in class dev.langchain4j.store.embedding.filter.logical.Or
 
toString() - Method in class dev.langchain4j.web.search.WebSearchInformationResult
 
toString() - Method in class dev.langchain4j.web.search.WebSearchOrganicResult
 
toString() - Method in class dev.langchain4j.web.search.WebSearchRequest
 
toString() - Method in class dev.langchain4j.web.search.WebSearchResults
 
toStringValueMap(Map<String, Object>) - Static method in class dev.langchain4j.internal.Utils
 
toSystemMessage() - Method in class dev.langchain4j.model.input.Prompt
Convert this prompt to a SystemMessage.
totalResults() - Method in class dev.langchain4j.web.search.WebSearchInformationResult
Gets the total number of results.
totalTokenCount() - Method in class dev.langchain4j.model.output.TokenUsage
Returns the total token count, or null if unknown.
toTextSegment() - Method in interface dev.langchain4j.data.document.Document
Builds a TextSegment from this document.
toTextSegment() - Method in class dev.langchain4j.web.search.WebSearchOrganicResult
Converts this WebSearchOrganicResult to a TextSegment.
toTextSegments() - Method in class dev.langchain4j.web.search.WebSearchResults
Converts the organic search results to a list of text segments.
toUserMessage() - Method in class dev.langchain4j.model.input.Prompt
Convert this prompt to a UserMessage.
toUserMessage(String) - Method in class dev.langchain4j.model.input.Prompt
Convert this prompt to a UserMessage with specified userName.
transform(Document) - Method in interface dev.langchain4j.data.document.DocumentTransformer
Transforms a provided document.
transform(TextSegment) - Method in interface dev.langchain4j.data.segment.TextSegmentTransformer
Transforms a provided segment.
transform(Query) - Method in class dev.langchain4j.rag.query.transformer.CompressingQueryTransformer
 
transform(Query) - Method in class dev.langchain4j.rag.query.transformer.DefaultQueryTransformer
 
transform(Query) - Method in class dev.langchain4j.rag.query.transformer.ExpandingQueryTransformer
 
transform(Query) - Method in interface dev.langchain4j.rag.query.transformer.QueryTransformer
Transforms the given Query into one or multiple Querys.
transformAll(List<Document>) - Method in interface dev.langchain4j.data.document.DocumentTransformer
Transforms all the provided documents.
transformAll(List<TextSegment>) - Method in interface dev.langchain4j.data.segment.TextSegmentTransformer
Transforms all the provided segments.
type() - Method in class dev.langchain4j.data.message.AiMessage
 
type() - Method in class dev.langchain4j.data.message.AudioContent
 
type() - Method in interface dev.langchain4j.data.message.ChatMessage
The type of the message.
type() - Method in interface dev.langchain4j.data.message.Content
Returns the type of content.
type() - Method in class dev.langchain4j.data.message.CustomMessage
 
type() - Method in class dev.langchain4j.data.message.ImageContent
 
type() - Method in class dev.langchain4j.data.message.PdfFileContent
 
type() - Method in class dev.langchain4j.data.message.SystemMessage
 
type() - Method in class dev.langchain4j.data.message.TextContent
 
type() - Method in class dev.langchain4j.data.message.ToolExecutionResultMessage
 
type() - Method in class dev.langchain4j.data.message.UserMessage
 
type() - Method in class dev.langchain4j.data.message.VideoContent
 
type() - Method in class dev.langchain4j.model.chat.request.ResponseFormat
 
type(ResponseFormatType) - Method in class dev.langchain4j.model.chat.request.ResponseFormat.Builder
 

U

UnresolvedModelServerException - Exception Class in dev.langchain4j.exception
 
UnresolvedModelServerException(String) - Constructor for exception class dev.langchain4j.exception.UnresolvedModelServerException
 
UnresolvedModelServerException(String, Throwable) - Constructor for exception class dev.langchain4j.exception.UnresolvedModelServerException
 
UnresolvedModelServerException(Throwable) - Constructor for exception class dev.langchain4j.exception.UnresolvedModelServerException
 
UnsupportedFeatureException - Exception Class in dev.langchain4j.exception
 
UnsupportedFeatureException(String) - Constructor for exception class dev.langchain4j.exception.UnsupportedFeatureException
 
updateMessages(Object, List<ChatMessage>) - Method in interface dev.langchain4j.store.memory.chat.ChatMemoryStore
Updates messages for a specified chat memory.
updateMessages(Object, List<ChatMessage>) - Method in class dev.langchain4j.store.memory.chat.InMemoryChatMemoryStore
 
url() - Method in class dev.langchain4j.data.audio.Audio
Get the url of the audio.
url() - Method in class dev.langchain4j.data.image.Image
Get the url of the image.
url() - Method in class dev.langchain4j.data.pdf.PdfFile
Get the url of the PDF.
url() - Method in class dev.langchain4j.data.video.Video
Get the url of the video.
url() - Method in class dev.langchain4j.web.search.WebSearchOrganicResult
Returns the URL associated with the web page.
url(String) - Method in class dev.langchain4j.data.audio.Audio.Builder
Set the url of the audio.
url(String) - Method in class dev.langchain4j.data.image.Image.Builder
Set the url of the image.
url(String) - Method in class dev.langchain4j.data.pdf.PdfFile.Builder
Set the url of the PDF document.
url(String) - Method in class dev.langchain4j.data.video.Video.Builder
Set the url of the video.
url(URI) - Method in class dev.langchain4j.data.audio.Audio.Builder
Set the url of the audio.
url(URI) - Method in class dev.langchain4j.data.image.Image.Builder
Set the url of the image.
url(URI) - Method in class dev.langchain4j.data.pdf.PdfFile.Builder
Set the url of the PDF document.
url(URI) - Method in class dev.langchain4j.data.video.Video.Builder
Set the url of the video.
URL - Static variable in interface dev.langchain4j.data.document.Document
Common metadata key for the URL from which the document was loaded.
USER - Enum constant in enum class dev.langchain4j.data.message.ChatMessageType
A message from the user.
userMessage(Content...) - Static method in class dev.langchain4j.data.message.UserMessage
Create a UserMessage from contents.
userMessage(String) - Static method in class dev.langchain4j.data.message.UserMessage
Create a UserMessage from a text.
userMessage(String, Content...) - Static method in class dev.langchain4j.data.message.UserMessage
Create a UserMessage from a name and contents.
userMessage(String, String) - Static method in class dev.langchain4j.data.message.UserMessage
Create a UserMessage from a name and a text.
userMessage(String, List<Content>) - Static method in class dev.langchain4j.data.message.UserMessage
Create a UserMessage from a name and contents.
userMessage(List<Content>) - Static method in class dev.langchain4j.data.message.UserMessage
Create a UserMessage from contents.
UserMessage - Class in dev.langchain4j.data.message
Represents a message from a user, typically an end user of the application.
UserMessage(Content...) - Constructor for class dev.langchain4j.data.message.UserMessage
Creates a UserMessage from one or multiple Contents.
UserMessage(String) - Constructor for class dev.langchain4j.data.message.UserMessage
Creates a UserMessage from a text.
UserMessage(String, Content...) - Constructor for class dev.langchain4j.data.message.UserMessage
Creates a UserMessage from a name and one or multiple Contents.
UserMessage(String, String) - Constructor for class dev.langchain4j.data.message.UserMessage
Creates a UserMessage from a name and a text.
UserMessage(String, List<Content>) - Constructor for class dev.langchain4j.data.message.UserMessage
Creates a UserMessage from a name and a list of Contents.
UserMessage(List<Content>) - Constructor for class dev.langchain4j.data.message.UserMessage
Creates a UserMessage from a list of Contents.
UserMessage.Builder - Class in dev.langchain4j.data.message
 
Utils - Class in dev.langchain4j.internal
Utility methods.

V

validate(ResponseFormat) - Static method in class dev.langchain4j.internal.ChatRequestValidationUtils
 
validate(ToolChoice) - Static method in class dev.langchain4j.internal.ChatRequestValidationUtils
 
validate(List<ToolSpecification>) - Static method in class dev.langchain4j.internal.ChatRequestValidationUtils
 
validateMessages(List<ChatMessage>) - Static method in class dev.langchain4j.internal.ChatRequestValidationUtils
 
validateParameters(ChatRequestParameters) - Static method in class dev.langchain4j.internal.ChatRequestValidationUtils
 
validateSpecifications(List<ToolSpecification>) - Static method in class dev.langchain4j.agent.tool.ToolSpecifications
Validates all the ToolSpecifications.
validateStructuredPrompt(Object) - Static method in class dev.langchain4j.model.input.structured.StructuredPrompt.Util
Validates that the given object is annotated with StructuredPrompt.
ValidationUtils - Class in dev.langchain4j.internal
Utility class for validating method arguments.
value() - Element in annotation interface dev.langchain4j.agent.tool.P
Description of a parameter
value() - Element in annotation interface dev.langchain4j.agent.tool.Tool
Description of the tool.
value() - Element in annotation interface dev.langchain4j.model.input.structured.StructuredPrompt
Prompt template can be defined in one line or multiple lines.
value() - Element in annotation interface dev.langchain4j.model.output.structured.Description
The description can be defined in one line or multiple lines.
valueOf(String) - Static method in enum class dev.langchain4j.data.message.ChatMessageType
Returns the enum constant of this class with the specified name.
valueOf(String) - Static method in enum class dev.langchain4j.data.message.ContentType
Returns the enum constant of this class with the specified name.
valueOf(String) - Static method in enum class dev.langchain4j.data.message.ImageContent.DetailLevel
Returns the enum constant of this class with the specified name.
valueOf(String) - Static method in enum class dev.langchain4j.model.chat.Capability
Returns the enum constant of this class with the specified name.
valueOf(String) - Static method in enum class dev.langchain4j.model.chat.request.ResponseFormatType
Returns the enum constant of this class with the specified name.
valueOf(String) - Static method in enum class dev.langchain4j.model.chat.request.ToolChoice
Returns the enum constant of this class with the specified name.
valueOf(String) - Static method in enum class dev.langchain4j.model.ModelProvider
Returns the enum constant of this class with the specified name.
valueOf(String) - Static method in enum class dev.langchain4j.model.output.FinishReason
Returns the enum constant of this class with the specified name.
valueOf(String) - Static method in enum class dev.langchain4j.rag.content.ContentMetadata
Returns the enum constant of this class with the specified name.
valueOf(String) - Static method in enum class dev.langchain4j.rag.query.router.LanguageModelQueryRouter.FallbackStrategy
Returns the enum constant of this class with the specified name.
values() - Static method in enum class dev.langchain4j.data.message.ChatMessageType
Returns an array containing the constants of this enum class, in the order they are declared.
values() - Static method in enum class dev.langchain4j.data.message.ContentType
Returns an array containing the constants of this enum class, in the order they are declared.
values() - Static method in enum class dev.langchain4j.data.message.ImageContent.DetailLevel
Returns an array containing the constants of this enum class, in the order they are declared.
values() - Static method in enum class dev.langchain4j.model.chat.Capability
Returns an array containing the constants of this enum class, in the order they are declared.
values() - Static method in enum class dev.langchain4j.model.chat.request.ResponseFormatType
Returns an array containing the constants of this enum class, in the order they are declared.
values() - Static method in enum class dev.langchain4j.model.chat.request.ToolChoice
Returns an array containing the constants of this enum class, in the order they are declared.
values() - Static method in enum class dev.langchain4j.model.ModelProvider
Returns an array containing the constants of this enum class, in the order they are declared.
values() - Static method in enum class dev.langchain4j.model.output.FinishReason
Returns an array containing the constants of this enum class, in the order they are declared.
values() - Static method in enum class dev.langchain4j.rag.content.ContentMetadata
Returns an array containing the constants of this enum class, in the order they are declared.
values() - Static method in enum class dev.langchain4j.rag.query.router.LanguageModelQueryRouter.FallbackStrategy
Returns an array containing the constants of this enum class, in the order they are declared.
vector() - Method in class dev.langchain4j.data.embedding.Embedding
Returns the vector.
vectorAsList() - Method in class dev.langchain4j.data.embedding.Embedding
Returns a copy of the vector as a list.
video() - Method in class dev.langchain4j.data.message.VideoContent
Get the Video.
Video - Class in dev.langchain4j.data.video
 
VIDEO - Enum constant in enum class dev.langchain4j.data.message.ContentType
Video content.
Video.Builder - Class in dev.langchain4j.data.video
Builder for Video.
VideoContent - Class in dev.langchain4j.data.message
 
VideoContent(Video) - Constructor for class dev.langchain4j.data.message.VideoContent
Create a new VideoContent from the given video.
VideoContent(String) - Constructor for class dev.langchain4j.data.message.VideoContent
Create a new VideoContent from the given url.
VideoContent(String, String) - Constructor for class dev.langchain4j.data.message.VideoContent
Create a new VideoContent from the given base64 data and mime type.
VideoContent(URI) - Constructor for class dev.langchain4j.data.message.VideoContent
Create a new VideoContent from the given url.
VirtualThreadUtils - Class in dev.langchain4j.internal
Utility class for working with virtual threads introduced in Java 21.
VirtualThreadUtils() - Constructor for class dev.langchain4j.internal.VirtualThreadUtils
 
VisitedClassMetadata(JsonSchemaElement, String, boolean) - Constructor for class dev.langchain4j.internal.JsonSchemaElementUtils.VisitedClassMetadata
 

W

WebSearchContentRetriever - Class in dev.langchain4j.rag.content.retriever
A ContentRetriever that retrieves relevant Content from the web using a WebSearchEngine.
WebSearchContentRetriever(WebSearchEngine, Integer) - Constructor for class dev.langchain4j.rag.content.retriever.WebSearchContentRetriever
 
WebSearchContentRetriever.WebSearchContentRetrieverBuilder - Class in dev.langchain4j.rag.content.retriever
 
webSearchEngine(WebSearchEngine) - Method in class dev.langchain4j.rag.content.retriever.WebSearchContentRetriever.WebSearchContentRetrieverBuilder
 
WebSearchEngine - Interface in dev.langchain4j.web.search
Represents a web search engine that can be used to perform searches on the Web in response to a user query.
WebSearchInformationResult - Class in dev.langchain4j.web.search
Represents general information about the web search performed.
WebSearchInformationResult(Long) - Constructor for class dev.langchain4j.web.search.WebSearchInformationResult
Constructs a new WebSearchInformationResult with the specified total results.
WebSearchInformationResult(Long, Integer, Map<String, Object>) - Constructor for class dev.langchain4j.web.search.WebSearchInformationResult
Constructs a new WebSearchInformationResult with the specified total results, page number, and metadata.
WebSearchOrganicResult - Class in dev.langchain4j.web.search
Represents an organic search results are the web pages that are returned by the search engine in response to a search query.
WebSearchOrganicResult(String, URI) - Constructor for class dev.langchain4j.web.search.WebSearchOrganicResult
Constructs a WebSearchOrganicResult object with the given title and URL.
WebSearchOrganicResult(String, URI, String, String) - Constructor for class dev.langchain4j.web.search.WebSearchOrganicResult
Constructs a WebSearchOrganicResult object with the given title, URL, snippet and/or content.
WebSearchOrganicResult(String, URI, String, String, Map<String, String>) - Constructor for class dev.langchain4j.web.search.WebSearchOrganicResult
Constructs a WebSearchOrganicResult object with the given title, URL, snippet and/or content, and metadata.
WebSearchRequest - Class in dev.langchain4j.web.search
Represents a search request that can be made by the user to perform searches in any implementation of WebSearchEngine.
WebSearchRequest.Builder - Class in dev.langchain4j.web.search
 
WebSearchResults - Class in dev.langchain4j.web.search
Represents the response of a web search performed.
WebSearchResults(WebSearchInformationResult, List<WebSearchOrganicResult>) - Constructor for class dev.langchain4j.web.search.WebSearchResults
Constructs a new instance of WebSearchResults.
WebSearchResults(Map<String, Object>, WebSearchInformationResult, List<WebSearchOrganicResult>) - Constructor for class dev.langchain4j.web.search.WebSearchResults
Constructs a new instance of WebSearchResults.
WebSearchTool - Class in dev.langchain4j.web.search
 
WebSearchTool(WebSearchEngine) - Constructor for class dev.langchain4j.web.search.WebSearchTool
 
withExceptionMapper(Callable<T>) - Method in interface dev.langchain4j.internal.ExceptionMapper
 
withRetry(Runnable, int) - Static method in class dev.langchain4j.internal.RetryUtils
This method attempts to execute a given action up to a specified number of times with an exponential backoff.
withRetry(Callable<T>) - Method in class dev.langchain4j.internal.RetryUtils.RetryPolicy
This method attempts to execute a given action up to 3 times with an exponential backoff.
withRetry(Callable<T>) - Static method in class dev.langchain4j.internal.RetryUtils
This method attempts to execute a given action up to 3 times with an exponential backoff.
withRetry(Callable<T>, int) - Method in class dev.langchain4j.internal.RetryUtils.RetryPolicy
This method attempts to execute a given action up to a specified number of times with an exponential backoff.
withRetry(Callable<T>, int) - Static method in class dev.langchain4j.internal.RetryUtils
This method attempts to execute a given action up to a specified number of times with an exponential backoff.
withRetryMappingExceptions(Callable<T>) - Static method in class dev.langchain4j.internal.RetryUtils
This method attempts to execute a given action up to 3 times with an exponential backoff.
withRetryMappingExceptions(Callable<T>, int) - Static method in class dev.langchain4j.internal.RetryUtils
This method attempts to execute a given action up to a specified number of times with an exponential backoff.
withRetryMappingExceptions(Callable<T>, int, ExceptionMapper) - Static method in class dev.langchain4j.internal.RetryUtils
This method attempts to execute a given action up to a specified number of times with an exponential backoff.
A B C D E F G H I J K L M N O P Q R S T U V W 
All Classes and Interfaces|All Packages|Constant Field Values|Serialized Form