Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/bmd1905/Customer-Purchase-Prediction-ML-System
/ functions
Functions
136 in github.com/bmd1905/Customer-Purchase-Prediction-ML-System
⨍
Functions
136
◇
Types & classes
25
↳
Endpoints
2
↓ 5 callers
Method
add_processing_time
(self, processing_time: float)
src/streaming/utils/metrics.py:27
↓ 4 callers
Method
increment_failure
(self)
src/streaming/utils/metrics.py:22
↓ 3 callers
Function
get_checkpoint_key
Generate checkpoint file key
src/orchestration/dags/data_pipeline/bronze/ingest_raw_data.py:31
↓ 3 callers
Function
load_sql_template
Load SQL template from file
src/orchestration/include/common/scripts/sql_utils.py:6
↓ 3 callers
Method
log_metrics
Log pipeline metrics and send alerts
src/orchestration/include/common/scripts/monitoring.py:10
↓ 2 callers
Method
_check_and_log
(self)
src/streaming/utils/metrics.py:37
↓ 2 callers
Function
batch_insert_data
Insert data in batches
src/orchestration/include/common/scripts/db_utils.py:40
↓ 2 callers
Function
build_sink
Build a Kafka sink. :param topic: The topic to write to. :param bootstrap_servers: The bootstrap servers. :return: The Kafka sink.
src/streaming/connectors/sinks/kafka_sink.py:8
↓ 2 callers
Function
build_source
Build a Kafka source. :param bootstrap_servers: The bootstrap servers. :param topics: The topics to read from. :param group_id: The
src/streaming/connectors/sources/kafka_source.py:8
↓ 2 callers
Function
check_minio_connection
Check if MinIO connection is working
src/orchestration/dags/data_pipeline/bronze/ingest_raw_data.py:20
↓ 2 callers
Function
chunk_list
Yield successive chunks of given size from data_list.
src/orchestration/dags/data_pipeline/bronze/ingest_raw_data.py:108
↓ 2 callers
Function
create_schema_and_table
Create table and indexes based on schema definition
src/orchestration/include/common/scripts/db_utils.py:13
↓ 2 callers
Function
extract_payload
Extract payload from nested record structure
src/orchestration/dags/data_pipeline/bronze/validate_raw_data.py:18
↓ 2 callers
Function
generate_record_hash
Generate a unique hash for a record based on business keys
src/orchestration/dags/data_pipeline/bronze/validate_raw_data.py:58
↓ 2 callers
Function
get_available_jobs
Return a dictionary of available jobs with lazy loading
src/streaming/main.py:12
↓ 2 callers
Function
get_field_name
Get field name from field definition, handling both schema formats.
src/streaming/jobs/schema_validation_job.py:86
↓ 2 callers
Function
ingest_raw_data
(config: DataPipelineConfig, valid: bool = True)
src/orchestration/dags/data_pipeline/bronze/ingest_raw_data.py:119
↓ 2 callers
Method
predict
(self, requests: List[PredictionRequest])
src/serving/main.py:102
↓ 2 callers
Function
validate_raw_data
Validate raw data using both Great Expectations and custom validation
src/orchestration/dags/data_pipeline/bronze/validate_raw_data.py:117
↓ 1 callers
Method
_connect
(self)
src/cdc/postgresql_client.py:20
↓ 1 callers
Method
_create_engine
Create SQLAlchemy engine with proper configuration.
src/feature_stores/offline_write_batch.py:36
↓ 1 callers
Function
_is_valid_timestamp
Check if a string is a valid timestamp.
src/streaming/jobs/schema_validation_job.py:67
↓ 1 callers
Method
_load_model
(self)
src/serving/prediction_service.py:24
↓ 1 callers
Method
_setup_telemetry
(self)
src/serving/main.py:64
↓ 1 callers
Function
add_derived_columns
Add derived columns based on existing data
src/orchestration/dags/data_pipeline/silver/transform_data.py:68
↓ 1 callers
Function
bronze_layer
Task group for the bronze layer of the data pipeline.
src/orchestration/dags/data_pipeline.py:44
↓ 1 callers
Function
bucketQuantile
bucketQuantile calculates the quantile 'q' based on the given buckets. The buckets will be sorted by upperBound by this function (i.e. no sorting need
src/observability/signoz/clickhouse-setup/user_scripts/histogramQuantile.go:57
↓ 1 callers
Function
calculate_session_metrics
Calculate metrics per user session
src/orchestration/dags/data_pipeline/silver/transform_data.py:84
↓ 1 callers
Function
check_connector_status
(connector_name)
src/streaming/connectors/deploy_s3_connector.py:144
↓ 1 callers
Function
check_duplicates
Remove duplicate records based on record_hash
src/orchestration/dags/data_pipeline/silver/transform_data.py:114
↓ 1 callers
Function
check_s3_bucket
()
src/streaming/connectors/check_s3_bucket.py:10
↓ 1 callers
Method
check_topic_exists
Check if a Kafka topic exists.
src/streaming/jobs/schema_validation_job.py:260
↓ 1 callers
Function
coalesceBuckets
coalesceBuckets merges buckets with the same upper bound. The input buckets must be sorted.
src/observability/signoz/clickhouse-setup/user_scripts/histogramQuantile.go:107
↓ 1 callers
Function
create_analytical_views
Create useful views for analysis
src/orchestration/dags/data_pipeline/gold/load_to_dwh.py:133
↓ 1 callers
Function
create_dim_category
Create category dimension table
src/orchestration/dags/data_pipeline/gold/load_to_dwh.py:37
↓ 1 callers
Function
create_dim_date
Create date dimension table
src/orchestration/dags/data_pipeline/gold/load_to_dwh.py:47
↓ 1 callers
Function
create_dim_product
Create product dimension table
src/orchestration/dags/data_pipeline/gold/load_to_dwh.py:28
↓ 1 callers
Function
create_dim_user
Create user dimension table
src/orchestration/dags/data_pipeline/gold/load_to_dwh.py:20
↓ 1 callers
Function
create_fact_events
Create fact table with foreign keys to dimensions
src/orchestration/dags/data_pipeline/gold/load_to_dwh.py:54
↓ 1 callers
Method
create_pipeline
Create and return the job pipeline
src/streaming/jobs/base.py:10
↓ 1 callers
Function
create_streams
(servers, avro_schemas_path, schema_registry_client)
src/producer/produce.py:65
↓ 1 callers
Method
create_table_from_features
Create a table with the proper schema for feature storage.
src/feature_stores/offline_write_batch.py:84
↓ 1 callers
Method
create_tables
(self)
src/cdc/postgresql_client.py:26
↓ 1 callers
Function
create_topic
(admin, topic_name)
src/producer/produce.py:53
↓ 1 callers
Function
data_pipeline
### Data Pipeline DAG This DAG processes data through three layers: * Bronze: Raw data ingestion and validation * Silver: Data trans
src/orchestration/dags/data_pipeline.py:175
↓ 1 callers
Function
delete_connector
(connector_name)
src/streaming/connectors/deploy_s3_connector.py:155
↓ 1 callers
Function
deploy_all_connectors
Deploy all configured connectors
src/streaming/connectors/deploy_s3_connector.py:122
↓ 1 callers
Function
deploy_connector
Deploy a specific connector type
src/streaming/connectors/deploy_s3_connector.py:68
↓ 1 callers
Method
drop_tables
(self)
src/cdc/postgresql_client.py:29
↓ 1 callers
Function
enrich_record
Add metadata to a record
src/orchestration/dags/data_pipeline/bronze/validate_raw_data.py:70
↓ 1 callers
Function
ensureMonotonic
The assumption that bucket counts increase monotonically with increasing upperBound may be violated during: * Recording rule evaluation of histogram_
src/observability/signoz/clickhouse-setup/user_scripts/histogramQuantile.go:156
↓ 1 callers
Function
ensure_bucket_exists
Create MinIO bucket if it doesn't exist
src/streaming/connectors/deploy_s3_connector.py:47
↓ 1 callers
Function
flatten_record
Flatten nested record structure
src/orchestration/dags/data_pipeline/bronze/validate_raw_data.py:95
↓ 1 callers
Function
format_record
(row)
src/cdc/insert_data.py:17
↓ 1 callers
Method
from_airflow_variables
Load configuration from Airflow Variables
src/orchestration/include/config/data_pipeline_config.py:24
↓ 1 callers
Function
get_all_keys_paginated
Use the S3 paginator to get all keys without loading them all at once.
src/orchestration/dags/data_pipeline/bronze/ingest_raw_data.py:93
↓ 1 callers
Function
get_job_class
Get the job class, loading it only when requested
src/streaming/main.py:25
↓ 1 callers
Function
get_minio_client
Create and return a MinIO client
src/streaming/connectors/deploy_s3_connector.py:35
↓ 1 callers
Method
get_session
(self)
src/cdc/postgresql_client.py:32
↓ 1 callers
Function
gold_layer
Task group for the gold layer of the data pipeline.
src/orchestration/dags/data_pipeline.py:115
↓ 1 callers
Method
increment_success
(self)
src/streaming/utils/metrics.py:17
↓ 1 callers
Function
initialize_feature_tables
Initialize feature tables in PostgreSQL if they don't exist.
src/feature_stores/ingest_stream.py:145
↓ 1 callers
Function
load_checkpoint
Load processed keys from checkpoint file
src/orchestration/dags/data_pipeline/bronze/ingest_raw_data.py:36
↓ 1 callers
Function
load_dimensions_and_facts
Load dimensional model into Data Warehouse
src/orchestration/dags/data_pipeline/gold/load_to_dwh.py:81
↓ 1 callers
Function
load_latest_model_and_mappings
Load the latest model version and its category mappings
notebook/inference.py:14
↓ 1 callers
Function
load_sample_data
Load and prepare sample data from parquet file
src/cdc/insert_data.py:39
↓ 1 callers
Function
load_training_data
Load training data from DWH :param row_limit: Number of rows to load :return: Dictionary with training data
src/orchestration/dags/training_pipeline/data_loader.py:19
↓ 1 callers
Function
main
(args)
src/producer/generate_schemas.py:10
↓ 1 callers
Function
main
()
src/cdc/insert_data.py:57
↓ 1 callers
Function
main
()
src/cdc/create_table.py:10
↓ 1 callers
Function
main
()
src/streaming/main.py:33
↓ 1 callers
Function
patch_logging_proxy
Patch logging proxy objects to handle encoding attribute
src/orchestration/include/utils/ray_setup.py:7
↓ 1 callers
Function
prepare_for_serialization
Convert DataFrame to serializable format
src/orchestration/dags/data_pipeline/silver/transform_data.py:123
↓ 1 callers
Function
readLines
End of copied code.
src/observability/signoz/clickhouse-setup/user_scripts/histogramQuantile.go:170
↓ 1 callers
Function
read_sql_file
Read SQL query from file.
src/feature_stores/data_sources.py:11
↓ 1 callers
Function
save_checkpoint
Save processed keys to checkpoint file
src/orchestration/dags/data_pipeline/bronze/ingest_raw_data.py:49
↓ 1 callers
Function
save_results
Save training results and metrics
src/orchestration/dags/training_pipeline/results_saver.py:9
↓ 1 callers
Function
silver_layer
Task group for the silver layer of the data pipeline.
src/orchestration/dags/data_pipeline.py:99
↓ 1 callers
Function
substitute_env_vars
Replace environment variables in the config
src/streaming/connectors/deploy_s3_connector.py:132
↓ 1 callers
Function
teardown_stream
(topic_name, servers=["localhost:9092"])
src/producer/produce.py:180
↓ 1 callers
Function
train_final_model
Train final model with best parameters
src/orchestration/dags/training_pipeline/model_trainer.py:6
↓ 1 callers
Function
training_pipeline
### ML Training Pipeline with Hyperparameter Tuning This DAG handles the end-to-end training process: 1. Load training data 2. Tune h
src/orchestration/dags/training_pipeline.py:24
↓ 1 callers
Function
transform_data
Transform the validated data
src/orchestration/dags/data_pipeline/silver/transform_data.py:137
↓ 1 callers
Function
transform_timestamps
Convert event_time to datetime and add derived time columns
src/orchestration/dags/data_pipeline/silver/transform_data.py:38
↓ 1 callers
Function
tune_hyperparameters
Tune XGBoost hyperparameters using Ray Tune
src/orchestration/dags/training_pipeline/hyperparameter_tuning.py:6
↓ 1 callers
Function
validate_field_type
Validate a field's type against its schema definition.
src/streaming/jobs/schema_validation_job.py:22
↓ 1 callers
Function
validate_field_value
Validate a field's value constraints.
src/streaming/jobs/schema_validation_job.py:91
↓ 1 callers
Function
validate_record
Validate a single record against business rules
src/orchestration/dags/data_pipeline/bronze/validate_raw_data.py:28
↓ 1 callers
Method
write_batch
Write a batch of data to PostgreSQL table.
src/feature_stores/offline_write_batch.py:44
Method
Len
()
src/observability/signoz/clickhouse-setup/user_scripts/histogramQuantile.go:27
Method
Less
(i, j int)
src/observability/signoz/clickhouse-setup/user_scripts/histogramQuantile.go:29
Method
Swap
(i, j int)
src/observability/signoz/clickhouse-setup/user_scripts/histogramQuantile.go:28
Method
__call__
Get online features for prediction
src/serving/online_feature_service.py:17
Method
__call__
(self, features: List[Dict])
src/serving/prediction_service.py:58
Method
__init__
(self, database, user, password, host="0.0.0.0", port="5434")
src/cdc/postgresql_client.py:10
Method
__init__
(self, name: str = "default")
src/streaming/utils/metrics.py:8
Method
__init__
(self)
src/streaming/jobs/alert_invalid_events_job.py:14
Method
__init__
(self)
src/streaming/jobs/schema_validation_job.py:231
Method
__init__
Initialize PostgreSQL connection parameters.
src/feature_stores/offline_write_batch.py:13
Method
__init__
(self, feature_retrieval_url: str)
src/serving/online_feature_service.py:13
next →
1–100 of 136, ranked by callers