AI Agent Studio: How to Fetch Dynamic Incident Fields Based on User Prompts in Now Assist?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
54m ago
Hi Everyone,
I am trying to build my first AI Agent using AI Agent Studio in ServiceNow. My objective is to fetch incident details through the Now Assist chatbox, based on what the user asks in the prompt.
For example, the user might ask for the priority of an incident, a summary of its description, work notes, assignment group, or any other field.
To achieve this, I am creating a tool and selecting Record Operation as the tool type, with the following configuration:
- Table: Incident
- Operation: Look up records
However, I am required to specify two fields: Max records returned and Returned fields.
I am unsure how to configure these fields because I want the agent to retrieve the relevant incident information dynamically based on the user's question, rather than specifying a fixed list of fields in advance.
For example, if the user asks for the priority, the agent should return the priority; if the user asks for work notes, it should return the work notes.
How can I achieve this dynamic behavior using the Record Operation tool? If this tool does not support it, what would be the recommended approach in AI Agent Studio?
Any guidance or examples would be greatly appreciated.
Thank you!
