├── .gitattributes ├── .gitignore ├── .vscode └── settings.json ├── LICENSE ├── README.md ├── beauty ├── README.md ├── __init__.py ├── attach_embeddings.ipynb ├── create_sessions.ipynb ├── dataset.pickle ├── finetuning │ ├── check_fine_tune_results.ipynb │ ├── ft-i5m6oTIIEbwlSDB0cEn7Q3UW.csv │ ├── ft-kKAdWXe2sKPsa9kqgfZW2P5e.csv │ ├── ft-lKhu84vhQp2q97BBcbIobyLI.csv │ ├── ft-vQjqVAUgAg5pAHZgxMI79yb2.csv │ ├── train_cases.jsonl │ └── validation_cases.jsonl ├── format_timestamps.ipynb ├── formatted_sessions.csv ├── item_id_to_int.json ├── openai_augmented_dataset.pickle ├── palm_augmented_dataset.pickle ├── product_embeddings_openai.csv.gz ├── product_embeddings_palm.csv.gz ├── products_lookup.csv ├── session_id_to_int.json ├── sessions.csv └── split_sessions.ipynb ├── figures ├── correct_recommendation_similarities.png └── recommendation_similarities.png ├── main ├── __init__.py ├── abstract_model.py ├── data │ ├── __init__.py │ ├── abstract_dataset.py │ ├── mece_split.py │ ├── random_split.py │ ├── session_dataset.py │ ├── side_information.py │ └── temporal_split.py ├── dim_reducer │ ├── __init__.py │ └── dim_reducer.py ├── eval │ ├── __init__.py │ ├── evaluation.py │ └── metrics │ │ ├── __init__.py │ │ ├── catalog_coverage.py │ │ ├── hitrate.py │ │ ├── metric.py │ │ ├── mrr.py │ │ ├── ndcg.py │ │ ├── novelty.py │ │ └── serendipity.py ├── exceptions.py ├── grurec │ ├── __init__.py │ ├── grurec.py │ ├── grurec_model.py │ └── grurec_with_embeddings.py ├── hybrids │ ├── embedding-ensemble.py │ ├── popularity-based-hybrid.py │ ├── properties.py │ ├── property-injected-embedding.py │ └── utils.py ├── llm_based │ ├── __init__.py │ ├── embedding_utils │ │ ├── __init__.py │ │ ├── create_embeddings.ipynb │ │ ├── key.txt │ │ ├── openai_utils.py │ │ └── palm_utils.py │ ├── gpt │ │ ├── __init__.py │ │ └── gpt_model.py │ ├── palm │ │ ├── __init__.py │ │ └── palm_model.py │ ├── prompt_model │ │ ├── README.md │ │ ├── __init__.py │ │ ├── classify │ │ │ ├── generate_finetune_prompts.ipynb │ │ │ ├── predict_gpt.ipynb │ │ │ └── predict_palm.ipynb │ │ ├── fine-tuning_scripts │ │ │ ├── finetune_gpt.py │ │ │ └── finetune_palm.py │ │ ├── genitem │ │ │ ├── generate_finetune_prompts.ipynb │ │ │ ├── predict_gpt.ipynb │ │ │ └── predict_palm.ipynb │ │ ├── genlist │ │ │ ├── generate_finetune_prompts.ipynb │ │ │ ├── predict_gpt.ipynb │ │ │ └── predict_palm.ipynb │ │ └── rank │ │ │ ├── generate_finetune_prompts.ipynb │ │ │ ├── generate_test_prompts_llmseqprompt_rank.ipynb │ │ │ ├── predict_gpt.ipynb │ │ │ └── predict_palm.ipynb │ └── similarity_model │ │ ├── __init__.py │ │ ├── llm_seq_sim.py │ │ └── session_embeddings.ipynb ├── neural_model.py ├── popularity │ ├── __init__.py │ └── session_popular.py ├── reranking │ ├── rerank_pairwise_similarity.py │ ├── reranker.py │ └── reranker_batch.py ├── sknn │ ├── __init__.py │ └── sknn.py ├── transformer │ ├── __init__.py │ ├── bert │ │ ├── __init__.py │ │ ├── bert.py │ │ ├── bert_model.py │ │ ├── bert_with_embeddings.py │ │ └── custom_generators │ │ │ ├── __init__.py │ │ │ ├── test_generator.py │ │ │ └── train_generator.py │ ├── custom_layers │ │ ├── __init__.py │ │ ├── embedding_layer.py │ │ └── transformer_encoder_layer.py │ ├── sasrec │ │ ├── sasrec.py │ │ ├── sasrec_model.py │ │ └── sasrec_with_embeddings.py │ ├── transformer.py │ └── transformer_model.py └── utils │ ├── __init__.py │ ├── config_util.py │ ├── dim_reducer.py │ ├── id_reducer.py │ ├── multiprocessing.py │ ├── neural_utils │ ├── custom_activations │ │ ├── __init__.py │ │ └── gelu.py │ ├── custom_callbacks │ │ └── metric_callback.py │ ├── custom_generators │ │ ├── next_item_test_generator.py │ │ └── next_item_train_generator.py │ ├── custom_layers │ │ ├── bias_layer.py │ │ └── projection_head.py │ ├── custom_losses │ │ └── masked_sparse_categorical_crossentropy.py │ └── custom_preprocessors │ │ ├── __init__.py │ │ ├── cloze.py │ │ ├── data_description.py │ │ └── tensor_factory.py │ ├── session_utils │ ├── __init__.py │ ├── decay_utils.py │ └── session_embedding_utils.py │ ├── side_encoder.py │ ├── similarity.py │ ├── split_dict.py │ ├── top_k_computer.py │ └── utils.py ├── notebooks ├── __init__.py ├── exploring_embeddings.ipynb ├── session_data_description.ipynb ├── session_length_hitrate_beauty.ipynb └── session_length_hitrate_dh.ipynb ├── online_material.md ├── paths.py ├── poetry.lock ├── pyproject.toml ├── run_experiments.ipynb ├── setup.cfg └── steam ├── .gitattributes ├── README.md ├── attach_embeddings.ipynb ├── create_sessions.ipynb ├── dataset.pickle ├── item_metadata.csv ├── openai_augmented_dataset.pickle ├── palm_augmented_dataset.pickle ├── product_embeddings_openai.csv.gz ├── product_embeddings_palm.csv.gz ├── sessions.csv └── split_sessions.ipynb /.gitattributes: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/.gitattributes -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/.gitignore -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "python.formatting.provider": "black" 3 | } -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/LICENSE -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/README.md -------------------------------------------------------------------------------- /beauty/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/README.md -------------------------------------------------------------------------------- /beauty/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /beauty/attach_embeddings.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/attach_embeddings.ipynb -------------------------------------------------------------------------------- /beauty/create_sessions.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/create_sessions.ipynb -------------------------------------------------------------------------------- /beauty/dataset.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/dataset.pickle -------------------------------------------------------------------------------- /beauty/finetuning/check_fine_tune_results.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/finetuning/check_fine_tune_results.ipynb -------------------------------------------------------------------------------- /beauty/finetuning/ft-i5m6oTIIEbwlSDB0cEn7Q3UW.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/finetuning/ft-i5m6oTIIEbwlSDB0cEn7Q3UW.csv -------------------------------------------------------------------------------- /beauty/finetuning/ft-kKAdWXe2sKPsa9kqgfZW2P5e.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/finetuning/ft-kKAdWXe2sKPsa9kqgfZW2P5e.csv -------------------------------------------------------------------------------- /beauty/finetuning/ft-lKhu84vhQp2q97BBcbIobyLI.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/finetuning/ft-lKhu84vhQp2q97BBcbIobyLI.csv -------------------------------------------------------------------------------- /beauty/finetuning/ft-vQjqVAUgAg5pAHZgxMI79yb2.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/finetuning/ft-vQjqVAUgAg5pAHZgxMI79yb2.csv -------------------------------------------------------------------------------- /beauty/finetuning/train_cases.jsonl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/finetuning/train_cases.jsonl -------------------------------------------------------------------------------- /beauty/finetuning/validation_cases.jsonl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/finetuning/validation_cases.jsonl -------------------------------------------------------------------------------- /beauty/format_timestamps.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/format_timestamps.ipynb -------------------------------------------------------------------------------- /beauty/formatted_sessions.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/formatted_sessions.csv -------------------------------------------------------------------------------- /beauty/item_id_to_int.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/item_id_to_int.json -------------------------------------------------------------------------------- /beauty/openai_augmented_dataset.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/openai_augmented_dataset.pickle -------------------------------------------------------------------------------- /beauty/palm_augmented_dataset.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/palm_augmented_dataset.pickle -------------------------------------------------------------------------------- /beauty/product_embeddings_openai.csv.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/product_embeddings_openai.csv.gz -------------------------------------------------------------------------------- /beauty/product_embeddings_palm.csv.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/product_embeddings_palm.csv.gz -------------------------------------------------------------------------------- /beauty/products_lookup.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/products_lookup.csv -------------------------------------------------------------------------------- /beauty/session_id_to_int.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/session_id_to_int.json -------------------------------------------------------------------------------- /beauty/sessions.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/sessions.csv -------------------------------------------------------------------------------- /beauty/split_sessions.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/beauty/split_sessions.ipynb -------------------------------------------------------------------------------- /figures/correct_recommendation_similarities.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/figures/correct_recommendation_similarities.png -------------------------------------------------------------------------------- /figures/recommendation_similarities.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/figures/recommendation_similarities.png -------------------------------------------------------------------------------- /main/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /main/abstract_model.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/abstract_model.py -------------------------------------------------------------------------------- /main/data/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /main/data/abstract_dataset.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/data/abstract_dataset.py -------------------------------------------------------------------------------- /main/data/mece_split.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/data/mece_split.py -------------------------------------------------------------------------------- /main/data/random_split.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/data/random_split.py -------------------------------------------------------------------------------- /main/data/session_dataset.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/data/session_dataset.py -------------------------------------------------------------------------------- /main/data/side_information.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/data/side_information.py -------------------------------------------------------------------------------- /main/data/temporal_split.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/data/temporal_split.py -------------------------------------------------------------------------------- /main/dim_reducer/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /main/dim_reducer/dim_reducer.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/dim_reducer/dim_reducer.py -------------------------------------------------------------------------------- /main/eval/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /main/eval/evaluation.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/eval/evaluation.py -------------------------------------------------------------------------------- /main/eval/metrics/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/eval/metrics/__init__.py -------------------------------------------------------------------------------- /main/eval/metrics/catalog_coverage.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/eval/metrics/catalog_coverage.py -------------------------------------------------------------------------------- /main/eval/metrics/hitrate.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/eval/metrics/hitrate.py -------------------------------------------------------------------------------- /main/eval/metrics/metric.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/eval/metrics/metric.py -------------------------------------------------------------------------------- /main/eval/metrics/mrr.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/eval/metrics/mrr.py -------------------------------------------------------------------------------- /main/eval/metrics/ndcg.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/eval/metrics/ndcg.py -------------------------------------------------------------------------------- /main/eval/metrics/novelty.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/eval/metrics/novelty.py -------------------------------------------------------------------------------- /main/eval/metrics/serendipity.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/eval/metrics/serendipity.py -------------------------------------------------------------------------------- /main/exceptions.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/exceptions.py -------------------------------------------------------------------------------- /main/grurec/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /main/grurec/grurec.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/grurec/grurec.py -------------------------------------------------------------------------------- /main/grurec/grurec_model.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/grurec/grurec_model.py -------------------------------------------------------------------------------- /main/grurec/grurec_with_embeddings.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/grurec/grurec_with_embeddings.py -------------------------------------------------------------------------------- /main/hybrids/embedding-ensemble.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/hybrids/embedding-ensemble.py -------------------------------------------------------------------------------- /main/hybrids/popularity-based-hybrid.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/hybrids/popularity-based-hybrid.py -------------------------------------------------------------------------------- /main/hybrids/properties.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/hybrids/properties.py -------------------------------------------------------------------------------- /main/hybrids/property-injected-embedding.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/hybrids/property-injected-embedding.py -------------------------------------------------------------------------------- /main/hybrids/utils.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/hybrids/utils.py -------------------------------------------------------------------------------- /main/llm_based/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /main/llm_based/embedding_utils/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /main/llm_based/embedding_utils/create_embeddings.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/embedding_utils/create_embeddings.ipynb -------------------------------------------------------------------------------- /main/llm_based/embedding_utils/key.txt: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /main/llm_based/embedding_utils/openai_utils.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/embedding_utils/openai_utils.py -------------------------------------------------------------------------------- /main/llm_based/embedding_utils/palm_utils.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/embedding_utils/palm_utils.py -------------------------------------------------------------------------------- /main/llm_based/gpt/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /main/llm_based/gpt/gpt_model.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/gpt/gpt_model.py -------------------------------------------------------------------------------- /main/llm_based/palm/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /main/llm_based/palm/palm_model.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/palm/palm_model.py -------------------------------------------------------------------------------- /main/llm_based/prompt_model/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/prompt_model/README.md -------------------------------------------------------------------------------- /main/llm_based/prompt_model/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /main/llm_based/prompt_model/classify/generate_finetune_prompts.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/prompt_model/classify/generate_finetune_prompts.ipynb -------------------------------------------------------------------------------- /main/llm_based/prompt_model/classify/predict_gpt.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/prompt_model/classify/predict_gpt.ipynb -------------------------------------------------------------------------------- /main/llm_based/prompt_model/classify/predict_palm.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/prompt_model/classify/predict_palm.ipynb -------------------------------------------------------------------------------- /main/llm_based/prompt_model/fine-tuning_scripts/finetune_gpt.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/prompt_model/fine-tuning_scripts/finetune_gpt.py -------------------------------------------------------------------------------- /main/llm_based/prompt_model/fine-tuning_scripts/finetune_palm.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/prompt_model/fine-tuning_scripts/finetune_palm.py -------------------------------------------------------------------------------- /main/llm_based/prompt_model/genitem/generate_finetune_prompts.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/prompt_model/genitem/generate_finetune_prompts.ipynb -------------------------------------------------------------------------------- /main/llm_based/prompt_model/genitem/predict_gpt.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/prompt_model/genitem/predict_gpt.ipynb -------------------------------------------------------------------------------- /main/llm_based/prompt_model/genitem/predict_palm.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/prompt_model/genitem/predict_palm.ipynb -------------------------------------------------------------------------------- /main/llm_based/prompt_model/genlist/generate_finetune_prompts.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/prompt_model/genlist/generate_finetune_prompts.ipynb -------------------------------------------------------------------------------- /main/llm_based/prompt_model/genlist/predict_gpt.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/prompt_model/genlist/predict_gpt.ipynb -------------------------------------------------------------------------------- /main/llm_based/prompt_model/genlist/predict_palm.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/prompt_model/genlist/predict_palm.ipynb -------------------------------------------------------------------------------- /main/llm_based/prompt_model/rank/generate_finetune_prompts.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/prompt_model/rank/generate_finetune_prompts.ipynb -------------------------------------------------------------------------------- /main/llm_based/prompt_model/rank/generate_test_prompts_llmseqprompt_rank.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/prompt_model/rank/generate_test_prompts_llmseqprompt_rank.ipynb -------------------------------------------------------------------------------- /main/llm_based/prompt_model/rank/predict_gpt.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/prompt_model/rank/predict_gpt.ipynb -------------------------------------------------------------------------------- /main/llm_based/prompt_model/rank/predict_palm.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/prompt_model/rank/predict_palm.ipynb -------------------------------------------------------------------------------- /main/llm_based/similarity_model/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /main/llm_based/similarity_model/llm_seq_sim.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/similarity_model/llm_seq_sim.py -------------------------------------------------------------------------------- /main/llm_based/similarity_model/session_embeddings.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/llm_based/similarity_model/session_embeddings.ipynb -------------------------------------------------------------------------------- /main/neural_model.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/neural_model.py -------------------------------------------------------------------------------- /main/popularity/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /main/popularity/session_popular.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/popularity/session_popular.py -------------------------------------------------------------------------------- /main/reranking/rerank_pairwise_similarity.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/reranking/rerank_pairwise_similarity.py -------------------------------------------------------------------------------- /main/reranking/reranker.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/reranking/reranker.py -------------------------------------------------------------------------------- /main/reranking/reranker_batch.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/reranking/reranker_batch.py -------------------------------------------------------------------------------- /main/sknn/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /main/sknn/sknn.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/sknn/sknn.py -------------------------------------------------------------------------------- /main/transformer/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /main/transformer/bert/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /main/transformer/bert/bert.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/transformer/bert/bert.py -------------------------------------------------------------------------------- /main/transformer/bert/bert_model.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/transformer/bert/bert_model.py -------------------------------------------------------------------------------- /main/transformer/bert/bert_with_embeddings.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/transformer/bert/bert_with_embeddings.py -------------------------------------------------------------------------------- /main/transformer/bert/custom_generators/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /main/transformer/bert/custom_generators/test_generator.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/transformer/bert/custom_generators/test_generator.py -------------------------------------------------------------------------------- /main/transformer/bert/custom_generators/train_generator.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/transformer/bert/custom_generators/train_generator.py -------------------------------------------------------------------------------- /main/transformer/custom_layers/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /main/transformer/custom_layers/embedding_layer.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/transformer/custom_layers/embedding_layer.py -------------------------------------------------------------------------------- /main/transformer/custom_layers/transformer_encoder_layer.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/transformer/custom_layers/transformer_encoder_layer.py -------------------------------------------------------------------------------- /main/transformer/sasrec/sasrec.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/transformer/sasrec/sasrec.py -------------------------------------------------------------------------------- /main/transformer/sasrec/sasrec_model.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/transformer/sasrec/sasrec_model.py -------------------------------------------------------------------------------- /main/transformer/sasrec/sasrec_with_embeddings.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/transformer/sasrec/sasrec_with_embeddings.py -------------------------------------------------------------------------------- /main/transformer/transformer.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/transformer/transformer.py -------------------------------------------------------------------------------- /main/transformer/transformer_model.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/transformer/transformer_model.py -------------------------------------------------------------------------------- /main/utils/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /main/utils/config_util.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/config_util.py -------------------------------------------------------------------------------- /main/utils/dim_reducer.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/dim_reducer.py -------------------------------------------------------------------------------- /main/utils/id_reducer.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/id_reducer.py -------------------------------------------------------------------------------- /main/utils/multiprocessing.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/multiprocessing.py -------------------------------------------------------------------------------- /main/utils/neural_utils/custom_activations/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/neural_utils/custom_activations/__init__.py -------------------------------------------------------------------------------- /main/utils/neural_utils/custom_activations/gelu.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/neural_utils/custom_activations/gelu.py -------------------------------------------------------------------------------- /main/utils/neural_utils/custom_callbacks/metric_callback.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/neural_utils/custom_callbacks/metric_callback.py -------------------------------------------------------------------------------- /main/utils/neural_utils/custom_generators/next_item_test_generator.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/neural_utils/custom_generators/next_item_test_generator.py -------------------------------------------------------------------------------- /main/utils/neural_utils/custom_generators/next_item_train_generator.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/neural_utils/custom_generators/next_item_train_generator.py -------------------------------------------------------------------------------- /main/utils/neural_utils/custom_layers/bias_layer.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/neural_utils/custom_layers/bias_layer.py -------------------------------------------------------------------------------- /main/utils/neural_utils/custom_layers/projection_head.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/neural_utils/custom_layers/projection_head.py -------------------------------------------------------------------------------- /main/utils/neural_utils/custom_losses/masked_sparse_categorical_crossentropy.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/neural_utils/custom_losses/masked_sparse_categorical_crossentropy.py -------------------------------------------------------------------------------- /main/utils/neural_utils/custom_preprocessors/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /main/utils/neural_utils/custom_preprocessors/cloze.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/neural_utils/custom_preprocessors/cloze.py -------------------------------------------------------------------------------- /main/utils/neural_utils/custom_preprocessors/data_description.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/neural_utils/custom_preprocessors/data_description.py -------------------------------------------------------------------------------- /main/utils/neural_utils/custom_preprocessors/tensor_factory.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/neural_utils/custom_preprocessors/tensor_factory.py -------------------------------------------------------------------------------- /main/utils/session_utils/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /main/utils/session_utils/decay_utils.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/session_utils/decay_utils.py -------------------------------------------------------------------------------- /main/utils/session_utils/session_embedding_utils.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/session_utils/session_embedding_utils.py -------------------------------------------------------------------------------- /main/utils/side_encoder.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/side_encoder.py -------------------------------------------------------------------------------- /main/utils/similarity.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/similarity.py -------------------------------------------------------------------------------- /main/utils/split_dict.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/split_dict.py -------------------------------------------------------------------------------- /main/utils/top_k_computer.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/top_k_computer.py -------------------------------------------------------------------------------- /main/utils/utils.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/main/utils/utils.py -------------------------------------------------------------------------------- /notebooks/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /notebooks/exploring_embeddings.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/notebooks/exploring_embeddings.ipynb -------------------------------------------------------------------------------- /notebooks/session_data_description.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/notebooks/session_data_description.ipynb -------------------------------------------------------------------------------- /notebooks/session_length_hitrate_beauty.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/notebooks/session_length_hitrate_beauty.ipynb -------------------------------------------------------------------------------- /notebooks/session_length_hitrate_dh.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/notebooks/session_length_hitrate_dh.ipynb -------------------------------------------------------------------------------- /online_material.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/online_material.md -------------------------------------------------------------------------------- /paths.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/paths.py -------------------------------------------------------------------------------- /poetry.lock: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/poetry.lock -------------------------------------------------------------------------------- /pyproject.toml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/pyproject.toml -------------------------------------------------------------------------------- /run_experiments.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/run_experiments.ipynb -------------------------------------------------------------------------------- /setup.cfg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/setup.cfg -------------------------------------------------------------------------------- /steam/.gitattributes: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/steam/.gitattributes -------------------------------------------------------------------------------- /steam/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/steam/README.md -------------------------------------------------------------------------------- /steam/attach_embeddings.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/steam/attach_embeddings.ipynb -------------------------------------------------------------------------------- /steam/create_sessions.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/steam/create_sessions.ipynb -------------------------------------------------------------------------------- /steam/dataset.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/steam/dataset.pickle -------------------------------------------------------------------------------- /steam/item_metadata.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/steam/item_metadata.csv -------------------------------------------------------------------------------- /steam/openai_augmented_dataset.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/steam/openai_augmented_dataset.pickle -------------------------------------------------------------------------------- /steam/palm_augmented_dataset.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/steam/palm_augmented_dataset.pickle -------------------------------------------------------------------------------- /steam/product_embeddings_openai.csv.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/steam/product_embeddings_openai.csv.gz -------------------------------------------------------------------------------- /steam/product_embeddings_palm.csv.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/steam/product_embeddings_palm.csv.gz -------------------------------------------------------------------------------- /steam/sessions.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/steam/sessions.csv -------------------------------------------------------------------------------- /steam/split_sessions.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dh-r/LLM-Sequential-Recommendation/HEAD/steam/split_sessions.ipynb --------------------------------------------------------------------------------