# To use the Python SDK, install the plugin:
# pip install --upgrade pinecone pinecone-plugin-assistant
from pinecone import Pinecone
pc = Pinecone(api_key="YOUR_API_KEY")
assistant = pc.assistant.create_assistant(
assistant_name="example-assistant",
instructions="Use American English for spelling and grammar.",
region="us", # Region to deploy assistant. Options: "us" (default) or "eu".
timeout=30 # Maximum seconds to wait for assistant status to become "Ready" before timing out.
)
{
"name": "example-assistant",
"instructions": "Use American English for spelling and grammar.",
"metadata": {},
"status": "Initializing",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
Create an assistant
Create an assistant. This is where you specify the underlying training model, which cloud provider you would like to deploy with, and more.
For guidance and examples, see Create an assistant
# To use the Python SDK, install the plugin:
# pip install --upgrade pinecone pinecone-plugin-assistant
from pinecone import Pinecone
pc = Pinecone(api_key="YOUR_API_KEY")
assistant = pc.assistant.create_assistant(
assistant_name="example-assistant",
instructions="Use American English for spelling and grammar.",
region="us", # Region to deploy assistant. Options: "us" (default) or "eu".
timeout=30 # Maximum seconds to wait for assistant status to become "Ready" before timing out.
)
{
"name": "example-assistant",
"instructions": "Use American English for spelling and grammar.",
"metadata": {},
"status": "Initializing",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
# To use the Python SDK, install the plugin:
# pip install --upgrade pinecone pinecone-plugin-assistant
from pinecone import Pinecone
pc = Pinecone(api_key="YOUR_API_KEY")
assistant = pc.assistant.create_assistant(
assistant_name="example-assistant",
instructions="Use American English for spelling and grammar.",
region="us", # Region to deploy assistant. Options: "us" (default) or "eu".
timeout=30 # Maximum seconds to wait for assistant status to become "Ready" before timing out.
)
{
"name": "example-assistant",
"instructions": "Use American English for spelling and grammar.",
"metadata": {},
"status": "Initializing",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
Authorizations
Pinecone API Key
Body
The desired configuration to create an assistant.
The configuration needed to create an assistant.
The name of the assistant. Resource name must be 1-45 characters long, start and end with an alphanumeric character, and consist only of lower case alphanumeric characters or '-'.
1 - 45"example-assistant"
Description or directive for the assistant to apply to all responses.
The region to deploy the assistant in. Our current options are either us or eu. Defaults to us.
us, eu Response
Create request successful.
The AssistantModel describes the configuration and status of a Pinecone Assistant.
The name of the assistant. Resource name must be 1-45 characters long, start and end with an alphanumeric character, and consist only of lower case alphanumeric characters or '-'.
1 - 45"example-assistant"
Initializing, Failed, Ready, Terminating Description or directive for the assistant to apply to all responses.
The host where the assistant is deployed.
Was this page helpful?