step
pinecone
Execute Pinecone vector database operations.
Overview
Supports operations:
- upsert: Insert or update vectors
- query: Find similar vectors
- delete: Delete vectors by ID
- fetch: Retrieve vectors by ID
- update: Update vector metadata or values
Setup:
1. Create a Pinecone account at https://www.pinecone.io/
2. Create a project and index in the Pinecone console
3. Get your API key from the API Keys section
4. Note your environment (e.g., us-west1-gcp) from the console
5. Store credentials securely (e.g., environment variables: PINECONE_API_KEY, PINECONE_ENVIRONMENT)
API Key: Required. Get from Pinecone console > API Keys
- upsert: Insert or update vectors
- query: Find similar vectors
- delete: Delete vectors by ID
- fetch: Retrieve vectors by ID
- update: Update vector metadata or values
Setup:
1. Create a Pinecone account at https://www.pinecone.io/
2. Create a project and index in the Pinecone console
3. Get your API key from the API Keys section
4. Note your environment (e.g., us-west1-gcp) from the console
5. Store credentials securely (e.g., environment variables: PINECONE_API_KEY, PINECONE_ENVIRONMENT)
API Key: Required. Get from Pinecone console > API Keys
Examples
Query similar vectors
Find most similar vectors to a query embedding
type: pinecone
api_key: ${env:PINECONE_API_KEY}
environment: us-west1-gcp
index_name: document-embeddings
operation: query
query_vector: [0.1, 0.2, 0.3, 0.4, 0.5]
top_k: 10
include_metadata: true
output_to: similar_docs
Upsert vectors with metadata
Insert or update vectors with associated metadata
type: pinecone
api_key: ${env:PINECONE_API_KEY}
environment: us-west1-gcp
index_name: product-embeddings
operation: upsert
vectors:
- id: prod-123
values: [0.1, 0.2, 0.3]
metadata:
title: Product A
category: electronics
- id: prod-124
values: [0.4, 0.5, 0.6]
metadata:
title: Product B
category: home
output_to: upsert_result
Query with metadata filter
Search vectors filtered by metadata conditions
type: pinecone
api_key: ${env:PINECONE_API_KEY}
environment: us-west1-gcp
index_name: articles
operation: query
query_vector: [0.15, 0.25, 0.35, 0.45]
top_k: 5
filter:
category: technology
published_year:
$gte: 2023
include_metadata: true
output_to: filtered_results
Delete vectors by ID
Remove specific vectors from the index
type: pinecone
api_key: ${env:PINECONE_API_KEY}
environment: us-west1-gcp
index_name: embeddings
operation: delete
vector_ids:
- vec-001
- vec-002
- vec-003
output_to: delete_result
Configuration
| Parameter | Type | Required | Description |
|---|---|---|---|
type | string | No | Step type identifier
Default: "pinecone" |
api_key | string | Yes | Pinecone API key for authentication |
environment | string | Yes | Pinecone environment/region identifier (e.g., us-west1-gcp, us-east-1-aws) |
index_name | string | Yes | Name of the Pinecone index to operate on |
operation | string | Yes | Operation to perform: upsert (insert/update vectors), query (similarity search), delete (remove vectors), fetch (get by ID), or update (modify metadata)
Options: upsert, query, delete, fetch, update |
vectors | string | No | List of vector objects to upsert, each with id, values (array of floats), and optional metadata |
vector_ids | string | No | List of vector IDs for delete or fetch operations |
query_vector | string | No | Query vector values for similarity search (required for query operation) |
top_k | integer | No | Number of most similar results to return (for query operation)
Default: 10 |
filter | string | No | Metadata filter to apply to query results (Pinecone filter syntax) |
include_metadata | boolean | No | Whether to include metadata in query/fetch results
Default: true |
include_values | boolean | No | Whether to include vector values in query/fetch results
Default: false |
namespace | string | No | Namespace to use for operations (for data isolation within an index) |
timeout | integer | No | HTTP request timeout in seconds
Default: 30 |
output_to | string | No | Key name where results will be stored in the event
Default: "pinecone" |
Base Configuration
These configuration options are available on all steps:
| Parameter | Type | Default | Description |
|---|---|---|---|
name | | null | Optional name for this step (for documentation and debugging) |
description | | null | Optional description of what this step does |
retries | integer | 0 | Number of retry attempts (0-10) |
backoff_seconds | number | 0 | Backoff (seconds) applied between retry attempts |
retry_propagate | boolean | false | If True, raise last exception after exhausting retries; otherwise swallow. |