如何更改 Android 语音语言理解 (LUIS) SDK 的端点?
How to change endpoint for Android Speech Language Understanding (LUIS) SDK?
我已经在 luis.ai 和 eu.luis.ai.
上设置了一个应用程序
我使用此存储库中提供的 SDK 将其用于语音识别目的:https://github.com/Azure-Samples/Cognitive-Speech-STT-Android
它有可能直接使用LUIS结合语音识别,这正是我所需要的。
它适用于 luis.ai,因为端点在美国西部。在 eu.luis.ai 上,它在 SDK 中不起作用,因为端点似乎是错误的。端点的 appID 和 subID 错误。
有什么方法可以强制 SDK(上面链接的存储库中的那个)使用 westeu 或其他东西吗?
假设您指的是 https://github.com/Microsoft/Cognitive-LUIS-Windows, the LuisClient constructor has an overload that accepts a base URI. See https://github.com/Microsoft/Cognitive-LUIS-Windows/blob/master/ClientLibrary/LuisClient.cs,具体来说:
/// <summary>
/// Construct a new Luis client with a shared <see cref="HttpClient"/> instance.
/// </summary>
/// <param name="appId">The application ID of the LUIS application</param>
/// <param name="appKey">The application subscription key of the LUIS application</param>
/// <param name="baseApiUrl">Root URI for the service endpoint.</param>
/// <param name="preview">A flag indicating whether to use preview features or not (Dialogue)</param>
/// top scoring in case of using the dialogue</param>
public LuisClient(string appId, string appKey, string baseApiUrl, bool preview = false)
更新 Android 语音 SDK 而不是 LUIS SDK:
Android 语音 SDK (https://github.com/Azure-Samples/Cognitive-Speech-STT-Android) has a similar method for specifying the URL. See the createDataClientWithIntent overload that takes the optional URL parameter at https://github.com/Azure-Samples/Cognitive-Speech-STT-Android/blob/e27487b57f31afa04f6f3a8badfc566b1885011d/docs/com/microsoft/cognitiveservices/speechrecognition/SpeechRecognitionServiceFactory.html:
<strong>createDataClientWithIntent</strong>(android.app.Activity activity,
java.lang.String 语言,
ISpeechRecognitionServerEvents 事件处理程序,
java.lang.String 主键,
java.lang.String 辅助键,
java.lang.String luisAppId,
java.lang.String luisSubscriptionId,
java.lang.String url)
我已经在 luis.ai 和 eu.luis.ai.
上设置了一个应用程序我使用此存储库中提供的 SDK 将其用于语音识别目的:https://github.com/Azure-Samples/Cognitive-Speech-STT-Android 它有可能直接使用LUIS结合语音识别,这正是我所需要的。
它适用于 luis.ai,因为端点在美国西部。在 eu.luis.ai 上,它在 SDK 中不起作用,因为端点似乎是错误的。端点的 appID 和 subID 错误。
有什么方法可以强制 SDK(上面链接的存储库中的那个)使用 westeu 或其他东西吗?
假设您指的是 https://github.com/Microsoft/Cognitive-LUIS-Windows, the LuisClient constructor has an overload that accepts a base URI. See https://github.com/Microsoft/Cognitive-LUIS-Windows/blob/master/ClientLibrary/LuisClient.cs,具体来说:
/// <summary>
/// Construct a new Luis client with a shared <see cref="HttpClient"/> instance.
/// </summary>
/// <param name="appId">The application ID of the LUIS application</param>
/// <param name="appKey">The application subscription key of the LUIS application</param>
/// <param name="baseApiUrl">Root URI for the service endpoint.</param>
/// <param name="preview">A flag indicating whether to use preview features or not (Dialogue)</param>
/// top scoring in case of using the dialogue</param>
public LuisClient(string appId, string appKey, string baseApiUrl, bool preview = false)
更新 Android 语音 SDK 而不是 LUIS SDK:
Android 语音 SDK (https://github.com/Azure-Samples/Cognitive-Speech-STT-Android) has a similar method for specifying the URL. See the createDataClientWithIntent overload that takes the optional URL parameter at https://github.com/Azure-Samples/Cognitive-Speech-STT-Android/blob/e27487b57f31afa04f6f3a8badfc566b1885011d/docs/com/microsoft/cognitiveservices/speechrecognition/SpeechRecognitionServiceFactory.html:
<strong>createDataClientWithIntent</strong>(android.app.Activity activity,
java.lang.String 语言,
ISpeechRecognitionServerEvents 事件处理程序,
java.lang.String 主键,
java.lang.String 辅助键,
java.lang.String luisAppId,
java.lang.String luisSubscriptionId,
java.lang.String url)