mirror of
https://github.com/hwchase17/langchain.git
synced 2025-06-22 06:39:52 +00:00
docs: updated tutorials for Image generation and Vector Search (#21000)
Description: docs: updated tutorials for Image generation and Vector Search @lkuligin for review --------- Co-authored-by: adityarane@google.com <adityarane@google.com>
This commit is contained in:
parent
17bbb7d2a5
commit
07ce39bfe7
382
docs/docs/integrations/tools/google_imagen.ipynb
Normal file
382
docs/docs/integrations/tools/google_imagen.ipynb
Normal file
File diff suppressed because one or more lines are too long
@ -187,6 +187,28 @@
|
|||||||
"## Create Vector Store from texts"
|
"## Create Vector Store from texts"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"cell_type": "markdown",
|
||||||
|
"id": "4d98d379",
|
||||||
|
"metadata": {},
|
||||||
|
"source": [
|
||||||
|
"NOTE : If you have existing Index and Endpoints, you can load them using below code"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"cell_type": "code",
|
||||||
|
"execution_count": null,
|
||||||
|
"id": "066c0f63",
|
||||||
|
"metadata": {},
|
||||||
|
"outputs": [],
|
||||||
|
"source": [
|
||||||
|
"# TODO : replace 1234567890123456789 with your acutial index ID\n",
|
||||||
|
"my_index = aiplatform.MatchingEngineIndex(\"1234567890123456789\")\n",
|
||||||
|
"\n",
|
||||||
|
"# TODO : replace 1234567890123456789 with your acutial endpoint ID\n",
|
||||||
|
"my_index_endpoint = aiplatform.MatchingEngineIndexEndpoint(\"1234567890123456789\")"
|
||||||
|
]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"cell_type": "code",
|
"cell_type": "code",
|
||||||
"execution_count": null,
|
"execution_count": null,
|
||||||
@ -679,17 +701,6 @@
|
|||||||
"vector_store.add_texts(texts=texts, metadatas=metadatas, is_complete_overwrite=True)"
|
"vector_store.add_texts(texts=texts, metadatas=metadatas, is_complete_overwrite=True)"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"cell_type": "code",
|
|
||||||
"execution_count": null,
|
|
||||||
"id": "711efca3",
|
|
||||||
"metadata": {},
|
|
||||||
"outputs": [],
|
|
||||||
"source": [
|
|
||||||
"my_index = aiplatform.MatchingEngineIndex(\"5908955807575179264\")\n",
|
|
||||||
"my_index_endpoint = aiplatform.MatchingEngineIndexEndpoint(\"7751631742611488768\")"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"cell_type": "code",
|
"cell_type": "code",
|
||||||
"execution_count": null,
|
"execution_count": null,
|
||||||
@ -735,7 +746,8 @@
|
|||||||
"mimetype": "text/x-python",
|
"mimetype": "text/x-python",
|
||||||
"name": "python",
|
"name": "python",
|
||||||
"nbconvert_exporter": "python",
|
"nbconvert_exporter": "python",
|
||||||
"pygments_lexer": "ipython3"
|
"pygments_lexer": "ipython3",
|
||||||
|
"version": "3.11.6"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nbformat": 4,
|
"nbformat": 4,
|
||||||
|
Loading…
Reference in New Issue
Block a user