Class InfinispanEmbeddingStore
java.lang.Object
dev.langchain4j.store.embedding.infinispan.InfinispanEmbeddingStore
- All Implemented Interfaces:
EmbeddingStore<TextSegment>
Infinispan Embedding Store
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionInfinispanEmbeddingStore(org.infinispan.client.hotrod.configuration.ConfigurationBuilder builder, InfinispanStoreConfiguration storeConfiguration) Creates an instance of InfinispanEmbeddingStoreInfinispanEmbeddingStore(org.infinispan.client.hotrod.RemoteCacheManager remoteCacheManager, InfinispanStoreConfiguration storeConfiguration) Creates an Infinispan embedding store from a RemoteCacheManager Assumes marshalling configuration is already provided by the RemoteCacheManager instance. -
Method Summary
Modifier and TypeMethodDescriptionadd(Embedding embedding, TextSegment textSegment) voidvoidbuilder()voidorg.infinispan.client.hotrod.RemoteCache<String, LangChainInfinispanItem> Gets the underlying Infinispan remote cacheorg.infinispan.client.hotrod.RemoteCache<String, LangChainInfinispanItem> voidvoidvoidremoveAll(Collection<String> ids) search(EmbeddingSearchRequest request) Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface EmbeddingStore
addAll, generateIds, remove
-
Constructor Details
-
InfinispanEmbeddingStore
public InfinispanEmbeddingStore(org.infinispan.client.hotrod.RemoteCacheManager remoteCacheManager, InfinispanStoreConfiguration storeConfiguration) Creates an Infinispan embedding store from a RemoteCacheManager Assumes marshalling configuration is already provided by the RemoteCacheManager instance.- Parameters:
remoteCacheManager- , the already configured remote cache managerstoreConfiguration- , the store configuration
-
InfinispanEmbeddingStore
public InfinispanEmbeddingStore(org.infinispan.client.hotrod.configuration.ConfigurationBuilder builder, InfinispanStoreConfiguration storeConfiguration) Creates an instance of InfinispanEmbeddingStore
-
-
Method Details
-
getRemoteCache
Gets the underlying Infinispan remote cache- Returns:
- RemoteCache
-
add
- Specified by:
addin interfaceEmbeddingStore<TextSegment>
-
add
- Specified by:
addin interfaceEmbeddingStore<TextSegment>
-
add
- Specified by:
addin interfaceEmbeddingStore<TextSegment>
-
addAll
- Specified by:
addAllin interfaceEmbeddingStore<TextSegment>
-
removeAll
public void removeAll()- Specified by:
removeAllin interfaceEmbeddingStore<TextSegment>
-
removeAll
- Specified by:
removeAllin interfaceEmbeddingStore<TextSegment>
-
removeAll
- Specified by:
removeAllin interfaceEmbeddingStore<TextSegment>
-
search
- Specified by:
searchin interfaceEmbeddingStore<TextSegment>
-
addAll
- Specified by:
addAllin interfaceEmbeddingStore<TextSegment>
-
builder
-
remoteCache
-
clearCache
public void clearCache()
-