{
"cells": [
{
"cell_type": "markdown",
"metadata": {
"id": "view-in-github",
"colab_type": "text"
},
"source": [
""
]
},
{
"cell_type": "markdown",
"metadata": {
"id": "5BGJ3fxhOk2V"
},
"source": [
"# Install Packages and Setup Variables\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"collapsed": true,
"id": "QPJzr-I9XQ7l"
},
"outputs": [],
"source": [
"!pip install -q llama-index==0.10.57 llama-index-vector-stores-chroma llama-index-llms-gemini==0.1.11 langchain_google_genai google-generativeai==0.5.4 langchain==0.1.17 langchain-chroma langchain_openai==0.1.5 openai==1.37.0 chromadb"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"id": "riuXwpSPcvWC"
},
"outputs": [],
"source": [
"import os\n",
"# Set the following API Keys in the Python environment. Will be used later.\n",
"os.environ[\"OPENAI_API_KEY\"] = \"\"\n",
"os.environ[\"GOOGLE_API_KEY\"] = \"\"\n",
"\n",
"# from google.colab import userdata\n",
"# os.environ[\"OPENAI_API_KEY\"] = userdata.get('openai_api_key')\n",
"# os.environ[\"GOOGLE_API_KEY\"] = userdata.get('Google_api_key')"
]
},
{
"cell_type": "markdown",
"metadata": {
"id": "I9JbAzFcjkpn"
},
"source": [
"# Load the Dataset (CSV)\n"
]
},
{
"cell_type": "markdown",
"metadata": {
"id": "_Tif8-JoRH68"
},
"source": [
"## Download\n"
]
},
{
"cell_type": "markdown",
"metadata": {
"id": "4fQaa1LN1mXL"
},
"source": [
"The dataset includes several articles from the TowardsAI blog, which provide an in-depth explanation of the LLaMA2 model. Read the dataset as a long string.\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"colab": {
"base_uri": "https://localhost:8080/"
},
"id": "-QTUkdfJjY4N",
"outputId": "34becd46-808a-42ee-e620-3e6b18f79e1d"
},
"outputs": [
{
"output_type": "stream",
"name": "stdout",
"text": [
" % Total % Received % Xferd Average Speed Time Time Time Current\n",
" Dload Upload Total Spent Left Speed\n",
"100 169k 100 169k 0 0 609k 0 --:--:-- --:--:-- --:--:-- 612k\n"
]
}
],
"source": [
"!curl -o ./mini-dataset.csv https://raw.githubusercontent.com/AlaFalaki/tutorial_notebooks/main/data/mini-llama-articles.csv"
]
},
{
"cell_type": "markdown",
"metadata": {
"id": "zk-4alIxROo8"
},
"source": [
"## Read File\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"colab": {
"base_uri": "https://localhost:8080/"
},
"id": "7CYwRT6R0o0I",
"outputId": "394603bd-6d33-40aa-8e06-6ef802879234"
},
"outputs": [
{
"output_type": "stream",
"name": "stdout",
"text": [
"171044\n"
]
}
],
"source": [
"import csv\n",
"\n",
"text = \"\"\n",
"\n",
"# Load the file as a JSON\n",
"with open(\"./mini-dataset.csv\", mode=\"r\", encoding=\"utf-8\") as file:\n",
" csv_reader = csv.reader(file)\n",
"\n",
" for idx, row in enumerate(csv_reader):\n",
" if idx == 0:\n",
" continue\n",
" text += row[1]\n",
"\n",
"# The number of characters in the dataset.\n",
"print(len(text))"
]
},
{
"cell_type": "markdown",
"metadata": {
"id": "S17g2RYOjmf2"
},
"source": [
"# Chunking\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"colab": {
"base_uri": "https://localhost:8080/"
},
"id": "STACTMUR1z9N",
"outputId": "d5360ce2-2c1e-459b-a3b3-e9899fe762b5"
},
"outputs": [
{
"output_type": "stream",
"name": "stdout",
"text": [
"335\n"
]
}
],
"source": [
"chunk_size = 512\n",
"chunks = []\n",
"\n",
"# Split the long text into smaller manageable chunks of 512 characters.\n",
"for i in range(0, len(text), chunk_size):\n",
" chunks.append(text[i : i + chunk_size])\n",
"\n",
"print(len(chunks))"
]
},
{
"cell_type": "markdown",
"metadata": {
"id": "9fOomeMGqu10"
},
"source": [
"#Interface of Chroma with LlamaIndex\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"id": "CtdsIUQ81_hT"
},
"outputs": [],
"source": [
"from llama_index.core import Document\n",
"\n",
"# Convert the chunks to Document objects so the LlamaIndex framework can process them.\n",
"documents = [Document(text=t) for t in chunks]"
]
},
{
"cell_type": "markdown",
"metadata": {
"id": "OWaT6rL7ksp8"
},
"source": [
"Save on Chroma\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"id": "mXi56KTXk2sp"
},
"outputs": [],
"source": [
"import chromadb\n",
"\n",
"# create client and a new collection\n",
"# chromadb.EphemeralClient saves data in-memory.\n",
"chroma_client = chromadb.PersistentClient(path=\"./mini-chunked-dataset\")\n",
"chroma_collection = chroma_client.create_collection(\"mini-chunked-dataset\")"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"id": "jKXURvLtkuTS"
},
"outputs": [],
"source": [
"from llama_index.vector_stores.chroma import ChromaVectorStore\n",
"from llama_index.core import StorageContext\n",
"\n",
"# Define a storage context object using the created vector database.\n",
"vector_store = ChromaVectorStore(chroma_collection=chroma_collection)\n",
"storage_context = StorageContext.from_defaults(vector_store=vector_store)"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"colab": {
"base_uri": "https://localhost:8080/",
"height": 81,
"referenced_widgets": [
"1a0185d42be8489c87874049e5d78424",
"e91d7972a14b4444808d649d5db15b7a",
"bd3eab2dfee94512b88d88fbd4cb3682",
"3ba2fa0f0c8449c3a22ff3593d2b6629",
"eb7ce1338f6a4c9a8fb9a92e8de78821",
"d9daeb567dcc4387a7ba406a559aa422",
"2a99f51fa5c24ce09f629d9d5322879d",
"edfd151ed26646d8a6d293a3cf1ecce6",
"032b979544624bd4a9f7eb91fa9dd2e8",
"28d35749a3fa4c6f80f626221f95cde1",
"3d78bf2951e04c21bd89c1d944412e5a",
"a0991085ef794c8cbf509370b67df911",
"780fa2ff5938403cb2c109c491368dce",
"f833fd603aa543f59a7e93fe980935cc",
"48e949bbaf7c4079bbe8fcf620066b8e",
"78fd41df7f604f0290dc034c9f01a18c",
"d2df0b3067574d46b951890b996a5751",
"b51937856bf64803a85ea7eb30f73cfe",
"74fe3cd416994417a2138d8a32beeed8",
"80626b461cce49e7bcb6e3e931c5d81c",
"23f0bdb422384eaf94a69d20502fdbe4",
"dfa74d96a1174e7ead6554b5c984f526"
]
},
"id": "WsD52wtrlESi",
"outputId": "2d522a85-cdea-477b-a693-e26b404c8ed9"
},
"outputs": [
{
"output_type": "display_data",
"data": {
"text/plain": [
"Parsing nodes: 0%| | 0/335 [00:00, ?it/s]"
],
"application/vnd.jupyter.widget-view+json": {
"version_major": 2,
"version_minor": 0,
"model_id": "1a0185d42be8489c87874049e5d78424"
}
},
"metadata": {}
},
{
"output_type": "display_data",
"data": {
"text/plain": [
"Generating embeddings: 0%| | 0/335 [00:00, ?it/s]"
],
"application/vnd.jupyter.widget-view+json": {
"version_major": 2,
"version_minor": 0,
"model_id": "a0991085ef794c8cbf509370b67df911"
}
},
"metadata": {}
}
],
"source": [
"from llama_index.core import VectorStoreIndex\n",
"from llama_index.core.node_parser import SentenceSplitter\n",
"from llama_index.embeddings.openai import OpenAIEmbedding\n",
"\n",
"# Build index / generate embeddings using OpenAI embedding model\n",
"index = VectorStoreIndex.from_documents(\n",
" documents,\n",
" embed_model=OpenAIEmbedding(model=\"text-embedding-3-small\"),\n",
" storage_context=storage_context,\n",
" show_progress=True,\n",
")"
]
},