Run GPTfy using AI Mass Processing

Picture of Kalanithi Balasubramanian

Kalanithi Balasubramanian

Updated on April 10, 2024

This article outlines the steps to configure the product for running prompts on records in a batch process and scheduling these processes.

Step 1: Create a New AI Mass Processing by clicking on the New button

  • Select the AI Mass Processing tile from Cockpit.
  • Begin by initiating the creation of a new scheduler. Locate and click the “New” button within the GPTfy interface.
  • Depending on the selected frequency, the scheduled time format will adjust accordingly.

Step 2: Add a New prompt scheduler

  • Proceed to add a new prompt scheduler by selecting the “New” option.

Query Builder: A tool that helps you create a where clause to filter out the specific records. No need to learn complex SOQL syntax!

Cross Object Filters – This is the query builder that helps to qualify the Parent record for processing according to the child record. Users can define the conditions on child records. On that basis, parent records will be qualified.

For example, suppose the account is the parent object, and then the user can add the condition to qualify the account record where the respective contact having the department is banking.

The COFi filters* will be added to the related objects, and the parameters below have to be added by opening the prompt scheduler record.

*COFi filters act like checkpoints to ensure only the intended tasks are processed. You can configure them to consider specific data points (like date, priority, or other relevant attributes) and define conditions those points must meet for a task to proceed.

  • Sequence: This number determines the order in which multiple COFi filters are applied. Lower sequence numbers are processed first.

  • Operator: This specifies the condition for records to meet for the filter to pass.

  • Qualify Count: This number indicates how many conditions within the filter’s Where Clause (explained below) need to be met for the filter to pass.

  • Where Clause: This clause defines the specific criteria for filtering the data. It’s likely written in a query language and specifies which data points should be considered based on the chosen operator and qualify count.


The following screenshot shows the above scenario in Cross Object Filter.

So, after saving the cross-object Filter, the Prompt Scheduler looks like the below

Step 3: Execute the Mass Processing

  • Click the “Run Now” button to initiate an immediate execution of the Mass Processing.
    The Mass Process will trigger the execution of the associated Apex job.
    This action will create a scheduled run record based on the number of records in for each prompt scheduler.
    Navigate to the related list on the scheduled run record to access additional information.
    Verify the response records that have been generated.

Retry Count – Handling Errors

  • If any errors occur during the process, the status will be marked as “Errored.”

  • Depending on the retry count, the system will reprocess the errored records, and the error message will be cleared.