File tree Expand file tree Collapse file tree 2 files changed +4
-7
lines changed
Expand file tree Collapse file tree 2 files changed +4
-7
lines changed Original file line number Diff line number Diff line change @@ -137,6 +137,8 @@ python -m indexing.build_index --index-name <desired_index_name>
137137
138138Add the argument ` --path-to-data` if you want to use different data than what is provided in the data directory of this sample.
139139
140+ You can view and use the index you just created on the ** Indexes** page of your Azure AI Studio project.
141+
140142# ## Step 4b: Set the index reference
141143
142144** Once you have the index you want to use, add the below entry to your .env file.** Note that the copilot code relies on this environment variable.
Original file line number Diff line number Diff line change @@ -43,16 +43,11 @@ def build_aisearch_index(index_name, path_to_data):
4343 tokens_per_chunk = 800 , # Optional field - Maximum number of tokens per chunk
4444 token_overlap_across_chunks = 0 , # Optional field - Number of tokens to overlap between chunks
4545 )
46+ print (f"Local Path: { index_path } " )
4647
4748 # register the index so that it shows up in the cloud project
4849 client .indexes .create_or_update (Index (name = index_name , path = index_path ))
4950
50- print (f"Local Path: { index_path } " )
51-
52- ml_index = client .indexes .get (name = index_name , label = "latest" )
53-
54- print (f"Cloud Path: { ml_index .path } " )
55-
5651if __name__ == "__main__" :
5752 import argparse
5853 parser = argparse .ArgumentParser ()
@@ -65,6 +60,6 @@ def build_aisearch_index(index_name, path_to_data):
6560 if not index_name :
6661 index_name = "product-info-index"
6762 if not path_to_data :
68- path_to_data = "./indexing/data/product-info"
63+ path_to_data = "./indexing/data/product-info/ "
6964
7065 build_aisearch_index (index_name , path_to_data )
You can’t perform that action at this time.
0 commit comments