Describe a model
Get a description of a model hosted by Pinecone.
You can use hosted models as an integrated part of Pinecone operations or for standalone embedding and reranking. For more details, see Vector embedding and Rerank results.
GET /models/{model_name}
curl --request GET \
--url https://api.pinecone.io/models/{model_name} \
--header 'Api-Key: <api-key>' \
--header 'X-Pinecone-Api-Version: <x-pinecone-api-version>'import requests
url = "https://api.pinecone.io/models/{model_name}"
headers = {
"Api-Key": "<api-key>",
"X-Pinecone-Api-Version": "<x-pinecone-api-version>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: "GET", headers: {"Api-Key": "<api-key>", "X-Pinecone-Api-Version": "<x-pinecone-api-version>"}};
fetch("https://api.pinecone.io/models/{model_name}", options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.pinecone.io/models/{model_name}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Api-Key: <api-key>",
"X-Pinecone-Api-Version: <x-pinecone-api-version>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.pinecone.io/models/{model_name}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Api-Key", "<api-key>")
req.Header.Add("X-Pinecone-Api-Version", "<x-pinecone-api-version>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.pinecone.io/models/{model_name}")
.header("Api-Key", "<api-key>")
.header("X-Pinecone-Api-Version", "<x-pinecone-api-version>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.pinecone.io/models/{model_name}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Api-Key"] = '<api-key>'
request["X-Pinecone-Api-Version"] = '<x-pinecone-api-version>'
response = http.request(request)
puts response.read_body{
"default_dimension": 256,
"max_batch_size": 96,
"max_sequence_length": 512,
"modality": "text",
"model": "example-embedding-model",
"provider_name": "Embedding Model Provider",
"short_description": "An example embedding model.",
"supported_dimensions": [
256,
512
],
"supported_metrics": [
"cosine",
"euclidean"
],
"supported_parameters": [
{
"allowed_values": [
"value1",
"value2"
],
"parameter": "example_required_param",
"required": true,
"type": "one_of",
"value_type": "string"
},
{
"allowed_values": [
"value1",
"value2"
],
"default": "value1",
"parameter": "example_param_with_default",
"required": false,
"type": "one_of",
"value_type": "string"
},
{
"default": 5,
"max": 10,
"min": 0,
"parameter": "example_numeric_range",
"required": false,
"type": "numeric_range",
"value_type": "integer"
}
],
"type": "embed",
"vector_type": "dense"
}{
"error": {
"code": "UNAUTHENTICATED",
"message": "Invalid API key."
},
"status": 401
}{
"error": {
"code": "NOT_FOUND",
"message": "Model example-model not found."
},
"status": 404
}{
"error": {
"code": "UNKNOWN",
"message": "Internal server error"
},
"status": 500
}Authorizations
Section titled “Authorizations”Api-KeystringrequiredAn API Key is required to call Pinecone APIs. Get yours from the console.
Headers
Section titled “Headers”X-Pinecone-Api-VersionstringrequiredRequired date-based version header
Path Parameters
Section titled “Path Parameters”model_namestringrequiredThe name of the model to look up.
Response
Section titled “Response”200 — The model details.
Represents the model configuration including model type, supported parameters, and other model details.
modelstringrequiredThe name of the model.
Example: multilingual-e5-large
short_descriptionstringrequiredA summary of the model.
Example: multilingual-e5-large
typestringrequiredThe type of model (e.g. 'embed' or 'rerank').
Example: embed
vector_type?stringWhether the embedding model produces 'dense' or 'sparse' embeddings.
default_dimension?integerThe default embedding model dimension (applies to dense embedding models only).
Required range: 1 <= x <= 20000. Example: 1024
modality?stringThe modality of the model (e.g. 'text').
Example: text
max_sequence_length?integerThe maximum tokens per sequence supported by the model.
Required range: 1 <= x. Example: 512
max_batch_size?integerThe maximum batch size (number of sequences) supported by the model.
Required range: 1 <= x. Example: 96
provider_name?stringThe name of the provider of the model.
Example: NVIDIA
supported_dimensions?integer[]The list of supported dimensions for the model (applies to dense embedding models only).
supported_metrics?string[]The distance metrics supported by the model for similarity search.
supported_parametersobject[]requiredList of parameters supported by the model.
Show child attributes
parameterstringrequiredThe name of the parameter.
Example: input_type
typestringrequiredThe parameter type e.g. 'one_of', 'numeric_range', or 'any'. If the type is 'one_of', then 'allowed_values' will be set, and the value specified must be one of the allowed values. 'one_of' is only compatible with value_type 'string' or 'integer'. If 'numeric_range', then 'min' and 'max' will be set, then the value specified must adhere to the value_type and must fall within the [min, max] range (inclusive). If 'any' then any value is allowed, as long as it adheres to the value_type.
Example: one_of
value_typestringrequiredThe type of value the parameter accepts, e.g. 'string', 'integer', 'float', or 'boolean'.
Example: string
requiredbooleanrequiredWhether the parameter is required (true) or optional (false).
Example: true
allowed_values?string[]The allowed parameter values when the type is 'one_of'.
min?numberThe minimum allowed value (inclusive) when the type is 'numeric_range'.
Example: 1
max?numberThe maximum allowed value (inclusive) when the type is 'numeric_range'.
Example: 1
default?string