Eunomia SDK for LangChain
This project has been archived.
The maintainers of this project have marked this project as archived. No new releases are expected.
Project description
Eunomia SDK for LangChain
This package allows to streamline LangChain's loaders resources and their metadata to the Eunomia server for an easier policy configuration process.
Installation
Install the eunomia-sdk-langchain package via pip:
pip install eunomia-sdk-langchain
Usage
The EunomiaLoader class is a wrapper around any loader class from LangChain.
Assume you want to use the CSVLoader, you can do the following:
from eunomia_sdk_langchain import EunomiaLoader
from langchain_community.document_loaders.csv_loader import CSVLoader
loader = CSVLoader(...)
wrapped_loader = EunomiaLoader(loader, server_url="http://localhost:8000")
You can then call any of the load methods:
# Synchronous loading
docs = wrapped_loader.load()
# Synchronous lazy loading
docs = []
for doc in wrapped_loader.lazy_load():
docs.append(doc)
# Asynchronous loading
import asyncio
asyncio.run(wrapped_loader.aload())
# Asynchronous lazy loading
docs = []
async for doc in wrapped_loader.alazy_load():
docs.append(doc)
All loaded documents will be automatically sent to the Eunomia server which will assign an identifier to each document and store their metadata. The identifiers and metadata can then be used to configure policies in the Eunomia server.
Documentation
For detailed usage, check out the SDK's documentation.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file eunomia_sdk_langchain-0.1.0.tar.gz.
File metadata
- Download URL: eunomia_sdk_langchain-0.1.0.tar.gz
- Upload date:
- Size: 2.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.6.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
89f3e8c307ac209eeea2f519d43f8d4e10dd7691b125e4827c2ddfba65929ffc
|
|
| MD5 |
68bee6b650d367039009f92caaa9b617
|
|
| BLAKE2b-256 |
30ce463481cb9dbe91c3423edefe99b04cad391149b3b1f0ff2eef8e078dec72
|
File details
Details for the file eunomia_sdk_langchain-0.1.0-py3-none-any.whl.
File metadata
- Download URL: eunomia_sdk_langchain-0.1.0-py3-none-any.whl
- Upload date:
- Size: 3.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.6.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
420f0bc8a15774bffe603ca5d7c7c7ad671611020726a9b24743a1eb17042238
|
|
| MD5 |
569556a27e99bee3e017cb511c0005fe
|
|
| BLAKE2b-256 |
904faa79c19e0f42ce60e0057caa152bcce2531c3363b5e2cfbe91ffb3165d79
|