You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -141,34 +142,58 @@ Let us test the connection to Cosmos DB instance and OpenAI service.
141
142
142
143
1. Open VS Code and navigate to the `aiapp1day` repository folder. If you are using Codespaces, you should already be in the repository folder.
143
144
144
-
2. Switch to VS Code `Search` tab, replace `<MONGODB_Name>` placeholder with your own database name. Search for `<MONGODB_Name>` and replace with `aiapp1day_xxxxx_xx` (for example: aiapp1day_daniel_66). Then click `Replace All` icon, there will be multiple items to be replaced. The placeholder string will be replaced in the whole repo so that you have a dedicated database on the shared Cosmos DB instance.
145
+
2. Navigate to the setup folder `~/labs/00-Setup/` within the repository. Go to `Terminal` window in VS Code.
146
+
```bash
147
+
cd labs/00-Setup/
148
+
```
145
149
146
-
:::info
147
-
Make sure the `<` and `>` included in search & replace.
150
+
3. Open `setup.sh`, let's update `<MONGODB_Name>` setting with your own database name. Replace `add_value` with `aiapp1day_xxxxx_xx` (for example: aiapp1day_daniel_66).
151
+
152
+

148
153
154
+
:::info
149
155
if you are deploying your own Azure resources, please update above shared keys and connection string with your own.
150
156
:::
151
157
152
-

158
+
4. Update `<MONGODB_CONNECTION_STRING>` with `mongodb+srv://aiapp1dayadmin:Aiapp1daypassword123@arg-syd-aiapp1day-mongo.mongocluster.cosmos.azure.com/?tls=true&authMechanism=SCRAM-SHA-256&retrywrites=false&maxIdleTimeMS=120000`
159
+
160
+
5. Update `<AZURE_OPENAI_API_INSTANCE_NAME>` with `arg-syd-aiapp1day-openai`
161
+
162
+
6. Update `<AZURE_OPENAI_API_KEY>` with `0f73b2e1cba543ce8c9518712a5b1efc`
153
163
154
-
3.Replace`<MONGODB_CONNECTION_STRING>` with `mongodb+srv://aiapp1dayadmin:Aiapp1daypassword123@arg-syd-aiapp1day-mongo.mongocluster.cosmos.azure.com/?tls=true&authMechanism=SCRAM-SHA-256&retrywrites=false&maxIdleTimeMS=120000`
164
+
7.Update`<GRAPH_RAG_API>` with `https://arg-syd-aiapp1day-ca--miqityv.niceisland-66754352.eastus.azurecontainerapps.io`
155
165
156
-
4.Replace `<AZURE_OPENAI_API_INSTANCE_NAME>` with `arg-syd-aiapp1day-openai`
166
+
8.Go to terminal windows and run below bash command to replace all variables in the repo.
157
167
158
-
5. Replace `<AZURE_OPENAI_API_KEY>` with `0f73b2e1cba543ce8c9518712a5b1efc`
168
+
```bash
169
+
chmod +x setup.sh
170
+
./setup.sh
171
+
```
172
+
173
+
:::info
174
+
If you have issue running above script, you can also carry out variable replacement manually.
175
+
176
+
Switch to VS Code `Search` tab, replace `<MONGODB_Name>` placeholder with your own database name.
177
+
178
+
Search for `<MONGODB_Name>` and replace with `aiapp1day_xxxxx_xx` (for example: aiapp1day_daniel_66).
179
+
180
+
Then click `Replace All` icon, there will be multiple items to be replaced. The placeholder string will be replaced in the whole repo so that you have a dedicated database on the shared Cosmos DB instance.
181
+
182
+

183
+
:::
159
184
160
-
6.Navigate to the setup test folder `~/labs/00-Setup/` within the repository.
185
+
9.Install node packages for test program.
161
186
162
187
```bash
163
188
npm install
164
189
```
165
190
166
-
7. Test Connection to CosMos Db and OpenAI service. Run the following command in the terminal window to execute the script:
191
+
10. Test Connection to CosMos Db and OpenAI service. Run the following command in the terminal window to execute the script:
167
192
168
193
```bash
169
194
node test.js
170
195
```
171
196
172
-
8. If you see below message in the console, you are ready to go! otherwise, please `YELL for help`.
197
+
11. If you see below message in the console, you are ready to go! otherwise, please `YELL for help`.
@@ -440,7 +458,7 @@ In this scenario, an agent will be equipped with two tools, one that uses a retr
440
458
Please think about the difference between `langchain-rag.js` and `langchain-agent.js`. Which one do you think is better?
441
459
:::
442
460
443
-
12. Experiment with additional questions of your own.
461
+
12. Experiment with additional questions of your own. For example, change the question in the `executeAgent`functionto`What's the top 2 Tire based on feedback?`. It will use `productFeedbackTool` to invoike API call to Graph RAG endpoint.
0 commit comments