Customer scoring suite
Just specifying the key column names, Shimoku will create a whole Customer Scoring Suite in less than 48 hours.

shimoku.suite.customer_scoring_suite(
data=data,
customer='customer_id',
date='date',
business_type='transactional',
)
Where
business_type
could be transactional
for Retail-like businesses or subscription
for subscription businesses.For retail, you may want to add also the product column for the recommender system
shimoku.suite.customer_scoring_suite((
data=data,
customer='customer_id',
product='product_id',
date='date',
business_type='transactional',
)
The minimum dataset for Shimoku to make predictions must contain
date
column as timestampcustomer_id
column as the customer unique identifierproduct_id
as the product identifier for Retail-like businesses
Nevertheless the more data you add the more will learn the algorithm, in particular, we suggest to add as much data as possible, being the ideal case the Shopify Order object
The first time you have to update at least 12 months of data. Nevertheless, after you post the historic dataset you can count on updated predictions just posting the daily lambdas by specifying
how='append'
historic_dataframe = pd.read_csv('historic_orders.csv') # Orders from the last 12 months
shimoku.suite.customer_scoring_suite((
data=historic_dataframe,
customer='customer_id',
product='product_id',
date='date',
business_type='transactional',
)
yesterday_df = pd.read_csv('yesterday_orders.csv') # orders from yesterday
shimoku.suite.customer_scoring_suite(
data=yesterday_df,
customer='customer_id',
product='product_id',
date='date',
business_type='transactional',
# to tell Shimoku SDK that this is a piece of data
# to be concat to the historic one
how='append',
)
Including the Class instance call
api_key: str = getenv('API_TOKEN')
universe_id: str = getenv('UNIVERSE_ID')
business_id: str = getenv('BUSINESS_ID')
config = {
'access_token': api_key,
}
shimoku = shimoku.Client(
config=config,
universe_id=universe_id,
)
shimoku.plt.set_business(business_id=business_id)
shimoku.suite.customer_scoring_suite((
data=data,
customer='customer_id',
product='product_id',
date='date',
business_type='transactional',
)
Last modified 2mo ago