HR Support AI Agent

Agent Description:

The HR Support AI Agent provides employees with an efficient self-service tool for HR inquiries and requests. It utilizes a KB Search Agent to query an SQL knowledge base and determine whether a query is informational or requires a specific HR action. If informational, the agent provides a direct, human-readable response. If an action is required, the Jira & Response Agent automatically creates a trackable Jira ticket using the task details, retrieves the ticket ID, and confirms the action to the employee. This dual capability ensures quick access to policy information and reliable tracking for task-based requests.

Purpose and Components
  • Purpose: To provide employees with a self-service tool for HR-related questions and requests, automating responses for informational queries and creating trackable tickets for tasks requiring HR action.
  • Components:
    • Knowledge Base Search Agent: An agent to query an internal HR SQL database based on employee questions.

    • Response & Jira Agent: An agent that either provides a direct answer based on the KB search or creates a Jira ticket if the query requires an HR task.

    • SQL Database Toolkit: A tool to interact with the (SQLite) HR knowledge base.

    • Jira Integration (Implicit): Capability within the second agent to create Jira tickets.

Supported Capabilities
  • Accepting user queries about HR policies or requests in natural language.

  • Normalizing queries (lowercase, remove punctuation) for effective searching.

  • Searching an HRKnowledgeBase SQL table for relevant answers or task descriptions.

  • Retrieving key information: Document ID, Title (Question), Content (Answer), and whether a task is required (TaskRequired).

  • If a query requires an action (TaskRequired = yes), extracting the TaskSummary and TaskDescription.

  • Providing human-readable answers directly if the query is informational (TaskRequired = false).

  • Automatically creating a Jira ticket using the TaskSummary and TaskDescription if an action is needed.

  • Retrieving the created ticket_id and ticket_url.

  • Returning a comprehensive response including the human-readable answer, supporting document info, and the Jira ticket details (if created).

  • Handling cases where no answer is found by suggesting the user contact HR directly.

LLM Used
  • GPT_4O_MINI

    Note: To learn more about the LLM and to modify its behavior, refer to the Configuring LLM settings section.

Sub-Agents

1. KB Search Agent

  • Role: Data Reader

  • Scope: Search the HR Knowledge Base for relevant answers or task requirements.

  • Description: This agent receives the employee's natural language query. It normalizes the text and uses the SQL toolkit to search the HRKnowledgeBase table for the best match. It retrieves the answer content and determines if the query requires a follow-up task (TaskRequired). It then forwards this structured information (including task details if needed) to the next agent.

  • LLM Used: Default (Inherits from parent agent).

  • Tools Used: SQL - Toolkit

2. Jira and Response Agent

  • Role: Query Responder

  • Scope: Generate human-readable answers for direct queries. Automatically create Jira tickets for actionable tasks.

  • Description: This agent receives the search results from the KB Search Agent. If no answer was found, it informs the user to contact HR. If an answer was found and no task is required (TaskRequired = false), it formats the answer into a human-readable response. If a task is required (TaskRequired = true), it uses the provided TaskSummary and TaskDescription to create a Jira ticket (implicitly, no tool listed but functionality described), retrieves the ticket ID/URL, and then provides both a human-readable confirmation and the structured details (answer, supporting docs, ticket info) as the final output.

  • LLM Used: Default (Inherits from parent agent).

  • Tools Used: None (Implicit Jira creation)

Tools Used:
  • SQL - Toolkit (SQLite): Executes queries against a SQLite database (HRKnowledgeBase) to find answers to employee questions.

Note: For details on modifying the Tools, refer Tools Library section.
Agent Workflow Behavior Summary
  1. An employee submits a query (e.g., "How do I request parental leave?").

  2. The KB Search Agent (start node) receives the query, normalizes it, and uses the SQL - Toolkit to search the HRKnowledgeBase.

  3. It retrieves the best matching answer and checks if a TaskRequired flag is set. It passes this structured data (answer, task info) to the next agent.

  4. The Jira & Response Agent (end node) receives the data.

  5. If TaskRequired is false, it formats the answer and sends it to the user.

  6. If TaskRequired is true, it creates a Jira ticket, gets the ticket details, and then sends a response to the user including the answer, supporting document info, and the Jira ticket ID/URL.

  7. If no match was found in step 3, it informs the user to contact HR.

Sample Questions:
  • What is the company policy on sick leave?

  • Where can I find the employee handbook?