Jump to content

Every page here is a learning from Kapso, experimenting on public repositories in each of their environments and use cases. Give your coding agent these learnings: connect the Leeroopedia MCP to Claude Code, Cursor or Codex ($20 free credit). Powered by Leeroo · founders@leeroo.com

Environment:AI Northstar Tech Vector io Python CLI

From Leeroopedia
Knowledge Sources
Domains Infrastructure, Vector_Databases
Last Updated 2026-10-15 00:00 GMT

Overview

Cross-platform Python 3.x CLI environment for the vector-io (VDF) library, enabling export, import, and re-embedding of vector datasets across 10+ vector databases.

Description

This environment provides the standard Python runtime context for all vector-io CLI operations. It is built on Python 3.x and includes a comprehensive dependency stack covering multiple vector database clients (Pinecone, Qdrant, Milvus, AstraDB, etc.), embedding backends (LiteLLM, Sentence Transformers, MLX), and data processing libraries (pandas, pyarrow, numpy). The package is installed via `pip install vdf_io` which registers nine console script entry points. Telemetry via Sentry/OpenTelemetry is enabled by default but can be disabled.

Usage

Use this environment for any VDF Export, VDF Import, or VDF Re-embedding workflow. It is the mandatory prerequisite for running the Export_CLI, Import_CLI, ExportVDB, ImportVDB, Reembed, Call_Litellm, Set_Arg_From_Input, Standardize_Metric, and Get_Parquet_Files implementations. Each vector database backend requires its own API key credential.

System Requirements

Category Requirement Notes
OS Linux, macOS, or Windows Cross-platform; macOS Apple Silicon supported for MLX embeddings
Hardware CPU (GPU optional) GPU required only for local Sentence Transformers re-embedding (CUDA or Apple Silicon MPS)
Disk Variable Sufficient for exported parquet files; default max file size 1024 MB
Python Python 3.8+ Required for f-strings, typing, and packaging
Network Internet access Required for vector database APIs and HuggingFace Hub

Dependencies

System Packages

  • Python 3.8+ runtime
  • pip package manager

Python Packages

  • `numpy`
  • `pandas`
  • `pyarrow`
  • `pinecone-client[grpc]` ~= 4.0
  • `qdrant_client`
  • `pymilvus` >= 2.3.6
  • `openai` >= 1.10.0
  • `litellm` >= 1.20.0
  • `google-cloud-aiplatform`
  • `google-api-python-client`
  • `google-auth-httplib2`
  • `google-auth-oauthlib`
  • `ratelimit`
  • `backoff`
  • `kdbai-client`
  • `sentry-sdk[opentelemetry]`
  • `halo`
  • `sentence-transformers` >= 2.6.1
  • `pyvespa`
  • `lancedb`
  • `chromadb`
  • `txtai`
  • `weaviate-client` >= 4.0.0
  • `astrapy`
  • `cassandra-driver`
  • `tenacity`
  • `torch`
  • `datasets` ~= 2.16, >= 2.19.0
  • `mlx_embedding_models`
  • `azure-search-documents`
  • `azure-identity`
  • `turbopuffer[fast]`
  • `psycopg2`
  • `python-dotenv`
  • `tqdm`
  • `huggingface_hub`

Credentials

The following environment variables may be required depending on the target vector database. Set them in a `.env` file or export them in the shell:

  • `PINECONE_API_KEY`: Pinecone API key (export/import)
  • `QDRANT_API_KEY`: Qdrant API key (export/import)
  • `OPENAI_API_KEY`: OpenAI API key (re-embedding with OpenAI models)
  • `ASTRA_DB_APPLICATION_TOKEN`: Astra DB application token (export/import)
  • `ASTRA_DB_API_ENDPOINT`: Astra DB API endpoint URL (export/import)
  • `ZILLIZ_CLOUD_TOKEN`: Milvus/Zilliz cloud token (import)
  • `TURBOPUFFER_API_KEY`: Turbopuffer API key (export/import)
  • `AZUREAI_API_KEY`: Azure AI Search API key (import)
  • `LANCEDB_API_KEY`: LanceDB API key (import)
  • `CASSANDRA_USER`: Cassandra username (AstraDB CQL)
  • `CASSANDRA_PASSWORD`: Cassandra password (AstraDB CQL)
  • `CASSANDRA_URI`: Cassandra connection URI (AstraDB CQL)
  • `DISABLE_TELEMETRY_VECTORIO`: Set to `1` to disable Sentry/OpenTelemetry telemetry

