# cohere_embeddings

> For the complete documentation index, see [llms.txt](https://docs.redpanda.com/llms.txt). Component-specific: [connect-full.txt](https://docs.redpanda.com/connect-full.txt)

---
title: cohere_embeddings
latest-connect-version: 4.93.0
latest-operator-version: v26.1.4
latest-console-tag: v3.7.3
latest-redpanda-tag: v26.1.9
docname: processors/cohere_embeddings
page-component-name: connect
page-version: master
page-component-version: master
page-component-title: Connect
page-relative-src-path: processors/cohere_embeddings.adoc
page-edit-url: https://github.com/redpanda-data/rp-connect-docs/edit/main/modules/components/pages/processors/cohere_embeddings.adoc
page-git-created-date: "2024-10-16"
page-git-modified-date: "2026-05-26"
---

<!-- Source: https://docs.redpanda.com/connect/components/processors/cohere_embeddings.md -->

**Available in:** [Cloud](https://docs.redpanda.com/cloud-data-platform/develop/connect/components/processors/cohere_embeddings/%20%22View%20the%20Cloud%20version%20of%20this%20component%22), Self-Managed

Generates vector embeddings to represent input text, using the [Cohere API](https://docs.cohere.com/docs/embeddings).

Introduced in version 4.37.0.

```yml
# Configuration fields, showing default values
label: ""
cohere_embeddings:
  base_url: https://api.cohere.com
  auth_token: "" # No default (required)
  model: embed-english-v3.0 # No default (required)
  text_mapping: "" # No default (optional)
  input_type: search_document
  dimensions: "" # No default (optional)
```

This processor sends text strings to your chosen large language model (LLM), which generates vector embeddings for them using the Cohere API. By default, the processor submits the entire payload of each message as a string, unless you use the `text_mapping` field to customize it.

To learn more about vector embeddings, see the [Cohere API documentation](https://docs.cohere.com/docs/embeddings).

## [](#examples)Examples

### [](#store-embedding-vectors-in-qdrant)Store embedding vectors in Qdrant

Compute embeddings for some generated data and store it within xrefs:component:outputs/qdrant.adoc\[Qdrant\]

```yaml
input:
  generate:
    interval: 1s
    mapping: |
      root = {"text": fake("paragraph")}
pipeline:
  processors:
  - cohere_embeddings:
      model: embed-english-v3
      api_key: "${COHERE_API_KEY}"
      text_mapping: "root = this.text"
output:
  qdrant:
    grpc_host: localhost:6334
    collection_name: "example_collection"
    id: "root = uuid_v4()"
    vector_mapping: "root = this"
```

## [](#fields)Fields

### [](#api_key)`api_key`

The API key for the Cohere API.

> ⚠️ **CAUTION**
>
> This field contains sensitive information that usually shouldn’t be added to a configuration directly. For more information, see [Secrets](https://docs.redpanda.com/connect/configuration/secrets/).

**Type**: `string`

### [](#base_url)`base_url`

The base URL to use for API requests.

**Type**: `string`

**Default**: `[https://api.cohere.com](https://api.cohere.com)`

### [](#dimensions)`dimensions`

The number of dimensions (numerical values) in each vector embedding generated by this processor. This parameter only supports [`embed-v4.0`](https://docs.cohere.com/v2/docs/embeddings) and newer models.

**Type**: `int`

### [](#input_type)`input_type`

The type of text input passed to the model.

**Type**: `string`

**Default**: `search_document`

| Option | Summary |
| --- | --- |
| classification | Used for embeddings passed through a text classifier. |
| clustering | Used for the embeddings run through a clustering algorithm. |
| search_document | Used for embeddings stored in a vector database for search use-cases. |
| search_query | Used for embeddings of search queries run against a vector DB to find relevant documents. |

### [](#model)`model`

The name of the Cohere LLM you want to use.

**Type**: `string`

```yaml
# Examples:
model: embed-english-v3.0

# ---

model: embed-english-light-v3.0

# ---

model: embed-multilingual-v3.0

# ---

model: embed-multilingual-light-v3.0
```

### [](#text_mapping)`text_mapping`

The text you want to generate a vector embedding for. By default, the processor submits the entire payload as a string.

**Type**: `string`