$$\rightleftharpoonup{xx}$$
$$\longleftharp{xx}$$,
$$\longrightharp{xx}$$,
Data collection
This study utilized the Loan Approval Prediction Dataset available on Kaggle. The dataset was extracted in February 2025 and consists of 4269 records aimed at evaluating loan data and forecasting loan approval outcomes. It includes 12 columns comprising detailed information on applicants' demographic profiles, such as employment status, dependents, self-employed, loan amount, loan term, CIBIL scores, financial background, and loan-specific attributes. The dataset was imported using the Pandas library and visually inspected using df.head () to understand its structure and quality.
Data pre-processing
During the data pre-processing phase, the first step involved removing the identifier column (loan_id) due to its lack of predictive value and potential to introduce noise into the model. The second step involved label encoding, where categorical variables such as education, self-employed, and loan_status were converted into numerical representations. This transformation was conducted using Label Encoder from the sklearn.preprocessing module. Specifically, education was encoded as 0 for Graduate and 1 for Not Graduate; self_employed as 0 for No and 1 for Yes, and loan_status, the target variable, as 0 for Not Approved and 1 for Approved. These conversions were necessary to ensure compatibility with machine learning models, which require numeric inputs, particularly for digital lending applications. The features were separated from the target variable using X=df.drop (["loan_status"], axis=1) and y=df ["loan_status]. This setup provided a comprehensive basis for examining the factors influencing loan approval decisions using historical loan records to train multiple ensemble machine learning models. These models were intended to improve overall accuracy and robustness by combining the predictive strengths of multiple classifiers.
The processed dataset was then split into training and testing subsets using the train_test_split function from sklearn.model_selection, with 80% of the data used for training and 20% reserved for testing. This ensured that the model was trained on a sufficiently large portion of the data while retaining a representative sample for performance evaluation. With the dataset cleansed, structured, and statistically explored, the foundation was laid for the implementation of a robust machine learning framework aimed at enhancing predictive accuracy in loan approval classification. Model development was conducted using four ensemble-based machine learning algorithms: Gradient Boosting Model, AdaBoost, Efficient Gradient Boosting Model, and Extra Trees Classifier. These were selected for their proven performance in classification tasks involving structured, tabular data. The Gradient Boosting Model Classifier, implemented from the Gradient Boosting Model library, was instantiated with default settings (iterations=1000, learning rate=0.1, depth=6, verbose=False). It was trained using. fit (x_train, y_train) and evaluated with .predict (X_test). Although the Gradient Boosting Model automatically handles categorical data encoding, this feature was not utilized as the data had already been label-encoded. The AdaBoost Classifier (Adaptive Boosting, which improves weak learners) was implemented using sklearn-ensemble. AdaBoost Classifier was configured with n_estimators=100 and learning_rate=1.0, using decision stumps as the default base estimator. It was trained and evaluated in a similar fashion, contributing robustness through iterative weighting of misclassified instances. The Efficient Gradient Boosting, implemented through the Efficient Gradient Boosting Model library (LGBMClassifier), was configured with n_estimators=100, learning_rate=0.1, and max_depth=-1 (unrestricted tree depth). This model, known for its speed and efficiency, particularly excels on large datasets with high-dimensional features using optimized gradient boosting decision trees.
Finally, the ExtraTrees Classifier from sklearn.ensemble was used with n_estimators=100 and criterion="gini" as the splitting strategy. Unlike Random Forest, Extra Trees introduces further randomness by selecting cut points at random, which helps to reduce model variance and improve generalization. The ensemble was conducted using scikit-learn's Stacking Classifier, which enhances generalization by aggregating predictions from the base learners. Each model was evaluated using standard classification metrics, including accuracy, precision, F1-score, error analysis, and the confusion matrix. These metrics were computed using functions from the sklearn.metrics module to ensure standardized performance comparison across all models.
The best-performing model (based on accuracy and F1-score) was saved for deployment using the Python library. dump(model, "best_model.pkl"), ensuring that the trained model could be reused without the need for retraining. To simulate a real-world application, a sample input array containing 11 features was created using NumPy and passed to the model .predict () function. For instance, the input vector [[0, 1, 1,4100000, 12200000, 8, 417, 2700000, 2200000, 8800000, 3300000]] returned a prediction of 1, indicating loan approval. All experimentation was conducted in a Python 3.10 environment using Google Notebook on Kaggle. Model development and evaluation were carried out using the scikit-learn (v1.3), Gradient Boosting Model, and Efficient Gradient Boosting Model libraries. All hyperparameters were documented explicitly, and defaults were clearly stated where applicable. The encoding procedures followed the approach described by Pedregosa and were implemented in scikit-learn46. This comprehensive and transparent methodology ensures that the experimental protocol is fully reproducible and adheres to rigorous academic standards in machine learning research.
The structure of the suggested methodology, encompassing the phase of data preparation feature section, model training and evaluation, are shown in Figure 1.
This research introduces a stacking ensemble learning framework that brings together the capabilities of four powerful classifiers: Gradient Boosting Model, AdaBoost, Efficient Gradient Boosting Model, and Extra Trees to predict loan approval decisions based on historical financial records. By combining both boosting and bagging strategies within stacked model architecture46. The approach effectively overcomes the individual shortcomings of these models, such as bias and variance, lending to enhanced prediction accuracy and model generalization. Each base learner contributes unique strengths Gradient Boosting Model is efficient with categorical variable, it is designed for handling high cordiality categorical features and internally performs target encoding using ordered boosting47. This avoids over fitting by ensuring that only past data is used in computing statistics. In the formula
,
each ht (x) represents a decision tree trained on residuals of the previous model, and nt denotes the step-specific learning contribution. AdaBoost or Adaptive Boosting, adjusts the weight of each instance during training and focuses on previously misclassified data points48. In the formula

αt reflects the performance of the t-th weak learner ht(x), placing more emphasis on previously misclassified samples. Efficient Gradient Boosting Model Incorporates gradient-based one-side sampling (GOSS) and exclusive feature bundling for faster performance. Efficient Gradient Boosting offers high speed and performance on large-scale data49.
![figure-protocol-3 Gradient boosting formula ΣF(t)=Σ[l(yi, Ft-1(xi)+ft(xi))+Ω(ft)]; equation, data modeling.](/files/ftp_upload/68832/68832eq3.jpg)
ft(xi) represents the new decision tree added to minimize the loss l(•) while Ω(ft) is a regularization term . In contrast boosting algorithms, Extra Trees reduces variance by adding randomness in decision tree splits50. It relies on bagging principles but injects extra randomness during node splitting into its prediction rule

Averages the outputs of M independently trained randomized trees. For each split, Extra trees selects random thresholds for features and chooses the best among them, thereby reducing variance and offering high diversity across trees, which improves generalization. These models are collectively integrated through a stacking classifier, which learns to optimally combine their outputs to decide whether a loan should be approved. The framework was evaluated with common classification metrics and tested with live input samples, demonstrating its practical relevance in digital lending environments51. These models are combined collectively using a stacking classifier, which learns to blend their outputs ideally to determine loan acceptance results. The model's performance was assessed using important classification measures such as accuracy, precision, recall, F1-score, and AUC-ROC, as well as a confusion matrix, to determine its capacity to reduce both Type I and Type II mistakes. To maintain class balance, a stratified 80:20 train-test split was utilized, with 5-fold cross-validation ensuring robustness and reducing sample variability. Furthermore, the model was evaluated on realistic loan applicant profiles that included information such as credit history, income, employment status, and loan amount, yielding binary judgments and probability ratings. This two-phase test demonstrates the model's efficacy, fairness, and practicality in real-time digital lending contexts. The novelty of this work lies in the hybrid ensemble design tailored for credit scoring, making it a robust, interpretable, and reproducible model for modern financial platforms52 .