﻿---
title: Identify, investigate, and document threats
description: Together, Attack Discovery and Elastic Agent Builder can help you identify and mitigate threats, investigate incidents, and generate incident reports...
url: https://docs-v3-preview.elastic.dev/elastic/docs-content/pull/9139/solutions/security/ai/identify-investigate-document-threats
products:
  - Elastic Cloud Serverless
  - Elastic Documentation
  - Elastic Security
applies_to:
  - Serverless Security projects: Generally available
  - Elastic Stack: Generally available
---

# Identify, investigate, and document threats
Together, [Attack Discovery](https://docs-v3-preview.elastic.dev/elastic/docs-content/pull/9139/solutions/security/ai/attack-discovery) and [Elastic Agent Builder](https://docs-v3-preview.elastic.dev/elastic/docs-content/pull/9139/solutions/security/ai/agent-builder/agent-builder) can help you identify and mitigate threats, investigate incidents, and generate incident reports in various languages so you can monitor and protect your environment.
In this guide, you'll learn how to:
- [Use Attack Discovery to identify threats](#use-case-incident-reporting-use-attack-discovery-to-identify-threats)
- [Use Elastic Agent Builder to analyze a threat](#use-case-incident-reporting-agent-builder-analyze)
- [Document the incident in a case](#use-case-incident-reporting-agent-builder-case)
- [Translate incident information to a different language](#use-case-incident-reporting-agent-builder-translate)

If you use AI Assistant, refer to [Use AI Assistant (deprecated)](#use-case-incident-reporting-ai-assistant).

## Use Attack Discovery to identify threats

Attack Discovery can detect a wide range of threats by finding relationships among alerts that may indicate a coordinated attack. This enables you to comprehend how threats move through and affect your systems. Attack Discovery generates a detailed summary of each potential threat and can highlight avenues for further investigation. Learn how to [get started with Attack Discovery](https://docs-v3-preview.elastic.dev/elastic/docs-content/pull/9139/solutions/security/ai/attack-discovery).
<important>
  To ensure that Attack Discovery analyzes related alerts together (and can therefore identify their connections), pay attention to the [alert filtering](https://docs-v3-preview.elastic.dev/elastic/docs-content/pull/9139/solutions/security/ai/attack-discovery) settings. This allows you to target Attack Discovery at specific groups of alerts, such as those related to a particular host, user, date and time, incident, or customer.
</important>

![An Attack Discovery card showing an attack with 11 related alerts](https://docs-v3-preview.elastic.dev/elastic/docs-content/pull/9139/solutions/images/security-attck-disc-11-alerts-disc.png)

In this example, Attack Discovery found connections between thirteen alerts, and used them to identify and describe an attack chain.
After Attack Discovery outlines your threat landscape, use AI chat to analyze a threat in detail.

## Use Elastic Agent Builder to analyze a threat

<applies-to>
  - Serverless Security projects: Generally available
  - Elastic Stack: Generally available since 9.4
</applies-to>

To start a conversation with a discovery as context, click **Add to chat** on a discovery on the **Attack Discovery** page. <applies-to>Elastic Stack: Generally available since 9.5, Elastic Stack: Preview in 9.4</applies-to> <applies-to>Elastic Cloud Serverless: Generally available</applies-to> Or, from the [**Attacks** view](https://docs-v3-preview.elastic.dev/elastic/docs-content/pull/9139/solutions/security/ai/attack-discovery/manage-discoveries-from-attacks-page), select **Take actions** → **Add to chat** on an attack.
The [Elastic AI Agent](/elastic/docs-content/pull/9139/explore-analyze/ai-features/agent-builder/builtin-agents-reference#elastic-ai-agent) can compile essential data and suggest next steps to help you plan an effective response. Ask it questions such as:
- "How can I remediate this threat?"
- "What ES|QL query would isolate actions taken by this user?"
- "What are the risk scores for the hosts and users involved?" (requires [entity risk scoring](https://docs-v3-preview.elastic.dev/elastic/docs-content/pull/9139/solutions/security/advanced-entity-analytics/entity-risk-scoring))

The agent uses [Security skills](https://docs-v3-preview.elastic.dev/elastic/docs-content/pull/9139/solutions/security/ai/agent-builder/skills-use-cases) such as `alert-analysis`, `entity-analytics`, and `threat-hunting` to answer. To learn more about using Elastic Agent Builder for ES|QL, refer to [Generate, customize, and learn about ES|QL queries](https://docs-v3-preview.elastic.dev/elastic/docs-content/pull/9139/solutions/security/ai/generate-customize-learn-about-esorql-queries).
<applies-to>Elastic Stack: Generally available since 9.5</applies-to> <applies-to>Elastic Cloud Serverless: Generally available</applies-to> You can also start in chat and have the agent run Attack Discovery for you, for example "Investigate lateral movement involving host-12 over the last 24 hours." Refer to [Run Attack Discovery from Elastic Agent Builder](https://docs-v3-preview.elastic.dev/elastic/docs-content/pull/9139/solutions/security/ai/attack-discovery/run-attack-discovery-from-agent-builder).

## Document the incident in a case

<applies-to>
  - Serverless Security projects: Generally available
  - Elastic Stack: Generally available since 9.4
</applies-to>

[Cases](https://docs-v3-preview.elastic.dev/elastic/docs-content/pull/9139/solutions/security/investigate/security-cases) centralize relevant details in one place for easy sharing with stakeholders. To add a discovery and its alerts to a case, select **Take action** → **Add to new case** or **Add to existing case** on the discovery. <applies-to>Elastic Stack: Generally available since 9.5, Elastic Stack: Preview in 9.4</applies-to> <applies-to>Elastic Cloud Serverless: Generally available</applies-to> Or, on the **Attacks** view, select **Take actions** → **Add to new case** or **Add to existing case** on the attack.
Ask the agent for an incident report, remediation steps, or a summary, then add them to the case.
<applies-to>Elastic Stack: Preview since 9.5</applies-to> <applies-to>Elastic Cloud Serverless: Preview</applies-to> You can also ask the agent to create the case or add its findings to an existing one, for example "Add these remediation steps as a comment on the case for this attack." The agent uses the [`cases-management`](/elastic/docs-content/pull/9139/explore-analyze/ai-features/agent-builder/builtin-skills-reference#agent-builder-cases-management-skill) skill.

## Translate incident information to a different language

<applies-to>
  - Serverless Security projects: Generally available
  - Elastic Stack: Generally available since 9.4
</applies-to>

The agent can translate its findings into other human languages, helping to enable collaboration among global security teams, and making it easier to operate within multilingual organizations.
After the agent provides information in one language, ask it to translate its response. For example, if it provides remediation steps for an incident, ask it to "Translate these remediation steps into Japanese." You can then add the translated output to a case.
<note>
  All LLMs can make mistakes, so review translations before you share them.
</note>


## Use AI Assistant (deprecated)

<applies-to>
  - Serverless Security projects: Deprecated
  - Elastic Stack: Planned for deprecation
  - Elastic Stack: Generally available from 9.0 to 9.5
</applies-to>


### Use AI Assistant to analyze a threat

From a discovery on the **Attack Discovery** page, click **View in AI Assistant** or **Add to chat** to start a chat that includes the discovery as context.
![A dialog with AI Assistant that has the discovery as context](https://docs-v3-preview.elastic.dev/elastic/docs-content/pull/9139/solutions/images/security-attck-disc-remediate-threat.gif)

AI Assistant can quickly compile essential data and provide suggestions to help you generate an incident report and plan an effective response. You can ask it to provide relevant data or answer questions, such as “How can I remediate this threat?” or “What ES|QL query would isolate actions taken by this user?”
![An AI Assistant dialog in which the user asks for a purpose-built ES|QL query](https://docs-v3-preview.elastic.dev/elastic/docs-content/pull/9139/solutions/images/security-attck-disc-esql-query-gen-example.png)

This image shows an ES|QL query generated by AI Assistant in response to a user prompt. Learn more about [using AI Assistant for ES|QL](/elastic/docs-content/pull/9139/solutions/security/ai/generate-customize-learn-about-esorql-queries#esql-queries-ai-assistant).
At any point in a conversation with AI Assistant, you can add data, narrative summaries, and other information from its responses to Elastic Security's case management system to generate incident reports.

### Generate reports

From the AI Assistant dialog window, click **Add to case** (![Add to case icon](https://docs-v3-preview.elastic.dev/elastic/docs-content/pull/9139/solutions/images/security-icon-add-to-case.png "title")) next to a message to add the information in that message to a [case](https://docs-v3-preview.elastic.dev/elastic/docs-content/pull/9139/solutions/security/investigate/security-cases). Cases help centralize relevant details in one place for easy sharing with stakeholders.
If you add a message that contains a discovery to a case, AI Assistant automatically adds the attack summary and all associated alerts to the case. You can also add AI Assistant messages that contain remediation steps and relevant data to the case.

### Translate incident information to a different human language using AI Assistant

![An AI Assistant dialog in which the assistant translates from English to Japanese](https://docs-v3-preview.elastic.dev/elastic/docs-content/pull/9139/solutions/images/security-attck-disc-translate-japanese.png)

AI Assistant can translate its findings into other human languages, helping to enable collaboration among global security teams, and making it easier to operate within multilingual organizations.
After AI Assistant provides information in one language, you can ask it to translate its responses. For example, if it provides remediation steps for an incident, you can instruct it to “Translate these remediation steps into Japanese.” You can then add the translated output to a case. This can help team members receive the same information and insights regardless of their primary language.
<note>
  In our internal testing, AI Assistant translations preserved the accuracy of the original content. However, all LLMs can make mistakes, so use caution.
</note>