> ## Documentation Index
> Fetch the complete documentation index at: https://docs.llmcontrols.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Embeddings models in LLM Controls

Embedding models convert text into numerical vectors. These embeddings capture the semantic meaning of the input text, and allow LLMs to understand context.

Refer to your specific component's documentation for more information on parameters.

## **Use an embeddings model component in a flow**[**​**](https://docs.langflow.org/components-embedding-models#use-an-embeddings-model-component-in-a-flow)

```text theme={null}

from llmc.components.data import FileComponent
from llmc.components.embeddings import OpenAIEmbeddingsComponent
from llmc.components.processing.split_text import SplitTextComponent
from llmc.components.vectorstores import AstraDBVectorStoreComponent
from llmc.graph import Graph

def ingestion_graph():
    # Document ingestion pipeline
    file_component = FileComponent()
    
    # Split documents into chunks
    text_splitter = SplitTextComponent()
    text_splitter.set(data_inputs=file_component.load_files)
    
    # Initialize OpenAI embeddings model
    openai_embeddings = OpenAIEmbeddingsComponent()
    # Set your OpenAI API key in the component's openai_api_key field
    
    # Connect embeddings to vector database
    vector_store = AstraDBVectorStoreComponent()
    vector_store.set(
        embedding_model=openai_embeddings.build_embeddings,
        ingest_data=text_splitter.split_text,
    )
    
    return Graph(file_component, vector_store)
```

**In this example :**

FileComponent loads documents from a local machine

* SplitTextComponent chunks the documents into smaller pieces
* OpenAIEmbeddingsComponent converts text chunks into numerical vectors
* AstraDBVectorStoreComponent stores the vectorized data in the vector database

The stored vectors can then be retrieved for similarity searches, RAG applications, and agent-based workflows.

<img src="https://mintcdn.com/devrel/3c4Ck_HlevcLlxoS/images/Embeddings_models.png?fit=max&auto=format&n=3c4Ck_HlevcLlxoS&q=85&s=57dc80604b815a98e0890b1868ff2607" alt="Embeddings Models Pn" width="795" height="720" data-path="images/Embeddings_models.png" />

## **AI/ML**

This component generates embeddings using the [AI/ML API](https://docs.aimlapi.com/api-overview/embeddings).

<Accordion title="Parameters">
  **Inputs**

  | **Name**       | **Type**     | **Description**                                                 |
  | :------------- | :----------- | :-------------------------------------------------------------- |
  | model\_name    | String       | The name of the AI/ML embedding model to use.                   |
  | aiml\_api\_key | SecretString | The API key required for authenticating with the AI/ML service. |

  **Outputs**

  | **Name**   | **Type**   | **Description**                                               |
  | :--------- | :--------- | :------------------------------------------------------------ |
  | embeddings | Embeddings | An instance of `AIMLEmbeddingsImpl` for generating embeddings |
</Accordion>

## **Amazon Bedrock Embeddings**

This component is used to load embedding models from [Amazon Bedrock](https://aws.amazon.com/bedrock/).

<Accordion title="Parameters">
  **Inputs**

  | **Name**                   | **Type** | **Description**                                                                                                                                                 |
  | :------------------------- | :------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------- |
  | credentials\_profile\_name | String   | The name of the AWS credentials profile in `~/.aws/credentials` or `~/.aws/config`, which has access keys or role information.                                  |
  | model\_id                  | String   | The ID of the model to call, such as `amazon.titan-embed-text-v1`. This is equivalent to the `modelId` property in the `list-foundation-models` API.            |
  | endpoint\_url              | String   | The URL to set a specific service endpoint other than the default AWS endpoint.                                                                                 |
  | region\_name               | String   | The AWS region to use, such as `us-west-2`. Falls back to the `AWS_DEFAULT_REGION` environment variable or region specified in `~/.aws/config` if not provided. |

  **Outputs**

  | **Name**   | **Type**   | **Description**                                             |
  | :--------- | :--------- | :---------------------------------------------------------- |
  | embeddings | Embeddings | An instance for generating embeddings using Amazon Bedrock. |
</Accordion>

## **Astra DB vectorize**

<Note>
  **important**

  This component is deprecated as of LLM Controls version 1.1.2. Instead, use the [<u>Astra DB vector store component</u>](https://docs.llmcontrols.ai/Components/Vectorstores#astra-db-vector-store).
</Note>

Connect this component to the **Embeddings** port of the [Astra DB vector store component](https://docs.llmcontrols.ai/Components/Vectorstores#astra-db-vector-store) to generate embeddings.

This component requires that your Astra DB database has a collection that uses a vectorized embedding provider integration. For more information and instructions, see [Embedding Generation](https://docs.datastax.com/en/astra-db-serverless/databases/embedding-generation.html).

<Accordion title="Parameters">
  **Inputs**

  | **Name**           | **Display Name**   | **Info**                                                                                                                                                                                                                                                                                                                                                                                                              |
  | :----------------- | :----------------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
  | provider           | Embedding Provider | The embedding provider to use.                                                                                                                                                                                                                                                                                                                                                                                        |
  | model\_name        | Model Name         | The embedding model to use.                                                                                                                                                                                                                                                                                                                                                                                           |
  | authentication     | Authentication     | The name of the API key in Astra that stores your [<u>vectorize embedding provider credentials</u>](https://docs.datastax.com/en/astra-db-serverless/databases/embedding-generation.html#embedding-provider-authentication). (Not required if using an [<u>Astra-hosted embedding provider</u>](https://docs.datastax.com/en/astra-db-serverless/databases/embedding-generation.html#supported-embedding-providers).) |
  | provider\_api\_key | Provider API Key   | As an alternative to `authentication`, directly provide your embedding provider credentials.                                                                                                                                                                                                                                                                                                                          |
  | model\_parameters  | Model Parameters   | Additional model parameters.                                                                                                                                                                                                                                                                                                                                                                                          |

  **Outputs**

  | **Name**   | **Type**   | **Description**                                              |
  | :--------- | :--------- | :----------------------------------------------------------- |
  | embeddings | Embeddings | An instance for generating embeddings using Astra vectorize. |
</Accordion>

## **Azure OpenAI Embeddings**

This component generates embeddings using Azure OpenAI models.

<Accordion title="Parameters">
  **Inputs**

  | **Name**        | **Type** | **Description**                                                                                    |
  | :-------------- | :------- | :------------------------------------------------------------------------------------------------- |
  | Model           | String   | The name of the model to use. Default: `text-embedding-3-small`.                                   |
  | Azure Endpoint  | String   | Your Azure endpoint, including the resource, such as `https://example-resource.azure.openai.com/`. |
  | Deployment Name | String   | The name of the deployment.                                                                        |
  | API Version     | String   | The API version to use, with options including various dates.                                      |
  | API Key         | String   | The API key required to access the Azure OpenAI service.                                           |

  **Outputs**

  | **Name**   | **Type**   | **Description**                                           |
  | :--------- | :--------- | :-------------------------------------------------------- |
  | embeddings | Embeddings | An instance for generating embeddings using Azure OpenAI. |
</Accordion>

## **Cloudflare Workers AI Embeddings**

This component generates embeddings using [Cloudflare Workers AI models](https://developers.cloudflare.com/workers-ai/).

<Accordion title="Parameters">
  **Inputs**

  | **Name**          | **Display Name**        | **Info**                                                                                                                                                     |
  | :---------------- | :---------------------- | :----------------------------------------------------------------------------------------------------------------------------------------------------------- |
  | account\_id       | Cloudflare account ID   | [<u>Find your Cloudflare account ID</u>](https://developers.cloudflare.com/fundamentals/setup/find-account-and-zone-ids/#find-account-id-workers-and-pages). |
  | api\_token        | Cloudflare API token    | [<u>Create an API token</u>](https://developers.cloudflare.com/fundamentals/api/get-started/create-token/).                                                  |
  | model\_name       | Model Name              | [<u>List of supported models</u>](https://developers.cloudflare.com/workers-ai/models/#text-embeddings).                                                     |
  | strip\_new\_lines | Strip New Lines         | Whether to strip new lines from the input text.                                                                                                              |
  | batch\_size       | Batch Size              | The number of texts to embed in each batch.                                                                                                                  |
  | api\_base\_url    | Cloudflare API base URL | The base URL for the Cloudflare API.                                                                                                                         |
  | headers           | Headers                 | Additional request headers.                                                                                                                                  |

  **Outputs**

  | **Name**   | **Display Name** | **Info**                                                        |
  | :--------- | :--------------- | :-------------------------------------------------------------- |
  | embeddings | Embeddings       | An instance for generating embeddings using Cloudflare Workers. |
</Accordion>

## **Cohere Embeddings**

This component is used to load embedding models from [Cohere](https://cohere.com/).

<Accordion title="Parameters">
  **Inputs**

  | **Name**         | **Type** | **Description**                                                                                             |
  | :--------------- | :------- | :---------------------------------------------------------------------------------------------------------- |
  | cohere\_api\_key | String   | The API key required to authenticate with the Cohere service.                                               |
  | model            | String   | The language model used for embedding text documents and performing queries. Default: `embed-english-v2.0`. |
  | truncate         | Boolean  | Whether to truncate the input text to fit within the model's constraints. Default: `False`.                 |

  **Outputs**

  | **Name**   | **Type**   | **Description**                                    |
  | :--------- | :--------- | :------------------------------------------------- |
  | embeddings | Embeddings | An instance for generating embeddings using Cohere |
</Accordion>

## **Embedding similarity**

This component computes selected forms of similarity between two embedding vectors.

<Accordion title="Parameters">
  **Inputs**

  | **Name**           | **Display Name**  | **Info**                                                                                                       |
  | :----------------- | :---------------- | :------------------------------------------------------------------------------------------------------------- |
  | embedding\_vectors | Embedding Vectors | A list containing exactly two data objects with embedding vectors to compare.                                  |
  | similarity\_metric | Similarity Metric | Select the similarity metric to use. Options: "Cosine Similarity", "Euclidean Distance", "Manhattan Distance". |

  **Outputs**

  | **Name**         | **Display Name** | **Info**                                                                           |
  | :--------------- | :--------------- | :--------------------------------------------------------------------------------- |
  | similarity\_data | Similarity Data  | A data object containing the computed similarity score and additional information. |
</Accordion>

## **Google generative AI embeddings**

This component connects to Google's generative AI embedding service using the GoogleGenerativeAIEmbeddings class from the `langchain-google-genai` package.

<Accordion title="Parameters">
  **Inputs**

  | **Name**    | **Display Name** | **Info**                                                                      |
  | :---------- | :--------------- | :---------------------------------------------------------------------------- |
  | api\_key    | API Key          | The secret API key for accessing Google's generative AI service. Required.    |
  | model\_name | Model Name       | The name of the embedding model to use. Default: "models/text-embedding-004". |

  **Outputs**

  | **Name**   | **Display Name** | **Info**                                       |
  | :--------- | :--------------- | :--------------------------------------------- |
  | embeddings | Embeddings       | The built GoogleGenerativeAIEmbeddings object. |
</Accordion>

## **Hugging Face Embeddings**

<Note>
  **note**

  This component is deprecated as of LLM Controls version 1.0.18. Instead, use the [<u>Hugging Face Embeddings Inference component</u>](https://docs.llmcontrols.ai/Components/Embeddings#hugging-face-embeddings-inference).
</Note>

This component loads embedding models from HuggingFace.

Use this component to generate embeddings using locally downloaded Hugging Face models. Ensure you have sufficient computational resources to run the models.

<Accordion title="Parameters">
  **Inputs**

  | **Name**      | **Display Name**   | **Info**                                       |
  | :------------ | :----------------- | :--------------------------------------------- |
  | Cache Folder  | Cache Folder       | The folder path to cache HuggingFace models.   |
  | Encode Kwargs | Encoding Arguments | Additional arguments for the encoding process. |
  | Model Kwargs  | Model Arguments    | Additional arguments for the model.            |
  | Model Name    | Model Name         | The name of the HuggingFace model to use.      |
  | Multi Process | Multi-Process      | Whether to use multiple processes.             |

  **Outputs**

  | **Name**   | **Display Name** | **Info**                  |
  | :--------- | :--------------- | :------------------------ |
  | embeddings | Embeddings       | The generated embeddings. |
</Accordion>

## **Hugging Face embeddings inference**

This component generates embeddings using [Hugging Face Inference API models](https://huggingface.co/) and requires a [Hugging Face API token](https://huggingface.co/docs/hub/security-tokens) to authenticate. Local inference models do not require an API key.

Use this component to create embeddings with Hugging Face's hosted models, or to connect to your own locally hosted models.

<Accordion title="Parameters">
  **Inputs**

  | **Name**   | **Display Name** | **Info**                                                  |
  | :--------- | :--------------- | :-------------------------------------------------------- |
  | API Key    | API Key          | The API key for accessing the Hugging Face Inference API. |
  | API URL    | API URL          | The URL of the Hugging Face Inference API.                |
  | Model Name | Model Name       | The name of the model to use for embeddings.              |

  **Outputs**

  | **Name**   | **Display Name** | **Info**                  |
  | :--------- | :--------------- | :------------------------ |
  | embeddings | Embeddings       | The generated embeddings. |
</Accordion>

### **Connect the Hugging Face component to a local embeddings model**

To run an embedding inference locally, see the [HuggingFace documentation](https://huggingface.co/docs/text-embeddings-inference/local_cpu).

To connect the local Hugging Face model to the **Hugging Face embeddings inference** component and use it in a flow, follow these steps:

1. Create a [Vector store RAG flow](/Templates/VectorstoreRAG). There are two embeddings models in this flow that you can replace with **Hugging Face** embeddings inference components.
2. Replace both **OpenAI** embeddings model components with **Hugging Face** model components.
3. Connect both **Hugging Face** components to the **Embeddings** ports of the **Astra DB vector store** components.
4. In the **Hugging Face** components, set the **Inference Endpoint** field to the URL of your local inference model. **The API Key field is not required for local inference.**
5. Run the flow. The local inference models generate embeddings for the input text.

## **IBM watsonx embeddings**

This component generates text using [IBM ](https://www.ibm.com/watsonx)[watsonx.ai](http://watsonx.ai) foundation models.

To use IBM [**watsonx.ai**](http://watsonx.ai) embeddings components, replace an embeddings component with the IBM [watsonx.ai](http://watsonx.ai) component in a flow.

An example document processing flow looks like the following:

<img src="https://mintcdn.com/devrel/3c4Ck_HlevcLlxoS/images/Embeddings_models_2.png?fit=max&auto=format&n=3c4Ck_HlevcLlxoS&q=85&s=f4279d42fca35d96668f6331b6fa2b93" alt="Embeddings Models 2 Pn" width="660" height="832" data-path="images/Embeddings_models_2.png" />

This flow loads a PDF file from local storage and splits the text into chunks.

The **IBM watsonx** embeddings component converts the text chunks into embeddings, which are then stored in a Chroma DB vector store.

The values for **API endpoint**, **Project ID**, **API key**, and **Model Name** are found in your IBM watsonx.ai deployment. For more information, see the [Langchain documentation](https://python.langchain.com/docs/integrations/text_embedding/ibm_watsonx/).

### **Default models**

The component supports several default models with the following vector dimensions:

* `sentence-transformers/all-minilm-l12-v2`: 384-dimensional embeddings
* `ibm/slate-125m-english-rtrvr-v2`: 768-dimensional embeddings
* `ibm/slate-30m-english-rtrvr-v2`: 768-dimensional embeddings
* `intfloat/multilingual-e5-large`: 1024-dimensional embeddings

The component automatically fetches and updates the list of available models from your watsonx.ai instance when you provide your API endpoint and credentials.

<Accordion title="Parameters">
  **Inputs**

  | **Name**                | **Display Name**                        | **Info**                                                                    |
  | :---------------------- | :-------------------------------------- | :-------------------------------------------------------------------------- |
  | url                     | watsonx API Endpoint                    | The base URL of the API.                                                    |
  | project\_id             | watsonx project id                      | The project ID for your [watsonx.ai](http://watsonx.ai) instance.           |
  | api\_key                | API Key                                 | The API Key to use for the model.                                           |
  | model\_name             | Model Name                              | The name of the embedding model to use.                                     |
  | truncate\_input\_tokens | Truncate Input Tokens                   | The maximum number of tokens to process. Default: `200`.                    |
  | input\_text             | Include the original text in the output | Determines if the original text is included in the output. Default: `True`. |

  **Outputs**

  | **Name**   | **Display Name** | **Info**                                                                     |
  | :--------- | :--------------- | :--------------------------------------------------------------------------- |
  | embeddings | Embeddings       | An instance for generating embeddings using [watsonx.ai](http://watsonx.ai). |
</Accordion>

## **LM Studio Embeddings**

This component generates embeddings using [LM Studio](https://lmstudio.ai/docs) models.

<Accordion title="Parameters">
  **Inputs**

  | **Name**    | **Display Name**   | **Info**                                              |
  | :---------- | :----------------- | :---------------------------------------------------- |
  | model       | Model              | The LM Studio model to use for generating embeddings. |
  | base\_url   | LM Studio Base URL | The base URL for the LM Studio API.                   |
  | api\_key    | LM Studio API Key  | The API key for authentication with LM Studio.        |
  | temperature | Model Temperature  | The temperature setting for the model.                |

  **Outputs**

  | **Name**   | **Display Name** | **Info**                  |
  | :--------- | :--------------- | :------------------------ |
  | embeddings | Embeddings       | The generated embeddings. |
</Accordion>

## **MistralAI**

This component generates embeddings using [MistralAI](https://docs.mistral.ai/) models.

<Accordion title="Parameters">
  **Inputs**

  | **Name**                  | **Type**     | **Description**                                                       |
  | :------------------------ | :----------- | :-------------------------------------------------------------------- |
  | model                     | String       | The MistralAI model to use. Default: "mistral-embed".                 |
  | mistral\_api\_key         | SecretString | The API key for authenticating with MistralAI.                        |
  | max\_concurrent\_requests | Integer      | The maximum number of concurrent API requests. Default: 64.           |
  | max\_retries              | Integer      | The maximum number of retry attempts for failed requests. Default: 5. |
  | timeout                   | Integer      | The request timeout in seconds. Default: 120.                         |
  | endpoint                  | String       | The custom API endpoint URL. Default: `https://api.mistral.ai/v1/`).  |

  **Outputs**

  | **Name**   | **Type**   | **Description**                                           |
  | :--------- | :--------- | :-------------------------------------------------------- |
  | embeddings | Embeddings | A MistralAIEmbeddings instance for generating embeddings. |
</Accordion>

## **NVIDIA**

This component generates embeddings using [NVIDIA models](https://docs.nvidia.com/).

<Accordion title="Parameters">
  **Inputs**

  | **Name**         | **Type**     | **Description**                                                                  |
  | :--------------- | :----------- | :------------------------------------------------------------------------------- |
  | model            | String       | The NVIDIA model to use for embeddings, such as `nvidia/nv-embed-v1`.            |
  | base\_url        | String       | The base URL for the NVIDIA API. Default: `https://integrate.api.nvidia.com/v1`. |
  | nvidia\_api\_key | SecretString | The API key for authenticating with NVIDIA's service.                            |
  | temperature      | Float        | The model temperature for embedding generation. Default: `0.1`.                  |

  **Outputs**

  | **Name**   | **Type**   | **Description**                                        |
  | :--------- | :--------- | :----------------------------------------------------- |
  | embeddings | Embeddings | A NVIDIAEmbeddings instance for generating embeddings. |
</Accordion>

## **Ollama embeddings**

This component generates embeddings using [Ollama models](https://ollama.com/).

For a list of Ollama embeddings models, see the [Ollama documentation](https://ollama.com/search?c=embedding).

To use this component in a flow, connect LLM Controls to your locally running Ollama server and select an embedding model.

1. In the Ollama component, in the **Ollama Base URL** field, enter the address for your locally running Ollama server. This value is set as the `OLLAMA_HOST` environment variable in Ollama. The default base URL is `http://localhost:11434`.
2. To refresh the server's list of models, click **Refresh**.
3. In the **Ollama Model** field, select an embedding model. This example uses `all-minilm:latest`.
4. Connect the **Ollama** embeddings component to a flow. For example, this flow connects a local Ollama server running a `all-minilm:latest` embeddings model to a [Chroma DB](https://docs.llmcontrols.ai/Components/Vectorstores#chroma-db) vector store to generate embeddings for split text.

<img src="https://mintcdn.com/devrel/3c4Ck_HlevcLlxoS/images/Embeddings_models_3.png?fit=max&auto=format&n=3c4Ck_HlevcLlxoS&q=85&s=36a61d24a6467eb6debc9a1fcd27e8e3" alt="Embeddings Models 3 Pn" width="581" height="578" data-path="images/Embeddings_models_3.png" />

For more information, see the [Ollama documentation](https://ollama.com/).

<Accordion title="Parameters">
  **Inputs**

  | **Name**          | **Type** | **Description**                                                                              |
  | :---------------- | :------- | :------------------------------------------------------------------------------------------- |
  | Ollama Model      | String   | The name of the Ollama model to use. Default: `llama2`.                                      |
  | Ollama Base URL   | String   | The base URL of the Ollama API. Default: `http://localhost:11434`.                           |
  | Model Temperature | Float    | The temperature parameter for the model. Adjusts the randomness in the generated embeddings. |

  **Outputs**

  | **Name**   | **Type**   | **Description**                                     |
  | :--------- | :--------- | :-------------------------------------------------- |
  | embeddings | Embeddings | An instance for generating embeddings using Ollama. |
</Accordion>

## **OpenAI Embeddings**

This component is used to load embedding models from [OpenAI](https://openai.com/).

<Accordion title="Parameters">
  **Inputs**

  | **Name**                 | **Type**   | **Description**                                                       |
  | :----------------------- | :--------- | :-------------------------------------------------------------------- |
  | OpenAI API Key           | String     | The API key to use for accessing the OpenAI API.                      |
  | Default Headers          | Dict       | The default headers for the HTTP requests.                            |
  | Default Query            | NestedDict | The default query parameters for the HTTP requests.                   |
  | Allowed Special          | List       | The special tokens allowed for processing. Default: `[]`.             |
  | Disallowed Special       | List       | The special tokens disallowed for processing. Default: `["all"]`.     |
  | Chunk Size               | Integer    | The chunk size for processing. Default: `1000`.                       |
  | Client                   | Any        | The HTTP client for making requests.                                  |
  | Deployment               | String     | The deployment name for the model. Default: `text-embedding-3-small`. |
  | Embedding Context Length | Integer    | The length of embedding context. Default: `8191`.                     |
  | Max Retries              | Integer    | The maximum number of retries for failed requests. Default: `6`.      |
  | Model                    | String     | The name of the model to use. Default: `text-embedding-3-small`.      |
  | Model Kwargs             | NestedDict | Additional keyword arguments for the model.                           |
  | OpenAI API Base          | String     | The base URL of the OpenAI API.                                       |
  | OpenAI API Type          | String     | The type of the OpenAI API.                                           |
  | OpenAI API Version       | String     | The version of the OpenAI API.                                        |
  | OpenAI Organization      | String     | The organization associated with the API key.                         |
  | OpenAI Proxy             | String     | The proxy server for the requests.                                    |
  | Request Timeout          | Float      | The timeout for the HTTP requests.                                    |
  | Show Progress Bar        | Boolean    | Whether to show a progress bar for processing. Default: `False`.      |
  | Skip Empty               | Boolean    | Whether to skip empty inputs. Default: `False`.                       |
  | TikToken Enable          | Boolean    | Whether to enable TikToken. Default: `True`.                          |
  | TikToken Model Name      | String     | The name of the TikToken model.                                       |

  **Outputs**

  | **Name**   | **Type**   | **Description**                                     |
  | :--------- | :--------- | :-------------------------------------------------- |
  | embeddings | Embeddings | An instance for generating embeddings using OpenAI. |
</Accordion>

## **Text embedder**

This component generates embeddings for a given message using a specified embedding model.

<Accordion title="Parameters">
  **Inputs**

  | **Name**         | **Display Name** | **Info**                                              |
  | :--------------- | :--------------- | :---------------------------------------------------- |
  | embedding\_model | Embedding Model  | The embedding model to use for generating embeddings. |
  | message          | Message          | The message for which to generate embeddings.         |

  **Outputs**

  | **Name**   | **Display Name** | **Info**                                                             |
  | :--------- | :--------------- | :------------------------------------------------------------------- |
  | embeddings | Embedding Data   | A data object containing the original text and its embedding vector. |
</Accordion>

## **VertexAI Embeddings**

This component is a wrapper around [Google Vertex AI](https://cloud.google.com/vertex-ai) [Embeddings API](https://cloud.google.com/vertex-ai/docs/generative-ai/embeddings/get-text-embeddings).

<Accordion title="Parameters">
  **Inputs**

  | **Name**             | **Type**    | **Description**                                                                                                                                        |
  | :------------------- | :---------- | :----------------------------------------------------------------------------------------------------------------------------------------------------- |
  | credentials          | Credentials | The default custom credentials to use.                                                                                                                 |
  | location             | String      | The default location to use when making API calls. Default: `us-central1`.                                                                             |
  | max\_output\_tokens  | Integer     | The token limit determines the maximum amount of text output from one prompt. Default: `128`.                                                          |
  | model\_name          | String      | The name of the Vertex AI large language model. Default: `text-bison`.                                                                                 |
  | project              | String      | The default GCP project to use when making Vertex API calls.                                                                                           |
  | request\_parallelism | Integer     | The amount of parallelism allowed for requests issued to VertexAI models. Default: `5`.                                                                |
  | temperature          | Float       | Tunes the degree of randomness in text generations. Should be a non-negative value. Default: `0`.                                                      |
  | top\_k               | Integer     | How the model selects tokens for output. The next token is selected from the top `k` tokens. Default: `40`.                                            |
  | top\_p               | Float       | Tokens are selected from the most probable to least until the sum of their probabilities exceeds the top `p` value. Default: `0.95`.                   |
  | tuned\_model\_name   | String      | The name of a tuned model. If provided, `model_name` is ignored.                                                                                       |
  | verbose              | Boolean     | This parameter controls the level of detail in the output. When set to `True`, it prints internal states of the chain to help debug. Default: `False`. |

  **Outputs**

  | **Name**   | **Type**   | **Description**                                       |
  | :--------- | :--------- | :---------------------------------------------------- |
  | embeddings | Embeddings | An instance for generating embeddings using VertexAI. |
</Accordion>
