Preparing search index...

    Class DialogModule

    Provides access to Question Answering Service powered by VoiceML.

    Allows to answer questions based on provided text.

    VoiceML capabilities are no longer supported. For Spectacles see options on ASRModule.

    Lens Scripting Version 182

    Since Lens Scripting Version 366

    Hierarchy (View Summary)

    Index

    Properties

    name: string

    The name of the Asset in Lens Studio.

    ""
    
    uniqueIdentifier: string

    Lens Scripting Version 176

    Methods

    • Sends a request to ask questions using the DialogModule. context is the text the model will use as context for answering the question. questions is a list of questions to ask. When answers are ready, onQuestionsAnswerComplete will be called with a list of Dialog.Answer objects corresponding to the questions in the questions list. onQuestionsAnswerError will be called if any error occurs.

      Parameters

      • context: string
      • questions: string[]
      • onQuestionsAnswerComplete: (answers: Answer[]) => void
      • onQuestionsAnswerError: (error: number, description: string) => void

      Returns void

      Lens Scripting Version 182

      Since Lens Scripting Version 366

    • Returns the fully-qualified JavaScript type name for this class (for example, "Component.Camera"). This is a static accessor (no instance required) and returns the same value as the instance getTypeName().

      Returns string

      Lens Scripting Version 182

      Since Lens Scripting Version 366

    • Returns the name of this object's type.

      Returns string

    • Returns true if the object matches or derives from the passed in type.

      Parameters

      • type: string

      Returns boolean

    • Returns true if this object is the same as other. Useful for checking if two references point to the same thing.

      Parameters

      Returns boolean