
{
"cell_type": "markdown",
"metadata": {
"id": "8JPD8yAinVSq"
},
"source": [
"Query Dataset\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"id": "mzS13x1ZlZ5X"
},
"outputs": [],
"source": [
"# Define a query engine that is responsible for retrieving related pieces of text,\n",
"# and using a LLM to formulate the final answer.\n",
"\n",
"from llama_index.llms.gemini import Gemini\n",
"\n",
"llm = Gemini(model=\"models/gemini-1.5-flash\", temperature=1, max_tokens=512)\n",
"\n",
"query_engine = index.as_query_engine(llm=llm, similarity_top_k=5)"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"id": "AYsQ4uLN_Oxg",
"colab": {
"base_uri": "https://localhost:8080/",
"height": 52
},
"outputId": "f56876cc-f7bc-4e63-bb7b-9515e9b404cc"
},
"outputs": [
{
"output_type": "stream",
"name": "stdout",
"text": [
"The LLaMA 2 model has four different sizes: 7 billion, 13 billion, 34 billion, and 70 billion parameters. \n",
"\n"
]
}
],
"source": [
"response = query_engine.query(\"How many parameters LLaMA2 model has?\")\n",
"print(response)"
]
},
{
"cell_type": "markdown",
"metadata": {
"id": "kWK571VNg-qR"
},
"source": [
"# Interface of Chroma with LangChain\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"id": "SMPAniL2e4NP"
},
"outputs": [],
"source": [
"from langchain.schema.document import Document\n",
"\n",
"# Convert the chunks to Document objects so the LangChain framework can process them.\n",
"documents = [Document(page_content=t) for t in chunks]"
]
},
{
"cell_type": "markdown",
"metadata": {
"id": "QBt8qGxArUPD"
},
"source": [
"Save on Chroma\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"id": "2xas7HkuhJ8A"
},
"outputs": [],
"source": [
"from langchain_chroma import Chroma\n",
"from langchain_openai import OpenAIEmbeddings\n",
"\n",
"# Add the documents to chroma DB and create Index / embeddings\n",
"\n",
"embeddings = OpenAIEmbeddings(model=\"text-embedding-3-small\")\n",
"chroma_db = Chroma.from_documents(\n",
" documents=documents,\n",
" embedding=embeddings,\n",
" persist_directory=\"./mini-chunked-dataset\",\n",
" collection_name=\"mini-chunked-dataset\",\n",
")"
]
},