SetFit with sentence-transformers/paraphrase-MiniLM-L6-v2
This is a SetFit model that can be used for Text Classification. This SetFit model uses sentence-transformers/paraphrase-MiniLM-L6-v2 as the Sentence Transformer embedding model. A LogisticRegression instance is used for classification.
The model has been trained using an efficient few-shot learning technique that involves:
- Fine-tuning a Sentence Transformer with contrastive learning.
- Training a classification head with features from the fine-tuned Sentence Transformer.
Model Details
Model Description
- Model Type: SetFit
- Sentence Transformer body: sentence-transformers/paraphrase-MiniLM-L6-v2
- Classification head: a LogisticRegression instance
- Maximum Sequence Length: 128 tokens
- Number of Classes: 19 classes
Model Sources
- Repository: SetFit on GitHub
- Paper: Efficient Few-Shot Learning Without Prompts
- Blogpost: SetFit: Efficient Few-Shot Learning Without Prompts
Model Labels
Label | Examples |
---|---|
Log Modification |
|
RDP Session Activity |
|
Credential Usage |
|
Authentication Attempt |
|
SSH Session Activity |
|
Container Management |
|
System Navigation |
|
Potential Data Exfiltration |
|
Package Management |
|
System Configuration Change |
|
Script Execution |
|
Network Configuration |
|
Process Execution |
|
Unauthorized Access |
|
Sensitive File Access |
|
Kubernetes Interaction |
|
Privilege Escalation |
|
Unusual Command Pattern |
|
Database Access |
|
Evaluation
Metrics
Label | Accuracy |
---|---|
all | 0.7068 |
Uses
Direct Use for Inference
First install the SetFit library:
pip install setfit
Then you can load this model and run inference.
from setfit import SetFitModel
# Download from the ๐ค Hub
model = SetFitModel.from_pretrained("setfit_model_id")
# Run inference
preds = model("pstree -p")
Training Details
Training Set Metrics
Training set | Min | Median | Max |
---|---|---|---|
Word count | 1 | 4.0921 | 22 |
Label | Training Sample Count |
---|---|
Unauthorized Access | 31 |
Privilege Escalation | 26 |
Sensitive File Access | 30 |
Potential Data Exfiltration | 24 |
Unusual Command Pattern | 28 |
System Navigation | 31 |
Database Access | 25 |
SSH Session Activity | 26 |
RDP Session Activity | 32 |
Kubernetes Interaction | 28 |
Container Management | 28 |
Process Execution | 33 |
Network Configuration | 27 |
Package Management | 28 |
Script Execution | 30 |
Authentication Attempt | 27 |
Credential Usage | 25 |
Log Modification | 24 |
System Configuration Change | 29 |
Training Hyperparameters
- batch_size: (16, 16)
- num_epochs: (1, 1)
- max_steps: -1
- sampling_strategy: oversampling
- body_learning_rate: (2e-05, 1e-05)
- head_learning_rate: 0.01
- loss: CosineSimilarityLoss
- distance_metric: cosine_distance
- margin: 0.25
- end_to_end: False
- use_amp: False
- warmup_proportion: 0.1
- l2_weight: 0.01
- seed: 42
- eval_max_steps: -1
- load_best_model_at_end: True
Training Results
Epoch | Step | Training Loss | Validation Loss |
---|---|---|---|
0.0001 | 1 | 0.2873 | - |
0.0030 | 50 | 0.2416 | - |
0.0060 | 100 | 0.2458 | - |
0.0090 | 150 | 0.2196 | - |
0.0119 | 200 | 0.2001 | - |
0.0149 | 250 | 0.204 | - |
0.0179 | 300 | 0.1896 | - |
0.0209 | 350 | 0.1929 | - |
0.0239 | 400 | 0.1809 | - |
0.0269 | 450 | 0.1652 | - |
0.0299 | 500 | 0.1521 | - |
0.0328 | 550 | 0.143 | - |
0.0358 | 600 | 0.1367 | - |
0.0388 | 650 | 0.1367 | - |
0.0418 | 700 | 0.1288 | - |
0.0448 | 750 | 0.1213 | - |
0.0478 | 800 | 0.1137 | - |
0.0507 | 850 | 0.1213 | - |
0.0537 | 900 | 0.1042 | - |
0.0567 | 950 | 0.0942 | - |
0.0597 | 1000 | 0.0942 | - |
0.0627 | 1050 | 0.0948 | - |
0.0657 | 1100 | 0.0845 | - |
0.0687 | 1150 | 0.0817 | - |
0.0716 | 1200 | 0.0862 | - |
0.0746 | 1250 | 0.0798 | - |
0.0776 | 1300 | 0.069 | - |
0.0806 | 1350 | 0.0749 | - |
0.0836 | 1400 | 0.0773 | - |
0.0866 | 1450 | 0.0723 | - |
0.0896 | 1500 | 0.0733 | - |
0.0925 | 1550 | 0.0599 | - |
0.0955 | 1600 | 0.065 | - |
0.0985 | 1650 | 0.0644 | - |
0.1015 | 1700 | 0.0586 | - |
0.1045 | 1750 | 0.0575 | - |
0.1075 | 1800 | 0.0531 | - |
0.1104 | 1850 | 0.0515 | - |
0.1134 | 1900 | 0.05 | - |
0.1164 | 1950 | 0.046 | - |
0.1194 | 2000 | 0.0418 | - |
0.1224 | 2050 | 0.0418 | - |
0.1254 | 2100 | 0.0437 | - |
0.1284 | 2150 | 0.0434 | - |
0.1313 | 2200 | 0.0362 | - |
0.1343 | 2250 | 0.0366 | - |
0.1373 | 2300 | 0.0237 | - |
0.1403 | 2350 | 0.0396 | - |
0.1433 | 2400 | 0.0339 | - |
0.1463 | 2450 | 0.0341 | - |
0.1493 | 2500 | 0.0306 | - |
0.1522 | 2550 | 0.0261 | - |
0.1552 | 2600 | 0.0309 | - |
0.1582 | 2650 | 0.0223 | - |
0.1612 | 2700 | 0.0263 | - |
0.1642 | 2750 | 0.0184 | - |
0.1672 | 2800 | 0.0272 | - |
0.1701 | 2850 | 0.0201 | - |
0.1731 | 2900 | 0.0193 | - |
0.1761 | 2950 | 0.0218 | - |
0.1791 | 3000 | 0.0251 | - |
0.1821 | 3050 | 0.0185 | - |
0.1851 | 3100 | 0.0182 | - |
0.1881 | 3150 | 0.019 | - |
0.1910 | 3200 | 0.0155 | - |
0.1940 | 3250 | 0.0208 | - |
0.1970 | 3300 | 0.0231 | - |
0.2 | 3350 | 0.0202 | - |
0.2030 | 3400 | 0.0162 | - |
0.2060 | 3450 | 0.0188 | - |
0.2090 | 3500 | 0.016 | - |
0.2119 | 3550 | 0.0194 | - |
0.2149 | 3600 | 0.0187 | - |
0.2179 | 3650 | 0.0179 | - |
0.2209 | 3700 | 0.0166 | - |
0.2239 | 3750 | 0.0155 | - |
0.2269 | 3800 | 0.0175 | - |
0.2299 | 3850 | 0.018 | - |
0.2328 | 3900 | 0.0095 | - |
0.2358 | 3950 | 0.0145 | - |
0.2388 | 4000 | 0.0102 | - |
0.2418 | 4050 | 0.0131 | - |
0.2448 | 4100 | 0.0191 | - |
0.2478 | 4150 | 0.0136 | - |
0.2507 | 4200 | 0.0126 | - |
0.2537 | 4250 | 0.0138 | - |
0.2567 | 4300 | 0.0102 | - |
0.2597 | 4350 | 0.01 | - |
0.2627 | 4400 | 0.0108 | - |
0.2657 | 4450 | 0.0125 | - |
0.2687 | 4500 | 0.0129 | - |
0.2716 | 4550 | 0.0095 | - |
0.2746 | 4600 | 0.0089 | - |
0.2776 | 4650 | 0.012 | - |
0.2806 | 4700 | 0.0085 | - |
0.2836 | 4750 | 0.0102 | - |
0.2866 | 4800 | 0.0106 | - |
0.2896 | 4850 | 0.007 | - |
0.2925 | 4900 | 0.006 | - |
0.2955 | 4950 | 0.0088 | - |
0.2985 | 5000 | 0.0094 | - |
0.3015 | 5050 | 0.0074 | - |
0.3045 | 5100 | 0.0105 | - |
0.3075 | 5150 | 0.0062 | - |
0.3104 | 5200 | 0.0068 | - |
0.3134 | 5250 | 0.0134 | - |
0.3164 | 5300 | 0.0104 | - |
0.3194 | 5350 | 0.0061 | - |
0.3224 | 5400 | 0.0087 | - |
0.3254 | 5450 | 0.0093 | - |
0.3284 | 5500 | 0.0066 | - |
0.3313 | 5550 | 0.0068 | - |
0.3343 | 5600 | 0.0081 | - |
0.3373 | 5650 | 0.0056 | - |
0.3403 | 5700 | 0.0064 | - |
0.3433 | 5750 | 0.009 | - |
0.3463 | 5800 | 0.008 | - |
0.3493 | 5850 | 0.0075 | - |
0.3522 | 5900 | 0.0054 | - |
0.3552 | 5950 | 0.0072 | - |
0.3582 | 6000 | 0.0054 | - |
0.3612 | 6050 | 0.0058 | - |
0.3642 | 6100 | 0.0052 | - |
0.3672 | 6150 | 0.0063 | - |
0.3701 | 6200 | 0.0047 | - |
0.3731 | 6250 | 0.0044 | - |
0.3761 | 6300 | 0.008 | - |
0.3791 | 6350 | 0.0068 | - |
0.3821 | 6400 | 0.0054 | - |
0.3851 | 6450 | 0.0065 | - |
0.3881 | 6500 | 0.0094 | - |
0.3910 | 6550 | 0.0055 | - |
0.3940 | 6600 | 0.0069 | - |
0.3970 | 6650 | 0.0027 | - |
0.4 | 6700 | 0.0045 | - |
0.4030 | 6750 | 0.0041 | - |
0.4060 | 6800 | 0.0051 | - |
0.4090 | 6850 | 0.0048 | - |
0.4119 | 6900 | 0.0065 | - |
0.4149 | 6950 | 0.0064 | - |
0.4179 | 7000 | 0.0049 | - |
0.4209 | 7050 | 0.0068 | - |
0.4239 | 7100 | 0.0069 | - |
0.4269 | 7150 | 0.0072 | - |
0.4299 | 7200 | 0.0024 | - |
0.4328 | 7250 | 0.0047 | - |
0.4358 | 7300 | 0.0063 | - |
0.4388 | 7350 | 0.0034 | - |
0.4418 | 7400 | 0.0038 | - |
0.4448 | 7450 | 0.0049 | - |
0.4478 | 7500 | 0.0047 | - |
0.4507 | 7550 | 0.0047 | - |
0.4537 | 7600 | 0.0081 | - |
0.4567 | 7650 | 0.0059 | - |
0.4597 | 7700 | 0.0071 | - |
0.4627 | 7750 | 0.006 | - |
0.4657 | 7800 | 0.005 | - |
0.4687 | 7850 | 0.0051 | - |
0.4716 | 7900 | 0.0043 | - |
0.4746 | 7950 | 0.0062 | - |
0.4776 | 8000 | 0.0042 | - |
0.4806 | 8050 | 0.0036 | - |
0.4836 | 8100 | 0.0049 | - |
0.4866 | 8150 | 0.0024 | - |
0.4896 | 8200 | 0.0052 | - |
0.4925 | 8250 | 0.005 | - |
0.4955 | 8300 | 0.0041 | - |
0.4985 | 8350 | 0.0043 | - |
0.5015 | 8400 | 0.0061 | - |
0.5045 | 8450 | 0.0055 | - |
0.5075 | 8500 | 0.005 | - |
0.5104 | 8550 | 0.0054 | - |
0.5134 | 8600 | 0.004 | - |
0.5164 | 8650 | 0.0039 | - |
0.5194 | 8700 | 0.0059 | - |
0.5224 | 8750 | 0.0063 | - |
0.5254 | 8800 | 0.0048 | - |
0.5284 | 8850 | 0.0031 | - |
0.5313 | 8900 | 0.0039 | - |
0.5343 | 8950 | 0.0049 | - |
0.5373 | 9000 | 0.0046 | - |
0.5403 | 9050 | 0.0035 | - |
0.5433 | 9100 | 0.0045 | - |
0.5463 | 9150 | 0.0022 | - |
0.5493 | 9200 | 0.0041 | - |
0.5522 | 9250 | 0.0037 | - |
0.5552 | 9300 | 0.0046 | - |
0.5582 | 9350 | 0.004 | - |
0.5612 | 9400 | 0.0079 | - |
0.5642 | 9450 | 0.0071 | - |
0.5672 | 9500 | 0.0049 | - |
0.5701 | 9550 | 0.0036 | - |
0.5731 | 9600 | 0.005 | - |
0.5761 | 9650 | 0.005 | - |
0.5791 | 9700 | 0.005 | - |
0.5821 | 9750 | 0.0036 | - |
0.5851 | 9800 | 0.0029 | - |
0.5881 | 9850 | 0.0044 | - |
0.5910 | 9900 | 0.0031 | - |
0.5940 | 9950 | 0.0047 | - |
0.5970 | 10000 | 0.0061 | - |
0.6 | 10050 | 0.0016 | - |
0.6030 | 10100 | 0.0049 | - |
0.6060 | 10150 | 0.0044 | - |
0.6090 | 10200 | 0.0032 | - |
0.6119 | 10250 | 0.0036 | - |
0.6149 | 10300 | 0.0037 | - |
0.6179 | 10350 | 0.0036 | - |
0.6209 | 10400 | 0.0033 | - |
0.6239 | 10450 | 0.0057 | - |
0.6269 | 10500 | 0.0038 | - |
0.6299 | 10550 | 0.0039 | - |
0.6328 | 10600 | 0.0024 | - |
0.6358 | 10650 | 0.0057 | - |
0.6388 | 10700 | 0.0044 | - |
0.6418 | 10750 | 0.0036 | - |
0.6448 | 10800 | 0.0064 | - |
0.6478 | 10850 | 0.0054 | - |
0.6507 | 10900 | 0.0023 | - |
0.6537 | 10950 | 0.0051 | - |
0.6567 | 11000 | 0.0038 | - |
0.6597 | 11050 | 0.0048 | - |
0.6627 | 11100 | 0.004 | - |
0.6657 | 11150 | 0.004 | - |
0.6687 | 11200 | 0.0027 | - |
0.6716 | 11250 | 0.0046 | - |
0.6746 | 11300 | 0.0044 | - |
0.6776 | 11350 | 0.0066 | - |
0.6806 | 11400 | 0.0031 | - |
0.6836 | 11450 | 0.0019 | - |
0.6866 | 11500 | 0.0022 | - |
0.6896 | 11550 | 0.0028 | - |
0.6925 | 11600 | 0.0043 | - |
0.6955 | 11650 | 0.0041 | - |
0.6985 | 11700 | 0.0064 | - |
0.7015 | 11750 | 0.0033 | - |
0.7045 | 11800 | 0.0019 | - |
0.7075 | 11850 | 0.0045 | - |
0.7104 | 11900 | 0.0052 | - |
0.7134 | 11950 | 0.0034 | - |
0.7164 | 12000 | 0.0036 | - |
0.7194 | 12050 | 0.0029 | - |
0.7224 | 12100 | 0.0042 | - |
0.7254 | 12150 | 0.0044 | - |
0.7284 | 12200 | 0.0032 | - |
0.7313 | 12250 | 0.0038 | - |
0.7343 | 12300 | 0.002 | - |
0.7373 | 12350 | 0.0027 | - |
0.7403 | 12400 | 0.006 | - |
0.7433 | 12450 | 0.0017 | - |
0.7463 | 12500 | 0.0025 | - |
0.7493 | 12550 | 0.004 | - |
0.7522 | 12600 | 0.0048 | - |
0.7552 | 12650 | 0.0026 | - |
0.7582 | 12700 | 0.0028 | - |
0.7612 | 12750 | 0.0036 | - |
0.7642 | 12800 | 0.0027 | - |
0.7672 | 12850 | 0.0029 | - |
0.7701 | 12900 | 0.0025 | - |
0.7731 | 12950 | 0.0045 | - |
0.7761 | 13000 | 0.0039 | - |
0.7791 | 13050 | 0.0027 | - |
0.7821 | 13100 | 0.0033 | - |
0.7851 | 13150 | 0.0038 | - |
0.7881 | 13200 | 0.003 | - |
0.7910 | 13250 | 0.0045 | - |
0.7940 | 13300 | 0.0062 | - |
0.7970 | 13350 | 0.0039 | - |
0.8 | 13400 | 0.005 | - |
0.8030 | 13450 | 0.0042 | - |
0.8060 | 13500 | 0.0031 | - |
0.8090 | 13550 | 0.0032 | - |
0.8119 | 13600 | 0.0024 | - |
0.8149 | 13650 | 0.005 | - |
0.8179 | 13700 | 0.0037 | - |
0.8209 | 13750 | 0.0035 | - |
0.8239 | 13800 | 0.0024 | - |
0.8269 | 13850 | 0.0024 | - |
0.8299 | 13900 | 0.0033 | - |
0.8328 | 13950 | 0.0028 | - |
0.8358 | 14000 | 0.0019 | - |
0.8388 | 14050 | 0.0036 | - |
0.8418 | 14100 | 0.0028 | - |
0.8448 | 14150 | 0.0034 | - |
0.8478 | 14200 | 0.0035 | - |
0.8507 | 14250 | 0.0032 | - |
0.8537 | 14300 | 0.0019 | - |
0.8567 | 14350 | 0.0022 | - |
0.8597 | 14400 | 0.0044 | - |
0.8627 | 14450 | 0.0028 | - |
0.8657 | 14500 | 0.0024 | - |
0.8687 | 14550 | 0.0028 | - |
0.8716 | 14600 | 0.005 | - |
0.8746 | 14650 | 0.0063 | - |
0.8776 | 14700 | 0.003 | - |
0.8806 | 14750 | 0.002 | - |
0.8836 | 14800 | 0.0038 | - |
0.8866 | 14850 | 0.0029 | - |
0.8896 | 14900 | 0.003 | - |
0.8925 | 14950 | 0.0038 | - |
0.8955 | 15000 | 0.0028 | - |
0.8985 | 15050 | 0.0046 | - |
0.9015 | 15100 | 0.0043 | - |
0.9045 | 15150 | 0.0034 | - |
0.9075 | 15200 | 0.0023 | - |
0.9104 | 15250 | 0.0041 | - |
0.9134 | 15300 | 0.003 | - |
0.9164 | 15350 | 0.0039 | - |
0.9194 | 15400 | 0.0031 | - |
0.9224 | 15450 | 0.0035 | - |
0.9254 | 15500 | 0.0051 | - |
0.9284 | 15550 | 0.0028 | - |
0.9313 | 15600 | 0.0061 | - |
0.9343 | 15650 | 0.0031 | - |
0.9373 | 15700 | 0.0027 | - |
0.9403 | 15750 | 0.0034 | - |
0.9433 | 15800 | 0.0035 | - |
0.9463 | 15850 | 0.0016 | - |
0.9493 | 15900 | 0.0023 | - |
0.9522 | 15950 | 0.0025 | - |
0.9552 | 16000 | 0.0028 | - |
0.9582 | 16050 | 0.0019 | - |
0.9612 | 16100 | 0.0026 | - |
0.9642 | 16150 | 0.003 | - |
0.9672 | 16200 | 0.0032 | - |
0.9701 | 16250 | 0.0037 | - |
0.9731 | 16300 | 0.004 | - |
0.9761 | 16350 | 0.0033 | - |
0.9791 | 16400 | 0.0038 | - |
0.9821 | 16450 | 0.0032 | - |
0.9851 | 16500 | 0.0039 | - |
0.9881 | 16550 | 0.0029 | - |
0.9910 | 16600 | 0.0034 | - |
0.9940 | 16650 | 0.0034 | - |
0.9970 | 16700 | 0.0023 | - |
1.0 | 16750 | 0.0034 | 0.1525 |
Framework Versions
- Python: 3.13.2
- SetFit: 1.1.2
- Sentence Transformers: 4.0.2
- Transformers: 4.51.0
- PyTorch: 2.6.0
- Datasets: 3.5.0
- Tokenizers: 0.21.1
Citation
BibTeX
@article{https://doi.org/10.48550/arxiv.2209.11055,
doi = {10.48550/ARXIV.2209.11055},
url = {https://arxiv.org/abs/2209.11055},
author = {Tunstall, Lewis and Reimers, Nils and Jo, Unso Eun Seo and Bates, Luke and Korat, Daniel and Wasserblat, Moshe and Pereg, Oren},
keywords = {Computation and Language (cs.CL), FOS: Computer and information sciences, FOS: Computer and information sciences},
title = {Efficient Few-Shot Learning Without Prompts},
publisher = {arXiv},
year = {2022},
copyright = {Creative Commons Attribution 4.0 International}
}
- Downloads last month
- 155
Inference Providers
NEW
This model isn't deployed by any Inference Provider.
๐
Ask for provider support