Skip to content

ysh-1998/CSRec

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CSRec

This is the official implementation for Common Sense Enhanced Knowledge-based Recommendation with Large Language Model

CSRec

Requirements

python==3.7.12
recbole==1.0.1
torch==1.13.1
cudatoolkit==11.3.1

Getting Started

  1. Clone the repository and install requirements
git clone https://github.com/ysh-1998/CSRec.git
  1. Download data from Google Drive and put it in the dataset folder.
  2. Run model on the build-in dataset
  • CSRec-based models
python run_csrec.py --gpu_id=0 --model="CKE" --cs_kg_name="coms" --dataset="Electronics" --temperature=0.01
python run_csrec.py --gpu_id=0 --model="CFKG" --cs_kg_name="coms" --dataset="Electronics" --temperature=0.1
python run_csrec.py --gpu_id=0 --model="CKE" --cs_kg_name="coms" --dataset="Office" --temperature=0.1
python run_csrec.py --gpu_id=0 --model="CFKG" --cs_kg_name="coms" --dataset="Office" --temperature=0.3 --learning_rate=0.005
  • Knowledge-based baselines
python run_base.py --gpu_id=0 --model="CKE" --kg_name="merge" --dataset="Electronics"
python run_base.py --gpu_id=0 --model="CKE" --kg_name="merge" --dataset="Office"
  • CF-based baselines
python run_base.py --gpu_id=0 --model="BPR" --dataset="Electronics"
python run_base.py --gpu_id=0 --model="BPR" --dataset="Office"

About

The official implementation for Common Sense Enhanced Knowledge-based Recommendation with Large Language Model

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages