Vector DBs
Pinecone Agent Knowledge
Setup
Follow the instructions in the Pinecone Setup Guide to get started quickly with Pinecone.
We do not yet support Pinecone v6.x.x. We are actively working to achieve compatibility. In the meantime, we recommend using Pinecone v5.4.2 for the best experience.
Example
agent_with_knowledge.py
PineconeDb Params
Parameter | Type | Default | Description |
---|---|---|---|
name | str | - | The name of the Pinecone index |
dimension | int | - | The dimension of the embeddings |
spec | Union[Dict, ServerlessSpec, PodSpec] | - | The index spec |
embedder | Optional[Embedder] | None | Embedder instance for creating embeddings (defaults to OpenAIEmbedder if not provided) |
metric | Optional[str] | "cosine" | The metric used for similarity search |
additional_headers | Optional[Dict[str, str]] | None | Additional headers to pass to the Pinecone client |
pool_threads | Optional[int] | 1 | The number of threads to use for the Pinecone client |
namespace | Optional[str] | None | The namespace for the Pinecone index |
timeout | Optional[int] | None | The timeout for Pinecone operations |
index_api | Optional[Any] | None | The Index API object |
api_key | Optional[str] | None | The Pinecone API key |
host | Optional[str] | None | The Pinecone host |
config | Optional[Config] | None | The Pinecone config |
use_hybrid_search | bool | False | Whether to use hybrid search |
hybrid_alpha | float | 0.5 | The alpha value for hybrid search |
Developer Resources
- View Cookbook