diff --git a/data/create-azure-search.py b/data/create-azure-search.py index 520dbd7e..d6000249 100644 --- a/data/create-azure-search.py +++ b/data/create-azure-search.py @@ -12,6 +12,12 @@ # In[1]: +get_ipython().system(' pip install pandas, azure-identity, azure-search-documents, openai, python-dotenv') + + +# In[2]: + + import os import pandas as pd from azure.identity import DefaultAzureCredential, get_bearer_token_provider @@ -45,7 +51,7 @@ load_dotenv() -# In[2]: +# In[3]: def delete_index(search_index_client: SearchIndexClient, search_index: str): @@ -53,7 +59,7 @@ def delete_index(search_index_client: SearchIndexClient, search_index: str): search_index_client.delete_index(search_index) -# In[3]: +# In[4]: def create_index_definition(name: str) -> SearchIndex: @@ -137,7 +143,7 @@ def create_index_definition(name: str) -> SearchIndex: return index -# In[4]: +# In[5]: def gen_products( @@ -176,7 +182,7 @@ def gen_products( return items -# In[5]: +# In[6]: aisearch_endpoint = os.environ["AZURE_SEARCH_ENDPOINT"] @@ -193,7 +199,7 @@ def gen_products( print(f"index {index_name} created") -# In[6]: +# In[7]: print(f"indexing documents") diff --git a/infra/ai.yaml b/infra/ai.yaml index 1eed19aa..820b17c4 100644 --- a/infra/ai.yaml +++ b/infra/ai.yaml @@ -24,7 +24,7 @@ deployments: version: "2024-05-13" sku: name: "GlobalStandard" - capacity: 20 + capacity: 19 - name: gpt-4-evals model: format: OpenAI @@ -32,4 +32,4 @@ deployments: version: "0613" sku: name: "Standard" - capacity: 10 + capacity: 8