Skip to content

Commit 2daa79a

Browse files
authored
consistency changes to include files
1 parent 0c70c63 commit 2daa79a

File tree

4 files changed

+43
-43
lines changed

4 files changed

+43
-43
lines changed

articles/app-service/includes/deploy-intelligent-apps/deploy-intelligent-apps-linux-dotnet-pivot.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ In this step, you add the using statement and create the kernel in a method that
162162

163163
## 4. Add your AI service
164164

165-
After the kernel is initialized, you can add your chosen AI service to the kernel. You define your model and pass in your key and endpoint information that the chosen model consumes. If you plan to use managed identity with Azure OpenAI, add the service by using the example in the next section.
165+
After the kernel is initialized, you can add your chosen AI service to the kernel. You define your model and pass in your key and endpoint information that the chosen model consumes. If you plan to use a managed identity with Azure OpenAI, add the service by using the example in the next section.
166166

167167
Use the following code for Azure OpenAI:
168168

@@ -189,11 +189,11 @@ builder.Services.AddOpenAIChatCompletion(
189189
var kernel = builder.Build();
190190
```
191191

192-
### Secure your app with managed identity
192+
### Secure your app with a managed identity
193193

194-
If you're using Azure OpenAI, we highly recommend that you secure your application by using [managed identity](../../overview-managed-identity.md) to authenticate your app to your Azure OpenAI resource. This process enables your application to access the Azure OpenAI resource without managing API keys. If you're not using Azure OpenAI, your secrets can remain secure by using Azure Key Vault as outlined previously.
194+
If you're using Azure OpenAI, we highly recommend that you secure your application by using a [managed identity](../../overview-managed-identity.md) to authenticate your app to your Azure OpenAI resource. This process enables your application to access the Azure OpenAI resource without managing API keys. If you're not using Azure OpenAI, your secrets can remain secure by using Azure Key Vault as outlined previously.
195195

196-
Complete the following tasks to secure your application with managed identity:
196+
Complete the following tasks to secure your application with a managed identity.
197197

198198
Add the identity package `Azure.Identity`. By using this package, you can use Azure credentials in your app. Install the package by using NuGet package manager and add the using statement to the top of the `OpenAI.razor` file.
199199

@@ -215,13 +215,13 @@ var kernel = Kernel.CreateBuilder()
215215

216216
After the credentials are added to the application, you'll need to enable a managed identity in your application and grant access to the resource.
217217

218-
1. In your web app resource, go to the **Identity** pane and turn on **System assigned** and select **Save**.
218+
1. In your web app resource, go to the **Identity** pane and turn on **System assigned**, and then select **Save**.
219219
1. After **System assigned** identity is turned on, it registers the web app with Microsoft Entra ID. The web app can be granted permissions to access protected resources.
220-
1. Go to your Azure OpenAI resource and go to the **Access control (IAM)** pane on the left pane.
220+
1. Go to your Azure OpenAI resource, and then go to **Access control (IAM)** on the left pane.
221221
1. Find the **Grant access to this resource** card and select **Add role assignment**.
222222
1. Search for the **Cognitive Services OpenAI User** role and select **Next**.
223223
1. On the **Members** tab, find **Assign access to** and choose the **Managed identity** option.
224-
1. Next, choose **+Select Members** and find your web app.
224+
1. Choose **+Select Members** and find your web app.
225225
1. Select **Review + assign**.
226226

227227
Your web app is now added as a cognitive service OpenAI user and can communicate to your Azure OpenAI resource.

articles/app-service/includes/deploy-intelligent-apps/deploy-intelligent-apps-linux-java-pivot.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -33,13 +33,13 @@ For this Spring Boot application, you're building off the [quickstart](../../qui
3333

3434
Get the keys and endpoint values from Azure OpenAI or OpenAI and add them as secrets to use in your application. Retrieve and save the values for later use to build the client.
3535

36-
For Azure OpenAI, see [this documentation](/azure/ai-services/openai/quickstart?pivots=programming-language-csharp&tabs=command-line%2Cpython#retrieve-key-and-endpoint) to retrieve the key and endpoint values. If you're planning to use [managed identity](../../overview-managed-identity.md) to secure your app, you need only the `endpoint` value. Otherwise, you need each of the following values:
36+
For Azure OpenAI, see [this documentation](/azure/ai-services/openai/quickstart?pivots=programming-language-csharp&tabs=command-line%2Cpython#retrieve-key-and-endpoint) to retrieve the key and endpoint values. If you're planning to use a [managed identity](../../overview-managed-identity.md) to secure your app, you need only the `endpoint` value. Otherwise, you need each of the following values:
3737

3838
- `endpoint`
3939
- `apiKey`
4040
- `deploymentName`
4141

42-
For OpenAI, see this [documentation](https://platform.openai.com/docs/api-reference) to retrieve the API keys. For this application, you need the following values:
42+
For OpenAI, see [this documentation](https://platform.openai.com/docs/api-reference) to retrieve the API keys. For this application, you need the following values:
4343

4444
- `apiKey`
4545
- `modelName`
@@ -48,7 +48,7 @@ Because you're deploying to App Service, you can put these secrets in Azure Key
4848

4949
Next, you can use key vault references as app settings in your App Service resource to reference in the application. Follow the instructions in the [documentation](../../app-service-key-vault-references.md?source=recommendations&tabs=azure-cli) to grant your app access to your key vault and to set up key vault references.
5050

51-
Then, go to the portal **Environment Variables** page in your resource and add the following app settings:
51+
Then, go to the portal **Environment Variables** page in your resource and add the following app settings.
5252

5353
For Azure OpenAI, use the following settings:
5454

@@ -139,9 +139,9 @@ import com.azure.ai.openai.OpenAIClientBuilder;
139139
import com.azure.core.credential.AzureKeyCredential;
140140
```
141141

142-
### Secure your app with managed identity
142+
### Secure your app with a managed identity
143143

144-
Although optional, we highly recommended that you secure your application using [managed identity](../../overview-managed-identity.md) to authenticate your app to your Azure OpenAI resource. This process enables your application to access the Azure OpenAI resource without managing API keys. Skip this step if you're not using Azure OpenAI.
144+
Although optional, we highly recommend that you secure your application by using a [managed identity](../../overview-managed-identity.md) to authenticate your app to your Azure OpenAI resource. This process enables your application to access the Azure OpenAI resource without managing API keys. Skip this step if you're not using Azure OpenAI.
145145

146146
To secure your application, complete the following steps:
147147

@@ -158,13 +158,13 @@ OpenAIClient client = new OpenAIClientBuilder()
158158

159159
After the credentials are added to the application, enable a managed identity in your application and grant access to the resource:
160160

161-
1. In your web app resource, go to the **Identity** pane and turn on **System assigned** and select **Save**.
161+
1. In your web app resource, go to the **Identity** pane and turn on **System assigned**, and then select **Save**.
162162
1. After system-assigned identity is turned on, it will register the web app with Microsoft Entra ID and the web app can be granted permissions to access protected resources.
163-
1. Go to your Azure OpenAI resource and go to the **Access control (IAM)** page on the left pane.
163+
1. Go to your Azure OpenAI resource, and then go to **Access control (IAM)** on the left pane.
164164
1. Find the **Grant access to this resource** card and select **Add role assignment**.
165165
1. Search for the **Cognitive Services OpenAI User** role and select **Next**.
166166
1. On the **Members** tab, find **Assign access to** and choose the **Managed identity** option.
167-
1. Next, choose **+Select Members** and find your web app.
167+
1. Choose **+Select Members** and find your web app.
168168
1. Select **Review + assign**.
169169

170170
Your web app is now added as a cognitive service OpenAI user and can communicate to your Azure OpenAI resource.

articles/app-service/includes/deploy-intelligent-apps/deploy-intelligent-apps-linux-node-pivot.md

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -42,13 +42,13 @@ First, copy and replace the `index.ejs` file with the following code:
4242
</html>
4343
```
4444

45-
The preceding code adds an input box to our index page to submit requests to OpenAI.
45+
The preceding code adds an input box to the index page to submit requests to OpenAI.
4646

4747
### API keys and endpoints
4848

4949
Get the keys and endpoint values from Azure OpenAI or OpenAI and add them as secrets for use in your application. Retrieve and save the values for later use to build the client.
5050

51-
For Azure OpenAI, see [this documentation](/azure/ai-services/openai/quickstart?pivots=programming-language-csharp&tabs=command-line%2Cpython#retrieve-key-and-endpoint) to retrieve the key and endpoint values. If you're planning to use managed identity to secure your app, you need only the `deploymentName` and `apiVersion` values.
51+
For Azure OpenAI, see [this documentation](/azure/ai-services/openai/quickstart?pivots=programming-language-csharp&tabs=command-line%2Cpython#retrieve-key-and-endpoint) to retrieve the key and endpoint values. If you're planning to use a managed identity to secure your app, you need only the `deploymentName` and `apiVersion` values.
5252

5353
Otherwise, you need each of the following values:
5454

@@ -59,15 +59,15 @@ For Azure OpenAI, use the following settings:
5959
- `deploymentName`
6060
- `apiVersion`
6161

62-
For OpenAI, see this documentation to retrieve the API keys. For our application, you need the following values:
62+
For OpenAI, see [this documentation](https://platform.openai.com/docs/api-reference) to retrieve the API keys. For this application, you need the following values:
6363

6464
- `apiKey`
6565

66-
Because you're deploying to App Service, you can put these secrets in Azure Key Vault for protection. Follow the [Quickstart](/azure/key-vault/secrets/quick-create-cli#create-a-key-vault) to set up your key vault and add the secrets that you saved from earlier.
66+
Because you're deploying to App Service, you can put these secrets in Azure Key Vault for protection. Follow the [quickstart](/azure/key-vault/secrets/quick-create-cli#create-a-key-vault) to set up your key vault and add the secrets that you saved from earlier.
6767

68-
Next, we can use key vault references as app settings in our App Service resource to reference in our application. Follow the instructions in the [documentation](../../app-service-key-vault-references.md?source=recommendations&tabs=azure-cli) to grant your app access to your key vault and to set up key vault references.
68+
Next, you can use key vault references as app settings in your App Service resource to reference in the application. Follow the instructions in the [documentation](../../app-service-key-vault-references.md?source=recommendations&tabs=azure-cli) to grant your app access to your key vault and to set up key vault references.
6969

70-
Then, go to the portal **Environment Variables** page in your resource and add the following app settings:
70+
Then, go to the portal **Environment Variables** page in your resource and add the following app settings.
7171

7272
For Azure OpenAI, use the following settings:
7373

@@ -104,7 +104,7 @@ const apiKey = process.env.API_KEY;
104104

105105
### Add the OpenAI package
106106

107-
Before you can create the client, add the Azure OpenAI package. Add the following OpenAI package by using the node package manager.
107+
Before you can create the client, add the Azure OpenAI package. Add the following OpenAI package by using the Node package manager.
108108

109109
For Azure OpenAI:
110110

@@ -120,7 +120,7 @@ npm install openai
120120

121121
### Create OpenAI client
122122

123-
After the package and environment variables are set up, we can create the client that enables chat completion calls.
123+
After the package and environment variables are set up, you can create the client that enables chat completion calls.
124124

125125
Add the following code to create the OpenAI client:
126126

@@ -147,11 +147,11 @@ import OpenAI from 'openai';
147147
});
148148
```
149149

150-
### Secure your app by using managed identity
150+
### Secure your app by using a managed identity
151151

152-
Although optional, we highly recommend that you secure your application by using [managed identity](../../overview-managed-identity.md) to authenticate your app to your Azure OpenAI resource. This process enables your application to access the Azure OpenAI resource without needing to manage API keys. Skip this step if you're not using Azure OpenAI.
152+
Although optional, we highly recommend that you secure your application by using a [managed identity](../../overview-managed-identity.md) to authenticate your app to your Azure OpenAI resource. This process enables your application to access the Azure OpenAI resource without needing to manage API keys. Skip this step if you're not using Azure OpenAI.
153153

154-
To secure your application, complete the following tasks:
154+
To secure your application, complete the following tasks.
155155

156156
Install the Azure identity package using the Node package manager.
157157

@@ -179,18 +179,18 @@ After the credentials are added to the application, enable a managed identity in
179179

180180
1. In your web app resource, go to the **Identity** pane and turn on **System assigned**. Select **Save**.
181181
1. After system-assigned identity is turned on, it will register the web app with Microsoft Entra ID and the web app can be granted permissions to access protected resources.
182-
1. Go to your Azure OpenAI resource and go to the **Access control (IAM)** page on the left pane.
182+
1. Go to your Azure OpenAI resource, and then go to **Access control (IAM)** on the left pane.
183183
1. Find the **Grant access to this resource** card and select **Add role assignment**.
184184
1. Search for the **Cognitive Services OpenAI User** role and select **Next**.
185185
1. On the **Members** tab, find **Assign access to** and choose the **Managed identity** option.
186-
1. Next, choose **+Select Members** and find your web app.
186+
1. Choose **+Select Members** and find your web app.
187187
1. Select **Review + assign**.
188188

189189
Your web app is now added as a cognitive service OpenAI user and can communicate to your Azure OpenAI resource.
190190

191191
### Set up a prompt and call to OpenAI
192192

193-
We can use chat completions to send our request message to OpenAI and return a response. Add your chat message prompt to the code to be passed to the chat completions method. Use the following code to set up chat completions:
193+
You can use chat completions to send your request message to OpenAI and return a response. Add your chat message prompt to the code to be passed to the chat completions method. Use the following code to set up chat completions:
194194

195195
```jsx
196196
app.post("/api/completions", async (req, res) => {

0 commit comments

Comments
 (0)