Skip to main content

RAG-X Library

Overview

RAG-X is a comprehensive library designed to optimize Retrieval-Augmented Generation (RAG) processes. It provides a suite of tools to automatically determine the best parameters for processing specific documents. This includes selecting appropriate chunking techniques, embedding models, vector databases, and Language Model (LLM) configurations.

Key Features:

  • Adaptive Chunking: Incorporates four advanced text chunking methodologies to enhance the handling of diverse document structures.
    • Specific Text Splitting
    • Recursive Text Splitting
    • Sentence Window Splitting
    • Semantic Window Splitting
  • Expandability: Future versions will introduce additional chunking strategies and enhancements based on user feedback and ongoing research.
  • Compatibility: Designed to seamlessly integrate with a wide range of embedding models and vector databases.

Getting Started

Installation

To get started, install the test_RAG_X library using the following command:

pip install test-RAG-X

To verify the installation and view library details, execute:

pip show RAG-X

Setting Up Your Environment

Before diving into the functionality of RAG-X, ensure that your environment variables are properly configured with your OpenAI API key and your Hugging Face token:

import os

os.environ['OPENAI_API_KEY'] = "YOUR_OPENAI_API_KEY"
os.environ['HF_TOKEN'] = "YOUR_HUGGINGFACE_TOKEN"

Usage

The following steps guide you through the process of utilizing the RAG-X library to optimize your RAG parameters:

from test_RAG_X.prag import parent_class

# Specify the path to your PDF document
file_path = "PATH_TO_YOUR_PDF_FILE"

# Initialize the RAG-X instance
my_instance = parent_class(file_path)

# Generate the optimal RAG parameters for your document
score_card = my_instance.get_best_param()

# Output the results
print(score_card)

Metadata

Release files for testpackage123321 0.1.7

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for testpackage123321 0.1.7
File Size Uploaded Provenance Actions
testpackage123321-0.1.7.tar.gz 11.2 kB Without provenance Details for testpackage123321-0.1.7.tar.gz

Release files / testpackage123321-0.1.7.tar.gz

Download URL testpackage123321-0.1.7.tar.gz
Size 11.2 kB
Tags Source
SHA-256 checksum
How to use checksums
9053fb69f28624e94011ef602254f4ff97370bdd11cd6b2766dac9a84d52f848
BLAKE2b-256 checksum
How to use checksums
0498355ac92dc2f06f9ab644e349d6edff6a91471d50eafd7c8392c5519cad02
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.11.5

Security for testpackage123321 0.1.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page