Ankur Malik 2cf9a2e5f9
All checks were successful
Build and Push Docker Image / test (push) Successful in 1m1s
Build and Push Docker Image / build_and_push (push) Successful in 17s
Update Rules block processing and schemas
2025-11-23 23:39:01 -05:00

36 lines
1.0 KiB
Python

import logging
from rules_processing import processing
# Configure logging
logging.basicConfig(
level=logging.INFO,
format="%(asctime)s [%(levelname)s] %(name)s - %(message)s",
)
logger = logging.getLogger(__name__)
def __main__(
hd_score_m1: float,
hd_score_g1: float,
cluster_size_users_v2: int,
target_connected_30_sum: float,
email_cnt: int,
rejected_app_count: float,
app_dt_day_cnt: int,
hd_score_iso_m2: float
) -> dict:
# Create a dictionary instead of using pandas DataFrame
data = {
"hd_score_m1": hd_score_m1,
"hd_score_g1": hd_score_g1,
"cluster_size_users_v2": cluster_size_users_v2,
"target_connected_30_sum": target_connected_30_sum,
"email_cnt": email_cnt,
"rejected_app_count": rejected_app_count,
"app_dt_day_cnt": app_dt_day_cnt,
"hd_score_iso_m2": hd_score_iso_m2,
}
final = processing(data)
logger.info(f"scores of application: {final}")
return final