Skip to main content

RAGent Core

Shared components for the RAGent pipelines and environments, including data-source loaders, LanceDB retrieval, agent search tools, judges, common types, and operational scripts.

Setup

From this directory, install the locked dependencies:

uv sync

Copy .env-template to an uncommitted .env when credentials or remote storage configuration are needed.

Operational scripts

Run the scripts from the repository root with uv run --project ragent_core. The default LanceDB URI is relative, so this keeps local indexes in the repository-level lancedb/ directory rather than under ragent_core/.

Build LanceDB indexes

Build chunk and document tables for every split in diegi97/ragent_data_sources:

uv run --project ragent_core python ragent_core/scripts/build_lancedb_indexes.py \
  --device cuda --batch-size 512

Build one source only:

uv run --project ragent_core python ragent_core/scripts/build_lancedb_indexes.py \
  --data-source nampdn_ai_devdocs_io --device cuda --batch-size 512

Create lexical BM25/FTS and scalar indexes without embeddings:

uv run --project ragent_core python ragent_core/scripts/build_lancedb_indexes.py \
  --data-source nampdn_ai_devdocs_io --no-embedding

Each source produces <data_source>_chunks and <data_source>_documents tables under lancedb/<namespace>/. Use --namespace to select another namespace.

Build the PersonaHub diversity index

PersonaHub is intended as a future diversity pool for synthetic-data generation, not as a searchable source corpus. Its pipeline integration is still a work in progress and it is not currently used.

uv run --project ragent_core python ragent_core/scripts/build_personahub_lancedb_index.py \
  --device cuda --batch-size 512

Use --limit 100 for a small smoke test.

Sync indexes with GCS

GCS can act as the durable store while local LanceDB remains the hot read path. Configure LANCEDB_GCS_URI and, if needed, GCS_SERVICE_ACCOUNT, then upload or download a namespace:

uv run --project ragent_core python ragent_core/scripts/sync_lancedb_gcs.py upload \
  --namespace default
uv run --project ragent_core python ragent_core/scripts/sync_lancedb_gcs.py download \
  --namespace default

Synchronization mirrors the source namespace to the destination. The script requires gsutil, plus gcloud when activating a service account.

Upload a data source

Data-source modules normalize corpora to the shared id, title, and text schema. Validate one locally:

uv run --project ragent_core python ragent_core/scripts/upload_data_source.py \
  posthog_com --dry-run

Upload it as an independent Hugging Face dataset split:

uv run --project ragent_core python ragent_core/scripts/upload_data_source.py posthog_com

Pass --overwrite to replace that source's split while preserving the others, or --repo-id owner/dataset to target another dataset.

Question-rubric publication and generated-data synchronization belong to the data_pipelines project.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ragent_core-0.3.0.tar.gz (359.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ragent_core-0.3.0-py3-none-any.whl (50.1 kB view details)

Uploaded Python 3

File details

Details for the file ragent_core-0.3.0.tar.gz.

File metadata

  • Download URL: ragent_core-0.3.0.tar.gz
  • Upload date:
  • Size: 359.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.5 {"installer":{"name":"uv","version":"0.11.5","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for ragent_core-0.3.0.tar.gz
Algorithm Hash digest
SHA256 1de7f66e4c614d524c6eb5f4355727eaad6faa846e08491fd681056cb2de3bf4
MD5 e0c72d42c66e5d2b39ce766116a61ad1
BLAKE2b-256 1cc8bcd329688d4840adf6da23ec7adb1383c6ee184649f1b0cbd1cb19484927

See more details on using hashes here.

File details

Details for the file ragent_core-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: ragent_core-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 50.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.5 {"installer":{"name":"uv","version":"0.11.5","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for ragent_core-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 a3189a4ef2170be199f6b632aa6a060fb4769f57a020df5a80a49e9752e4a3bc
MD5 33b0d0084dc40f381d2d29cfcb2e4992
BLAKE2b-256 79d301c2f2e1ec4704b680bc050a89853c9f056702ac1af01d7299376a6259de

See more details on using hashes here.

Release history Release notifications | RSS feed

0.4.2

2 files

0.4.1

2 files

0.4.0

2 files

This release

0.3.0 This release

2 files

0.2.1

2 files

0.2.0

2 files

0.1.1

2 files

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