Quick Install

# Install vector-io and all dependencies
pip install vdf_io

# Or install from source
pip install -e .

# Install with .env file support (recommended)
echo "PINECONE_API_KEY=your_key_here" > .env
echo "DISABLE_TELEMETRY_VECTORIO=1" >> .env  # optional: disable telemetry

Code Evidence

Package setup with console scripts from `setup.py:13-24`:

entry_points={
    "console_scripts": [
        "export_vdf=vdf_io.export_vdf_cli:main",
        "import_vdf=vdf_io.import_vdf_cli:main",
        "reembed_vdf=vdf_io.scripts.reembed:main",
        "consolidate_parquet_vdf=vdf_io.scripts.consolidate_parquet:main",
        "get_id_list_vdf=vdf_io.scripts.get_id_list:main",
        "push_to_hub_vdf=vdf_io.scripts.push_to_hub_vdf:main",
        "bump_version_vdf=vdf_io.scripts.bump_version:main",
        "check_for_updates_vdf=vdf_io.scripts.check_for_updates:main",
        "count_vdf=vdf_io.scripts.count_rows:main",
    ],
},

Telemetry opt-out check from `export_vdf_cli.py:68`:

if os.environ.get("DISABLE_TELEMETRY_VECTORIO", False) != "1":
    sentry_sdk.init(
        dsn="https://4826b78415eeaf0135c12416e222596d@o1284436.ingest.sentry.io/4506716331573248",
        enable_tracing=True,
        instrumenter="otel",
        default_integrations=False,
    )

Version compatibility check from `vdf_import_cls.py:101-104`:

elif Version(self.vdf_meta["version"]) > Version(self.args["library_version"]):
    print(
        f"Warning: The version of vector-io library: ({self.args['library_version']}) "
        f"is behind the version of the vdf directory: ({self.vdf_meta['version']})."
    )

Credential collection with env var fallback from `util.py:95-100`:

if (
    (default_value is None)
    and (env_var is not None)
    and (os.getenv(env_var) is not None)
):
    default_value = os.getenv(env_var)

Default batch size constant from `constants.py:4`:

DEFAULT_BATCH_SIZE = 10_000

Common Errors

Error Message Cause Solution
`Invalid dir path, VDF_META.json not found` Import directory lacks VDF metadata Ensure the directory was exported using `export_vdf` and contains `VDF_META.json`
`Class ... lacks required class variable 'DB_NAME_SLUG'` Custom ExportVDB/ImportVDB subclass missing DB_NAME_SLUG Add `DB_NAME_SLUG = DBNames.YOUR_DB` to the subclass
`No parquet files found in the specified directory` Re-embedding on directory without parquet files Run `export_vdf` first or provide a valid VDF directory
`Could not fetch vectors` Pinecone API error during batch fetch Reduce batch size or check API key and network
`Failed to resolve dimensions for index '...'` Cannot determine vector dimensions from data Ensure parquet files contain valid vector columns
`ModuleNotFoundError: No module named 'pymilvus'` Optional DB client not installed `pip install pymilvus>=2.3.6`
Warning: `library_version` behind vdf version VDF data exported with newer library version Upgrade vector-io: `pip install --upgrade vdf_io`

Compatibility Notes

  • Apple Silicon (M1/M2/M3): MLX embedding backend auto-detected via `os.uname().machine == "arm64"`. Use `--disable_mlx` flag to force CPU/GPU instead.
  • GPU (CUDA): Sentence Transformers auto-detects CUDA via `torch.cuda.is_available()` for local re-embedding acceleration.
  • Windows: Not explicitly tested; Python 3.x should work but some DB clients may have native dependency issues.
  • Telemetry: Sentry/OpenTelemetry is enabled by default in both `export_vdf_cli.py` and `import_vdf_cli.py`. Set `DISABLE_TELEMETRY_VECTORIO=1` to opt out.
  • Vector database clients: Not all 10+ DB clients need to be installed simultaneously; only the target DB client is required at runtime. Missing clients for unused DBs will not cause import errors due to dynamic module loading.

Related Pages

Page Connections

Double-click a node to navigate. Hold to expand connections.
Principle
Implementation
Heuristic
Environment