Skip to content

Commit 88a4072

Browse files
committed
Now all required changes
1 parent fb3288a commit 88a4072

File tree

1 file changed

+27
-6
lines changed

1 file changed

+27
-6
lines changed

articles/cognitive-services/Speech-Service/sovereign-clouds.md

Lines changed: 27 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ Replace `<REGION_IDENTIFIER>` with the identifier matching the region of your su
6363

6464
#### Speech SDK
6565

66-
For Speech SDK in sovereign clouds you need to use "from host" instantiation of `SpeechConfig` class or `--host` option of [Speech CLI](spx-overview.md). (You may also use "from endpoint" instantiation and `--endpoint` Speech CLI option).
66+
For [Speech SDK](speech-sdk.md) in sovereign clouds you need to use "from host / with host" instantiation of `SpeechConfig` class or `--host` option of [Speech CLI](spx-overview.md). (You may also use "from endpoint / with endpoint" instantiation and `--endpoint` Speech CLI option).
6767

6868
`SpeechConfig` class should be instantiated like this:
6969

@@ -73,20 +73,20 @@ var config = SpeechConfig.FromHost(usGovHost, subscriptionKey);
7373
```
7474
# [C++](#tab/cpp)
7575
```cpp
76-
auto config = SpeechConfig::FromEndpoint(endPoint, subscriptionKey);
76+
auto config = SpeechConfig::FromHost(usGovHost, subscriptionKey);
7777
```
7878
# [Java](#tab/java)
7979
```java
80-
SpeechConfig config = SpeechConfig.fromEndpoint(endPoint, subscriptionKey);
80+
SpeechConfig config = SpeechConfig.fromHost(usGovHost, subscriptionKey);
8181
```
8282
# [Python](#tab/python)
8383
```python
8484
import azure.cognitiveservices.speech as speechsdk
85-
speech_config = speechsdk.SpeechConfig(endpoint=endPoint, subscription=subscriptionKey)
85+
speech_config = speechsdk.SpeechConfig(host=usGovHost, subscription=subscriptionKey)
8686
```
8787
# [Objective-C](#tab/objective-c)
8888
```objectivec
89-
SPXSpeechConfiguration *speechConfig = [[SPXSpeechConfiguration alloc] initWithEndpoint:endPoint subscription:subscriptionKey];
89+
SPXSpeechConfiguration *speechConfig = [[SPXSpeechConfiguration alloc] initWithHost:usGovHost subscription:subscriptionKey];
9090
```
9191
***
9292
@@ -155,12 +155,33 @@ Replace `<REGION_IDENTIFIER>` with the identifier matching the region of your su
155155

156156
#### Speech SDK
157157

158-
For Speech SDK in sovereign clouds you need to use "from host" instantiation of `SpeechConfig` class or `--host` option of [Speech CLI](spx-overview.md). (You may also use "from endpoint" instantiation and `--endpoint` Speech CLI option).
158+
For [Speech SDK](speech-sdk.md) in sovereign clouds you need to use "from host / with host" instantiation of `SpeechConfig` class or `--host` option of [Speech CLI](spx-overview.md). (You may also use "from endpoint / with endpoint" instantiation and `--endpoint` Speech CLI option).
159159

160160
`SpeechConfig` class should be instantiated like this:
161+
162+
# [C#](#tab/c-sharp)
161163
```csharp
162164
var config = SpeechConfig.FromHost(azCnHost, subscriptionKey);
163165
```
166+
# [C++](#tab/cpp)
167+
```cpp
168+
auto config = SpeechConfig::FromHost(azCnHost, subscriptionKey);
169+
```
170+
# [Java](#tab/java)
171+
```java
172+
SpeechConfig config = SpeechConfig.fromHost(azCnHost, subscriptionKey);
173+
```
174+
# [Python](#tab/python)
175+
```python
176+
import azure.cognitiveservices.speech as speechsdk
177+
speech_config = speechsdk.SpeechConfig(host=azCnHost, subscription=subscriptionKey)
178+
```
179+
# [Objective-C](#tab/objective-c)
180+
```objectivec
181+
SPXSpeechConfiguration *speechConfig = [[SPXSpeechConfiguration alloc] initWithHost:azCnHost subscription:subscriptionKey];
182+
```
183+
***
184+
164185
Speech CLI should be used like this (note the `--host` option):
165186
```dos
166187
spx recognize --host "azCnHost" --file myaudio.wav

0 commit comments

Comments
 (0)