Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update generated openapi code #309

Merged
merged 2 commits into from
Feb 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions pinecone/core/client/__init__.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
# flake8: noqa

"""
Pineonce.io Public API
Pinecone Control Plane API

Pinecone is a vector database that makes it easy to search and retrieve billions of high-dimensional vectors. # noqa: E501

The version of the OpenAPI document: 1.0
The version of the OpenAPI document: v1
Contact: [email protected]
Generated by: https://openapi-generator.tech
"""

Expand Down
45 changes: 23 additions & 22 deletions pinecone/core/client/api/manage_indexes_api.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
"""
Pineonce.io Public API
Pinecone Control Plane API

Pinecone is a vector database that makes it easy to search and retrieve billions of high-dimensional vectors. # noqa: E501

The version of the OpenAPI document: 1.0
The version of the OpenAPI document: v1
Contact: [email protected]
Generated by: https://openapi-generator.tech
"""

Expand Down Expand Up @@ -49,17 +50,17 @@ def __configure_index(
configure_index_request,
**kwargs
):
"""configure_index # noqa: E501
"""Configure an index # noqa: E501

This operation specifies the pod type and number of replicas for an index. # noqa: E501
This operation specifies the pod type and number of replicas for an index. It applies to pod-based indexes only. Serverless indexes scale automatically based on usage. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True

>>> thread = api.configure_index(index_name, configure_index_request, async_req=True)
>>> result = thread.get()

Args:
index_name (str): The name of the index to configure
index_name (str): The name of the index to configure.
configure_index_request (ConfigureIndexRequest): The desired pod type and replica configuration for the index.

Keyword Args:
Expand Down Expand Up @@ -183,9 +184,9 @@ def __create_collection(
create_collection_request,
**kwargs
):
"""create_collection # noqa: E501
"""Create a collection # noqa: E501

This operation creates a Pinecone collection. # noqa: E501
This operation creates a Pinecone collection. Serverless and starter indexes do not support collections. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True

Expand Down Expand Up @@ -308,7 +309,7 @@ def __create_index(
create_index_request,
**kwargs
):
"""create_index # noqa: E501
"""Create an index # noqa: E501

This operation deploys a Pinecone index. This is where you specify the measure of similarity, the dimension of vectors to be stored in the index, which cloud provider you would like to deploy with, and more. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
Expand Down Expand Up @@ -433,17 +434,17 @@ def __delete_collection(
collection_name,
**kwargs
):
"""delete_collection # noqa: E501
"""Delete a collection # noqa: E501

This operation deletes an existing collection. # noqa: E501
This operation deletes an existing collection. Serverless and starter indexes do not support collections. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True

>>> thread = api.delete_collection(collection_name, async_req=True)
>>> result = thread.get()

Args:
collection_name (str): The name of the collection
collection_name (str): The name of the collection.

Keyword Args:
_return_http_data_only (bool): response data without head status
Expand Down Expand Up @@ -558,7 +559,7 @@ def __delete_index(
index_name,
**kwargs
):
"""delete_index # noqa: E501
"""Delete an index # noqa: E501

