snap-research/GRID
A generative recommendation framework from Snap Research that learns semantic IDs from item text embeddings using LLMs and Residual Quantization, then generates recommendation sequences via transformers.

GRID implements a three-stage pipeline for generative recommendation: first, it converts item text into embeddings using any Huggingface LLM; second, it learns hierarchical semantic IDs from embeddings through Residual Quantization techniques including RQ-KMeans, RQ-VAE, and RVQ; third, it generates recommendation sequences as semantic ID tokens using transformer architectures. The framework is built on PyTorch, Hydra, and Lightning.