How prajwalgn-35/phishguard-ai works
PhishGuard AI is a URL phishing classifier: a user submits a URL in the Streamlit app, which extracts six features, builds the model input, loads the Random Forest, and displays a Safe or Phishing result and the feature values. The README also documents an offline workflow from labeled data through feature engineering, model training, and evaluation of Decision Tree and Random Forest models. Those offline stages are documented but their implementation source is not present in the supplied excerpts, so directory paths identify the relevant areas. Relationships for those stages rely on the README; runtime calls are supported by app.py and feature_extraction.py.
Main entry points: app.py Streamlit app · feature_extraction.py Feature extraction · models Model training · random_forest.pkl Random Forest model
Components 11
Prediction interface
- Streamlit app
app.py - Displayed result
app.py
URL features
- Feature extraction
feature_extraction.py
Training data
- Labeled URL data
data/phishing_site_urls.csv - Dataset preparation
data
Training and evaluation
- Train/test split
models - Model training
models - Model evaluation
models/MODEL_REPORT.md
Model artifacts
- Decision Tree model
models/decision_tree.pkl - Random Forest model
models/random_forest.pkl
Other components
- URL user
Connections 13
- URL user → Streamlit app: submits URL
README.md - Streamlit app → Feature extraction: extracts features
app.py - Feature extraction → Streamlit app: returns features
app.py - Streamlit app → Random Forest model: loads and predicts
app.py - Streamlit app → Displayed result: displays prediction
app.py - Labeled URL data → Dataset preparation: prepares data
README.md - Dataset preparation → Feature extraction: engineers features
README.md - Feature extraction → Train/test split: supplies features
README.md - Train/test split → Model training: provides partitions
README.md - Model training → Decision Tree model: trains
README.md - Model training → Random Forest model: trains
README.md - Decision Tree model → Model evaluation: evaluated in
README.md - Random Forest model → Model evaluation: evaluated in
README.md