Feature Extraction
MLX
English
hrr
vsa
holographic-reduced-representations
tokenizer
morphemes
compositional
Instructions to use thebasedcapital/morph-hrr with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- MLX
How to use thebasedcapital/morph-hrr with MLX:
# Download the model from the Hub pip install huggingface_hub[hf_xet] huggingface-cli download --local-dir morph-hrr thebasedcapital/morph-hrr
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- LM Studio
| """morph-hrr: compositional HRR morpheme tokenizer for Apple MLX. | |
| A word becomes one fixed-width vector via circular-convolution composition of its | |
| morphemes (prefix (x) root (x) suffix), giving algebraically manipulable, | |
| out-of-vocabulary-friendly token representations. | |
| """ | |
| from __future__ import annotations | |
| __version__ = "0.1.1" | |
| from .hrr import ( | |
| bind, | |
| bundle, | |
| cosine_similarity, | |
| make_unitary, | |
| normalize, | |
| unbind, | |
| update_context, | |
| ) | |
| from .morphemes import PREFIXES, SUFFIXES, segment | |
| from .tokenizer import HolographicMorphemeTokenizer, MorphemeTokenizer | |
| __all__ = [ | |
| "MorphemeTokenizer", | |
| "HolographicMorphemeTokenizer", | |
| "segment", | |
| "PREFIXES", | |
| "SUFFIXES", | |
| "bind", | |
| "unbind", | |
| "bundle", | |
| "normalize", | |
| "make_unitary", | |
| "cosine_similarity", | |
| "update_context", | |
| "__version__", | |
| ] | |