Text Encoders

Utilities for text lookup, caching, and encoding.

Classes

TextCache()

An interface for looking up text for various flavors of entity identifiers.

IdentityCache()

A cache without functionality.

PyOBOTextCache(*args, **kwargs)

A cache that looks up labels of biomedical entities based on their CURIEs.

WikidataTextCache()

A cache for requests against Wikidata's SPARQL endpoint.

TextEncoder(*args, **kwargs)

An encoder for text.

CharacterEmbeddingTextEncoder([dim, ...])

A simple character-based text encoder.

TransformerTextEncoder([...])

A combination of a tokenizer and a model.

Variables

text_cache_resolver

Resolve from a list of classes.

text_encoder_resolver

Resolve from a list of classes.

Class Inheritance Diagram

Inheritance diagram of pykeen.nn.text.cache.TextCache, pykeen.nn.text.cache.IdentityCache, pykeen.nn.text.cache.PyOBOTextCache, pykeen.nn.text.cache.WikidataTextCache, pykeen.nn.text.encoder.TextEncoder, pykeen.nn.text.encoder.CharacterEmbeddingTextEncoder, pykeen.nn.text.encoder.TransformerTextEncoder