Using AI agents in Virtual Agent topics

  • Release version: Zurich
  • Updated July 31, 2025
  • 2 minutes to read
  • Summarize
    Summarized using AI
    This content was generated using new OpenAI-powered functionality. Results are provided on an as is basis and are not guaranteed to be accurate or complete.

    Summary of Using AI agents in Virtual Agent topics

    This feature enables ServiceNow customers to incorporate AI agents within Virtual Agent topics to perform specific tasks, such as compiling information from Knowledge Base (KB) articles. AI agents are used through the AI Connector utility in the Virtual Agent Designer, allowing automated data retrieval and response generation within Virtual Agent conversations.

    Show full answer Show less

    How to Use AI Agents in Virtual Agent

    • Access AI agents via the AI Connector utility in Virtual Agent Designer.
    • Select the AI agent skill type and choose the specific AI agent from the available options.
    • Define the task by setting the Task input mapping variable, which can be a direct command or script (e.g., return KB00090; to retrieve a specific KB article).
    • The AI agent executes the task and returns output mappings automatically defined based on the agent type.

    Key Features

    • Integration with Now Assist AI agents, which may already be installed but not utilized in Virtual Agent topics.
    • Automatic generation of detailed execution plans that include the task objective, state, messages, and tools used.
    • Output mappings from AI agents provide comprehensive information such as execution plan ID, state, objective, state reason, messages, tasks performed, and tools involved.
    • Execution plans are stored in the Execution Plan [snaiaexecutionplanlist] table, enabling tracking and management of AI agent activities.

    Benefits for ServiceNow Customers

    By leveraging AI agents within Virtual Agent topics, customers can automate information gathering and task execution, enhancing Virtual Agent capabilities and improving user interactions. This integration allows for dynamic responses based on real-time data retrieval and task execution results, ultimately providing more accurate and context-aware assistance to end users.

    Use an AI agent custom skill to have it perform a task passed to it, such as compiling info on a KB article.

    There may be AI agents installed with the Now Assist application that are not used in use cases. To learn how to see all agents that are available to you, see Find AI agents.

    An AI agent performs a task that you pass to it inside the AI Connector utility in Virtual Agent Designer. For more information on the AI Connector utility, see AI Connector utility.

    For example, you can use the AI Agent in the AI Connector utility to get all data on a Knowledge Base article. The AI Agent provides the article if it is available or notifies you if it can't find it. The agent also provides data on the consolidation itself by way of its output mappings.

    To see which AI agents are installed on your instance, see Find AI agents.

    To use the AI agent, select it from the Skill type drop-down list in the AI Connector utility, then select the AI agent's type from the Select AI agent drop-down. For example, to have the AI agent consolidate a knowledge base article, select KB content consolidation AI agent.

    Define the task for the AI agent by placing a value in the Task input mapping variable. You can define a condition, or enter a script or command. For example, enter return KB00090; to have the AI agent retrieve that knowledge base article and consolidate its information into a reply in the Virtual Agent chat.

    The AI agent's output mapping properties are automatically defined when you select the AI agent type. All output mappings are returned in the chat when the AI agent completes the task.

    Select the AI agent and its task type inside the AI Connector utility.
    Table 1. AI agent output mapping properties
    Variable Description
    Execution plan ID ID number of the execution plan.
    Execution state Current state of the execution plan.
    Objective Intended task for the execution plan.
    State reason Reason for the execution plan's current state.
    Messages List of messages sent through the execution plan.
    Execution tasks List of tasks in the execution plan.
    Execution tools List of tools in the execution plan.

    When the AI agent performs its job, it generates the full plan showing the input and output mappings. Each plan shows the objective, all tasks performed for the objective, and any messages sent or tools used in the plan. All plans are listed in the Execution Plan [sn_aia_execution_plan_list] table.

    Execution plan for consolidating KB00090.