Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface IAiExternalProcessMessenger

A messenger to provide APIs to communicate with external AI inference engine (software).

api-version

2

user

Hierarchy

Index

Properties

trainedModelsRegisteredInServer: Monitorable<AiProcessModelInfo[]>

Monitorable A list of trained models which are registered in AI server. If the login is successful, it will be initialized to the data accessible to the logged-in account.

api-version

2

user

Methods

  • Register an event listener for the {@link eventName}.

    api-version

    2

    user

    Parameters

    • eventName: string

      Event name.

    • listener: AiProcessEventListener

      A listener to receive callbacks when an event has been sent from AI process.

    • Optional once: boolean

      If you set true, then the listener will be removed after receive an event. Default is false.

    Returns Promise<{ error?: AiProcessMessengerError; result: boolean }>

    Return Fulfills with true if the request has been operated successfully, otherwise false with AiProcessMessengerError.

  • deleteTrainedModel(modelId: string, options?: Record<string, string | number | boolean>): Promise<{ error?: AiProcessMessengerError; result: boolean }>
  • Request to download and update training model to AI inference module.

    api-version

    2

    user

    Parameters

    • modelId: string

      Target model id.

    • Optional options: Record<string, string | number | boolean>

      Additional options. It will be passed to API lib module or external AI inference engine.

    Returns Promise<{ error?: AiProcessMessengerError; result: boolean }>

    Return Fulfills with true if the request has been operated successfully, otherwise false with AiProcessMessengerError.

  • destroy(): Promise<void>
  • Destroy and release the AI process handler. You cannot reuse it after destroying it.

    api-version

    2

    user

    Returns Promise<void>

    Return Fulfills with void if the request has been done.

  • Manually disconnect the connection. In that case, it will not try to reconnect.

    api-version

    2

    user

    Returns Promise<{ error?: AiProcessMessengerError; result: boolean }>

    Return Fulfills with true if the handler has been disconnected successfully, otherwise false.

  • Request to download and install training model to AI inference module.

    api-version

    2

    user

    Parameters

    • modelId: string

      Target model id.

    • listener: AiProcessModelInstallListener

      A listener to be registered.

    • Optional options: Record<string, string | number | boolean>

      Additional options. It will be passed to API lib module or external AI inference engine.

    Returns Promise<{ error?: AiProcessMessengerError; result: boolean }>

    Return Fulfills with true if the request has been operated successfully, otherwise false with AiProcessMessengerError.

  • Whether the handler has been connected or not.

    api-version

    2

    user

    Returns Promise<{ error?: AiProcessMessengerError; result: boolean }>

    Return Fulfills with true if the handler has been connected, otherwise false.

  • loadTrainedModel(modelId: string, options?: Record<string, string | number | boolean>): Promise<{ error?: AiProcessMessengerError; result: boolean }>
  • Request to load a model to AI inference module.

    api-version

    2

    user

    Parameters

    • modelId: string

      Target model id.

    • Optional options: Record<string, string | number | boolean>

      Additional options. It will be passed to API lib module or external AI inference engine.

    Returns Promise<{ error?: AiProcessMessengerError; result: boolean }>

    Return Fulfills with true if the request has been operated successfully, otherwise false with AiProcessMessengerError.

  • login(account: string, password: string, options?: Record<string, string | number | boolean>): Promise<{ error?: AiProcessMessengerError; result: boolean }>
  • Request to log in to AI process with a Dart-Store account.

    api-version

    2

    user

    Parameters

    • account: string

      An account to use when logging in.

    • password: string

      An password to use when logging in.

    • Optional options: Record<string, string | number | boolean>

      Additional options. It will be passed to API lib module or external AI inference engine.

    Returns Promise<{ error?: AiProcessMessengerError; result: boolean }>

    Return Fulfills with true if the request has been operated successfully, otherwise false with AiProcessMessengerError.

  • logout(options?: Record<string, string | number | boolean>): Promise<{ error?: AiProcessMessengerError; result: boolean }>
  • sendEvent(eventName: string, args: Record<string, string | number | boolean>): Promise<{ error?: AiProcessMessengerError; result: boolean }>
  • Send an event to the connected AI process.

    api-version

    2

    user

    Parameters

    • eventName: string

      Event name.

    • args: Record<string, string | number | boolean>

      Arguments consists of key value pair for the event.

    Returns Promise<{ error?: AiProcessMessengerError; result: boolean }>

    Return Fulfills with true if the request has been operated successfully, otherwise false with AiProcessMessengerError.

  • uploadCollectionData(projectId: string, collectedDataId: string, options?: Record<string, string | number | boolean>): Promise<{ error?: AiProcessMessengerError; result: boolean }>
  • Request to upload collection data for model training to AI server.

    api-version

    2

    user

    Parameters

    • projectId: string

      An id of the project where you want to upload the collection data.

    • collectedDataId: string

      An id of collected data to upload.

    • Optional options: Record<string, string | number | boolean>

      Additional options. It will be passed to API lib module or external AI inference engine.

    Returns Promise<{ error?: AiProcessMessengerError; result: boolean }>

    Return Fulfills with true if the request has been operated successfully, otherwise false with AiProcessMessengerError.

Generated using TypeDoc