Install & Compatibility
Where this runs
tested against v0.1.90 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
py 3.9
✕ build_error
✕ build_error
20MB installed
● package 20MB
Code
Verified usage
Verified import paths — ran on the pinned version, not inferred.
rusket
✓ import rusket
✗ import rusket
This example demonstrates how to use `MarketBasketAnalyzer` to find association rules from a pandas DataFrame of transactional data. It initializes the analyzer, fits it to the data using specified transaction and item columns, and then retrieves the generated rules.
import pandas as pd
from rusket import MarketBasketAnalyzer
# Sample transactional data for Market Basket Analysis
data = {
'transaction_id': [1, 1, 1, 2, 2, 3, 3, 4, 4, 4, 5, 5, 5, 6, 6, 6],
'item_id': ['Apple', 'Banana', 'Orange', 'Apple', 'Grape', 'Banana', 'Orange', 'Apple', 'Banana', 'Grape', 'Milk', 'Bread', 'Eggs', 'Milk', 'Cheese', 'Butter']
}
df = pd.DataFrame(data)
# Initialize and fit the Market Basket Analyzer
# Lower min_support/min_confidence for small sample data to ensure rules are found
mba = MarketBasketAnalyzer(min_support=0.01, min_confidence=0.01)
mba.fit(df, transaction_col='transaction_id', item_col='item_id')
# Get association rules
rules = mba.get_rules()
print("Generated Association Rules (first 5):")
if not rules.empty:
print(rules.head())
else:
print("No rules found. Try adjusting min_support or min_confidence.")
Debug
Known issues
breakingAs Rusket is currently in early development (version 0.1.x), its API is subject to change without strict backward compatibility guarantees. Expect potential breaking changes between minor versions (e.g., 0.1.x to 0.2.x) until a stable 1.0 release.fixAlways pin to specific minor versions (`rusket==0.1.90`) in production environments and review release notes carefully when upgrading.
affects: All versions < 1.0.0
gotchaRusket requires input data as a pandas DataFrame with explicitly named columns for transaction/user and item IDs. Incorrect column names or data types will lead to errors.fixEnsure your DataFrame columns match the `transaction_col`/`user_col` and `item_col` arguments provided to the `fit` method. For best performance, ensure data types are optimized (e.g., integers for IDs).
affects: All versions
gotchaWhile Rusket provides Pythonic interfaces, its core logic is implemented in Rust. If you encounter unexpected performance issues or unhandled exceptions that aren't typical Python errors, it might be related to the underlying Rust implementation. Error messages might sometimes be less verbose than pure Python errors.fixConsult the official GitHub repository for common issues or open a new issue with a minimal reproducible example if you suspect a Rust-level problem. Ensure your system meets the basic requirements for Rust binaries (e.g., up-to-date glibc on Linux).
affects: All versions
Upgrade
Version history
0.1.90latest on PyPI · released Mar 12, 2026
Audit
Dependencies
No dependency data recorded yet.