Skip to content

Commit

Permalink
test: pull DI URL from environment in doctest
Browse files Browse the repository at this point in the history
  • Loading branch information
Michael-JB committed Dec 5, 2024
1 parent fe65883 commit ab7be5f
Showing 1 changed file with 4 additions and 13 deletions.
17 changes: 4 additions & 13 deletions src/documentation/document_index.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,7 @@
"source": [
"## Upload documents to the Document Index\n",
"\n",
"To search through the DI, you'll first need to upload the documents to it.\n",
"For now, we'll use the [DI instance hosted by Aleph Alpha](https://app.document-index.aleph-alpha.com).\n",
"We assume you have an assigned namespace and possess a token to access it."
"To search through the DI, you'll first need to upload the documents to it. We assume that the URL of your DI instance is available under the `DOCUMENT_INDEX_URL` environment variable, and that you already have a namespace and a token to access it."
]
},
{
Expand All @@ -72,8 +70,8 @@
"metadata": {},
"outputs": [],
"source": [
"# specify this for your own namespace\n",
"NAMESPACE = \"aleph-alpha\""
"# change this to your namespace\n",
"NAMESPACE = \"Search\""
]
},
{
Expand All @@ -84,7 +82,7 @@
"source": [
"document_index = DocumentIndexClient(\n",
" token=getenv(\"AA_TOKEN\"),\n",
" base_document_index_url=\"https://document-index.aleph-alpha.com\",\n",
" base_document_index_url=getenv(\"DOCUMENT_INDEX_URL\"),\n",
")"
]
},
Expand Down Expand Up @@ -659,13 +657,6 @@
"source": [
"tracer"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
Expand Down

0 comments on commit ab7be5f

Please sign in to comment.