Uses of Interface
org.nasdanika.ai.EmbeddingGenerator
-
Uses of EmbeddingGenerator in org.nasdanika.ai
Subinterfaces of EmbeddingGenerator in org.nasdanika.aiModifier and TypeInterfaceDescriptioninterfaceEmbeddingModel<S,E> interfaceinterfaceinterfaceinterfaceConverts image to text (String).interfaceNarrator<S>Converts source to text (String).interfaceinterfaceTextFloatVectorEmbeddingModel "business" interface focusing on ease of use and leaving token usage reporting to implementations.interfaceClasses in org.nasdanika.ai that implement EmbeddingGeneratorModifier and TypeClassDescriptionclassSplits input by whitespace, lowercases and then computes frequency of each wordclassclassCachingEmbeddingGenerator<S,E, K> Caches image embeddings in a map which can be loaded and saved between runs Uses image digest as caching keyclassCaches image embeddings in a map which can be loaded and saved between runs Uses image digest as caching keyclassclassCaches text embeddings in a map which can be loaded and saved between runs Uses text digest as caching keyclassclassclassclassMapCachingEmbeddingGenerator<S,E, K> Caches image embeddings in a map which can be loaded and saved between runs Uses image digest as caching keyclassA simple implementation which treats a character as a token.classclassclassCan handle data: URIsclassFields in org.nasdanika.ai declared as EmbeddingGeneratorModifier and TypeFieldDescriptionprotected EmbeddingGenerator<S, E> CachingEmbeddingGenerator.targetMethods in org.nasdanika.ai that return EmbeddingGeneratorModifier and TypeMethodDescriptiondefault <V> EmbeddingGenerator<V, E> default EmbeddingGenerator<File, E> ImageEmbeddingGenerator.asFileEmbeddingGenerator()default EmbeddingGenerator<InputStream, E> ImageEmbeddingGenerator.asInputStreamEmbeddingGenerator()default EmbeddingGenerator<URL, E> ImageEmbeddingGenerator.asUrlEmbeddingGenerator()default EmbeddingGenerator<S, E> EmbeddingGenerator.compose(EmbeddingGenerator<? super S, ? extends E> other, BinaryOperator<E> composer) Calls this embedding generator and returns its return value if it is not null and composer is null.default EmbeddingGenerator<S, E> EmbeddingGenerator.compose(EmbeddingGenerator<S, E> other) static <S,E> EmbeddingGenerator <S, E> EmbeddingGenerator.compose(EmbeddingGenerator<S, E> a, EmbeddingGenerator<S, E> b, BinaryOperator<E> composer) default EmbeddingGenerator<S, E> EmbeddingGenerator.composeAsync(EmbeddingGenerator<? super S, ? extends E> other, BiFunction<? super E, ? super E, reactor.core.publisher.Mono<E>> composer) Calls this embedding generator and returns its return value if it is not null and composer is null.default <F> EmbeddingGenerator<S, F> EmbeddingGenerator.then(EmbeddingGenerator<E, F> next) Methods in org.nasdanika.ai that return types with arguments of type EmbeddingGeneratorModifier and TypeMethodDescriptionPredicate<EmbeddingGenerator<?, ?>> EmbeddingGenerator.Requirement.predicate()Returns the value of thepredicaterecord component.static <S,E> Optional <EmbeddingGenerator<S, E>> EmbeddingGenerator.reduce(Stream<EmbeddingGenerator<S, E>> stream, BinaryOperator<E> composer) Predicate<Class<? extends EmbeddingGenerator<?, ?>>> EmbeddingGenerator.Requirement.typePredicate()Returns the value of thetypePredicaterecord component.Methods in org.nasdanika.ai with parameters of type EmbeddingGeneratorModifier and TypeMethodDescriptiondefault EmbeddingGenerator<S, E> EmbeddingGenerator.compose(EmbeddingGenerator<? super S, ? extends E> other, BinaryOperator<E> composer) Calls this embedding generator and returns its return value if it is not null and composer is null.default EmbeddingGenerator<S, E> EmbeddingGenerator.compose(EmbeddingGenerator<S, E> other) static <S,E> EmbeddingGenerator <S, E> EmbeddingGenerator.compose(EmbeddingGenerator<S, E> a, EmbeddingGenerator<S, E> b, BinaryOperator<E> composer) default EmbeddingGenerator<S, E> EmbeddingGenerator.composeAsync(EmbeddingGenerator<? super S, ? extends E> other, BiFunction<? super E, ? super E, reactor.core.publisher.Mono<E>> composer) Calls this embedding generator and returns its return value if it is not null and composer is null.static <S,E, K> MapCachingEmbeddingGenerator <S, E, K> MapCachingEmbeddingGenerator.create(EmbeddingGenerator<S, E> target, Map<K, E> cache, Function<S, K> keyComputer) Creates an instance which uses the provided key computer.default <F> EmbeddingGenerator<S, F> EmbeddingGenerator.then(EmbeddingGenerator<E, F> next) Method parameters in org.nasdanika.ai with type arguments of type EmbeddingGeneratorModifier and TypeMethodDescriptionstatic <S,E> Optional <EmbeddingGenerator<S, E>> EmbeddingGenerator.reduce(Stream<EmbeddingGenerator<S, E>> stream, BinaryOperator<E> composer) Constructors in org.nasdanika.ai with parameters of type EmbeddingGeneratorModifierConstructorDescriptionprotectedCachingEmbeddingGenerator(EmbeddingGenerator<S, E> target) protectedMapCachingEmbeddingGenerator(EmbeddingGenerator<S, E> target, Map<K, E> cache) Constructor parameters in org.nasdanika.ai with type arguments of type EmbeddingGeneratorModifierConstructorDescriptionRequirement(Class<?> sourceType, Class<?> embeddingType, Predicate<Class<? extends EmbeddingGenerator<?, ?>>> typePredicate, Predicate<EmbeddingGenerator<?, ?>> predicate) Creates an instance of aRequirementrecord class.