Skip to content

Commit e7a34ec

Browse files
committed
edits per learn-authoring-ai-assistant
1 parent 72285e1 commit e7a34ec

File tree

1 file changed

+21
-21
lines changed

1 file changed

+21
-21
lines changed

articles/search/includes/quickstarts/search-get-started-rag-java.md

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -26,23 +26,23 @@ Requests to the search endpoint must be authenticated and authorized. You can us
2626

2727
You're setting up two clients, so you need permissions on both resources.
2828

29-
Azure AI Search is receiving the query request from your local system. Assign yourself the **Search Index Data Reader** role assignment if the hotels sample index already exists. If it doesn't exist, assign yourself **Search Service Contributor** and **Search Index Data Contributor** roles so that you can create and query the index.
29+
Azure AI Search receives the query request from your local system. Assign yourself the **Search Index Data Reader** role assignment if the hotels sample index already exists. If it doesn't exist, assign yourself **Search Service Contributor** and **Search Index Data Contributor** roles so that you can create and query the index.
3030

31-
Azure OpenAI is receiving the query and the search results from your local system. Assign yourself the **Cognitive Services OpenAI User** role on Azure OpenAI.
31+
Azure OpenAI receives the query and the search results from your local system. Assign yourself the **Cognitive Services OpenAI User** role on Azure OpenAI.
3232

