Add a Knowledge Graph to an AI agent
Add a Knowledge Graph to an AI agent in AI Agent Studio that uses the structured and unstructured data from different ServiceNow records to enhance the performance of AI agents.
Before you begin
Role required: sn_aia.admin
Procedure
- Navigate to All > AI Agent Studio > Create and manage > AI agents.
- Select New or open the AI agent that you want to add a Knowledge Graph to and navigate to the Add tools and information section.
-
In the Add tool drop-down list, select Knowledge graph.
You may have to scroll down.
-
On the form, fill in the fields.
Table 1. Add a Knowledge Graph form Fields Description Name Name that you want to specify for your selected Knowledge Graph.
Description Description of the Knowledge Graph and what it’s going to do to assist your AI agent. Note:This description is sent to the large language model (LLM).Select Knowledge Graph Existing Knowledge Graph to be added to the AI agent. If there is a tool used by an AI agent for the same Knowledge Graph, the rest of the form will populate the fields based on the other tool. You can make any changes specific to the current AI agent to suit your needs, and it will not affect the tool of the existing AI agent.
You can utilize Enterprise Graph and Enterprise Graph (Small) as Knowledge Graph resources while creating the Knowledge Graph tool.
Query instruction The search query. Translate your request into a search query, including a verb. The query instruction is passed on to the LLM to generate a structured query for the Graph from the inputs selected in the tool form.
Execution mode Mode of execution for your selected Knowledge Graph: - Supervised: Inputs from your human agent are required during the execution of this Knowledge Graph while the AI agent runs.
- Autonomous: Doesn't require any input from your live agent during the execution of this Knowledge Graph while the AI agent runs.
Display output Permission to display the output of the execution in the Now Assist panel or in Virtual Agent: - Yes
- No
If you want the AI agent to work in Off Glide architecture with Premium Chat experience, you must turn-on the Display output toggle. When the toggle is turned-on, you can add widgets that can be used in assistants built with Premium Chat experiences. The widget configuration includes:- Widget: Defines the display output to render the content in a better user experience. You can select the widget from the drop-down.
- Require widget transformation: An additional LLM call is required to transform the raw tool. If you choose to skip this transformation step, the tool output will be
directly mapped to the widget.
- Yes
- No
- Display refined widget message: Refines the widget message when configured.
- Yes
- No
Note:The display output as a toggle is exclusively available for the Premium Chat experience when the Off Glide Conversation Server plugin (com.glide.cs.offglide) is installed. If the plugin is not installed, you will continue to access the standard display output options.Advanced settings Select an output transformation format Style for the LLM to present the results as it passes information between tools and to other agents. Out transformation formats: - None
- Concise
- Paragraph
- Summary
- Custom
Write processing messages for users Message to display to users during tool execution. - In-progress message: Write an in-progress message to be displayed to end-users while the tool is running.
- Completion message: Write a completion message to be displayed to end-users once the tool finishes running.
-
Select Add.
The Knowledge Graph tool is added to the AI agent.