Interface NCEmbeddedResult

    • Method Detail

      • getModelId

        String getModelId()
        Gets the ID of the model that produced this result. Note that embedded probe can host more than one data model hence this parameter is important to distinguish to which model this result belongs.
        Returns:
        ID of the model produced this result.
      • getServerRequestId

        String getServerRequestId()
        Gets ID of the request that produced this result.
        Returns:
        ID of the request that produced this result.
      • getOriginalText

        String getOriginalText()
        Gets original text of the request that produced this result.
        Returns:
        Original text of the request that produced this result.
      • getUserId

        long getUserId()
        Gets ID of the user that made the request this result is for.
        Returns:
        ID of the user that made the request this result is for.
      • getBody

        String getBody()
        Gets optional result body. Note that either both result body and type are set or error message and error code are set, but not both pairs.
        Returns:
        Result body or null if error occurred.
      • getType

        String getType()
        Gets optional result type. Note that either both result body and type are set or error message and error code are set, but not both pairs.
        Returns:
        Result type or null if error occurred.
      • getErrorMessage

        String getErrorMessage()
        Gets optional error message.
        Returns:
        Error message or null if no errors occurred.
      • getErrorCode

        int getErrorCode()
        Gets optional error code. One of the following codes:
        Error codes.
        Code Description
        1 Rejected by the model.
        100 Unexpected system error.
        101 Model's result is too big.
        102 Recoverable system error.
        10001 Too many unknown words.
        10002 Sentence is too complex (too many free words).
        10003 Too many suspicious or unrelated words.
        10004 Swear words found and are not allowed.
        10005 Sentence contains no nouns.
        10006 Only latin charset is supported.
        10007 Only english language is supported.
        10008 Sentence seems unrelated to data model.
        10009 Sentence is too short (before processing).
        10010 Sentence is ambiguous.
        10011 Sentence is too short (after processing).
        10012 Sentence is too long.
        Returns:
        Error code if error message is not null.
      • getProbeId

        String getProbeId()
        Gets ID of the probe this result was generated by.
        Returns:
        ID of the probe this result was generated by.
      • getLogHolder

        String getLogHolder()
        Gets request processing log holder as JSON string.
        Returns:
        Request processing log holder as JSON string.
      • getIntentId

        String getIntentId()
        Gets ID of the intent that was matched against the input sentence. Only set if result was successful.
        Returns:
        ID of the matching intent.