CBX secrets train data
Generated by CobuildX and checked against our annotation guide: code, configs, logs, chat and documents with invented secrets and hard negatives (placeholders, references, hashes, fake values).
01 · Safety · Open weights
cbx-secrets-detector-32M
Finds credentials in code, configs, logs and chat.
Real, cached outputs from the model.
STRIPE_SECRET_KEY=sk-live-9fQ2mXyzAB12cd34EF56gh78 DATABASE_URL=postgres://admin:[email protected]:5432/orders password: correcthorsebatterystaple
Benchmark
From the model card
Finds secrets and credentials (passwords, API keys, tokens, private keys, cloud and database credentials) in code, config files, logs, tickets and chat, and returns the exact position of each value with one of 12 labels. 32M parameters; about 8 ms per 1,000 tokens on a GPU and 81 ms on a CPU.
This is the recommended default: more accurate than 17M, at about 1.25× its time on a GPU and 2.2× on a CPU. Fine-tuned from jhu-clsp/ettin-encoder-32m. Version v0.1, the first release (use --revision v0.1 to pin it). Also available in 17M.
Unlike rule-based scanners, it reads the context: it finds passwords and keys that have no fixed prefix, and it leaves alone placeholders, variable references, hashes and obviously fake values.
Span F1, label-agnostic: a found value counts if it overlaps a true secret, whatever its label (the benchmarks and the scanners use different type names). Precision and recall in brackets. "False alarms" is the share of labelled non-secret lines or candidates on which something is flagged.
| Model | CredData test | false alarms | Issue reports test | false alarms | CBX secrets test |
|---|---|---|---|---|---|
| cbx-secrets-detector-17M | 0.805 (0.80 / 0.81) | 0.9% | 0.836 (0.90 / 0.78) | 0.9% | 0.983 (0.99 / 0.98) |
| cbx-secrets-detector-32M | 0.820 (0.77 / 0.87) | 1.3% | 0.861 (0.86 / 0.86) | 1.4% | 0.998 (1.00 / 1.00) |
| Gitleaks 8.30.1 | 0.442 (0.90 / 0.29) | 0.6% | 0.678 (0.93 / 0.54) | 0.5% | 0.757 (0.99 / 0.61) |
| detect-secrets 1.5.0 | 0.460 (0.47 / 0.45) | 9.8% | 0.290 (0.40 / 0.23) | 4.0% | 0.626 (0.90 / 0.48) |
| TruffleHog 3.99.2 | 0.042 (0.38 / 0.02) | 0.8% | 0.228 (0.66 / 0.14) | 0.9% | 0.215 (1.00 / 0.12) |
Speed. Median 8 ms (p95 8 ms) per text of 1,000 tokens on an NVIDIA TITAN RTX (fp16), 81 ms (p95 84 ms) on an Intel i7-10700 CPU with 8 threads; texts processed one at a time, end to end (text in, spans out).
Limitations
key, token, password).Training data
Generated by CobuildX and checked against our annotation guide: code, configs, logs, chat and documents with invented secrets and hard negatives (placeholders, references, hashes, fake values).
(lines and labels from 116 repositories with MIT, Apache-2.0 or BSD licences; values already obfuscated by Samsung). The repositories and their licences are listed in training_data_sources.csv.
The training split of Secret Leak Detection in Software Issue Reports using LLMs, Ahmed et al., arXiv:2410.23657, dataset 10.5281/zenodo.19622962, licensed CC BY 4.0. Changed: every real secret was replaced by an invented value of the same shape before training, and texts were cut into windows. No real secret from this dataset is in the model's training data or in this repository.
Sign in to the console to call this model live, compare sizes and create an API key.