
{
"cell_type": "markdown",
"metadata": {
"id": "P8AXJJyBrZWF"
},
"source": [
"Query Dataset\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"id": "-H64YLxshM2b"
},
"outputs": [],
"source": [
"from langchain_google_genai import ChatGoogleGenerativeAI\n",
"\n",
"# Initializing the LLM model\n",
"#llm = ChatOpenAI(temperature=0, model=\"gpt-4o-mini\", max_tokens=512)\n",
"\n",
"llm = ChatGoogleGenerativeAI(\n",
" model=\"gemini-1.5-flash\",\n",
" temperature=0,\n",
" max_tokens=512,\n",
")"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"id": "AxBqPNtthPaa",
"colab": {
"base_uri": "https://localhost:8080/"
},
"outputId": "607b082a-66c2-49a2-ca59-b3cb85bf6067"
},
"outputs": [
{
"output_type": "stream",
"name": "stdout",
"text": [
"The LLaMA 2 model comes in four different sizes: 7 billion, 13 billion, 34 billion, and 70 billion parameters. \n",
"\n"
]
}
],
"source": [
"from langchain.chains import RetrievalQA\n",
"\n",
"query = \"How many parameters LLaMA 2 model has?\"\n",
"retriever = chroma_db.as_retriever(search_kwargs={\"k\": 4})\n",
"# Define a RetrievalQA chain that is responsible for retrieving related pieces of text,\n",
"# and using a LLM to formulate the final answer.\n",
"chain = RetrievalQA.from_chain_type(llm=llm, chain_type=\"stuff\", retriever=retriever)\n",
"\n",
"response = chain.invoke(query)\n",
"print(response[\"result\"])"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"id": "AKr16L_kwyYX"
},
"outputs": [],
"source": []
}
],
"metadata": {
"colab": {
"provenance": [],
"include_colab_link": true
},
"kernelspec": {
"display_name": "Python 3",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.12.4"
},
"widgets": {
"application/vnd.jupyter.widget-state+json": {
"1a0185d42be8489c87874049e5d78424": {
"model_module": "@jupyter-widgets/controls",
"model_name": "HBoxModel",
"model_module_version": "1.5.0",
"state": {
"_dom_classes": [],
"_model_module": "@jupyter-widgets/controls",
"_model_module_version": "1.5.0",
"_model_name": "HBoxModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/controls",
"_view_module_version": "1.5.0",
"_view_name": "HBoxView",
"box_style": "",
"children": [
"IPY_MODEL_e91d7972a14b4444808d649d5db15b7a",
"IPY_MODEL_bd3eab2dfee94512b88d88fbd4cb3682",
"IPY_MODEL_3ba2fa0f0c8449c3a22ff3593d2b6629"
],
"layout": "IPY_MODEL_eb7ce1338f6a4c9a8fb9a92e8de78821"
}
},
"e91d7972a14b4444808d649d5db15b7a": {
"model_module": "@jupyter-widgets/controls",
"model_name": "HTMLModel",
"model_module_version": "1.5.0",
"state": {
"_dom_classes": [],
"_model_module": "@jupyter-widgets/controls",
"_model_module_version": "1.5.0",
"_model_name": "HTMLModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/controls",
"_view_module_version": "1.5.0",
"_view_name": "HTMLView",
"description": "",
"description_tooltip": null,
"layout": "IPY_MODEL_d9daeb567dcc4387a7ba406a559aa422",
"placeholder": "",
"style": "IPY_MODEL_2a99f51fa5c24ce09f629d9d5322879d",
"value": "Parsing nodes: 100%"
}
},
"bd3eab2dfee94512b88d88fbd4cb3682": {
"model_module": "@jupyter-widgets/controls",
"model_name": "FloatProgressModel",
"model_module_version": "1.5.0",
"state": {
"_dom_classes": [],
"_model_module": "@jupyter-widgets/controls",
"_model_module_version": "1.5.0",
"_model_name": "FloatProgressModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/controls",
"_view_module_version": "1.5.0",
"_view_name": "ProgressView",
"bar_style": "success",
"description": "",
"description_tooltip": null,
"layout": "IPY_MODEL_edfd151ed26646d8a6d293a3cf1ecce6",
"max": 335,
"min": 0,
"orientation": "horizontal",
"style": "IPY_MODEL_032b979544624bd4a9f7eb91fa9dd2e8",
"value": 335
}
},
"3ba2fa0f0c8449c3a22ff3593d2b6629": {
"model_module": "@jupyter-widgets/controls",
"model_name": "HTMLModel",
"model_module_version": "1.5.0",
"state": {
"_dom_classes": [],
"_model_module": "@jupyter-widgets/controls",
"_model_module_version": "1.5.0",
"_model_name": "HTMLModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/controls",
"_view_module_version": "1.5.0",
"_view_name": "HTMLView",
"description": "",
"description_tooltip": null,
"layout": "IPY_MODEL_28d35749a3fa4c6f80f626221f95cde1",
"placeholder": "",
"style": "IPY_MODEL_3d78bf2951e04c21bd89c1d944412e5a",
"value": " 335/335 [00:00<00:00, 3304.59it/s]"
}
},
"eb7ce1338f6a4c9a8fb9a92e8de78821": {
"model_module": "@jupyter-widgets/base",
"model_name": "LayoutModel",
"model_module_version": "1.2.0",
"state": {
"_model_module": "@jupyter-widgets/base",
"_model_module_version": "1.2.0",
"_model_name": "LayoutModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/base",
"_view_module_version": "1.2.0",
"_view_name": "LayoutView",
"align_content": null,
"align_items": null,
"align_self": null,
"border": null,
"bottom": null,
"display": null,
"flex": null,
"flex_flow": null,
"grid_area": null,
"grid_auto_columns": null,
"grid_auto_flow": null,
"grid_auto_rows": null,
"grid_column": null,
"grid_gap": null,
"grid_row": null,
"grid_template_areas": null,
"grid_template_columns": null,
"grid_template_rows": null,
"height": null,
"justify_content": null,
"justify_items": null,
"left": null,
"margin": null,
"max_height": null,
"max_width": null,
"min_height": null,
"min_width": null,
"object_fit": null,
"object_position": null,
"order": null,
"overflow": null,
"overflow_x": null,
"overflow_y": null,
"padding": null,
"right": null,
"top": null,
"visibility": null,
"width": null
}
},
"d9daeb567dcc4387a7ba406a559aa422": {
"model_module": "@jupyter-widgets/base",
"model_name": "LayoutModel",
"model_module_version": "1.2.0",
"state": {
"_model_module": "@jupyter-widgets/base",
"_model_module_version": "1.2.0",
"_model_name": "LayoutModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/base",
"_view_module_version": "1.2.0",
"_view_name": "LayoutView",
"align_content": null,
"align_items": null,
"align_self": null,
"border": null,
"bottom": null,
"display": null,
"flex": null,
"flex_flow": null,
"grid_area": null,
"grid_auto_columns": null,
"grid_auto_flow": null,
"grid_auto_rows": null,
"grid_column": null,
"grid_gap": null,
"grid_row": null,
"grid_template_areas": null,
"grid_template_columns": null,
"grid_template_rows": null,
"height": null,
"justify_content": null,
"justify_items": null,
"left": null,
"margin": null,
"max_height": null,
"max_width": null,
"min_height": null,
"min_width": null,
"object_fit": null,
"object_position": null,
"order": null,
"overflow": null,
"overflow_x": null,
"overflow_y": null,
"padding": null,
"right": null,
"top": null,
"visibility": null,
"width": null
}
},
"2a99f51fa5c24ce09f629d9d5322879d": {
"model_module": "@jupyter-widgets/controls",
"model_name": "DescriptionStyleModel",
"model_module_version": "1.5.0",
"state": {
"_model_module": "@jupyter-widgets/controls",
"_model_module_version": "1.5.0",
"_model_name": "DescriptionStyleModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/base",
"_view_module_version": "1.2.0",
"_view_name": "StyleView",
"description_width": ""
}
},
"edfd151ed26646d8a6d293a3cf1ecce6": {
"model_module": "@jupyter-widgets/base",
"model_name": "LayoutModel",
"model_module_version": "1.2.0",
"state": {
"_model_module": "@jupyter-widgets/base",
"_model_module_version": "1.2.0",
"_model_name": "LayoutModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/base",
"_view_module_version": "1.2.0",
"_view_name": "LayoutView",
"align_content": null,
"align_items": null,
"align_self": null,
"border": null,
"bottom": null,
"display": null,
"flex": null,
"flex_flow": null,
"grid_area": null,
"grid_auto_columns": null,
"grid_auto_flow": null,
"grid_auto_rows": null,
"grid_column": null,
"grid_gap": null,
"grid_row": null,
"grid_template_areas": null,
"grid_template_columns": null,
"grid_template_rows": null,
"height": null,
"justify_content": null,
"justify_items": null,
"left": null,
"margin": null,
"max_height": null,
"max_width": null,
"min_height": null,
"min_width": null,
"object_fit": null,
"object_position": null,
"order": null,
"overflow": null,
"overflow_x": null,
"overflow_y": null,
"padding": null,
"right": null,
"top": null,
"visibility": null,
"width": null
}
},
"032b979544624bd4a9f7eb91fa9dd2e8": {
"model_module": "@jupyter-widgets/controls",
"model_name": "ProgressStyleModel",
"model_module_version": "1.5.0",
"state": {
"_model_module": "@jupyter-widgets/controls",
"_model_module_version": "1.5.0",
"_model_name": "ProgressStyleModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/base",
"_view_module_version": "1.2.0",
"_view_name": "StyleView",
"bar_color": null,
"description_width": ""
}
},
"28d35749a3fa4c6f80f626221f95cde1": {
"model_module": "@jupyter-widgets/base",
"model_name": "LayoutModel",
"model_module_version": "1.2.0",
"state": {
"_model_module": "@jupyter-widgets/base",
"_model_module_version": "1.2.0",
"_model_name": "LayoutModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/base",
"_view_module_version": "1.2.0",
"_view_name": "LayoutView",
"align_content": null,
"align_items": null,
"align_self": null,
"border": null,
"bottom": null,
"display": null,
"flex": null,
"flex_flow": null,
"grid_area": null,
"grid_auto_columns": null,
"grid_auto_flow": null,
"grid_auto_rows": null,
"grid_column": null,
"grid_gap": null,
"grid_row": null,
"grid_template_areas": null,
"grid_template_columns": null,
"grid_template_rows": null,
"height": null,
"justify_content": null,
"justify_items": null,
"left": null,
"margin": null,
"max_height": null,
"max_width": null,
"min_height": null,
"min_width": null,
"object_fit": null,
"object_position": null,
"order": null,
"overflow": null,
"overflow_x": null,
"overflow_y": null,
"padding": null,
"right": null,
"top": null,
"visibility": null,
"width": null
}
},
"3d78bf2951e04c21bd89c1d944412e5a": {
"model_module": "@jupyter-widgets/controls",
"model_name": "DescriptionStyleModel",
"model_module_version": "1.5.0",
"state": {
"_model_module": "@jupyter-widgets/controls",
"_model_module_version": "1.5.0",
"_model_name": "DescriptionStyleModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/base",
"_view_module_version": "1.2.0",
"_view_name": "StyleView",
"description_width": ""
}
},
"a0991085ef794c8cbf509370b67df911": {
"model_module": "@jupyter-widgets/controls",
"model_name": "HBoxModel",
"model_module_version": "1.5.0",
"state": {
"_dom_classes": [],
"_model_module": "@jupyter-widgets/controls",
"_model_module_version": "1.5.0",
"_model_name": "HBoxModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/controls",
"_view_module_version": "1.5.0",
"_view_name": "HBoxView",
"box_style": "",
"children": [
"IPY_MODEL_780fa2ff5938403cb2c109c491368dce",
"IPY_MODEL_f833fd603aa543f59a7e93fe980935cc",
"IPY_MODEL_48e949bbaf7c4079bbe8fcf620066b8e"
],
"layout": "IPY_MODEL_78fd41df7f604f0290dc034c9f01a18c"
}
},
"780fa2ff5938403cb2c109c491368dce": {
"model_module": "@jupyter-widgets/controls",
"model_name": "HTMLModel",
"model_module_version": "1.5.0",
"state": {
"_dom_classes": [],
"_model_module": "@jupyter-widgets/controls",
"_model_module_version": "1.5.0",
"_model_name": "HTMLModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/controls",
"_view_module_version": "1.5.0",
"_view_name": "HTMLView",
"description": "",
"description_tooltip": null,
"layout": "IPY_MODEL_d2df0b3067574d46b951890b996a5751",
"placeholder": "",
"style": "IPY_MODEL_b51937856bf64803a85ea7eb30f73cfe",
"value": "Generating embeddings: 100%"
}
},
"f833fd603aa543f59a7e93fe980935cc": {
"model_module": "@jupyter-widgets/controls",
"model_name": "FloatProgressModel",
"model_module_version": "1.5.0",
"state": {
"_dom_classes": [],
"_model_module": "@jupyter-widgets/controls",
"_model_module_version": "1.5.0",
"_model_name": "FloatProgressModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/controls",
"_view_module_version": "1.5.0",
"_view_name": "ProgressView",
"bar_style": "success",
"description": "",
"description_tooltip": null,
"layout": "IPY_MODEL_74fe3cd416994417a2138d8a32beeed8",
"max": 335,
"min": 0,
"orientation": "horizontal",
"style": "IPY_MODEL_80626b461cce49e7bcb6e3e931c5d81c",
"value": 335
}
},
"48e949bbaf7c4079bbe8fcf620066b8e": {
"model_module": "@jupyter-widgets/controls",
"model_name": "HTMLModel",
"model_module_version": "1.5.0",
"state": {
"_dom_classes": [],
"_model_module": "@jupyter-widgets/controls",
"_model_module_version": "1.5.0",
"_model_name": "HTMLModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/controls",
"_view_module_version": "1.5.0",
"_view_name": "HTMLView",
"description": "",
"description_tooltip": null,
"layout": "IPY_MODEL_23f0bdb422384eaf94a69d20502fdbe4",
"placeholder": "",
"style": "IPY_MODEL_dfa74d96a1174e7ead6554b5c984f526",
"value": " 335/335 [00:03<00:00, 89.38it/s]"
}
},
"78fd41df7f604f0290dc034c9f01a18c": {
"model_module": "@jupyter-widgets/base",
"model_name": "LayoutModel",
"model_module_version": "1.2.0",
"state": {
"_model_module": "@jupyter-widgets/base",
"_model_module_version": "1.2.0",
"_model_name": "LayoutModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/base",
"_view_module_version": "1.2.0",
"_view_name": "LayoutView",
"align_content": null,
"align_items": null,
"align_self": null,
"border": null,
"bottom": null,
"display": null,
"flex": null,
"flex_flow": null,
"grid_area": null,
"grid_auto_columns": null,
"grid_auto_flow": null,
"grid_auto_rows": null,
"grid_column": null,
"grid_gap": null,
"grid_row": null,
"grid_template_areas": null,
"grid_template_columns": null,
"grid_template_rows": null,
"height": null,
"justify_content": null,
"justify_items": null,
"left": null,
"margin": null,
"max_height": null,
"max_width": null,
"min_height": null,
"min_width": null,
"object_fit": null,
"object_position": null,
"order": null,
"overflow": null,
"overflow_x": null,
"overflow_y": null,
"padding": null,
"right": null,
"top": null,
"visibility": null,
"width": null
}
},
"d2df0b3067574d46b951890b996a5751": {
"model_module": "@jupyter-widgets/base",
"model_name": "LayoutModel",
"model_module_version": "1.2.0",
"state": {
"_model_module": "@jupyter-widgets/base",
"_model_module_version": "1.2.0",
"_model_name": "LayoutModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/base",
"_view_module_version": "1.2.0",
"_view_name": "LayoutView",
"align_content": null,
"align_items": null,
"align_self": null,
"border": null,
"bottom": null,
"display": null,
"flex": null,
"flex_flow": null,
"grid_area": null,
"grid_auto_columns": null,
"grid_auto_flow": null,
"grid_auto_rows": null,
"grid_column": null,
"grid_gap": null,
"grid_row": null,
"grid_template_areas": null,
"grid_template_columns": null,
"grid_template_rows": null,
"height": null,
"justify_content": null,
"justify_items": null,
"left": null,
"margin": null,
"max_height": null,
"max_width": null,
"min_height": null,
"min_width": null,
"object_fit": null,
"object_position": null,
"order": null,
"overflow": null,
"overflow_x": null,
"overflow_y": null,
"padding": null,
"right": null,
"top": null,
"visibility": null,
"width": null
}
},
"b51937856bf64803a85ea7eb30f73cfe": {
"model_module": "@jupyter-widgets/controls",
"model_name": "DescriptionStyleModel",
"model_module_version": "1.5.0",
"state": {
"_model_module": "@jupyter-widgets/controls",
"_model_module_version": "1.5.0",
"_model_name": "DescriptionStyleModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/base",
"_view_module_version": "1.2.0",
"_view_name": "StyleView",
"description_width": ""
}
},
"74fe3cd416994417a2138d8a32beeed8": {
"model_module": "@jupyter-widgets/base",
"model_name": "LayoutModel",
"model_module_version": "1.2.0",
"state": {
"_model_module": "@jupyter-widgets/base",
"_model_module_version": "1.2.0",
"_model_name": "LayoutModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/base",
"_view_module_version": "1.2.0",
"_view_name": "LayoutView",
"align_content": null,
"align_items": null,
"align_self": null,
"border": null,
"bottom": null,
"display": null,
"flex": null,
"flex_flow": null,
"grid_area": null,
"grid_auto_columns": null,
"grid_auto_flow": null,
"grid_auto_rows": null,
"grid_column": null,
"grid_gap": null,
"grid_row": null,
"grid_template_areas": null,
"grid_template_columns": null,
"grid_template_rows": null,
"height": null,
"justify_content": null,
"justify_items": null,
"left": null,
"margin": null,
"max_height": null,
"max_width": null,
"min_height": null,
"min_width": null,
"object_fit": null,
"object_position": null,
"order": null,
"overflow": null,
"overflow_x": null,
"overflow_y": null,
"padding": null,
"right": null,
"top": null,
"visibility": null,
"width": null
}
},
"80626b461cce49e7bcb6e3e931c5d81c": {
"model_module": "@jupyter-widgets/controls",
"model_name": "ProgressStyleModel",
"model_module_version": "1.5.0",
"state": {
"_model_module": "@jupyter-widgets/controls",
"_model_module_version": "1.5.0",
"_model_name": "ProgressStyleModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/base",
"_view_module_version": "1.2.0",
"_view_name": "StyleView",
"bar_color": null,
"description_width": ""
}
},
"23f0bdb422384eaf94a69d20502fdbe4": {
"model_module": "@jupyter-widgets/base",
"model_name": "LayoutModel",
"model_module_version": "1.2.0",
"state": {
"_model_module": "@jupyter-widgets/base",
"_model_module_version": "1.2.0",
"_model_name": "LayoutModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/base",
"_view_module_version": "1.2.0",
"_view_name": "LayoutView",
"align_content": null,
"align_items": null,
"align_self": null,
"border": null,
"bottom": null,
"display": null,
"flex": null,
"flex_flow": null,
"grid_area": null,
"grid_auto_columns": null,
"grid_auto_flow": null,
"grid_auto_rows": null,
"grid_column": null,
"grid_gap": null,
"grid_row": null,
"grid_template_areas": null,
"grid_template_columns": null,
"grid_template_rows": null,
"height": null,
"justify_content": null,
"justify_items": null,
"left": null,
"margin": null,
"max_height": null,
"max_width": null,
"min_height": null,
"min_width": null,
"object_fit": null,
"object_position": null,
"order": null,
"overflow": null,
"overflow_x": null,
"overflow_y": null,
"padding": null,
"right": null,
"top": null,
"visibility": null,
"width": null
}
},
"dfa74d96a1174e7ead6554b5c984f526": {
"model_module": "@jupyter-widgets/controls",
"model_name": "DescriptionStyleModel",
"model_module_version": "1.5.0",
"state": {
"_model_module": "@jupyter-widgets/controls",
"_model_module_version": "1.5.0",
"_model_name": "DescriptionStyleModel",
"_view_count": null,
"_view_module": "@jupyter-widgets/base",
"_view_module_version": "1.2.0",
"_view_name": "StyleView",
"description_width": ""
}
}
}
}
},
"nbformat": 4,
"nbformat_minor": 0
}