memgen-checkpoints / README.md
Jamesding000
Update README
3a8e4c6

MemGen Checkpoints

The model checkpoints and artifacts for On the Memorization and Generalization of Generative Recommendation.

Folder Structure

  • SASRec/: SASRec checkpoints (.pth)
  • TIGER/: TIGER checkpoints (.pth)
  • semantic_ids/: semantic ID files (.sem_ids) used to train the corresponding TIGER checkpoints

All checkpoints are trained with the default configs in the code repo. If you are unsure about model size / architecture, please refer to the configs in [Code].

Download (example)

from huggingface_hub import hf_hub_download

repo_id = "jamesding0302/memgen-checkpoints"
out_dir = "./downloads"   # change this to desired output path

ckpt_path = hf_hub_download(
    repo_id=repo_id,
    filename="TIGER/TIGER-AmazonReviews2014-category_Sports_and_Outdoors.pth",
    local_dir=out_dir,
)

sem_ids_path = hf_hub_download(
    repo_id=repo_id,
    filename="semantic_ids/AmazonReviews2014-Sports_and_Outdoors_sentence-t5-base_256,256,256,256.sem_ids",
    local_dir=out_dir,
)

Evaluation

You can run fine-grained evaluation using the saved checkpoint_path and sem_ids_path:

CUDA_VISIBLE_DEVICES=0 python mem_gen_evaluation.py \
    --model=TIGER \
    --dataset=AmazonReviews2014 \
    --category=Sports_and_Outdoors \
    --checkpoint_path=path/to/TIGER.pth \
    --sem_ids_path=path/to/semantic_ids.sem_ids \
    --eval=test \
    --save_inference