Downloads · 30 days
0
rameshb79/mortgage-rate-predictor
mortgage-rate-predictor is a machine learning model from rameshb79. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
This repository contains three pre-trained machine learning models for predicting and classifying mortgage rate movements.
Downloads · 30 days
0
Access
Public
Updated Apr 8, 2026
Repo size
4 MB
Likes
0
Public
Click a slice to open those files.
.pkl4 MB · 99%
From the Hugging Face model README
This repository contains three pre-trained machine learning models for predicting and classifying mortgage rate movements.
File: prophet_model.pkl (81 KB)
Highly accurate time-series forecasting model for predicting mortgage rates 4+ weeks in advance.
Quick Start:
from predictor import MortgageRatePredictor
predictor = MortgageRatePredictor('prophet_model.pkl')
forecast = predictor.predict(periods=30)
print(forecast['dates']) # 30 upcoming dates
print(forecast['predictions']) # Predicted rates
print(forecast['bounds']) # Confidence intervals
File: classifier_model.pkl (5 KB)
Random Forest classifier for binary UP/DOWN rate direction prediction.
Quick Start:
import joblib
import numpy as np
classifier = joblib.load('classifier_model.pkl')
features = np.array([3.5, 3.4, 3.6, 3.7, 3.6, -0.1, -0.5, 3.55, 0.08])
prediction = classifier.predict(features.reshape(1, -1))
probs = classifier.predict_proba(features.reshape(1, -1))
print(f"Direction: {'UP' if prediction[0] == 1 else 'DOWN'}")
print(f"Confidence: {probs[0][prediction[0]]:.2%}")
File: arima_model.pkl (10 KB)
Classical statistical ARIMA(1,1,2) model for backup forecasting.
Quick Start:
import joblib
arima_model = joblib.load('arima_model.pkl')
forecast_result = arima_model.get_forecast(steps=4)
forecast_df = forecast_result.conf_int()
print(forecast_df)
| Feature | Prophet | Classifier | ARIMA |
|---|---|---|---|
| Accuracy | 0.0397% MAPE ⭐ | 100% accuracy | 0.0905% MAPE |
| Output | Exact values | UP/DOWN | Exact values |
| Speed | <1 sec | <100ms | <100ms |
| Confidence | Yes | Yes | Yes |
| Interpretable | Medium | High | High |
| File Size | 81 KB | 5 KB | 10 KB |
| Best For | Primary | Binary alerts | Fallback |
# Install dependencies
pip install pandas numpy scikit-learn statsmodels joblib
# Load models directly
import joblib
prophet = joblib.load('prophet_model.pkl')
classifier = joblib.load('classifier_model.pkl')
arima = joblib.load('arima_model.pkl')
# Copy predictor.py from main project
cp ../src/predictor.py .
# Use the clean API
from predictor import MortgageRatePredictor
predictor = MortgageRatePredictor('prophet_model.pkl')
forecast = predictor.predict(periods=30)
See INTEGRATION_GUIDE.md for complete instructions on integrating with MortgageRateNotifier.
MIT License - Free for commercial and personal use
These models are provided as-is for educational and research purposes.
⚠️ Important Warnings:
Use at your own risk. Validate thoroughly before deployment to critical systems.
Last Updated: April 8, 2026