Prediction Input
- Properties
-
Name Type Description Required or Optional Available Version async Boolean Indicates whether the execution mode is async (true) or not (false). Optional 55.0 columnNames String[] Comma-separated list of column names representing the columns that the model analyzes. These are the features that are inputs to the model for predicting the scores. Optional 55.0 enableFeaturePersistence Boolean Indicates whether you want to persist the features (true) or not (false). Optional 55.0 enableInsightPersistence Boolean Indicates whether you want to persist the insights (true) or not (false). Optional 55.0 enableScorePersistence Boolean Indicates whether you want to persist the prediction scores (true) or not (false). Optional 55.0 enableSuggestionPersistence Boolean Indicates whether you want to persist the suggestions (true) or not (false). Optional 55.0 enrichModelClassification Boolean Indicates whether you want to retrieve the classification model type and the classification threshold (true) or not (false). Optional 55.0 enrichModelFeatures Boolean Indicates whether you want to retrieve the model feature details, including label and data type (true) or not (false). Optional 55.0 enrichPredictionDefinition Boolean Indicates whether you want to retrieve the prediction definition label (true) or not (false). Optional 55.0 featureColumnMap Map<String, String> Represents the map that contains which features must be persisted and where they must be persisted. The key-value pair must contain: - key—Feature name
- value—ResponseObjects (configured in the Admin UI setup).FieldName
Optional 55.0 featureExtractorDevName String The API name of the feature extractor record. Optional 55.0 featureExtractionParameters Feature Extraction Parameters Field Map Value[] Represents the input parameters that are required by the Feature Extractor to extract the features that a model requires to make the prediction. Supports a maximum of 200 records. Optional 55.0 featureExtractorId String The ID of the feature extractor record from the AIFeatureExtractor object. The specified feature extractor is used to extract the features for the prediction. For information on the custom feature extractor interface implementation, see CustomFeatureExtractor Interface.
Optional 55.0 historyReferencePoint String Represents a reference point for a comparison between current and previous prediction scores. Optional 55.0 inputType String The type of input used to make the prediction. Supports a maximum of 200 records. Possible values are:- Records—All the features for a model are present in the Salesforce database.
- RawData—All the features for a model are provided in the API request itself.
- RecordOverrides—The API reads a part of the features for the model from the Salesforce database by using the specified record Id. The remaining features are provided in the API request as raw data.
- ExtractedRawData—The API computes some or all the features for the model at runtime using the configured Feature Extractor, others can be passed as raw data in the API request.
- ExtractedRecordOverrides—The API computes some features for the model at run time by using the configured Feature Extractor. For the remaining features, the API refers to the Salesforce database through the specified record ID.
Required 55.0 insightColumnMap Map<String, String> Represents the map that contains which insight's Name/Value must be persisted, and to which object they must be persisted. The key-value pair must contain: - key—INSIGHT1.Name / INSIGHT1.Value (up to maximum of 3 insights Name/Value)
- value—ResponseObjects (configured in the Admin UI setup).FieldName
Optional 55.0 insightsSettings Map<String, Integer> A map for configuring insight settings. Here are the settings that contribute to the prediction score:- maxInsights—Maximum number of insights that you want the machine learning model to generate.
- maxSuggestionCount—Maximum number of suggestions that you want the machine learning model to generate.
- suggestionImpactMinimumPct—Minimum eligible percentage for improving the prediction score based on suggestions.
For more information, see Define Maximum Suggestions and Insights in the AI Accelerator Admin Guide.
Optional 55.0 predictionDefinition String The developer name or API name from the DiscoveryGoal object. Required 55.0 rawData Raw Data Input Wrap[] A two-dimensional array of row values in which each row is a comma-separated list of values for features provided in columnNames. Supports a maximum of 200 records. Optional 55.0 records String[] The IDs of the Salesforce record that is used as input features for model to make the prediction. Optional 55.0 scorePersistenceColumn String The name and value of the score that must be persisted, and to which object it must be persisted. The valid format is ResponseObject.FieldName. Optional. 55.0 suggestionColumnMap Map<String, String> Represents the map that contains which suggestions Name/Value must be persisted, and to which object they must be persisted. The key-value pair must contain: - key—SUGGESTION1.Name / SUGGESTION1.Value (maximum of 5 suggestions Name/Value)
- value—ResponseObjects (configured in the Admin UI setup).FieldName
Optional 55.0 usecaseDefinition String The ID of the usecase definition record from the AIUsecaseDefinition object. Optional 55.0 usecaseDevname String The API name of the usecase definition record. Required 55.0 - JSON example
- An example of inputType as Records.
1{ 2 "usecaseDevname": "AIUsecaseDefinitionIdentifier", 3 "predictionDefinition": "PredictionDefinitionIdentifier", 4 "inputType": "Records", 5 "records": { 6 "wrappedList": [ 7 "a00x0000000CHa0AAG" 8 ] 9 }, 10 "insightsSettings": { 11 "insightsSettings": { 12 "maxSuggestionCount": 1, 13 "maxInsights": 1, 14 "suggestionImpactMinimumPct": 0 15 } 16 }, 17 "insightColumnMap": { 18 "columnMap": { 19 "INSIGHT1.Name": "Demo__c.InsightName1Override__c", 20 "INSIGHT1.Value": "Demo__c.InsightValue1__c", 21 "INSIGHT1.Impact": "Demo__c.InsightImpact1__c" 22 } 23 }, 24 "suggestionColumnMap": { 25 "columnMap": { 26 "SUGGESTION1.Name": "Demo__c.RecommendationName1__c", 27 "SUGGESTION1.Value": "Demo__c.RecommendationValue1__c", 28 "SUGGESTION1.Impact": "Demo__c.RecommendationImpact1Override__c" 29 } 30 }, 31..”scorePersistenceColumn”:”Demo__c.Score__c”, 32..”enableInsightPersistence”:true, 33 "enableScorePersistence": true, 34..”enableSuggestionPersistence”:true, 35 "async": false 36} - An example of inputType as RawData.
1{ 2 "usecaseDevname": "AIUsecaseDefinitionIdentifier", 3 "predictionDefinition": "PredictionDefinitionIdentifier", 4 "inputType": "RawData", 5 "columnNames": { 6 "wrappedList": [ 7 "corp_year_week__c", 8 "sap_source_id__c", 9 "sap_ppg_id__c", 10 "sales_units__c" 11 ] 12 }, 13 "rawData": { 14 "rawData": [ 15 { 16 "rawDataInputWrap": { 17 "rawDataInput": [ 18 "202016", 19 "0YQx0000000CaS8GAK", 20 "01tx00000006j2DAAQ", 21 "20" 22 ] 23 } 24 }, 25 { 26 "rawDataInputWrap": { 27 "rawDataInput": [ 28 "202016", 29 "0YQx0000000CaS8GAK", 30 "01tx00000006j2DAAQ", 31 "20000" 32 ] 33 } 34 } 35 ] 36 }, 37 "featureColumnMap": { 38 "columnMap": { 39 "corp_year_week__c": "Demo__c.YearWeekFeature__c", 40 "sap_source_id__c": "Demo__c.StoreIdFeature__c", 41 "sap_ppg_id__c": "Demo__c.ProductIdFeature__c", 42 "sales_units__c": "Demo__c.SalesUnitsFeatureOverride__c" 43 } 44 }, 45 "enableFeaturePersistence": true 46} - An example of inputType as RecordOverrides.
1{ 2 "usecaseDevname": "AIUsecaseDefinitionIdentifier", 3 "predictionDefinition": "PredictionDefinitionIdentifier", 4 "inputType": "RecordOverrides", 5 "records": { 6 "wrappedList": [ 7 "a00x0000000CHa0AAG" 8 ] 9 }, 10 "columnNames": { 11 "wrappedList": [ 12 "corp_year_week__c", 13 "sap_source_id__c", 14 "sap_ppg_id__c", 15 "sales_units__c" 16 ] 17 }, 18 "rawData": { 19 "rawData": [ 20 { 21 "rawDataInputWrap": { 22 "rawDataInput": [ 23 "202016", 24 "0YQx0000000CaS8GAK", 25 "01tx00000006j2DAAQ", 26 "20" 27 ] 28 } 29 }, 30 { 31 "rawDataInputWrap": { 32 "rawDataInput": [ 33 "202016", 34 "0YQx0000000CaS8GAK", 35 "01tx00000006j2DAAQ", 36 "20000" 37 ] 38 } 39 } 40 ] 41 } 42} - An example of inputType as ExtractedRawData.
1{ 2 "usecaseDevname": "AIUsecaseDefinitionIdentifier", 3 "predictionDefinition": "PredictionDefinitionIdentifier", 4 "inputType": "ExtractedRawData", 5..”featureExtractorDevName”: “featureExtractorIdentifier”, 6 "featureExtractionParameters": { 7 "featureExtractionParameters": [ 8 { 9 "featureExtractionParametersMapValue": { 10 "recordId": "01tx00000006j2DAAQ1", 11 "rawData": { 12 "corp_year_week__c": "202016" 13 } 14 } 15 } 16 ] 17 }, 18 "enableFeaturePersistence": true 19} - An example of inputType as ExtractedRecordOverrides.
1{ 2 "usecaseDevname": "AIUsecaseDefinitionIdentifier", 3 "predictionDefinition": "PredictionDefinitionIdentifier", 4 "inputType": "ExtractedRecordOverrides", 5 "records": { 6 "wrappedList": [ 7 "a00x0000000CHa0AAG" 8 ] 9 }, 10..”featureExtractorDevName”: “featureExtractorIdentifier”, 11 "featureExtractionParameters": { 12 "featureExtractionParameters": [ 13 { 14 "featureExtractionParametersMapValue": { 15 "recordId": "01tx00000006j2DAAQ1" 16 } 17 } 18 ] 19 } 20}