Databricks SDK for JavaScript
    Preparing search index...
    interface AiDecideResponse {
        metadata?: AiDecideResponseMetadata;
        response?: JsonValue;
    }
    Index

    Properties

    Properties

    Metadata identifying the function API version used for this request.

    response?: JsonValue

    A JSON object containing an answers map with one answer for each question, keyed by the same IDs as questions.

    Each answer has a type matching its question and the following fields:

    • choice: choice is the highest-probability option from criteria. probabilities maps every option name to its probability. confidence is a number from 0 to 1 indicating how well the state supports the assessment. The probabilities values sum to 1. For example:
    {
    "answers": {
    "team": {
    "type": "choice",
    "choice": "billing",
    "probabilities": {
    "billing": 0.85,
    "technical_support": 0.15
    },
    "confidence": 0.9
    }
    }
    }
    • noul: probability is a number from 0 to 1 estimating the probability that the answer is true. For example:
    {
    "answers": {
    "escalate": {
    "type": "noul",
    "probability": 0.8
    }
    }
    }
    • score: score is the probability-weighted mean of the zero-based level indices. It can fall between levels, from 0 to the number of levels minus 1. probabilities maps each level index to its probability, and legend maps each index to its original description. Both maps use string keys such as "0", "1", and "2". confidence is a number from 0 to 1 indicating how well the state supports the assessment. The probabilities values sum to 1. For example:
    {
    "answers": {
    "urgency": {
    "type": "score",
    "score": 1.6,
    "probabilities": {
    "0": 0.1,
    "1": 0.2,
    "2": 0.7
    },
    "legend": {
    "0": "Routine: can wait a few days",
    "1": "Time-sensitive: needs attention today",
    "2": "Critical: needs immediate action"
    },
    "confidence": 0.85
    }
    }
    }