From 5d60c6ed4bc373581bb78cb0d163e1e2dc0a510e Mon Sep 17 00:00:00 2001 From: Matt Gotteiner <[email protected]> Date: Wed, 21 Feb 2024 15:54:43 -0800 Subject: [PATCH] isolating dependencies --- ...-huggingface-model-sample-requirements.txt | 5 +++ ...ctor-python-huggingface-model-sample.ipynb | 38 ++++++++++++------- 2 files changed, 29 insertions(+), 14 deletions(-) create mode 100644 demo-python/code/azure-search-vector-python-huggingface-model-sample-requirements.txt diff --git a/demo-python/code/azure-search-vector-python-huggingface-model-sample-requirements.txt b/demo-python/code/azure-search-vector-python-huggingface-model-sample-requirements.txt new file mode 100644 index 0000000..c29e891 --- /dev/null +++ b/demo-python/code/azure-search-vector-python-huggingface-model-sample-requirements.txt @@ -0,0 +1,5 @@ +python-dotenv +azure-search-documents==11.6.0b1 +azure-identity +sentence-transformers +ipywidgets \ No newline at end of file diff --git a/demo-python/code/azure-search-vector-python-huggingface-model-sample.ipynb b/demo-python/code/azure-search-vector-python-huggingface-model-sample.ipynb index fd77a3d..d2b738f 100644 --- a/demo-python/code/azure-search-vector-python-huggingface-model-sample.ipynb +++ b/demo-python/code/azure-search-vector-python-huggingface-model-sample.ipynb @@ -32,11 +32,21 @@ }, { "cell_type": "code", - "execution_count": null, + "execution_count": 5, "metadata": {}, - "outputs": [], + "outputs": [ + { + "name": "stderr", + "output_type": "stream", + "text": [ + "\n", + "[notice] A new release of pip is available: 23.2.1 -> 24.0\n", + "[notice] To update, run: python.exe -m pip install --upgrade pip\n" + ] + } + ], "source": [ - "! pip install -r requirements.txt --quiet" + "! pip install -r azure-search-vector-python-huggingface-model-sample-requirements.txt --quiet" ] }, { @@ -48,7 +58,7 @@ }, { "cell_type": "code", - "execution_count": 11, + "execution_count": 6, "metadata": {}, "outputs": [], "source": [ @@ -76,7 +86,7 @@ }, { "cell_type": "code", - "execution_count": 3, + "execution_count": 7, "metadata": {}, "outputs": [], "source": [ @@ -113,14 +123,14 @@ }, { "cell_type": "code", - "execution_count": 13, + "execution_count": 8, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ - "huggingface-e5-index created\n" + "huggingface-test created\n" ] } ], @@ -199,7 +209,7 @@ }, { "cell_type": "code", - "execution_count": 15, + "execution_count": 9, "metadata": {}, "outputs": [ { @@ -233,7 +243,7 @@ }, { "cell_type": "code", - "execution_count": 18, + "execution_count": 10, "metadata": {}, "outputs": [ { @@ -284,7 +294,7 @@ }, { "cell_type": "code", - "execution_count": 19, + "execution_count": 11, "metadata": {}, "outputs": [ { @@ -329,7 +339,7 @@ }, { "cell_type": "code", - "execution_count": 20, + "execution_count": 12, "metadata": {}, "outputs": [ { @@ -376,7 +386,7 @@ }, { "cell_type": "code", - "execution_count": 21, + "execution_count": 13, "metadata": {}, "outputs": [ { @@ -424,7 +434,7 @@ }, { "cell_type": "code", - "execution_count": 22, + "execution_count": 14, "metadata": {}, "outputs": [ { @@ -470,7 +480,7 @@ }, { "cell_type": "code", - "execution_count": 26, + "execution_count": 15, "metadata": {}, "outputs": [ {