• Home
  • Categories
  • Tags
  • Pricing
  • Submit
    Decorative pattern
    1. Home
    2. Sdks & Libraries
    3. OpenAIEmbeddingFunction

    OpenAIEmbeddingFunction

    An embedding function that utilizes the OpenAI API to compute vector embeddings, commonly used with vector databases.

    🌐Visit Website

    About this tool

    OpenAIEmbeddingFunction

    Description

    An embedding function that utilizes the OpenAI API to compute vector embeddings, commonly used with vector databases. This class, part of pymilvus, handles encoding text into embeddings using OpenAI models to support embedding retrieval in Milvus.

    Features

    The OpenAIEmbeddingFunction offers flexible configuration for integrating with OpenAI's embedding services:

    • Model Selection: Choose from various OpenAI models for encoding, including text-embedding-3-small, text-embedding-3-large, and text-embedding-ada-002 (default).
    • API Key Management: Securely provide your OpenAI API key; the function also checks environment variables as a fallback.
    • Custom Endpoint Support: Configure a custom base URL for the OpenAI API endpoint, defaulting to the public OpenAI API server.
    • Embedding Dimensions Control: Specify the desired number of dimensions for the output embeddings, a feature supported by text-embedding-3 and later models.
    • Extensible Configuration: Allows passing additional keyword arguments directly to the underlying OpenAI model initialization for advanced use cases.

    Constructor Parameters

    To initialize OpenAIEmbeddingFunction, the following parameters are available:

    • model_name (string): Specifies the OpenAI model for encoding. Valid options are text-embedding-3-small, text-embedding-3-large, and text-embedding-ada-002 (default).
    • api_key (string, optional): Your OpenAI API key. If unspecified, environment variables are checked.
    • base_url (string, optional): The base URL of the OpenAI API endpoint. Defaults to None (public OpenAI API server).
    • dimensions (int, optional): The number of dimensions the resulting output embeddings should have. Only supported in text-embedding-3 and later models.
    • **kwargs: Allows additional keyword arguments to be passed to the model initialization.
    Surveys

    Loading more......

    Information

    Websitedocs.zilliz.com
    PublishedJul 1, 2025

    Categories

    1 Item
    Sdks & Libraries

    Tags

    3 Items
    #Embeddings#Openai#Api

    Similar Products

    6 result(s)
    text-embedding-3-large

    OpenAI's flagship text embedding model with up to 3,072 dimensions, offering best-in-class performance and accuracy for English tasks with adjustable output sizes to optimize storage costs.

    JinaEmbeddingFunction

    A wrapper embedding function for Jina Embedding models, used to generate vector embeddings.

    voyage-3-large
    Featured

    State-of-the-art general-purpose and multilingual embedding model from Voyage AI that ranks first across eight domains spanning 100 datasets, outperforming OpenAI and Cohere models by significant margins.

    HuggingFace Text Embedding Server
    Featured

    A server that provides text embeddings, serving as a backend for embedding functions used with vector databases.

    Voyage AI Embeddings

    High-quality embedding models from Voyage AI including voyage-3-large, voyage-4, and voyage-multimodal-3. Known for strong performance on retrieval benchmarks and domain-specific fine-tuning capabilities.

    Mixedbread AI

    AI startup providing state-of-the-art embedding and reranking models through accessible APIs, offering both open-source and proprietary models optimized for various use cases.

    Decorative pattern
    Built with
    Ever Works
    Ever Works

    Connect with us

    Stay Updated

    Get the latest updates and exclusive content delivered to your inbox.

    Product

    • Categories
    • Tags
    • Pricing
    • Help

    Clients

    • Sign In
    • Register
    • Forgot password?

    Company

    • About Us
    • Admin
    • Sitemap

    Resources

    • Blog
    • Submit
    • API Documentation
    All product names, logos, and brands are the property of their respective owners. All company, product, and service names used in this repository, related repositories, and associated websites are for identification purposes only. The use of these names, logos, and brands does not imply endorsement, affiliation, or sponsorship. This directory may include content generated by artificial intelligence.
    Copyright © 2025 Awesome Vector Databases. All rights reserved.·Terms of Service·Privacy Policy·Cookies