vibe.providers_common

Common utilities for VIBE provider modules.

This module provides shared functions used by embedding_providers, rerank_providers, and potentially other provider modules.

get_provider_config

get_provider_config(section: str, key: str) -> dict[str, Any] | None

Get provider config from global config.yml.

Parameters:
  • section (str) –

    Config section name (e.g., "embedding_providers", "rerank_providers")

  • key (str) –

    Provider key within the section (e.g., "local", "berget")

Returns:
  • dict[str, Any] | None

    Provider configuration dict, or None if not found

import_class

import_class(class_path: str) -> type

Dynamically import a class from a module path.

Parameters:
  • class_path (str) –

    Fully qualified class path (e.g., "vibe.embedding_providers.local.LocalEmbeddingProvider")

Returns:
  • type

    The imported class