This operation deletes an existing index. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
Expand All @@ -568,7 +569,7 @@ def __delete_index(
>>> result = thread.get()

Args:
index_name (str): The name of the index to delete
index_name (str): The name of the index to delete.

Keyword Args:
_return_http_data_only (bool): response data without head status
Expand Down Expand Up @@ -682,17 +683,17 @@ def __describe_collection(
collection_name,
**kwargs
):
"""describe_collection # noqa: E501
"""Describe a collection # noqa: E501

This operation gets a description of a collection. # noqa: E501
This operation gets a description of a collection. Serverless and starter indexes do not support collections. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True

>>> thread = api.describe_collection(collection_name, async_req=True)
>>> result = thread.get()

Args:
collection_name (str): The name of the collection to be described
collection_name (str): The name of the collection to be described.

Keyword Args:
_return_http_data_only (bool): response data without head status
Expand Down Expand Up @@ -806,7 +807,7 @@ def __describe_index(
index_name,
**kwargs
):
"""describe_index # noqa: E501
"""Describe an index # noqa: E501

Get a description of an index. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
Expand All @@ -816,7 +817,7 @@ def __describe_index(
>>> result = thread.get()

Args:
index_name (str): The name of the index to be described
index_name (str): The name of the index to be described.

Keyword Args:
_return_http_data_only (bool): response data without head status
Expand Down Expand Up @@ -929,9 +930,9 @@ def __list_collections(
self,
**kwargs
):
"""list_collections # noqa: E501
"""List collections # noqa: E501

This operation returns a list of your Pinecone collections. # noqa: E501
This operation returns a list of your Pinecone collections. Serverless and starter indexes do not support collections. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True

Expand Down Expand Up @@ -1041,9 +1042,9 @@ def __list_indexes(
self,
**kwargs
):
"""list_indexes # noqa: E501
"""List indexes # noqa: E501

This operation returns a list of your Pinecone indexes. # noqa: E501
This operation returns a list of all indexes in a project. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True

Expand Down
137 changes: 135 additions & 2 deletions pinecone/core/client/api/vector_operations_api.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
"""
Pineonce.io Public API
Pinecone Control Plane API

Pinecone is a vector database that makes it easy to search and retrieve billions of high-dimensional vectors. # noqa: E501

The version of the OpenAPI document: 1.0
The version of the OpenAPI document: v1
Contact: [email protected]
Generated by: https://openapi-generator.tech
"""

Expand All @@ -25,6 +26,7 @@
from pinecone.core.client.model.describe_index_stats_request import DescribeIndexStatsRequest
from pinecone.core.client.model.describe_index_stats_response import DescribeIndexStatsResponse
from pinecone.core.client.model.fetch_response import FetchResponse
from pinecone.core.client.model.list_response import ListResponse
from pinecone.core.client.model.query_request import QueryRequest
from pinecone.core.client.model.query_response import QueryResponse
from pinecone.core.client.model.rpc_status import RpcStatus
Expand Down Expand Up @@ -644,6 +646,137 @@ def __fetch(
callable=__fetch
)

def __list(
self,
**kwargs
):
"""List # noqa: E501

The `List` operations lists the IDs of vectors in a single namespace. An optional prefix can be passed to limit the listing to those ids that start with the given prefix. Ids are returned in sorted order (bitwise/\"C\" collation). A maximum of 100 ids are returned at a time. A pagination token is also returned to allow the client to list the next 100. The absence of the pagination token indicates that there are no more ids that match the given parameters. # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True

>>> thread = api.list(async_req=True)
>>> result = thread.get()


Keyword Args:
prefix (str): The vector IDs to fetch. Does not accept values containing spaces.. [optional]
limit (int): Max number of ids to return.. [optional]
pagination_token (str): Pagination token to continue a previous listing operation.. [optional]
namespace (str): [optional]
_return_http_data_only (bool): response data without head status
code and headers. Default is True.
_preload_content (bool): if False, the urllib3.HTTPResponse object
will be returned without reading/decoding response data.
Default is True.
_request_timeout (int/float/tuple): timeout setting for this request. If
one number provided, it will be total request timeout. It can also
be a pair (tuple) of (connection, read) timeouts.
Default is None.
_check_input_type (bool): specifies if type checking
should be done one the data sent to the server.
Default is True.
_check_return_type (bool): specifies if type checking
should be done one the data received from the server.
Default is True.
_host_index (int/None): specifies the index of the server
that we want to use.
Default is read from the configuration.
async_req (bool): execute request asynchronously

Returns:
ListResponse
If the method is called asynchronously, returns the request
thread.
"""
kwargs['async_req'] = kwargs.get(
'async_req', False
)
kwargs['_return_http_data_only'] = kwargs.get(
'_return_http_data_only', True
)
kwargs['_preload_content'] = kwargs.get(
'_preload_content', True
)
kwargs['_request_timeout'] = kwargs.get(
'_request_timeout', None
)
kwargs['_check_input_type'] = kwargs.get(
'_check_input_type', True
)
kwargs['_check_return_type'] = kwargs.get(
'_check_return_type', True
)
kwargs['_host_index'] = kwargs.get('_host_index')
return self.call_with_http_info(**kwargs)

self.list = _Endpoint(
settings={
'response_type': (ListResponse,),
'auth': [
'ApiKeyAuth'
],
'endpoint_path': '/vectors/list',
'operation_id': 'list',
'http_method': 'GET',
'servers': None,
},
params_map={
'all': [
'prefix',
'limit',
'pagination_token',
'namespace',
],
'required': [],
'nullable': [
],
'enum': [
],
'validation': [
]
},
root_map={
'validations': {
},
'allowed_values': {
},
'openapi_types': {
'prefix':
(str,),
'limit':
(int,),
'pagination_token':
(str,),
'namespace':
(str,),
},
'attribute_map': {
'prefix': 'prefix',
'limit': 'limit',
'pagination_token': 'paginationToken',
'namespace': 'namespace',
},
'location_map': {
'prefix': 'query',
'limit': 'query',
'pagination_token': 'query',
'namespace': 'query',
},
'collection_format_map': {
}
},
headers_map={
'accept': [
'application/json'
],
'content_type': [],
},
api_client=api_client,
callable=__list
)

def __query(
self,
query_request,
Expand Down
5 changes: 3 additions & 2 deletions pinecone/core/client/api_client.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
"""
Pineonce.io Public API
Pinecone Control Plane API

Pinecone is a vector database that makes it easy to search and retrieve billions of high-dimensional vectors. # noqa: E501

The version of the OpenAPI document: 1.0
The version of the OpenAPI document: v1
Contact: [email protected]
Generated by: https://openapi-generator.tech
"""

Expand Down
9 changes: 5 additions & 4 deletions pinecone/core/client/configuration.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
"""
Pineonce.io Public API
Pinecone Control Plane API

Pinecone is a vector database that makes it easy to search and retrieve billions of high-dimensional vectors. # noqa: E501

The version of the OpenAPI document: 1.0
The version of the OpenAPI document: v1
Contact: [email protected]
Generated by: https://openapi-generator.tech
"""

Expand Down Expand Up @@ -405,7 +406,7 @@ def to_debug_report(self):
return "Python SDK Debug Report:\n"\
"OS: {env}\n"\
"Python Version: {pyversion}\n"\
"Version of the API: 1.0\n"\
"Version of the API: v1\n"\
"SDK Package Version: 1.0.0".\
format(env=sys.platform, pyversion=sys.version)

Expand All @@ -417,7 +418,7 @@ def get_host_settings(self):
return [
{
'url': "https://api.pinecone.io",
'description': "No description provided",
'description': "Production API endpoints; unversioned legacy.",
}
]

Expand Down
5 changes: 3 additions & 2 deletions pinecone/core/client/exceptions.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
"""
Pineonce.io Public API
Pinecone Control Plane API

Pinecone is a vector database that makes it easy to search and retrieve billions of high-dimensional vectors. # noqa: E501

The version of the OpenAPI document: 1.0
The version of the OpenAPI document: v1
Contact: [email protected]
Generated by: https://openapi-generator.tech
"""

Expand Down
Loading