๐งพ What is SubSlay?
SubSlay is a text-to-emoji transformer that turns plain text into expressive emoji sequences โ powered by semantic similarity (via GloVe vectors), direct keyword mappings, and fuzzy Levenshtein fallback.
โจ
"Hello, world!"โ"๐ ๐"
This crate is built entirely in Rust and is compatible with native binaries and WebAssembly, with no external files or setup required.
๐ Try It Live
๐ SubSlay.app โ Web demo powered by this crate
๐ Features
- ๐ฆ Pure Rust (no WASM bindings inside)
- ๐ฆ No setup โ GloVe + emoji mappings are embedded
- ๐ก Keyword match, cosine similarity, and Levenshtein fallback
- ๐งช Fully tested
- ๐ Easily used in WASM apps (via your own wrapper)
โจ Usage
Add it to your project:
[]
= "0.1.8"
Use it in Rust:
use EmojiStylist;
๐ง How It Works
SubSlay internally loads:
emoji.jsonโ maps emojis to keyword listsglove.txtโ GloVe-style word embeddings
Then it:
- Matches input words to emoji keywords
- Uses cosine similarity to suggest close matches
- Falls back to Levenshtein distance if all else fails
All logic is pure Rust and runs without filesystem access โ ideal for embedded and WASM environments.
๐ Project Layout
โ Test
Run tests with:
All embeddings and mappings are embedded, so no setup is needed.
๐ค Contribute
Feel free to open issues or pull requests for:
- New emoji suggestions
- Better embedding support
- Fallback improvements
- WASM wrappers or examples
๐ License
MIT ยฉ AndriaK GitHub: github.com/8ria/subslay
"Built to slay, not obey." ๐ ๐ป