Name | llama-index-readers-elasticsearch JSON |
Version |
0.2.1
JSON |
| download |
home_page | None |
Summary | llama-index readers elasticsearch integration |
upload_time | 2024-08-24 00:28:49 |
maintainer | jaylmiller |
docs_url | None |
author | Your Name |
requires_python | <4.0,>=3.8.1 |
license | MIT |
keywords |
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
# LlamaIndex Readers Integration: Elasticsearch
## Overview
Elasticsearch (or Opensearch) Reader over REST API is a tool designed to read documents from an Elasticsearch or Opensearch index using the basic search API. These documents can then be utilized in downstream LlamaIndex data structures.
### Installation
You can install Elasticsearch (or Opensearch) Reader via pip:
```bash
pip install llama-index-readers-elasticsearch
```
## Usage
```python
from llama_index.core.schema import Document
from llama_index.readers.elasticsearch import ElasticsearchReader
# Initialize ElasticsearchReader
reader = ElasticsearchReader(
endpoint="<Your Elasticsearch/Opensearch Endpoint>",
index="<Index Name>",
httpx_client_args={
"timeout": 10
}, # Optional additional arguments for the httpx.Client
)
# Load data from Elasticsearch
documents = reader.load_data(
field="<Field Name>", # Field in the document to retrieve text from
query={"query": {"match_all": {}}}, # Elasticsearch JSON query DSL object
embedding_field="<Embedding Field>", # Field for embeddings (optional)
)
```
This loader is designed to be used as a way to load data into
[LlamaIndex](https://github.com/run-llama/llama_index/tree/main/llama_index) and/or subsequently
used as a Tool in a [LangChain](https://github.com/hwchase17/langchain) Agent.
Raw data
{
"_id": null,
"home_page": null,
"name": "llama-index-readers-elasticsearch",
"maintainer": "jaylmiller",
"docs_url": null,
"requires_python": "<4.0,>=3.8.1",
"maintainer_email": null,
"keywords": null,
"author": "Your Name",
"author_email": "you@example.com",
"download_url": "https://files.pythonhosted.org/packages/0d/96/7946936ac062fabadd8b37b15409bcf89b77d800a5f6817b97e8bfd85199/llama_index_readers_elasticsearch-0.2.1.tar.gz",
"platform": null,
"description": "# LlamaIndex Readers Integration: Elasticsearch\n\n## Overview\n\nElasticsearch (or Opensearch) Reader over REST API is a tool designed to read documents from an Elasticsearch or Opensearch index using the basic search API. These documents can then be utilized in downstream LlamaIndex data structures.\n\n### Installation\n\nYou can install Elasticsearch (or Opensearch) Reader via pip:\n\n```bash\npip install llama-index-readers-elasticsearch\n```\n\n## Usage\n\n```python\nfrom llama_index.core.schema import Document\nfrom llama_index.readers.elasticsearch import ElasticsearchReader\n\n# Initialize ElasticsearchReader\nreader = ElasticsearchReader(\n endpoint=\"<Your Elasticsearch/Opensearch Endpoint>\",\n index=\"<Index Name>\",\n httpx_client_args={\n \"timeout\": 10\n }, # Optional additional arguments for the httpx.Client\n)\n\n# Load data from Elasticsearch\ndocuments = reader.load_data(\n field=\"<Field Name>\", # Field in the document to retrieve text from\n query={\"query\": {\"match_all\": {}}}, # Elasticsearch JSON query DSL object\n embedding_field=\"<Embedding Field>\", # Field for embeddings (optional)\n)\n```\n\nThis loader is designed to be used as a way to load data into\n[LlamaIndex](https://github.com/run-llama/llama_index/tree/main/llama_index) and/or subsequently\nused as a Tool in a [LangChain](https://github.com/hwchase17/langchain) Agent.\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "llama-index readers elasticsearch integration",
"version": "0.2.1",
"project_urls": null,
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "e3081d2c705948907a18042ccb57e8082d159151e438852b5d2619efeebd9888",
"md5": "e7a394e08ac391986928e3d5e1d51321",
"sha256": "d0a42a13510efd59716f23736737a59cc89a12ad649330c59c481cdbac001f35"
},
"downloads": -1,
"filename": "llama_index_readers_elasticsearch-0.2.1-py3-none-any.whl",
"has_sig": false,
"md5_digest": "e7a394e08ac391986928e3d5e1d51321",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": "<4.0,>=3.8.1",
"size": 3332,
"upload_time": "2024-08-24T00:28:48",
"upload_time_iso_8601": "2024-08-24T00:28:48.395969Z",
"url": "https://files.pythonhosted.org/packages/e3/08/1d2c705948907a18042ccb57e8082d159151e438852b5d2619efeebd9888/llama_index_readers_elasticsearch-0.2.1-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "0d967946936ac062fabadd8b37b15409bcf89b77d800a5f6817b97e8bfd85199",
"md5": "1d78926af7f687338889e881e57b190d",
"sha256": "0c8855bad3b4767a225a8fee221a3b7f9b2595f02b6c2d10aabf27da1c879dbe"
},
"downloads": -1,
"filename": "llama_index_readers_elasticsearch-0.2.1.tar.gz",
"has_sig": false,
"md5_digest": "1d78926af7f687338889e881e57b190d",
"packagetype": "sdist",
"python_version": "source",
"requires_python": "<4.0,>=3.8.1",
"size": 2844,
"upload_time": "2024-08-24T00:28:49",
"upload_time_iso_8601": "2024-08-24T00:28:49.836290Z",
"url": "https://files.pythonhosted.org/packages/0d/96/7946936ac062fabadd8b37b15409bcf89b77d800a5f6817b97e8bfd85199/llama_index_readers_elasticsearch-0.2.1.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-08-24 00:28:49",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "llama-index-readers-elasticsearch"
}