Private Deployment Usage
You can use Cohere's SDK to access privately deployed Cohere models.
Installation
Section titled “Installation”To install the Cohere SDK, choose from the following 4 languages:
Getting Started
Section titled “Getting Started”The only difference between using Cohere's models on private deployments and the Cohere platform is how you set up the client. With private deployments, you need to pass the following parameters:
api_key- Pass a blank valuebase_url- Pass the URL of your private deployment
import cohere
co = cohere.ClientV2(
api_key="", # Leave this blank
base_url="<YOUR_DEPLOYMENT_URL>",
)To get started with example use cases, refer to the following quickstart examples:
- Text Generation (Command model)
- RAG (Command model)
- Tool Use (Command model)
- Semantic Search (Embed model)
- Reranking (Rerank model)
Integrations
Section titled “Integrations”You can use the LangChain library with privately deployed Cohere models. Refer to the LangChain section for more information on setting up LangChain for private deployments.