3333
1. Sign in to the [Azure portal](https://portal.azure.com).
3434

3535
1. Configure Azure AI Search for role-based access:
3636

3737
1. In the Azure portal, find your Azure AI Search service.
3838

39-
1. On the left menu, select **Settings** > **Keys**, and then select either **Role-based access control** or **Both**.
39+
1. On the left menu, select **Settings** > **Keys**, then select either **Role-based access control** or **Both**.
4040

4141
1. Assign roles:
4242

4343
1. On the left menu, select **Access control (IAM)**.
4444

45-
1. On Azure AI Search, select these roles to create, load, and query a search index, and then assign them to your Microsoft Entra ID user identity:
45+
1. On Azure AI Search, select these roles to create, load, and query a search index, then assign them to your Microsoft Entra ID user identity:
4646

4747
- **Search Index Data Contributor**
4848
- **Search Service Contributor**
@@ -55,7 +55,7 @@ It can take several minutes for permissions to take effect.
5555

5656
## Create an index
5757

58-
A search index provides grounding data for the chat model. We recommend the hotels-sample-index, which can be created in minutes and runs on any search service tier. This index is created using built-in sample data.
58+
A search index provides grounding data for the chat model. We recommend the **hotels-sample-index**, which you can create in minutes and runs on any search service tier. This index uses built-in sample data.
5959

6060
1. In the Azure portal, [find your search service](https://portal.azure.com/#blade/HubsExtension/BrowseResourceBlade/resourceType/Microsoft.Search%2FsearchServices).
6161

@@ -71,7 +71,7 @@ A search index provides grounding data for the chat model. We recommend the hote
7171

7272
1. Select **Edit JSON**.
7373

74-
1. Scroll to the end of the index, where you can find placeholders for constructs that can be added to an index.
74+
1. Scroll to the end of the index, where you find placeholders for constructs that you can add to an index.
7575

7676
```json
7777
"analyzers": [],
@@ -116,7 +116,7 @@ A search index provides grounding data for the chat model. We recommend the hote
116116

117117
1. Run the following query in [Search Explorer](../../search-explorer.md) to test your index: `complimentary breakfast`.
118118

119-
Output should look similar to the following example. Results that are returned directly from the search engine consist of fields and their verbatim values, along with metadata like a search score and a semantic ranking score and caption if you use semantic ranker. We used a [select statement](../../search-query-odata-select.md) to return just the HotelName, Description, and Tags fields.
119+
The output should look similar to the following example. Results that are returned directly from the search engine consist of fields and their verbatim values, along with metadata like a search score and a semantic ranking score and caption if you use semantic ranker. We used a [select statement](../../search-query-odata-select.md) to return just the HotelName, Description, and Tags fields.
120120

121121
```
122122
{
@@ -180,7 +180,7 @@ A search index provides grounding data for the chat model. We recommend the hote
180180
181181
## Get service endpoints
182182
183-
In the remaining sections, you set up API calls to Azure OpenAI and Azure AI Search. Get the service endpoints so that you can provide them as variables in your code.
183+
In the following sections, you set up API calls to Azure OpenAI and Azure AI Search. Get the service endpoints so that you can provide them as variables in your code.
184184
185185
1. Sign in to the [Azure portal](https://portal.azure.com).
186186
@@ -205,7 +205,7 @@ export AZURE_DEPLOYMENT_MODEL=<YOUR DEPLOYMENT NAME>
205205

206206
## Sign in to Azure
207207

208-
You're using Microsoft Entra ID and role assignments for the connection. Make sure you're logged in to the same tenant and subscription as Azure AI Search and Azure OpenAI. You can use the Azure CLI on the command line to show current properties, change properties, and to sign in. For more information, see [Connect without keys](../../search-get-started-rbac.md).
208+
You're using Microsoft Entra ID and role assignments for the connection. Make sure you're signed in to the same tenant and subscription as Azure AI Search and Azure OpenAI. You can use the Azure CLI on the command line to show current properties, change properties, and to sign in. For more information, see [Connect without keys](../../search-get-started-rbac.md).
209209

210210
Run each of the following commands in sequence.
211211

@@ -217,7 +217,7 @@ az account set --subscription <PUT YOUR SUBSCRIPTION ID HERE>
217217
az login --tenant <PUT YOUR TENANT ID HERE>
218218
```
219219

220-
You should now be logged in to Azure from your local device.
220+
You're now signed in to Azure from your local device.
221221

222222
## Set up the Java project
223223

@@ -372,10 +372,10 @@ Create a query script that uses the Azure AI Search index and the chat model to
372372
}
373373
```
374374

375-
The preceding code does the following:
376-
- Loads environment variables using `System.getenv`.
377-
- Configures Azure AI Search and Azure OpenAI clients using role-based authentication.
378-
- Queries Azure AI Search for hotels with complimentary breakfast using semantic search.
375+
The preceding code does the following steps:
376+
- Loads environment variables by using `System.getenv`.
377+
- Configures Azure AI Search and Azure OpenAI clients by using role-based authentication.
378+
- Queries Azure AI Search for hotels with complimentary breakfast by using semantic search.
379379
- Sends the search results to Azure OpenAI as context for a chat completion.
380380
- Prints the model's response.
381381
@@ -408,7 +408,7 @@ Create a query script that uses the Azure AI Search index and the chat model to
408408

409409
## Troubleshooting
410410

411-
If you get a **Forbidden** error message, check Azure AI Search configuration to make sure role-based access is enabled.
411+
If you get a **Forbidden** error message, check your Azure AI Search configuration to make sure you enable role-based access.
412412

413413
If you get an **Authorization failed** error message, wait a few minutes and try again. It can take several minutes for role assignments to become operational.
414414

@@ -577,7 +577,7 @@ Tell me their description, address, tags, and the rate for one room that sleeps
577577

578578
## Troubleshooting errors
579579

580-
To debug Azure SDK errors, you can enable logging by adding the following dependency to your `pom.xml`:
580+
To debug Azure SDK errors, enable logging by adding the following dependency to your `pom.xml`:
581581

582582
```xml
583583
<dependency>
@@ -594,16 +594,16 @@ mvn compile exec:java -Dexec.mainClass="com.example.rag.Query" \
594594
-Dorg.slf4j.simpleLogger.defaultLogLevel=debug
595595
```
596596

597-
This will enable detailed logging for the Azure SDK, which can help identify [issues with authentication](https://github.com/Azure/azure-sdk-for-java/wiki/Azure-Identity-Troubleshooting), network connectivity, or other problems.
597+
This configuration enables detailed logging for the Azure SDK, which can help you identify [issues with authentication](https://github.com/Azure/azure-sdk-for-java/wiki/Azure-Identity-Troubleshooting), network connectivity, or other problems.
598598

599-
Rerun the query script. You should now get informational statements from the SDKs in the output that provide more detail about any issues.
599+
Rerun the query script. You should now see informational statements from the SDKs in the output that provide more detail about any issues.
600600

601-
If you see output messages related to ManagedIdentityCredential and token acquisition failures, it could be that you have multiple tenants, and your Azure sign-in is using a tenant that doesn't have your search service. To get your tenant ID, search the Azure portal for "tenant properties" or run `az login tenant list`.
601+
If you see output messages related to `ManagedIdentityCredential` and token acquisition failures, it might be that you have multiple tenants, and your Azure sign-in uses a tenant that doesn't have your search service. To get your tenant ID, search the Azure portal for "tenant properties" or run `az login tenant list`.
602602

603-
Once you have your tenant ID, run `az login --tenant <YOUR-TENANT-ID>` at a command prompt, and then rerun the script.
603+
After you get your tenant ID, run `az login --tenant <YOUR-TENANT-ID>` at a command prompt, then rerun the script.
604604

605605
## Clean up
606606

607-
When you're working in your own subscription, it's a good idea at the end of a project to identify whether you still need the resources you created. Resources left running can cost you money. You can delete resources individually or delete the resource group to delete the entire set of resources.
607+
When you're working in your own subscription, it's a good idea at the end of a project to check if you still need the resources you created. Resources left running can cost you money. You can delete resources individually or delete the resource group to delete the entire set of resources.
608608

609609
You can find and manage resources in the Azure portal by using the **All resources** or **Resource groups** link in the leftmost pane.

0 commit comments

Comments
 (0)