-
Notifications
You must be signed in to change notification settings - Fork 135
AI Assistant Knowledge Base walkthrough #2616
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
benironside
merged 17 commits into
main
from
2529-assistant-knowledge-base-usecase-walkthrough
Aug 21, 2025
Merged
Changes from 13 commits
Commits
Show all changes
17 commits
Select commit
Hold shift + click to select a range
8237847
first complete draft (bad)
benironside 9e0d286
adds new file to ToC
benironside 5a769a5
Merge branch 'main' into 2529-assistant-knowledge-base-usecase-walkth…
benironside 111e50c
fixes build error, other updates
benironside 70ea3e1
Merge branch '2529-assistant-knowledge-base-usecase-walkthrough' of h…
benironside 5c758f7
adds new data upload method
benironside 348fdb8
minor fixes
benironside 056c4e1
Many updates. Almost ready for review
benironside 39af712
Update usecase-knowledge-base-walkthrough.md
benironside c8a3025
fixes tag
benironside 7d143d9
Merge branch 'main' into 2529-assistant-knowledge-base-usecase-walkth…
benironside 1eb2474
updates applies to formatting
benironside db1a62e
adds related link
benironside 761a28b
Apply suggestions from code review
benironside f4b08bf
incorporates reviews
benironside 8189b82
Merge branch 'main' into 2529-assistant-knowledge-base-usecase-walkth…
benironside d325100
Merge branch 'main' into 2529-assistant-knowledge-base-usecase-walkth…
benironside File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
72 changes: 72 additions & 0 deletions
72
solutions/security/ai/usecase-knowledge-base-walkthrough.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
--- | ||
applies_to: | ||
stack: ga 9.1 | ||
serverless: | ||
security: all | ||
products: | ||
- id: security | ||
--- | ||
|
||
|
||
# Use AI Assistant's Knowledge Base to improve response quality | ||
|
||
You can use AI Assistant's Knowledge Base to give it information on anything from threat hunting playbooks, to on-call rotations, security research, infrastructure information, your team's internal communications from platforms like Slack or Teams, and more — constrained only by your creativity. This page guides you through an example of how to ingest data from various sources into AI Assistant's Knowledge Base, and shows how this can improve the quality of its responses in a threat response scenario. | ||
benironside marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
## Prerequisites | ||
|
||
Before attempting to follow this guide, review the [Knowlege Base](/solutions/security/ai/ai-assistant-knowledge-base.md) topic for general information and prerequisites, and [enable Knowledge Base](/solutions/security/ai/ai-assistant-knowledge-base.md#enable-knowledge-base). | ||
benironside marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
## Add relevant data from various sources to Knowledge Base | ||
|
||
AI Assistant is more useful for incident response when it can access information about your organization's specific infrastructure, threat hunting playbooks, personnel, and processes. How you can add this data to Knowledge Base depends on its format and structure. This section provides several examples of useful data and how to add it. | ||
|
||
### Add your Slack messages to Knowledge Base | ||
|
||
You can add messages from Slack channels to Knowledge Base using the Slack content connector. For instance, if you have a Slack channel that contains information about ongoing incidents, you could include that information in Knowledge Base to give AI Assistant more context about what your security team is dealing with. | ||
|
||
1. Use the [global search field](/explore-analyze/find-and-organize/find-apps-and-objects.md) to find "Content connectors". Click **+ New Connector** to open the **Create a connector** interface. | ||
2. Follow the steps to [create a content connector](/solutions/security/get-started/content-connectors.md). This ingests your selected data into {{es}}. During setup, select `Slack`, and configure the connector to ingest your desired data. | ||
benironside marked this conversation as resolved.
Show resolved
Hide resolved
|
||
3. Follow the instructions to [add an index to Knowledge Base](/solutions/security/ai/ai-assistant-knowledge-base.md#). Select the index you created while setting up your new connector. | ||
|
||
### Add your on-call rotation to Knowledge Base | ||
|
||
If you add information about who is responsible for security incidents at different dates and times to Knowledge Base, AI Assistant can help you quickly follow the correct escalation protocol for potential threats. | ||
|
||
If information about your on-call rotation is contained in a file, you can follow the steps to [add an individual file](/solutions/security/ai/ai-assistant-knowledge-base.md#add-specific-file) to Knowledge Base. | ||
|
||
However, you can also copy and paste the information to directly [add it as a markdown document](/solutions/security/ai/ai-assistant-knowledge-base.md#knowledge-base-add-knowledge-document). Adding it as a markdown document is fast, and easy to update when the on-call rotation changes. | ||
benironside marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
:::{image} /solutions/images/security-knowledge-base-add-on-call-rotation.png | ||
:alt: Knowledge base's Edit document entry menu showing a snippet of an on call rotation document | ||
::: | ||
|
||
Whichever method you use to add the information to Knowledge Base, consider making it **Required knowledge**. This will ensure that all of AI Assistant's responses are informed by the on-call rotation, even if your prompt doesn't specify that the information is relevant. This makes it more likely that AI Assistant will suggest appropriate escalation steps when you ask it about a threat. | ||
|
||
### Add your threat hunting playbooks to Knowledge Base | ||
|
||
If you have threat hunting playbooks stored in a GitHub repository, you can add them to Knowledge Base using the GitHub content connector. This enables AI Assistant to tell your team about your organization's standard practices for responding to a wide range of potential threats. | ||
benironside marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
1. Use the [global search field](/explore-analyze/find-and-organize/find-apps-and-objects.md) to find "Content connectors". Click **+ New Connector** to open the **Create a connector** interface. | ||
2. Follow the steps to [create a content connector](/solutions/security/get-started/content-connectors.md). This ingests your selected data into {{es}}. During setup, select `GitHub`, and configure the connector to ingest your desired data. | ||
benironside marked this conversation as resolved.
Show resolved
Hide resolved
|
||
3. Follow the instructions to [add an index to Knowledge Base](/solutions/security/ai/ai-assistant-knowledge-base.md#). Select the index you created while setting up your new connector. | ||
|
||
## Use Knowledge Base in conversations | ||
|
||
AI Assistant will use the information you've added to Knowledge Base to inform its responses to your prompts. With the information we've added in this example, you can ask questions like: | ||
benironside marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
- Is this alert related to any ongoing incidents? | ||
- Who should I contact to escalate this potential threat? | ||
- What should I do to respond to this threat? | ||
|
||
Be creative, and experiment with adding different types of information to optimize AI Assistant for your team's purposes. | ||
|
||
## Video demo: investigate an Attack Discovery using AI Assistant's Knowledge Base | ||
|
||
The following video demo starts with a potential threat identified using Attack Discovery, and shows how the information you've added to Knowledge Base greatly increases AI Assistant's ability to help guide your team's incident response (click to play video): | ||
|
||
[](https://videos.elastic.co/watch/SGrcygEFBCEJRURGjR8sMh?) | ||
|
||
## Additional Resources | ||
|
||
- Learn more about [Knowledge Base](https://www.elastic.co/guide/en/security/current/ai-assistant-knowledge-base.html) | ||
- Learn to [Ingest data with Elastic connectors](https://www.elastic.co/guide/en/elasticsearch/reference/current/search-connectors.html) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.