You have a working Sigma rule and three SIEMs to deploy it to. Hand-translating the same logic into KQL, SPL, and Elastic DSL is tedious and error-prone, and the errors are silent — a mistranslated operator produces a query that runs cleanly and matches the wrong events.
Tier: Core · Workflow area: Detection engineering with AI
This playbook uses a transpiler-first workflow (pySigma does the deterministic conversion) with the LLM handling only the field-mapping gaps, and every backend proven against the same test data.
Skip the LLM entirely when a pySigma backend already has a complete mapping for your environment — the transpiler alone is more reliable than any model.
Transpile deterministically first. Run the Sigma rule through pySigma for each backend. The transpiler is deterministic and correct where it has a field mapping — use it as the source of truth and only bring in the LLM for what it cannot resolve.
sigma convert -t kusto rule.yml # KQL / Sentinel
sigma convert -t splunk rule.yml # SPL
sigma convert -t esql rule.yml # Elastic
Use the LLM only to close mapping gaps. When a backend errors on an unmapped field or your environment uses non-standard column names, ask for the mapping — not a free rewrite.
pySigma could not map field "SourceImage" for the Splunk backend against
our schema. Our Sysmon data in Splunk uses these field names: [paste real
field list]. Give me ONLY the field-mapping (Sigma field -> our field) so
I can add it to the pipeline config. Do not rewrite the whole query; do not
invent field names outside the list I gave you.
Expected output: a small, checkable field-mapping table you add to the pySigma pipeline — not a hand-written query you have to trust wholesale.
Read all three generated queries side by side. Confirm each references fields that exist in that SIEM's schema and that the logic (AND/OR/NOT structure) is identical across all three. Divergence means one translation drifted.
Run every backend against the same test data. Load an identical known-bad and known-good sample into each SIEM (community editions) and confirm all three fire on the bad and stay silent on the good. Equivalent rules must produce equivalent verdicts.
Diff the result sets. If KQL matches the bad sample but SPL does not, the SPL translation is wrong — usually a case-sensitivity or wildcard-semantics difference. Fix the mapping and re-run until all three agree.
Trust the transpiler, verify the mapping. pySigma's conversion is deterministic; the LLM's field-mapping guesses are not. Keeping the model's job narrow (mappings only) is what keeps three-way translation reliable.
has is not SPL =, and Elastic wildcards differ from both. Mistranslated operators are the classic silent failure.Field mappings expose a client's schema and naming conventions, so treat them as sensitive. Run the LLM mapping step on a local Ollama model or the client's approved endpoint, and where possible give it a generalized field list rather than the client's literal index names. Do all three-way testing against the client's sample or lab indices in their own SIEM instances. Commit the pySigma pipeline config and the validated queries into the client's detection repository so the mappings are versioned alongside their schema — the equivalence proof (identical verdicts on identical test data) is the artifact the client's detection owner signs off on.