Pinecone · Schema

QueryVector

A single query vector within a `QueryRequest`.

Vector DatabasesAIEmbeddingsRAG

Properties

Name Type Description
values array The query vector values. This should be the same length as the dimension of the index being queried.
sparseValues object
topK integer An override for the number of results to return for this query vector.
namespace string An override the namespace to search.
filter object An override for the metadata filter to apply. This replaces the request-level filter.
View JSON Schema on GitHub

JSON Schema

pinecone-queryvector-schema.json Raw ↑
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "#/components/schemas/QueryVector",
  "title": "QueryVector",
  "deprecated": true,
  "description": "A single query vector within a `QueryRequest`.",
  "type": "object",
  "properties": {
    "values": {
      "example": [
        0.1,
        0.2,
        0.3,
        0.4,
        0.5,
        0.6,
        0.7,
        0.8
      ],
      "description": "The query vector values. This should be the same length as the dimension of the index being queried.",
      "type": "array",
      "required": [
        "values"
      ],
      "items": {
        "type": "number",
        "format": "float"
      },
      "minLength": 1,
      "maxLength": 20000
    },
    "sparseValues": {
      "$ref": "#/components/schemas/SparseValues"
    },
    "topK": {
      "example": 10,
      "description": "An override for the number of results to return for this query vector.",
      "type": "integer",
      "format": "int64",
      "minimum": 1,
      "maximum": 10000
    },
    "namespace": {
      "example": "example-namespace",
      "description": "An override the namespace to search.",
      "type": "string"
    },
    "filter": {
      "example": {
        "genre": {
          "$in": [
            "comedy",
            "documentary",
            "drama"
          ]
        },
        "year": {
          "$eq": 2019
        }
      },
      "description": "An override for the metadata filter to apply. This replaces the request-level filter.",
      "type": "object"
    }
  },
  "required": [
    "values"
  ]
}