Skip to content

meltedinhex/analyst-ai-pack / skills/writing-sigma-detection-rules

writing-sigma-detection-rules

Verified

Converts hunt findings into portable Sigma detection rules: choosing the right logsource, expressing robust selection/filter logic, setting level and ATT&CK tags, and validating before converting to a SIEM query. Activates for requests to write a Sigma rule, convert a hunt to a detection, or create portable SIEM detection logic.

FileKindSize
LICENSEother340 B
SKILL.mdskill md3.1 KB
references/api-reference.mdmarkdown1.2 KB
scripts/analyst.pyscript2.0 KB

references/api-reference.md

View on GitHub
# API Reference: Writing Sigma Detection Rules

## Overview

`scripts/analyst.py` emits a Sigma YAML rule skeleton with a pinned logsource, selection/filter
pattern, ATT&CK tag, level, and falsepositives list. It emits text only; use sigma-cli to
validate and convert.

## Dependencies

| Package | Version | Purpose |
|---------|---------|---------|
| (stdlib) | — | text generation |

## External tools

| Tool | Purpose |
|------|---------|
| sigma-cli (pysigma) | Validate (`sigma check`) and convert (`sigma convert`) rules |

## Core functions

### `scaffold(title, category, technique, level, author)`
Returns a Sigma rule skeleton with selection, negated filter, tags, and falsepositives.

## Usage

```bash
python scripts/analyst.py scaffold --title "Encoded PowerShell" --category process_creation \
  --technique T1059.001 --level high
sigma convert -t splunk rules/encoded_powershell.yml
```

## Sources

- Sigma specification — https://github.com/SigmaHQ/sigma-specification
- Sigma rules repository (logsource taxonomy, rule structure) — https://github.com/SigmaHQ/sigma
- Selection + negated-filter pattern for low false positives, established detection-engineering
  practice
slack-gif-creatoranthropics/skillsKnowledge and utilities for creating animated GIFs optimized for Slack. Provides constraints, validation tools, and animation concepts. Use when users request animated GIFs for Slack like "make me a GIF of X doing Y for Slack."Stars: 198kUpdated Claude CodeCodexVerifiedInstall
ponytailDietrichGebert/ponytailLazy senior dev mode for any coding task: the smallest change that fully solves it, and a reply a busy human understands in one read.Stars: 194kUpdated Claude CodeCodexVerifiedInstall
ponytail-debtDietrichGebert/ponytailHarvest every shortcut: comment into one debt ledger, so deferrals get tracked instead of forgotten. One-shot report.Stars: 194kUpdated Claude CodeCodexVerifiedInstall
ponytail-debtDietrichGebert/ponytailList every `shortcut:` comment (and older `ponytail:` ones) as a debt ledger. One-shot report, changes nothing. Use for "ponytail debt", "what did ponytail defer", "list the shortcuts", /ponytail-debt.Stars: 194kUpdated Claude CodeCodexVerifiedInstall