← Lab /Security & privacy

AI generates ready-to-use ES|QL detection rules from plain English descriptions

Elastic’s AI Agent can automatically produce validated, MITRE-mapped ES|QL detection rules from natural-language descriptions, cutting rule authoring time to a few minutes.

Security & privacy Elastic Security Labs 4 May 2026 Tooling Deployed evidence

Published as “From plain English to production rule: AI-native Elasticsearch ES|QL detection in Elastic Security”

Why it matters

If true, AI-driven rule authoring could dramatically speed up detection engineering and improve coverage.

Summary

The blog shows how analysts can describe a threat behavior in plain English and the Elastic AI Agent returns a complete ES|QL detection rule with MITRE ATT&CK mappings and severity recommendations. The generated rule is validated and previewed against the user’s own Okta logs within the Elastic Security UI. The authors report that the end-to-end workflow takes only a few minutes, compared to the much longer manual authoring process. Evidence is based on a single walkthrough example rather than a large-scale study.

What they found 2

  1. The AI Agent returns a complete ES|QL rule covering the described attack sequence

    “And then it returns a complete ES|QL rule that covers the full attack sequence described.”

  2. The end-to-end rule creation process takes only a few minutes

    “The walk-through above, from opening the rule creation form to having a validated, multistage, MITRE-mapped ES|QL rule covering the full Okta account takeover chain, takes a few minutes.”

Caveats 3

  • AI-generated rules should be reviewed before deployment in production environments. The AI Agent may not have full awareness of your specific data schema, log source quirks, or environment-specific baseline behavior.
  • The capability is only available at the Enterprise license tier.
  • Currently only ES|QL rule type is supported; additional rule types are on the roadmap.

What’s new here 4

  • Integrated AI-driven rule creation directly in the Elastic Security rule workflow
  • Automatic generation of full ES|QL queries, metadata, and MITRE ATT&CK mappings from natural-language prompts
  • In-platform validation and preview of the rule against live data
  • Chat-based iterative refinement of the generated rule