Detection Engineering 标志

Detection Engineering

组织
gensecaihq
detection-engineering

将检测规则作为代码进行设计、回测和调优:编写符合 ADS 文档规范且覆盖 ATT&CK 的 Sigma 或 Wazuh 规则,并通过 propose_detection 提交人工审核;用于填补检测盲区、处理反复出现的误报,或应对在狩猎和事件处理中发现的新 TTP。

概览

发布者gensecaihq
代码仓库Wazuh-Autopilot
技能名称detection-engineering
星标数
61
复刻数
15
附带文件
仅含指令
许可协议MIT
链接
  • Markdown 格式的指令

    模型按需加载 SKILL.md 文件,因此只有在请求确实与该技能匹配时才会消耗 Token。

  • 兼容任何大语言模型

    AI 技能采用纯 Markdown,而非特定提供商的代码,因此可搭配 GPT、Claude、Gemini、Grok 或本地模型使用。

  • 指令自成一体

    模型所需的一切都包含在指令中,无需同步额外文件。

  • 开源

    由 gensecaihq 发布于 GitHub。请在安装前查看技能的源文件。

安装

在 TypingMind 中安装 Detection Engineering AI 技能,即可搭配任意大语言模型使用;也可以将其放入其他支持读取 SKILL.md 的智能体中。

1

安装到 TypingMind

TypingMind 可直接从 GitHub 文件夹安装技能:读取 SKILL.md,打包资源文件,并将结果保存在本地。

  1. 打开应用,前往“插件 → 技能”。
  2. 选择“从 GitHub 安装”。
  3. 粘贴下方的技能文件夹 URL 并确认。
    https://github.com/gensecaihq/Wazuh-Autopilot/tree/main/backend/app/skills/detection-engineering
  4. 请在每个需要使用该技能的聊天中启用它。
依次选择“插件 → 技能 → 添加技能 → 从 GitHub URL 导入”,然后粘贴文件夹 URL 并点击“继续”。
2

安装到其他智能体

任何支持 Agent Skills 格式的智能体都可以使用此技能,只需将文件夹复制到该智能体的技能目录中。

Claude Code — .claude/skills
git clone --depth 1 https://github.com/gensecaihq/Wazuh-Autopilot.git /tmp/Wazuh-Autopilot
mkdir -p .claude/skills
cp -r /tmp/Wazuh-Autopilot/backend/app/skills/detection-engineering .claude/skills/detection-engineering
复制后,请重启 Claude Code,以加载新技能。

在 TypingMind 中使用此技能

在任意 TypingMind 聊天中启用 Detection Engineering,后续即可交由模型处理。技能的名称和描述会放在系统提示词中,一旦请求匹配,模型就会自动加载完整指令,无需您手动调用,且在实际使用前不会消耗 Token。

一旦请求与技能匹配,模型就会自动加载 Detection Engineering。

兼容任何 AI 模型

AI 技能是纯 Markdown 指令,而非特定提供商的代码,因此 Detection Engineering 不局限于最初适配的模型。只需在 TypingMind 中安装一次,即可搭配 GPT-5、Claude、Gemini、Grok、DeepSeek、Mistral、Llama 或您自行运行的本地模型使用,全程使用您自己的 API 密钥。

  • 仅在需要时加载

    系统提示词中仅包含技能名称和描述。首次遇到匹配的请求时才会加载完整指令,因此技能未使用时,这些指令不会消耗 Token。

  • 在聊天中切换模型

    技能是指令而非代码,因此切换模型不会导致技能失效,新模型会读取同一个 SKILL.md。

技能指令

这是模型会加载的 SKILL.md 内容。请在安装前阅读,因为技能就是模型将遵循的指令。

Detection Engineering

Detections are code: versioned, documented, tested, reviewed. You propose; humans review and deploy. Never claim a rule is deployed.

Inputs that trigger work

  • Hunt found activity with no alert (detection gap).
  • Incident where first detection was late (dwell time > 0).
  • Rule producing repeated false positives (tuning).
  • New TTP from threat intel relevant to the environment.

ADS (Alerting and Detection Strategy) — Palantir framework

Every proposal documents:

  1. Goal — what behaviour it detects.
  2. Categorization — ATT&CK tactic/technique.
  3. Strategy Abstract — how, at a high level.
  4. Technical Context — data sources, fields, platform details.
  5. Blind Spots and Assumptions — what it misses, what must be true.
  6. False Positives — known benign triggers.
  7. Validation — how to generate a true positive to test it.
  8. Priority — alert severity and why.
  9. Response — what the analyst should do when it fires.

Rule formats

Prefer Sigma (portable) with a Wazuh mapping note; use native Wazuh XML when the logic depends on Wazuh decoders or if_sid chaining.

Sigma essentials: title, id (UUID), status: experimental, description, references, author, date, tags (attack.t1110.001), logsource (product/service/category), detection (selections + condition), falsepositives, level.

