RFQ Insurance Agent Resources

Challenge Page Link

The original challenge page for the RFQ Insurance Agentic Quest. It contains both the original challenge resource page and the mailbox used to start the process.

https://pathfinder.automationanywhere.com/challenges/insurance-rfq-challenge-ai.html

1. Create and Map AI Skill in API Task

Objective:

Create new output variables for the insurance RFQ data and map the AI Skill output to those variables.

Steps:

  1. 1. Navigate to the Tools/Prompts folder and open the Extraction AI Skill.
  2. 2. Update the AI Skill to use the following prompt in the User Prompt:
    
    Extract the following information from the Email Body.
    
    
    
    1. RFQ Number: This is the unique request for quote number.
    2. Policy Category: The category of the insurance policy.  This can be either "Business" or "Personal"
    3. Policy Type: The specific type of insurance policy being discussed, such as "Auto Insurance", "Cyber Liability Insurance" or "Commerical Property Insurance".
    4. Coverage Amount: The total coverage amount specified for the insurance policy, only include the number with no currency sign or additional formatting. 
    5. Policy Start Date: The time frame given for when the policy will begin, such as "2 Months", "5 Months", etc. 
    6. Policy Duration: How long the policy will remain active in a year value labelled with year(s). Examples: 12 Months Duration will have a value of "1 year".  6 month duration would be ".5 years".
    
    Return a JSON in the following format
    
    {"rfq_number": "RFQ NUMBER", 
      "policy_category": "CATEGORY", 
      "policy_type": "POLICY TYPE", 
      "coverage_amount": "COVERAGE AMOUNT", 
      "policy_start_date": "POLICY START DATE", 
      "Policy_Duration": "POLICY DURATION"}
    
    Do not provide any other text or markdown.  Only repsond with the valid JSON.
    
    Email Body: $EmailText$
                    
  3. 3. Update the default value for your Prompt Input with the body of an RFQ email to test it. Otherwise just add any value. Click save.
  4. 4. Open the ExtractionAPI API Task in the tools folder.
  5. 5. Update the description of the API Task to: This tool extracts and structures the relevant information for the current RFQ.
  6. 6. On line 1, you will need to drag an AI Skill here. Make sure you drop this on line 1, before the JSON:Start Session. Click choose and locate the just-built AI Skill named Extraction.
  7. 7. Select the input variable for the body of the email: $RFQEmailBody$ and pass this into the AI Skill as the input variable.
  8. 8. Map the AI Skill response to the variable called ExtractedRFQData.
  9. 9. Click save to apply the changes.

2. Create Win Probability Variables and business rules

Objective:

Complete the WinProbabilityChecker tool integration to determine the win probability of the insurance RFQ. The inputs are already complete, we only need to handle the outputs.

Steps:

  1. 1. Find and open the Task Bot named WinProbabilityChecker in the Tools folder.
  2. 2. Add the following variables as Outputs with their descriptions
    • a. Number Variable: WinProbabilityNumber: The calculated win probability as a decimal number (0.0 to 1.0)
    • b. String Variable: WinProbabilityRank: The probability ranking category (low, medium, high)
  3. 3. Below line 7, we need to add a Number:Assign to Cast the output from the JavaScript function to a number and map it to the WinProbabilityNumber variable. For this, for the source variable enter: $winprobstring.String:toNumber$ And save the response to WinProbababilityNumber, the variable you created.
  4. 4. Use IF-THEN logic to calculate the WinProbabilityRank based on the WinProbabilityNumber, make sure your ranks are identical to how they are below:
    • • If WinProbabilityNumber < 0.33, set WinProbabilityRank to "Low"
    • • Else if WinProbabilityNumber < 0.66, set WinProbabilityRank to "Medium"
    • • Else set WinProbabilityRank to "High"
  5. 5. Update the description of the task bot to: This tool calculates the win probability of the current RFQ
  6. 6. Click save to apply the changes.

3. Update RFQInput to update the prioritization engine

Objective:

Update the input variables for RFQInput and map them to the Recorder Actions with If-Then logic.

Steps:

  1. 1. Open the RFQInput Task Bot tool in the Tools folder.
  2. 2. Add the following variables as Inputs with their descriptions
    • a. WinLikelihoodRank: The probability ranking category (low, medium, high)
    • b. Justification: The reasoning behind the win probability and profitability calculations
  3. 4. Add two recorder actions and clone them in the RFQ input window. The first is the Likelihood of Winning Business drop down. The second is the Justification. To do this, you must open the Challenge Page window and then clone the page using the Recorder Package. NOTE: It is recommended use chose 1ms delay for text inputs for Justification. Map the input variables accordingly.
  4. 5. Click save to apply the changes.

4. Configure RFQ Insurance Agent with Tools

Objective:

Configure the RFQ Insurance Agent by adding tools and setting up the action plan to process RFQs from highest to lowest profitability.

Steps:

  1. 1. Open the RFQInsuranceAgent and navigate to the tools menu.
  2. 2. Add an API Task tool using the Add Tool button.
  3. 3. Locate the ExtractionAPI Tool and select it for the tool.
  4. 4. Repeat this process for the Win Probability tool, but using a task bot.
  5. 5. Repeat this process for the RFQ Input tool, but using a task bot.
  6. 6. Click Generate and experience the agent writing its own Role, Goal, and Action Plan.
  7. 7. Edit the Role, Goal, and Action Plan using the details below.
  8. Role:
  9. You are a procurement analyst specializing in RFQ data processing and prioritization.
  10. Goal:
  11. Your goal is to gather RFQs, structure and enrich their data using available tools, and input them into the batch form.
  12. Action Plan:
  13. # Assumptions
    - RFQs are available in the incoming mailbox.
    - Tools are accessible and functional for data extraction, enrichment, and submission.
    - Profitability is a key metric for prioritization.
    
    # Process
    1. Use the 'CollectRFQs' tool to gather all available RFQs from the mailbox.
    2. For each RFQ, use the 'ExtractionAPI' tool to extract and structure relevant data.
    3. Use the 'ProfitabilityCalculator' tool to calculate the profitability margin for each RFQ.
    4. Use the 'StrategicAlignment' tool to gather strategic alignment data for each RFQ.
    5. Use the 'WinProbabilityChecker' tool to calculate the win probability for each RFQ.
    6. Call the RFQInput tool one at a time to input the RFQs into the batch form, starting with the highest profitability number and going in descending order.
    7. Upon successful input of all RFQs into the batch form. Submit the batch using the 'FormSubmission' tool.
    
    # Guidelines
    - Ensure all extracted data is accurate and complete before proceeding to enrichment.
    - Ensure you do not mix RFQ data between RFQs.
    - Handle errors from tools gracefully and log any issues for troubleshooting.
    - Verify the batch form submission to confirm successful processing.
  14. 8. Click run to execute the agent with the configured tools.