GuidesRecipesAPI ReferenceChangelogDiscussions
Log In

Results

Overview

To retrieve results call the get results route with the job identifier. Results are keyed on the user’s input item names provided upon job submittal. Each model has its own result MIME type, found in the model’s details. You can also add the user’s input item name to the route and limit the results to a single input item.

Jobs requested for multiple input items may have partial results available prior to job completion. Items get fully processed and can be seen in the job details route while the job continues to run. Call the retrieve results route to retrieve specific information for an input processing including status, startTime, endTime, updateTime, elapsedTime, and assigned engine.

Explainability

Image classification models with the explainability feature return JSON outputs with mask values for explainable results. Mask values include the prediction results and the explainability results (pixel values that motivate the prediction made by the model).

Text classification models with the explainability feature return JSON outputs with word importance values for explainable results. It includes the prediction results and explainability results (score values that motivate the prediction made by the model).

Input status

Input status is about what happens with a specific input processing. Inputs start off as FETCHING_DATA and move to PROCESSING. They can then transition to FAILED or SUCCESSFUL.

Input statusDescription
FETCHING_DATAThe input item is retrieved.
PROCESSINGA pod is assigned to the input for processing.
FAILEDThe input processing failed.
SUCCESSFULThe input was processed successfully.

The results object

{
    "jobIdentifier": "...",
    "total": 1,
    "completed": 1,
    "failed": 0,
    "finished": true,
    "submittedByKey": "...",
    "explained": true,
    "results": {
        "inputName": {}
    },
    "failures": {}
}
ParameterTypeDescription
jobIdentifierstringThe job’s identifier.
totalnumberTotal number of inputs processed by the job request.
completednumberTotal number of inputs fully processed by the model.
failednumberTotal number of inputs that failed to be processed by the model.
finishedbooleanIf the job finished processing the outputs.
submittedByKeystringThe API key that submitted the job.
explainedbooleanDefines if the job has explainable results.
resultsobjectContains an input object for every input item processed. Input item names can be defined before running the model and used to retrieve individual results.
failuresobjectContains an input object for every input that failed to be processed by the model. Input item names can be defined before running the model and used to retrieve individual results.

The input items object

{
    "inputName": {
        "status": "...",
        "engine": "...",
        "startTime": "...",
        "updateTime": "...",
        "endTime": "...",
        "elapsedTime": 123,
        "outputName": {}
    }
}
ParameterTypeDescription
statusstringThe input item’s status. Values can be FETCHING_DATA, PROCESSING, FAILED, and SUCCESSFUL.
enginestringContains the details of the processing engine that ran this input item.
startTimestringTime the inference stated for the input item in ISO8601 (YYYY-MM-DDThh:mm:ss.sTZD) format.
updateTimestringTime the input item status was last updated in ISO8601 (YYYY-MM-DDThh:mm:ss.sTZD) format.
endTimestringTime the inference is completed for the input item in ISO8601 (YYYY-MM-DDThh:mm:ss.sTZD) format.
elapsedTimenumberTime between an input starts to run and it finishes in milliseconds.
outputNameobjectContains the model’s inference output for the input item. Each version has its own output name.

The explainability object

{
  "modelType": "imageClassification",
  "result": {
    "classPredictions": []
  },
  "explanation": {
    "maskRLE": [],
    "dimensions": {}
  }
}
{
  "modelType": "textClassification",
  "result": {
    "classPredictions": []
  },
  "explanation": {
    "wordImportances": {},
    "explainableText": {}
  }
}

Image classification models explainability object

ParameterTypeDescription
modelTypestringDefines the explanation format. Possible options: imageClassification, imageSegmentation, objectDetection.
resultobjectContains the results in a classPredictions array.
explanationobjectContains a maskRLE array with the explanation and a dimensions object with the height and width pixels. The maskRLE follows a column-major order (Fortran order).

Text classification models explainability object

ParameterTypeDescription
modelTypestringDefines the explanation format. Possible Options: textClassification.
resultobjectContains the results in a classPredictions list that consists of a prediction and score for each class.
explanationobjectContains:

Optional explainableText key/value pair whose value is a string containing the preprocessed text which was fed to the model.

wordImportances key/value pair whose value is an object in which keys are class names and values are lists containing explanation entry objects. Each of these explanation entry objects contains the word, score, and optionally the index of the occurrence of the word in the text split on whitespace. If explainableText is provided, then index values must refer to the explainableText. If explainableText is not provided, then index values must refer to the original input text. If a score is negative, it means that the word contributed negatively to that class prediction.