AventIQ-AI / SMS-Spam-Detection-Model

huggingface.co
Total runs: 10
24-hour runs: 0
7-day runs: -1
30-day runs: -1
Model's Last Updated: May 23 2025

Introduction of SMS-Spam-Detection-Model

Model Details of SMS-Spam-Detection-Model

🧠 SMSDetection-DistilBERT-SMS

A DistilBERT-based binary classifier fine-tuned on the SMS Spam Collection dataset. It classifies messages as either spam or ham (not spam). This model is suitable for real-world applications like mobile SMS spam filters, automated customer message triage, and telecom fraud detection.


✨ Model Highlights

  • 📌 Based on distilbert-base-uncased
  • 🔍 Fine-tuned on the SMS Spam Collection dataset
  • ⚡ Supports binary classification: Spam vs Not Spam
  • 💾 Lightweight and optimized for both CPU and GPU environments

🧠 Intended Uses

  • ✅ Mobile SMS spam filtering
  • ✅ Telecom customer service automation
  • ✅ Fraudulent message detection
  • ✅ User inbox categorization
  • ✅ Regulatory compliance monitoring

  • 🚫 Limitations

  • ❌ Trained on English SMS messages only

  • ❌ May underperform on emails, social media texts, or non-English content

  • ❌ Not designed for multilingual datasets

  • ❌ Slight performance dip expected for long messages (>128 tokens)


🏋️‍♂️ Training Details

Field Value
Base Model distilbert-base-uncased
Dataset SMS Spam Collection (UCI)
Framework PyTorch with 🤗 Transformers
Epochs 3
Batch Size 16
Max Length 128 tokens
Optimizer AdamW
Loss CrossEntropyLoss (token-level)
Device Trained on CUDA-enabled GPU

📊 Evaluation Metrics

Metric Score
Accuracy 0.99
F1-Score 0.96
Precision 0.98
Recall 0.93


🚀 Usage

from transformers import BertTokenizerFast, BertForTokenClassification
from transformers import pipeline
import torch

model_name = "AventIQ-AI/SMS-Spam-Detection-Model"
tokenizer = BertTokenizerFast.from_pretrained(model_name)
model = BertForTokenClassification.from_pretrained(model_name)
model.eval()


# Inference
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
model.to(device)

def predict_sms(text):
    inputs = tokenizer(text, return_tensors="pt", padding=True, truncation=True, max_length=128)
    inputs = {k: v.to(device) for k, v in inputs.items()}
    with torch.no_grad():
        outputs = model(**inputs)
        logits = outputs.logits
        predicted = torch.argmax(logits, dim=1).item()
    return "spam" if predicted == 1 else "ham"

# Test example
print(predict_sms("You've won $1,000,000! Call now to claim your prize!"))

  • 🧩 Quantization
  • Post-training static quantization applied using PyTorch to reduce model size and accelerate inference on edge devices.

🗂 Repository Structure

.
├── model/               # Quantized model files
├── tokenizer_config/    # Tokenizer and vocab files
├── model.safensors/     # Fine-tuned model in safetensors format
├── README.md            # Model card

🤝 Contributing

Open to improvements and feedback! Feel free to submit a pull request or open an issue if you find any bugs or want to enhance the model.

Runs of AventIQ-AI SMS-Spam-Detection-Model on huggingface.co

10
Total runs
0
24-hour runs
-1
3-day runs
-1
7-day runs
-1
30-day runs

More Information About SMS-Spam-Detection-Model huggingface.co Model

SMS-Spam-Detection-Model huggingface.co

SMS-Spam-Detection-Model huggingface.co is an AI model on huggingface.co that provides SMS-Spam-Detection-Model's model effect (), which can be used instantly with this AventIQ-AI SMS-Spam-Detection-Model model. huggingface.co supports a free trial of the SMS-Spam-Detection-Model model, and also provides paid use of the SMS-Spam-Detection-Model. Support call SMS-Spam-Detection-Model model through api, including Node.js, Python, http.

SMS-Spam-Detection-Model huggingface.co Url

https://huggingface.co/AventIQ-AI/SMS-Spam-Detection-Model

AventIQ-AI SMS-Spam-Detection-Model online free

SMS-Spam-Detection-Model huggingface.co is an online trial and call api platform, which integrates SMS-Spam-Detection-Model's modeling effects, including api services, and provides a free online trial of SMS-Spam-Detection-Model, you can try SMS-Spam-Detection-Model online for free by clicking the link below.

AventIQ-AI SMS-Spam-Detection-Model online free url in huggingface.co:

https://huggingface.co/AventIQ-AI/SMS-Spam-Detection-Model

SMS-Spam-Detection-Model install

SMS-Spam-Detection-Model is an open source model from GitHub that offers a free installation service, and any user can find SMS-Spam-Detection-Model on GitHub to install. At the same time, huggingface.co provides the effect of SMS-Spam-Detection-Model install, users can directly use SMS-Spam-Detection-Model installed effect in huggingface.co for debugging and trial. It also supports api for free installation.

SMS-Spam-Detection-Model install url in huggingface.co:

https://huggingface.co/AventIQ-AI/SMS-Spam-Detection-Model

Url of SMS-Spam-Detection-Model

SMS-Spam-Detection-Model huggingface.co Url

Provider of SMS-Spam-Detection-Model huggingface.co

AventIQ-AI
ORGANIZATIONS

Other API from AventIQ-AI

huggingface.co

Total runs: 19
Run Growth: 13
Growth Rate: 72.22%
Updated:February 17 2025