Text Classification
Transformers
Safetensors
distilbert
Generated from Trainer
text-embeddings-inference
Instructions to use systemslibrarian/cipher-detective-classifier with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use systemslibrarian/cipher-detective-classifier with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="systemslibrarian/cipher-detective-classifier")# Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("systemslibrarian/cipher-detective-classifier") model = AutoModelForSequenceClassification.from_pretrained("systemslibrarian/cipher-detective-classifier", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Model save
Browse files
README.md
CHANGED
|
@@ -1,87 +1,73 @@
|
|
| 1 |
---
|
| 2 |
-
license: mit
|
| 3 |
library_name: transformers
|
|
|
|
|
|
|
| 4 |
tags:
|
| 5 |
-
|
| 6 |
-
- cryptography
|
| 7 |
-
- cryptanalysis
|
| 8 |
-
- classical-ciphers
|
| 9 |
-
- cybersecurity-education
|
| 10 |
-
datasets:
|
| 11 |
-
- systemslibrarian/classical-cipher-corpus
|
| 12 |
metrics:
|
| 13 |
-
|
| 14 |
-
|
|
|
|
|
|
|
| 15 |
---
|
| 16 |
|
| 17 |
-
|
|
|
|
| 18 |
|
| 19 |
-
|
| 20 |
|
| 21 |
-
|
| 22 |
-
|
| 23 |
-
-
|
| 24 |
-
-
|
|
|
|
|
|
|
|
|
|
| 25 |
|
| 26 |
-
##
|
| 27 |
|
| 28 |
-
|
| 29 |
|
| 30 |
-
|
| 31 |
-
- classical cipher demonstrations
|
| 32 |
-
- comparison against transparent heuristic baselines
|
| 33 |
-
- teaching why weak ciphers leak patterns
|
| 34 |
|
| 35 |
-
|
| 36 |
|
| 37 |
-
|
| 38 |
-
- `caesar_rot`
|
| 39 |
-
- `atbash`
|
| 40 |
-
- `vigenere`
|
| 41 |
-
- `rail_fence`
|
| 42 |
-
- `columnar`
|
| 43 |
-
- `affine`
|
| 44 |
-
- `substitution`
|
| 45 |
|
| 46 |
-
|
| 47 |
|
| 48 |
-
|
| 49 |
-
- unauthorized access
|
| 50 |
-
- surveillance
|
| 51 |
-
- password recovery
|
| 52 |
-
- bypassing security controls
|
| 53 |
-
- claims about real-world cryptanalytic capability
|
| 54 |
|
| 55 |
-
## Training
|
| 56 |
|
| 57 |
-
|
| 58 |
-
|
| 59 |
-
|
| 60 |
-
|
| 61 |
-
|
| 62 |
-
|
| 63 |
-
|
| 64 |
-
|
| 65 |
-
|
| 66 |
-
|
|
|
|
|
|
|
|
|
|
| 67 |
|
| 68 |
-
Training
|
| 69 |
|
| 70 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 71 |
|
| 72 |
-
| Metric | Value |
|
| 73 |
-
|---|---|
|
| 74 |
-
| Accuracy | **48.3%** |
|
| 75 |
-
| Macro Precision | **56.9%** |
|
| 76 |
-
| Macro Recall | **52.0%** |
|
| 77 |
-
| Macro F1 | **51.8%** |
|
| 78 |
|
| 79 |
-
|
| 80 |
|
| 81 |
-
|
| 82 |
-
|
| 83 |
-
|
| 84 |
-
|
| 85 |
-
## Responsible-use statement
|
| 86 |
-
|
| 87 |
-
Use this model to teach how classical ciphers leak patterns and why modern cryptography requires careful protocol design, key management, implementation correctness, and threat modeling.
|
|
|
|
| 1 |
---
|
|
|
|
| 2 |
library_name: transformers
|
| 3 |
+
license: apache-2.0
|
| 4 |
+
base_model: distilbert-base-uncased
|
| 5 |
tags:
|
| 6 |
+
- generated_from_trainer
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 7 |
metrics:
|
| 8 |
+
- accuracy
|
| 9 |
+
model-index:
|
| 10 |
+
- name: cipher-detective-classifier
|
| 11 |
+
results: []
|
| 12 |
---
|
| 13 |
|
| 14 |
+
<!-- This model card has been generated automatically according to the information the Trainer had access to. You
|
| 15 |
+
should probably proofread and complete it, then remove this comment. -->
|
| 16 |
|
| 17 |
+
# cipher-detective-classifier
|
| 18 |
|
| 19 |
+
This model is a fine-tuned version of [distilbert-base-uncased](https://huggingface.co/distilbert-base-uncased) on the None dataset.
|
| 20 |
+
It achieves the following results on the evaluation set:
|
| 21 |
+
- Loss: 1.2801
|
| 22 |
+
- Accuracy: 0.6127
|
| 23 |
+
- Macro Precision: 0.6196
|
| 24 |
+
- Macro Recall: 0.6392
|
| 25 |
+
- Macro F1: 0.6217
|
| 26 |
|
| 27 |
+
## Model description
|
| 28 |
|
| 29 |
+
More information needed
|
| 30 |
|
| 31 |
+
## Intended uses & limitations
|
|
|
|
|
|
|
|
|
|
| 32 |
|
| 33 |
+
More information needed
|
| 34 |
|
| 35 |
+
## Training and evaluation data
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 36 |
|
| 37 |
+
More information needed
|
| 38 |
|
| 39 |
+
## Training procedure
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 40 |
|
| 41 |
+
### Training hyperparameters
|
| 42 |
|
| 43 |
+
The following hyperparameters were used during training:
|
| 44 |
+
- learning_rate: 2e-05
|
| 45 |
+
- train_batch_size: 32
|
| 46 |
+
- eval_batch_size: 32
|
| 47 |
+
- seed: 42
|
| 48 |
+
- gradient_accumulation_steps: 2
|
| 49 |
+
- total_train_batch_size: 64
|
| 50 |
+
- optimizer: Use OptimizerNames.ADAMW_TORCH_FUSED with betas=(0.9,0.999) and epsilon=1e-08 and optimizer_args=No additional optimizer arguments
|
| 51 |
+
- lr_scheduler_type: cosine
|
| 52 |
+
- lr_scheduler_warmup_steps: 0.06
|
| 53 |
+
- num_epochs: 5.0
|
| 54 |
+
- mixed_precision_training: Native AMP
|
| 55 |
+
- label_smoothing_factor: 0.05
|
| 56 |
|
| 57 |
+
### Training results
|
| 58 |
|
| 59 |
+
| Training Loss | Epoch | Step | Validation Loss | Accuracy | Macro Precision | Macro Recall | Macro F1 |
|
| 60 |
+
|:-------------:|:-----:|:----:|:---------------:|:--------:|:---------------:|:------------:|:--------:|
|
| 61 |
+
| 3.6387 | 1.0 | 912 | 1.7823 | 0.4904 | 0.5276 | 0.5280 | 0.5108 |
|
| 62 |
+
| 3.0345 | 2.0 | 1824 | 1.4479 | 0.5485 | 0.5757 | 0.5806 | 0.5552 |
|
| 63 |
+
| 2.7365 | 3.0 | 2736 | 1.3711 | 0.5835 | 0.6195 | 0.6139 | 0.5988 |
|
| 64 |
+
| 2.5225 | 4.0 | 3648 | 1.2933 | 0.6067 | 0.6196 | 0.6332 | 0.6186 |
|
| 65 |
+
| 2.6116 | 5.0 | 4560 | 1.2801 | 0.6127 | 0.6196 | 0.6392 | 0.6217 |
|
| 66 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 67 |
|
| 68 |
+
### Framework versions
|
| 69 |
|
| 70 |
+
- Transformers 5.13.1
|
| 71 |
+
- Pytorch 2.11.0+cu128
|
| 72 |
+
- Datasets 4.0.0
|
| 73 |
+
- Tokenizers 0.22.2
|
|
|
|
|
|
|
|
|