Skip to content

Commit

Permalink
generateReadme: Refresh
Browse files Browse the repository at this point in the history
  • Loading branch information
actions-user committed Sep 27, 2023
1 parent 62a23a4 commit 9c547e2
Show file tree
Hide file tree
Showing 5 changed files with 142 additions and 86 deletions.
48 changes: 24 additions & 24 deletions .github/push_templates_to_algolia.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,10 @@
"id": "aa0e3e6f-1260-4452-8abf-7c084e26c8a4",
"metadata": {
"execution": {
"iopub.execute_input": "2023-09-27T12:04:53.135222Z",
"iopub.status.busy": "2023-09-27T12:04:53.134838Z",
"iopub.status.idle": "2023-09-27T12:04:53.192987Z",
"shell.execute_reply": "2023-09-27T12:04:53.192317Z"
"iopub.execute_input": "2023-09-27T12:39:15.190965Z",
"iopub.status.busy": "2023-09-27T12:39:15.190304Z",
"iopub.status.idle": "2023-09-27T12:39:15.248496Z",
"shell.execute_reply": "2023-09-27T12:39:15.247769Z"
},
"papermill": {},
"tags": []
Expand Down Expand Up @@ -95,10 +95,10 @@
"id": "cfa97168-63eb-4e8c-89c3-0a5d26f47740",
"metadata": {
"execution": {
"iopub.execute_input": "2023-09-27T12:04:53.196574Z",
"iopub.status.busy": "2023-09-27T12:04:53.196346Z",
"iopub.status.idle": "2023-09-27T12:04:53.201271Z",
"shell.execute_reply": "2023-09-27T12:04:53.200655Z"
"iopub.execute_input": "2023-09-27T12:39:15.252481Z",
"iopub.status.busy": "2023-09-27T12:39:15.251865Z",
"iopub.status.idle": "2023-09-27T12:39:15.255953Z",
"shell.execute_reply": "2023-09-27T12:39:15.255289Z"
},
"papermill": {},
"tags": []
Expand Down Expand Up @@ -141,10 +141,10 @@
"id": "7a9c86c2-931d-4113-abbc-31b3f517b6c4",
"metadata": {
"execution": {
"iopub.execute_input": "2023-09-27T12:04:53.204594Z",
"iopub.status.busy": "2023-09-27T12:04:53.204182Z",
"iopub.status.idle": "2023-09-27T12:04:53.219707Z",
"shell.execute_reply": "2023-09-27T12:04:53.218973Z"
"iopub.execute_input": "2023-09-27T12:39:15.259365Z",
"iopub.status.busy": "2023-09-27T12:39:15.258798Z",
"iopub.status.idle": "2023-09-27T12:39:15.274861Z",
"shell.execute_reply": "2023-09-27T12:39:15.274038Z"
},
"tags": []
},
Expand Down Expand Up @@ -178,10 +178,10 @@
"id": "c50e96b2-4403-413c-a99a-9243be0c0a04",
"metadata": {
"execution": {
"iopub.execute_input": "2023-09-27T12:04:53.222782Z",
"iopub.status.busy": "2023-09-27T12:04:53.222343Z",
"iopub.status.idle": "2023-09-27T12:04:53.982327Z",
"shell.execute_reply": "2023-09-27T12:04:53.981475Z"
"iopub.execute_input": "2023-09-27T12:39:15.278355Z",
"iopub.status.busy": "2023-09-27T12:39:15.277781Z",
"iopub.status.idle": "2023-09-27T12:39:16.158199Z",
"shell.execute_reply": "2023-09-27T12:39:16.157464Z"
},
"tags": []
},
Expand Down Expand Up @@ -230,10 +230,10 @@
"id": "da661ba3-fd15-4abc-bd4f-d13ae77b82b0",
"metadata": {
"execution": {
"iopub.execute_input": "2023-09-27T12:04:53.986249Z",
"iopub.status.busy": "2023-09-27T12:04:53.985785Z",
"iopub.status.idle": "2023-09-27T12:04:55.030778Z",
"shell.execute_reply": "2023-09-27T12:04:55.029882Z"
"iopub.execute_input": "2023-09-27T12:39:16.161924Z",
"iopub.status.busy": "2023-09-27T12:39:16.161520Z",
"iopub.status.idle": "2023-09-27T12:39:17.111412Z",
"shell.execute_reply": "2023-09-27T12:39:17.110673Z"
},
"tags": []
},
Expand All @@ -260,10 +260,10 @@
"id": "f1482a8f-4ce5-4e04-93c8-ddd883375d67",
"metadata": {
"execution": {
"iopub.execute_input": "2023-09-27T12:04:55.034288Z",
"iopub.status.busy": "2023-09-27T12:04:55.033833Z",
"iopub.status.idle": "2023-09-27T12:04:55.051488Z",
"shell.execute_reply": "2023-09-27T12:04:55.050831Z"
"iopub.execute_input": "2023-09-27T12:39:17.115092Z",
"iopub.status.busy": "2023-09-27T12:39:17.114598Z",
"iopub.status.idle": "2023-09-27T12:39:17.132336Z",
"shell.execute_reply": "2023-09-27T12:39:17.131782Z"
},
"tags": []
},
Expand Down
97 changes: 76 additions & 21 deletions LangChain/LangChain_Vector_Search_on_PDF.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -27,24 +27,27 @@
},
"source": [
"# LangChain - Vector Search on PDF\n",
"<a href=\"https://app.naas.ai/user-redirect/naas/downloader?url=https://raw.githubusercontent.com/jupyter-naas/awesome-notebooks/master/template.ipynb\" target=\"_parent\">\n",
"<img src=\"https://naasai-public.s3.eu-west-3.amazonaws.com/open_in_naas.svg\"/>\n",
"</a>\n",
"<br><br><a href=\"https://github.com/jupyter-naas/awesome-notebooks/issues/new?assignees=&labels=&template=template-request.md&title=Tool+-+Action+of+the+notebook+\">Template request</a> | <a href=\"https://github.com/jupyter-naas/awesome-notebooks/issues/new?assignees=&labels=&template=bug_report.md&title=[ERROR]+Tool+/+Folder+Action+of+the+notebook+\">Bug report</a>"
"<a href=\"https://app.naas.ai/user-redirect/naas/downloader?url=https://raw.githubusercontent.com/jupyter-naas/awesome-notebooks/master/LangChain/LangChain_Vector_Search_on_PDF.ipynb\" target=\"_parent\"><img src=\"https://naasai-public.s3.eu-west-3.amazonaws.com/Open_in_Naas_Lab.svg\"/></a><br><br><a href=\"https://bit.ly/3JyWIk6\">Give Feedback</a> | <a href=\"https://github.com/jupyter-naas/awesome-notebooks/issues/new?assignees=&labels=bug&template=bug_report.md&title=LangChain+-+Vector+Search+on+PDF:+Error+short+description\">Bug report</a>"
]
},
{
"cell_type": "markdown",
"id": "religious-programmer",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"**Tags:** #langchain #pdf #weaviate #huggingface #llm #database #embeddings"
]
},
{
"cell_type": "markdown",
"id": "1fe9f56e-561c-4f52-aef8-b861c9462107",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"**Author:** [Sriniketh Jayasendil](https://www.linkedin.com/in/sriniketh-jayasendil)"
]
Expand All @@ -63,7 +66,10 @@
{
"cell_type": "markdown",
"id": "31ea7cdb-e10d-43fc-b026-f69249a59736",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"**Description:** This notebook is used to perform vector search on your PDF and it will answer basic questions that are closely related based on the prompt provided.\n",
"\n",
Expand All @@ -81,7 +87,10 @@
{
"cell_type": "markdown",
"id": "1a14806c-9da2-446e-b8fd-b55f8d7ac3f0",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"**References:**\n",
"- [Langchain docs](https://python.langchain.com/docs/get_started/introduction.html)\n",
Expand All @@ -103,7 +112,10 @@
{
"cell_type": "markdown",
"id": "numeric-mediterranean",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"### Import libraries"
]
Expand All @@ -113,6 +125,7 @@
"execution_count": null,
"id": "potential-surfing",
"metadata": {
"papermill": {},
"tags": []
},
"outputs": [],
Expand Down Expand Up @@ -148,7 +161,10 @@
{
"cell_type": "markdown",
"id": "64db5ac5-046f-4203-8503-990002927075",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"### Setup variables\n",
"- `pdf_file`: Path to which the PDF file exists.\",\n",
Expand All @@ -162,6 +178,7 @@
"execution_count": null,
"id": "continuous-melbourne",
"metadata": {
"papermill": {},
"tags": []
},
"outputs": [],
Expand All @@ -175,15 +192,21 @@
{
"cell_type": "markdown",
"id": "registered-showcase",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"## Model"
]
},
{
"cell_type": "markdown",
"id": "8ae9725c-161a-47f6-a115-7d74cee3bd2f",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"### Setup environ"
]
Expand All @@ -193,6 +216,7 @@
"execution_count": null,
"id": "bd067008-9cf1-45b1-a6d1-c37627dc4976",
"metadata": {
"papermill": {},
"tags": []
},
"outputs": [],
Expand All @@ -203,7 +227,10 @@
{
"cell_type": "markdown",
"id": "tested-astrology",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"### Extract text from PDF"
]
Expand Down Expand Up @@ -237,7 +264,10 @@
{
"cell_type": "markdown",
"id": "8daa42c1-3a2b-4f96-a7dd-fb1deb395a84",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"### Split the text into chunks scraped from the PDF"
]
Expand Down Expand Up @@ -267,7 +297,10 @@
{
"cell_type": "markdown",
"id": "ef1720bf-a28a-4757-b189-7df97947c158",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"### Create embeddings of the text make it compatible to store it in the database"
]
Expand All @@ -277,6 +310,7 @@
"execution_count": null,
"id": "e4a376ac-a10e-4d6a-ba01-e5445efdf091",
"metadata": {
"papermill": {},
"tags": []
},
"outputs": [],
Expand All @@ -290,7 +324,10 @@
{
"cell_type": "markdown",
"id": "4169feb2-05ac-4914-bbb2-501dae7dcd89",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"### Store the embeddings into the weaviate database"
]
Expand All @@ -300,6 +337,7 @@
"execution_count": null,
"id": "6922b1d4-e394-493a-8549-07ba3c947e7d",
"metadata": {
"papermill": {},
"tags": []
},
"outputs": [],
Expand All @@ -311,7 +349,10 @@
{
"cell_type": "markdown",
"id": "981fac74-2e1e-4b62-8b91-09d51d344bba",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"### Get the closest response to the user query on the PDF"
]
Expand All @@ -321,6 +362,7 @@
"execution_count": null,
"id": "bdf9e7a9-7de9-4c50-b677-97cb2a1d5d3b",
"metadata": {
"papermill": {},
"tags": []
},
"outputs": [],
Expand All @@ -339,7 +381,9 @@
"iopub.status.idle": "2021-07-02T23:32:10.796900Z",
"shell.execute_reply": "2021-07-02T23:32:10.796358Z",
"shell.execute_reply.started": "2021-07-02T23:32:10.789033Z"
}
},
"papermill": {},
"tags": []
},
"source": [
"## Output"
Expand All @@ -348,7 +392,10 @@
{
"cell_type": "markdown",
"id": "890f7c86-b7bb-4f5d-9a1b-e492dd9580fd",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"source": [
"### Show the response"
]
Expand All @@ -358,6 +405,7 @@
"execution_count": null,
"id": "9c4e3b7b-6440-4844-8054-265f1aec65eb",
"metadata": {
"papermill": {},
"tags": []
},
"outputs": [],
Expand All @@ -370,7 +418,10 @@
"cell_type": "code",
"execution_count": null,
"id": "5e2bc7f1-acf9-402b-b0aa-93de14764f8b",
"metadata": {},
"metadata": {
"papermill": {},
"tags": []
},
"outputs": [],
"source": []
}
Expand All @@ -393,6 +444,10 @@
"pygments_lexer": "ipython3",
"version": "3.9.6"
},
"naas": {
"notebook_id": "327f0a8a8dfb334ce84fe3443964d4f1607c5346b593742909d57a379024620f",
"notebook_path": "LangChain/LangChain_Vector_Search_on_PDF.ipynb"
},
"papermill": {
"default_parameters": {},
"environment_variables": {},
Expand All @@ -409,4 +464,4 @@
},
"nbformat": 4,
"nbformat_minor": 5
}
}
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -608,6 +608,7 @@ We are committed to sharing templates and giving shout outs to the contributors
* [Gmail Toolkit](https://github.com/jupyter-naas/awesome-notebooks/blob/master/LangChain/LangChain_Gmail_Toolkit.ipynb)
* [JSON Agent](https://github.com/jupyter-naas/awesome-notebooks/blob/master/LangChain/LangChain_JSON_Agent.ipynb)
* [Pandas Dataframe Agent](https://github.com/jupyter-naas/awesome-notebooks/blob/master/LangChain/LangChain_Pandas_Dataframe_Agent.ipynb)
* [Vector Search on PDF](https://github.com/jupyter-naas/awesome-notebooks/blob/master/LangChain/LangChain_Vector_Search_on_PDF.ipynb)

## LeFigaro
* [House Price analysis](https://github.com/jupyter-naas/awesome-notebooks/blob/master/LeFigaro/LeFigaro_House_Price_analysis.ipynb)
Expand Down
Loading

0 comments on commit 9c547e2

Please sign in to comment.