Wazuh mapping notes:

  • Custom rules live in local_rules.xml (or files under /var/ossec/etc/rules/), IDs 100000–120000, so they don't collide with the stock ruleset. Write them as custom rule 100210 in findings.
  • Chain on stock rules with <if_sid> (the parent matched this event) or <if_matched_sid> plus frequency / timeframe (a count of earlier matches). Model frequency rules on the stock sshd brute-force rule 5712, which fires after 8 matches of rule 5710 from the same source within 120 seconds and then stays quiet for 60. As a custom rule 100210 that reads:
    xml
    <rule id="100210" level="10" frequency="8" timeframe="120" ignore="60">
      <if_matched_sid>PARENT_SID</if_matched_sid>
      <same_source_ip />
      <description>...</description>
    </rule>
    Other correlation options in the stock ruleset: <same_user />, <same_field>, <if_matched_group>.
  • Map Sigma fields to decoded Wazuh fields (data.win.eventdata.commandLine, data.win.system.eventID, data.srcip, data.dstuser) with <field name="..."> PCRE2 or OS_Regex patterns. Field names drop the data. prefix inside rules (<field name="win.eventdata.commandLine">).
  • Add <mitre><id>T1110.001</id></mitre>, a meaningful <group> (plus compliance groups such as pci_dss_10.2.4 if it supports a requirement), and set the level with the classification in alert-triage. Level 12+ pages people.
  • To tune a noisy stock rule, prefer a child rule at level 0 matching the benign pattern (<if_sid>PARENT</if_sid> + fields) over editing the stock rule. Changes to stock files are lost on upgrade.
  • Load wazuh-rules-and-decoders for decoders and rule evaluation order, and wazuh-windows-sysmon for Windows/Sysmon field paths.

Backtesting

  1. Express the logic as a search over history: search_security_events / get_wazuh_alerts (30 days where possible).
  2. Report: expected fire count per day, top triggering hosts/users, how many hits map to known incidents (true positives) vs. benign.
  3. Target: < 5 alerts/day per rule unless it is a high-fidelity critical rule; FP rate estimate stated explicitly.

FP tuning

Prefer narrowing by behaviour (parent process, command-line pattern, frequency) over broad allowlists. Every exclusion documents who/what is excluded and why; never exclude by a value an attacker controls easily (e.g. username alone).

Coverage

Use get_wazuh_rules_summary and existing alert data to note which ATT&CK techniques the environment already detects; state how the proposal changes coverage.

Output

  • propose_detection(title, rule_format="sigma"|"wazuh_xml", rule_body, rationale, mitre) where rationale contains the ADS sections and backtest results.
  • add_finding on the originating case titled Detection proposal: <title>, or save_report(kind="detection", ...) for batch reviews. standard_refs: SIGMA, MITRE-ATTACK:<id>, NIST-CSF-2:DE.CM.

常见问题

Detection Engineering AI 技能有什么作用?

将检测规则作为代码进行设计、回测和调优:编写符合 ADS 文档规范且覆盖 ATT&CK 的 Sigma 或 Wazuh 规则,并通过 propose_detection 提交人工审核;用于填补检测盲区、处理反复出现的误报,或应对在狩猎和事件处理中发现的新 TTP。

为什么在 TypingMind 中使用 Detection Engineering?

因为您只需安装一次,就能搭配任何模型使用。Detection Engineering 采用纯 Markdown 格式,而非特定提供商专用的代码,因此同一技能可用于 GPT-5、Claude、Gemini、Grok 或本地模型。您甚至可以在聊天中途切换模型,而不会影响技能的正常使用。TypingMind 使用您自己的 API 密钥,因此您直接向提供商付费,而不是按席位订阅;您的技能和聊天记录也都保留在您自己的存储空间中。

如何在 TypingMind 中安装 Detection Engineering?

在 TypingMind 中打开“插件 → 技能 → 从 GitHub 安装”,然后粘贴 https://github.com/gensecaihq/Wazuh-Autopilot/tree/main/backend/app/skills/detection-engineering。TypingMind 会读取其中的 SKILL.md,并将其安装为技能,供您在各个聊天中按需启用。

哪些 AI 模型可以使用 Detection Engineering?

您在 TypingMind 中连接的任何模型都可以。AI 技能采用纯 Markdown 指令,而非特定提供商专用的代码,因此 GPT、Claude、Gemini、Grok 和本地模型都能在请求匹配时加载此技能。

Detection Engineering 可以搭配多少个 AI 模型使用?

数量不限。只要模型支持技能,您就可以将它与 Detection Engineering 搭配使用。GPT、Claude、Gemini、Grok、DeepSeek、Mistral、Llama 等模型都可以通过您自己的 API 密钥接入 TypingMind。

Detection Engineering AI 技能免费吗?

是的。gensecaihq 已在 GitHub 上根据 MIT 许可证发布了该技能。您只需向自己的 AI 提供商支付所用 Token 的费用。

什么是 AI 技能?

AI 技能是一组可复用的指令,用于教会 AI 模型完成某项特定任务。它遵循开放的 Agent Skills 格式:包含名称和描述的 SKILL.md 文件,以及模型可能需要的脚本、模板或参考文件。模型仅在您的请求与技能匹配时才会读取这些指令,因此已安装的技能在使用前不会产生任何费用。

AI 技能与插件或 MCP 服务器有何不同?

插件或 MCP 服务器为模型提供可调用的新工具,也就是在某处运行并返回结果的代码。AI 技能则为模型提供知识和流程:如何处理任务、遵循哪些步骤,以及怎样的输出才算优质。技能采用纯 Markdown 格式,因此不需要服务器、API 密钥或运行时环境,并且适用于任何模型。

查看全部

立即创建您自己的 AI 工作区

订阅我们的电子简报,获取新功能和后续赠奖活动的通知 👇