Recommender-system experiments and checkpoint pipelines for Compresso
Project description
Compresso Recsys
compresso-recsys is the recommender-system companion package for
Compresso. It provides dataset
loaders, checkpoint builders, checkpoint read/write helpers, and retrieval
metrics for sparse representation learning experiments.
The package distribution name is compresso-recsys; the Python import is:
import compresso_recsys as cr
Install
Install from PyPI:
pip install compresso-recsys
Install optional dataset export support:
pip install "compresso-recsys[datasets]"
For local development:
pip install -e ../compresso
pip install -e ".[dev,datasets]"
Quickstart
Build a MovieLens 1M checkpoint from Python:
import compresso_recsys as cr
checkpoint_path = cr.build_recsys_checkpoint(
dataset="ml1m",
checkpoint_path="artifacts/ml1m/exp001.zip",
annotation_source="genres",
)
with cr.read_checkpoint(checkpoint_path) as root:
split = cr.load_recsys_split(root)
print(split["x_train"].shape)
Build the same kind of checkpoint from the command line:
compresso-recsys-build-checkpoint \
--dataset ml1m \
--checkpoint_path artifacts/ml1m/exp001.zip \
--annotation_source genres
Amazon Reviews 2023 checkpoints can use item metadata for cold-item retrieval experiments:
compresso-recsys-build-checkpoint \
--dataset amazon2023 \
--amazon_category Toys_and_Games \
--checkpoint_path artifacts/amazon_toys/temporal_exp001.zip \
--split_mode temporal \
--metadata_text_fields title,features,description,categories \
--min_entity_text_words 30 \
--annotation_source none
What Is Included
- Dataset utilities for GoodBooks, MovieLens 1M, MovieLens 20M, and Amazon Reviews 2023.
- ZIP checkpoint format for source/target splits, embeddings, sparse embeddings, metrics, and Compresso cluster-graph stages.
- Retrieval metrics for Recall and nDCG at common cutoffs including 20, 50, and 100.
- A checkpoint-building console command:
compresso-recsys-build-checkpoint.
Documentation
Release documentation is available at:
https://zombak79.github.io/compresso-recsys/
The full CLI parameter table, checkpoint split schema, and supported Amazon Reviews 2023 categories are maintained in the Checkpoint CLI Reference.
Build the docs locally:
pip install -e ".[docs]"
sphinx-build -b html docs/source docs/build/html
License
Apache License 2.0. See LICENSE.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file compresso_recsys-0.1.0.tar.gz.
File metadata
- Download URL: compresso_recsys-0.1.0.tar.gz
- Upload date:
- Size: 35.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cd450bce42ba2ad6d8bcf15c073f66ed6f8e33c836654a66eb1e9c3dfe2dcd45
|
|
| MD5 |
d42cba26c221d679269d425a15b26478
|
|
| BLAKE2b-256 |
8bc572a4c30e75c330053c0faecaa0b95e3d1d57cdd23946422fbb737c02aebf
|
Provenance
The following attestation bundles were made for compresso_recsys-0.1.0.tar.gz:
Publisher:
publish.yml on zombak79/compresso-recsys
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
compresso_recsys-0.1.0.tar.gz -
Subject digest:
cd450bce42ba2ad6d8bcf15c073f66ed6f8e33c836654a66eb1e9c3dfe2dcd45 - Sigstore transparency entry: 2130196867
- Sigstore integration time:
-
Permalink:
zombak79/compresso-recsys@2b2d12cb19b54847dc65fd5f72b69005c51b3dd5 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/zombak79
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@2b2d12cb19b54847dc65fd5f72b69005c51b3dd5 -
Trigger Event:
push
-
Statement type:
File details
Details for the file compresso_recsys-0.1.0-py3-none-any.whl.
File metadata
- Download URL: compresso_recsys-0.1.0-py3-none-any.whl
- Upload date:
- Size: 36.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5babf18627d7179b63d34d7afa50e5dd8962a0d70dc01b46d5852aff5392e088
|
|
| MD5 |
2f170a06d6012c5844622a61c1cb6538
|
|
| BLAKE2b-256 |
b9583db55d94e9c8a3f89bded6d6bb5ac39bfe437042deb6e6028d3863fa40b6
|
Provenance
The following attestation bundles were made for compresso_recsys-0.1.0-py3-none-any.whl:
Publisher:
publish.yml on zombak79/compresso-recsys
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
compresso_recsys-0.1.0-py3-none-any.whl -
Subject digest:
5babf18627d7179b63d34d7afa50e5dd8962a0d70dc01b46d5852aff5392e088 - Sigstore transparency entry: 2130197005
- Sigstore integration time:
-
Permalink:
zombak79/compresso-recsys@2b2d12cb19b54847dc65fd5f72b69005c51b3dd5 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/zombak79
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@2b2d12cb19b54847dc65fd5f72b69005c51b3dd5 -
Trigger Event:
push
-
Statement type: