Skip to content

Commit 6f460d5

Browse files
authored
Update index-lookup-tool.md
1 parent ac924c3 commit 6f460d5

File tree

1 file changed

+39
-33
lines changed

1 file changed

+39
-33
lines changed

articles/ai-studio/how-to/prompt-flow-tools/index-lookup-tool.md

Lines changed: 39 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -20,39 +20,9 @@ author: lgayhardt
2020
The prompt flow Index Lookup tool enables the use of common vector indices (such as Azure AI Search, Faiss, and Pinecone) for retrieval augmented generation in prompt flow. The tool automatically detects the indices in the workspace and allows the selection of the index to be used in the flow.
2121

2222
## Build with the Index Lookup tool
23-
1. The Index Lookup tool looks to replace the three deprecated legacy index tools: the Vector Index Lookup tool, the Vector DB Lookup tool, and the Faiss Index Lookup tool.
24-
If you have a flow that contains one of these tools, follow the next steps to upgrade your flow.
25-
1. To update your runtime, go to the project **Settings** tab on the left pane in AI Studio. In the list of prompt flow runtimes that appears, select the name of the runtime you want to update. Then select **Update**. Wait for the runtime to update itself.
26-
1. To go to your flow, select the **Prompt flow** tab on the left pane in AI Studio. Select the **Flows** tab, and then select the name of your flow.
27-
28-
1. Inside the flow, select **+ More tools**. In the dropdown list, select **Index Lookup** [Preview] to add an instance of the Index Lookup tool.
29-
30-
:::image type="content" source="../../media/prompt-flow/upgrade-index-tools/index-dropdown.png" alt-text="Screenshot that shows the More tools dropdown list in the prompt flow." lightbox="../../media/prompt-flow/upgrade-index-tools/index-dropdown.png":::
31-
32-
1. Name the new node and select **Add**.
33-
34-
:::image type="content" source="../../media/prompt-flow/upgrade-index-tools/save-node.png" alt-text="Screenshot that shows the Index Lookup node with a name." lightbox="../../media/prompt-flow/upgrade-index-tools/save-node.png":::
35-
36-
1. In the new node, select the **mlindex_content** textbox. It should be the first textbox in the list.
37-
38-
:::image type="content" source="../../media/prompt-flow/upgrade-index-tools/mlindex-box.png" alt-text="Screenshot that shows the expanded Index Lookup node with the mlindex_content textbox." lightbox="../../media/prompt-flow/upgrade-index-tools/mlindex-box.png":::
39-
40-
1. In **Generate**, follow these steps to upgrade from the three legacy tools:
41-
- **Vector Index Lookup**: Select **Registered Index** in the **index_type** dropdown. Select your vector index asset from the **mlindex_asset_id** dropdown list.
42-
- **Faiss Index Lookup**: Select **Faiss** in the **index_type** dropdown list. Specify the same path as in the legacy tool.
43-
- **Vector DB Lookup**: Select AI Search or Pinecone depending on the DB type in the **index_type** dropdown list. Fill in the information, as necessary.
44-
1. Select **Save**.
45-
1. Back in the node, information is now populated in the **mlindex_content** textbox. Select the **queries** textbox and select the search terms you want to query. Select the same value as the input to the **embed_the_question** node. This value is typically either `\${inputs.question}` or `${modify_query_with_history.output}`. Use `\${inputs.question}` if you're in a standard flow. Use `${modify_query_with_history.output}` if you're in a chat flow.
46-
47-
:::image type="content" source="../../media/prompt-flow/upgrade-index-tools/mlindex-with-content.png" alt-text="Screenshot that shows the expanded Index Lookup node with index information in the cells." lightbox="../../media/prompt-flow/upgrade-index-tools/mlindex-with-content.png":::
48-
49-
1. Select a query type by selecting the dropdown next to **query_type**. **Vector** produces identical results as the legacy flow. Depending on your index configuration, other options such as **Hybrid** and **Semantic** might be available.
50-
51-
:::image type="content" source="../../media/prompt-flow/upgrade-index-tools/vector-search.png" alt-text="Screenshot that shows the expanded Index Lookup node with Vector search." lightbox="../../media/prompt-flow/upgrade-index-tools/vector-search.png":::
52-
53-
1. Edit downstream components to consume the output of your newly added node, instead of the output of the legacy Vector Index Lookup node.
54-
1. Delete the Vector Index Lookup node and its parent embedding node.
55-
1. Create or open a flow in [Azure AI Studio](https://ai.azure.com). For more information, see [Create a flow](../flow-develop.md).
23+
24+
1. If you have a flow that contains one of the deprecated legacy index tools ( the Vector Index Lookup tool, Vector DB Lookup tool, and Faiss Index Lookup tool) you will first need to [upgrade your flow](#upgrade-your-tools).
25+
2. Create or open a flow in [Azure AI Studio](https://ai.azure.com). For more information, see [Create a flow](../flow-develop.md).
5626
1. Select **+ More tools** > **Index Lookup** to add the Index Lookup tool to your flow.
5727

5828
:::image type="content" source="../../media/prompt-flow/configure-index-lookup-tool.png" alt-text="Screenshot that shows the Index Lookup tool added to a flow in Azure AI Studio." lightbox="../../media/prompt-flow/configure-index-lookup-tool.png":::
@@ -171,7 +141,43 @@ The following JSON format response is an example returned by the tool that inclu
171141
]
172142

173143
```
144+
## Migrate from legacy tools to the Index Lookup tool
145+
146+
The Index Lookup tool looks to replace the three deprecated legacy index tools: the Vector Index Lookup tool, the Vector DB Lookup tool, and the Faiss Index Lookup tool.
147+
If you have a flow that contains one of these tools, follow the next steps to upgrade your flow.
148+
149+
### Upgrade your tools
150+
151+
1. To update your runtime, go to the project **Settings** tab on the left pane in AI Studio. In the list of prompt flow runtimes that appears, select the name of the runtime you want to update. Then select **Update**. Wait for the runtime to update itself.
152+
1. To go to your flow, select the **Prompt flow** tab on the left pane in AI Studio. Select the **Flows** tab, and then select the name of your flow.
153+
154+
1. Inside the flow, select **+ More tools**. In the dropdown list, select **Index Lookup** [Preview] to add an instance of the Index Lookup tool.
155+
156+
:::image type="content" source="../../media/prompt-flow/upgrade-index-tools/index-dropdown.png" alt-text="Screenshot that shows the More tools dropdown list in the prompt flow." lightbox="../../media/prompt-flow/upgrade-index-tools/index-dropdown.png":::
157+
158+
1. Name the new node and select **Add**.
159+
160+
:::image type="content" source="../../media/prompt-flow/upgrade-index-tools/save-node.png" alt-text="Screenshot that shows the Index Lookup node with a name." lightbox="../../media/prompt-flow/upgrade-index-tools/save-node.png":::
161+
162+
1. In the new node, select the **mlindex_content** textbox. It should be the first textbox in the list.
163+
164+
:::image type="content" source="../../media/prompt-flow/upgrade-index-tools/mlindex-box.png" alt-text="Screenshot that shows the expanded Index Lookup node with the mlindex_content textbox." lightbox="../../media/prompt-flow/upgrade-index-tools/mlindex-box.png":::
165+
166+
1. In **Generate**, follow these steps to upgrade from the three legacy tools:
167+
- **Vector Index Lookup**: Select **Registered Index** in the **index_type** dropdown. Select your vector index asset from the **mlindex_asset_id** dropdown list.
168+
- **Faiss Index Lookup**: Select **Faiss** in the **index_type** dropdown list. Specify the same path as in the legacy tool.
169+
- **Vector DB Lookup**: Select AI Search or Pinecone depending on the DB type in the **index_type** dropdown list. Fill in the information, as necessary.
170+
1. Select **Save**.
171+
1. Back in the node, information is now populated in the **mlindex_content** textbox. Select the **queries** textbox and select the search terms you want to query. Select the same value as the input to the **embed_the_question** node. This value is typically either `\${inputs.question}` or `${modify_query_with_history.output}`. Use `\${inputs.question}` if you're in a standard flow. Use `${modify_query_with_history.output}` if you're in a chat flow.
172+
173+
:::image type="content" source="../../media/prompt-flow/upgrade-index-tools/mlindex-with-content.png" alt-text="Screenshot that shows the expanded Index Lookup node with index information in the cells." lightbox="../../media/prompt-flow/upgrade-index-tools/mlindex-with-content.png":::
174+
175+
1. Select a query type by selecting the dropdown next to **query_type**. **Vector** produces identical results as the legacy flow. Depending on your index configuration, other options such as **Hybrid** and **Semantic** might be available.
176+
177+
:::image type="content" source="../../media/prompt-flow/upgrade-index-tools/vector-search.png" alt-text="Screenshot that shows the expanded Index Lookup node with Vector search." lightbox="../../media/prompt-flow/upgrade-index-tools/vector-search.png":::
174178

179+
1. Edit downstream components to consume the output of your newly added node, instead of the output of the legacy Vector Index Lookup node.
180+
1. Delete the Vector Index Lookup node and its parent embedding node.
175181

176182

177183
## Next steps

0 commit comments

Comments
 (0)