Downloads · 30 days
45
6% of all-time downloads
e12ex2/Qwen3-1.7B-SigmaRL
Qwen3-1.7B-SigmaRL is a text generation model from e12ex2. Use it when you need the model to write or continue text. It is set up for mlx. The card lists the license as apache-2.0.
Threat description → Sigma detection rule. A small, defensive detection-engineering model: a LoRA fine-tune of Qwen3-1.7B that writes valid, backend-compilable Sigma rules from natural-language threat descriptions.
Downloads · 30 days
45
6% of all-time downloads
All-time downloads
785
Public
Parameters
1.7B
3.5 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors3.4 GB · 100%
From the Hugging Face model README
Threat description → Sigma detection rule. A small, defensive detection-engineering model: a LoRA fine-tune of Qwen3-1.7B that writes valid, backend-compilable Sigma rules from natural-language threat descriptions.
Defensive use only. This model generates blue-team detection rules. It is not designed or intended for offensive security.
Same 24 held-out prompts, scored by a graded verifiable reward: parse YAML → valid Sigma schema (pySigma) → compiles to a Splunk query (pySigma-backend-splunk).
| metric | base Qwen3-1.7B | this model (SFT) |
|---|---|---|
| valid + compilable rule rate | 0.0% | 45.8% |
| mean reward (0–0.6) | 0.10 | 0.36 |
| tier breakdown (0.0 / 0.2 / 0.6) | 12 / 12 / 0 | 3 / 10 / 11 |
The base model never once produced a valid, compilable rule; after fine-tuning, nearly half of outputs are valid and Splunk-compilable.
Qwen/Qwen3-1.7B (Apache-2.0)(description → rule) pairs derived from SigmaHQ (MIT)from transformers import AutoModelForCausalLM, AutoTokenizer
model_id = "e12ex2/Qwen3-1.7B-SigmaRL" # <-- set to your repo
tok = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(model_id)
SYSTEM = ("You are a detection engineer. Given a threat description, output a single "
"valid Sigma detection rule in YAML. Output only the YAML, no prose, no code fences.")
messages = [
{"role": "system", "content": SYSTEM},
{"role": "user", "content": "Write a Sigma rule that detects: powershell launched with a base64 -enc command"},
]
text = tok.apply_chat_template(messages, add_generation_prompt=True, tokenize=False)
out = model.generate(**tok(text, return_tensors="pt"), max_new_tokens=512)
print(tok.decode(out[0], skip_special_tokens=True))
The graded verifiable reward, data pipeline, and training scripts are open. Rules are scored, not hand-labeled — the same reward drives both eval and (planned) reinforcement learning.