From fc00d6f41057a05ccedfab0db96d11ee9ffb708d Mon Sep 17 00:00:00 2001 From: Dirk Kulawiak Date: Tue, 22 Oct 2024 09:02:27 +0200 Subject: [PATCH 1/4] Fix imports after latest proto changes --- weaviate/collections/classes/internal.py | 6 +- weaviate/proto/v1/generative_pb2.py | 121 ++++ weaviate/proto/v1/generative_pb2.pyi | 684 +++++++++++++++++++++++ weaviate/proto/v1/generative_pb2_grpc.py | 3 + weaviate/proto/v1/search_get_pb2.py | 157 +++--- weaviate/proto/v1/search_get_pb2.pyi | 56 +- 6 files changed, 924 insertions(+), 103 deletions(-) create mode 100644 weaviate/proto/v1/generative_pb2.py create mode 100644 weaviate/proto/v1/generative_pb2.pyi create mode 100644 weaviate/proto/v1/generative_pb2_grpc.py diff --git a/weaviate/collections/classes/internal.py b/weaviate/collections/classes/internal.py index dabac02fe..d1e343a7f 100644 --- a/weaviate/collections/classes/internal.py +++ b/weaviate/collections/classes/internal.py @@ -50,7 +50,7 @@ from weaviate.util import _to_beacons from weaviate.types import INCLUDE_VECTOR, UUID, UUIDS -from weaviate.proto.v1 import search_get_pb2 +from weaviate.proto.v1 import search_get_pb2, generative_pb2 @dataclass @@ -208,8 +208,8 @@ def __init__( self.grouped = grouped self.grouped_properties = grouped_properties - def to_grpc(self) -> search_get_pb2.GenerativeSearch: - return search_get_pb2.GenerativeSearch( + def to_grpc(self) -> generative_pb2.GenerativeSearch: + return generative_pb2.GenerativeSearch( single_response_prompt=self.single, grouped_response_task=self.grouped, grouped_properties=self.grouped_properties, diff --git a/weaviate/proto/v1/generative_pb2.py b/weaviate/proto/v1/generative_pb2.py new file mode 100644 index 000000000..5f8c937f9 --- /dev/null +++ b/weaviate/proto/v1/generative_pb2.py @@ -0,0 +1,121 @@ +# -*- coding: utf-8 -*- +# Generated by the protocol buffer compiler. DO NOT EDIT! +# source: v1/generative.proto +# Protobuf Python Version: 4.25.1 +"""Generated protocol buffer code.""" +from google.protobuf import descriptor as _descriptor +from google.protobuf import descriptor_pool as _descriptor_pool +from google.protobuf import symbol_database as _symbol_database +from google.protobuf.internal import builder as _builder + +# @@protoc_insertion_point(imports) + +_sym_db = _symbol_database.Default() + + +from weaviate.proto.v1 import base_pb2 as v1_dot_base__pb2 + + +DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile( + b'\n\x13v1/generative.proto\x12\x0bweaviate.v1\x1a\rv1/base.proto"\x9b\x03\n\x10GenerativeSearch\x12"\n\x16single_response_prompt\x18\x01 \x01(\tB\x02\x18\x01\x12!\n\x15grouped_response_task\x18\x02 \x01(\tB\x02\x18\x01\x12\x1e\n\x12grouped_properties\x18\x03 \x03(\tB\x02\x18\x01\x12\x34\n\x06single\x18\x04 \x01(\x0b\x32$.weaviate.v1.GenerativeSearch.Single\x12\x36\n\x07grouped\x18\x05 \x01(\x0b\x32%.weaviate.v1.GenerativeSearch.Grouped\x1aY\n\x06Single\x12\x0e\n\x06prompt\x18\x01 \x01(\t\x12\r\n\x05\x64\x65\x62ug\x18\x02 \x01(\x08\x12\x30\n\x07queries\x18\x03 \x03(\x0b\x32\x1f.weaviate.v1.GenerativeProvider\x1aW\n\x07Grouped\x12\x0c\n\x04task\x18\x01 \x01(\t\x12/\n\nproperties\x18\x02 \x01(\x0b\x32\x16.weaviate.v1.TextArrayH\x00\x88\x01\x01\x42\r\n\x0b_properties"\xa3\x04\n\x12GenerativeProvider\x12\x17\n\x0freturn_metadata\x18\x01 \x01(\x08\x12\x35\n\tanthropic\x18\x02 \x01(\x0b\x32 .weaviate.v1.GenerativeAnthropicH\x00\x12\x33\n\x08\x61nyscale\x18\x03 \x01(\x0b\x32\x1f.weaviate.v1.GenerativeAnyscaleH\x00\x12)\n\x03\x61ws\x18\x04 \x01(\x0b\x32\x1a.weaviate.v1.GenerativeAWSH\x00\x12/\n\x06\x63ohere\x18\x05 \x01(\x0b\x32\x1d.weaviate.v1.GenerativeCohereH\x00\x12-\n\x05\x64ummy\x18\x06 \x01(\x0b\x32\x1c.weaviate.v1.GenerativeDummyH\x00\x12\x31\n\x07mistral\x18\x07 \x01(\x0b\x32\x1e.weaviate.v1.GenerativeMistralH\x00\x12/\n\x06octoai\x18\x08 \x01(\x0b\x32\x1d.weaviate.v1.GenerativeOctoAIH\x00\x12/\n\x06ollama\x18\t \x01(\x0b\x32\x1d.weaviate.v1.GenerativeOllamaH\x00\x12/\n\x06openai\x18\n \x01(\x0b\x32\x1d.weaviate.v1.GenerativeOpenAIH\x00\x12/\n\x06google\x18\x0b \x01(\x0b\x32\x1d.weaviate.v1.GenerativeGoogleH\x00\x42\x06\n\x04kind"\xad\x02\n\x13GenerativeAnthropic\x12\x15\n\x08\x62\x61se_url\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x17\n\nmax_tokens\x18\x02 \x01(\x03H\x01\x88\x01\x01\x12\x12\n\x05model\x18\x03 \x01(\tH\x02\x88\x01\x01\x12\x18\n\x0btemperature\x18\x04 \x01(\x01H\x03\x88\x01\x01\x12\x12\n\x05top_k\x18\x05 \x01(\x03H\x04\x88\x01\x01\x12\x12\n\x05top_p\x18\x06 \x01(\x01H\x05\x88\x01\x01\x12\x33\n\x0estop_sequences\x18\x07 \x01(\x0b\x32\x16.weaviate.v1.TextArrayH\x06\x88\x01\x01\x42\x0b\n\t_base_urlB\r\n\x0b_max_tokensB\x08\n\x06_modelB\x0e\n\x0c_temperatureB\x08\n\x06_top_kB\x08\n\x06_top_pB\x11\n\x0f_stop_sequences"\x80\x01\n\x12GenerativeAnyscale\x12\x15\n\x08\x62\x61se_url\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x12\n\x05model\x18\x02 \x01(\tH\x01\x88\x01\x01\x12\x18\n\x0btemperature\x18\x03 \x01(\x01H\x02\x88\x01\x01\x42\x0b\n\t_base_urlB\x08\n\x06_modelB\x0e\n\x0c_temperature"W\n\rGenerativeAWS\x12\x12\n\x05model\x18\x03 \x01(\tH\x00\x88\x01\x01\x12\x18\n\x0btemperature\x18\x08 \x01(\x01H\x01\x88\x01\x01\x42\x08\n\x06_modelB\x0e\n\x0c_temperature"\x84\x03\n\x10GenerativeCohere\x12\x15\n\x08\x62\x61se_url\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x1e\n\x11\x66requency_penalty\x18\x02 \x01(\x01H\x01\x88\x01\x01\x12\x17\n\nmax_tokens\x18\x03 \x01(\x03H\x02\x88\x01\x01\x12\x12\n\x05model\x18\x04 \x01(\tH\x03\x88\x01\x01\x12\x0e\n\x01k\x18\x05 \x01(\x03H\x04\x88\x01\x01\x12\x0e\n\x01p\x18\x06 \x01(\x01H\x05\x88\x01\x01\x12\x1d\n\x10presence_penalty\x18\x07 \x01(\x01H\x06\x88\x01\x01\x12\x33\n\x0estop_sequences\x18\x08 \x01(\x0b\x32\x16.weaviate.v1.TextArrayH\x07\x88\x01\x01\x12\x18\n\x0btemperature\x18\t \x01(\x01H\x08\x88\x01\x01\x42\x0b\n\t_base_urlB\x14\n\x12_frequency_penaltyB\r\n\x0b_max_tokensB\x08\n\x06_modelB\x04\n\x02_kB\x04\n\x02_pB\x13\n\x11_presence_penaltyB\x11\n\x0f_stop_sequencesB\x0e\n\x0c_temperature"\x11\n\x0fGenerativeDummy"\xc5\x01\n\x11GenerativeMistral\x12\x15\n\x08\x62\x61se_url\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x17\n\nmax_tokens\x18\x02 \x01(\x03H\x01\x88\x01\x01\x12\x12\n\x05model\x18\x03 \x01(\tH\x02\x88\x01\x01\x12\x18\n\x0btemperature\x18\x04 \x01(\x01H\x03\x88\x01\x01\x12\x12\n\x05top_p\x18\x05 \x01(\x01H\x04\x88\x01\x01\x42\x0b\n\t_base_urlB\r\n\x0b_max_tokensB\x08\n\x06_modelB\x0e\n\x0c_temperatureB\x08\n\x06_top_p"\xda\x01\n\x10GenerativeOctoAI\x12\x15\n\x08\x62\x61se_url\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x17\n\nmax_tokens\x18\x02 \x01(\x03H\x01\x88\x01\x01\x12\x12\n\x05model\x18\x03 \x01(\tH\x02\x88\x01\x01\x12\x0e\n\x01n\x18\x04 \x01(\x03H\x03\x88\x01\x01\x12\x18\n\x0btemperature\x18\x05 \x01(\x01H\x04\x88\x01\x01\x12\x12\n\x05top_p\x18\x06 \x01(\x01H\x05\x88\x01\x01\x42\x0b\n\t_base_urlB\r\n\x0b_max_tokensB\x08\n\x06_modelB\x04\n\x02_nB\x0e\n\x0c_temperatureB\x08\n\x06_top_p"\x86\x01\n\x10GenerativeOllama\x12\x19\n\x0c\x61pi_endpoint\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x12\n\x05model\x18\x02 \x01(\tH\x01\x88\x01\x01\x12\x18\n\x0btemperature\x18\x03 \x01(\x01H\x02\x88\x01\x01\x42\x0f\n\r_api_endpointB\x08\n\x06_modelB\x0e\n\x0c_temperature"\x99\x03\n\x10GenerativeOpenAI\x12\x1e\n\x11\x66requency_penalty\x18\x01 \x01(\x01H\x00\x88\x01\x01\x12\x16\n\tlog_probs\x18\x02 \x01(\x08H\x01\x88\x01\x01\x12\x17\n\nmax_tokens\x18\x03 \x01(\x03H\x02\x88\x01\x01\x12\r\n\x05model\x18\x04 \x01(\t\x12\x0e\n\x01n\x18\x05 \x01(\x03H\x03\x88\x01\x01\x12\x1d\n\x10presence_penalty\x18\x06 \x01(\x01H\x04\x88\x01\x01\x12)\n\x04stop\x18\x07 \x01(\x0b\x32\x16.weaviate.v1.TextArrayH\x05\x88\x01\x01\x12\x18\n\x0btemperature\x18\x08 \x01(\x01H\x06\x88\x01\x01\x12\x12\n\x05top_p\x18\t \x01(\x01H\x07\x88\x01\x01\x12\x1a\n\rtop_log_probs\x18\n \x01(\x03H\x08\x88\x01\x01\x42\x14\n\x12_frequency_penaltyB\x0c\n\n_log_probsB\r\n\x0b_max_tokensB\x04\n\x02_nB\x13\n\x11_presence_penaltyB\x07\n\x05_stopB\x0e\n\x0c_temperatureB\x08\n\x06_top_pB\x10\n\x0e_top_log_probs"\xf0\x02\n\x10GenerativeGoogle\x12\x1e\n\x11\x66requency_penalty\x18\x01 \x01(\x01H\x00\x88\x01\x01\x12\x17\n\nmax_tokens\x18\x02 \x01(\x03H\x01\x88\x01\x01\x12\x12\n\x05model\x18\x03 \x01(\tH\x02\x88\x01\x01\x12\x1d\n\x10presence_penalty\x18\x04 \x01(\x01H\x03\x88\x01\x01\x12\x18\n\x0btemperature\x18\x05 \x01(\x01H\x04\x88\x01\x01\x12\x12\n\x05top_k\x18\x06 \x01(\x03H\x05\x88\x01\x01\x12\x12\n\x05top_p\x18\x07 \x01(\x01H\x06\x88\x01\x01\x12\x33\n\x0estop_sequences\x18\x08 \x01(\x0b\x32\x16.weaviate.v1.TextArrayH\x07\x88\x01\x01\x42\x14\n\x12_frequency_penaltyB\r\n\x0b_max_tokensB\x08\n\x06_modelB\x13\n\x11_presence_penaltyB\x0e\n\x0c_temperatureB\x08\n\x06_top_kB\x08\n\x06_top_pB\x11\n\x0f_stop_sequences"\x92\x01\n\x1bGenerativeAnthropicMetadata\x12=\n\x05usage\x18\x01 \x01(\x0b\x32..weaviate.v1.GenerativeAnthropicMetadata.Usage\x1a\x34\n\x05Usage\x12\x14\n\x0cinput_tokens\x18\x01 \x01(\x03\x12\x15\n\routput_tokens\x18\x02 \x01(\x03"\x1c\n\x1aGenerativeAnyscaleMetadata"\x17\n\x15GenerativeAWSMetadata"\x9c\x06\n\x18GenerativeCohereMetadata\x12J\n\x0b\x61pi_version\x18\x01 \x01(\x0b\x32\x30.weaviate.v1.GenerativeCohereMetadata.ApiVersionH\x00\x88\x01\x01\x12L\n\x0c\x62illed_units\x18\x02 \x01(\x0b\x32\x31.weaviate.v1.GenerativeCohereMetadata.BilledUnitsH\x01\x88\x01\x01\x12\x41\n\x06tokens\x18\x03 \x01(\x0b\x32,.weaviate.v1.GenerativeCohereMetadata.TokensH\x02\x88\x01\x01\x12-\n\x08warnings\x18\x04 \x01(\x0b\x32\x16.weaviate.v1.TextArrayH\x03\x88\x01\x01\x1a\x8e\x01\n\nApiVersion\x12\x14\n\x07version\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x1a\n\ris_deprecated\x18\x02 \x01(\x08H\x01\x88\x01\x01\x12\x1c\n\x0fis_experimental\x18\x03 \x01(\x08H\x02\x88\x01\x01\x42\n\n\x08_versionB\x10\n\x0e_is_deprecatedB\x12\n\x10_is_experimental\x1a\xc5\x01\n\x0b\x42illedUnits\x12\x19\n\x0cinput_tokens\x18\x01 \x01(\x01H\x00\x88\x01\x01\x12\x1a\n\routput_tokens\x18\x02 \x01(\x01H\x01\x88\x01\x01\x12\x19\n\x0csearch_units\x18\x03 \x01(\x01H\x02\x88\x01\x01\x12\x1c\n\x0f\x63lassifications\x18\x04 \x01(\x01H\x03\x88\x01\x01\x42\x0f\n\r_input_tokensB\x10\n\x0e_output_tokensB\x0f\n\r_search_unitsB\x12\n\x10_classifications\x1a\x62\n\x06Tokens\x12\x19\n\x0cinput_tokens\x18\x01 \x01(\x01H\x00\x88\x01\x01\x12\x1a\n\routput_tokens\x18\x02 \x01(\x01H\x01\x88\x01\x01\x42\x0f\n\r_input_tokensB\x10\n\x0e_output_tokensB\x0e\n\x0c_api_versionB\x0f\n\r_billed_unitsB\t\n\x07_tokensB\x0b\n\t_warnings"\x19\n\x17GenerativeDummyMetadata"\x81\x02\n\x19GenerativeMistralMetadata\x12@\n\x05usage\x18\x01 \x01(\x0b\x32,.weaviate.v1.GenerativeMistralMetadata.UsageH\x00\x88\x01\x01\x1a\x97\x01\n\x05Usage\x12\x1a\n\rprompt_tokens\x18\x01 \x01(\x03H\x00\x88\x01\x01\x12\x1e\n\x11\x63ompletion_tokens\x18\x02 \x01(\x03H\x01\x88\x01\x01\x12\x19\n\x0ctotal_tokens\x18\x03 \x01(\x03H\x02\x88\x01\x01\x42\x10\n\x0e_prompt_tokensB\x14\n\x12_completion_tokensB\x0f\n\r_total_tokensB\x08\n\x06_usage"\xff\x01\n\x18GenerativeOctoAIMetadata\x12?\n\x05usage\x18\x01 \x01(\x0b\x32+.weaviate.v1.GenerativeOctoAIMetadata.UsageH\x00\x88\x01\x01\x1a\x97\x01\n\x05Usage\x12\x1a\n\rprompt_tokens\x18\x01 \x01(\x03H\x00\x88\x01\x01\x12\x1e\n\x11\x63ompletion_tokens\x18\x02 \x01(\x03H\x01\x88\x01\x01\x12\x19\n\x0ctotal_tokens\x18\x03 \x01(\x03H\x02\x88\x01\x01\x42\x10\n\x0e_prompt_tokensB\x14\n\x12_completion_tokensB\x0f\n\r_total_tokensB\x08\n\x06_usage"\x1a\n\x18GenerativeOllamaMetadata"\xff\x01\n\x18GenerativeOpenAIMetadata\x12?\n\x05usage\x18\x01 \x01(\x0b\x32+.weaviate.v1.GenerativeOpenAIMetadata.UsageH\x00\x88\x01\x01\x1a\x97\x01\n\x05Usage\x12\x1a\n\rprompt_tokens\x18\x01 \x01(\x03H\x00\x88\x01\x01\x12\x1e\n\x11\x63ompletion_tokens\x18\x02 \x01(\x03H\x01\x88\x01\x01\x12\x19\n\x0ctotal_tokens\x18\x03 \x01(\x03H\x02\x88\x01\x01\x42\x10\n\x0e_prompt_tokensB\x14\n\x12_completion_tokensB\x0f\n\r_total_tokensB\x08\n\x06_usage"\xe8\x06\n\x18GenerativeGoogleMetadata\x12\x45\n\x08metadata\x18\x01 \x01(\x0b\x32..weaviate.v1.GenerativeGoogleMetadata.MetadataH\x00\x88\x01\x01\x12P\n\x0eusage_metadata\x18\x02 \x01(\x0b\x32\x33.weaviate.v1.GenerativeGoogleMetadata.UsageMetadataH\x01\x88\x01\x01\x1a~\n\nTokenCount\x12&\n\x19total_billable_characters\x18\x01 \x01(\x03H\x00\x88\x01\x01\x12\x19\n\x0ctotal_tokens\x18\x02 \x01(\x03H\x01\x88\x01\x01\x42\x1c\n\x1a_total_billable_charactersB\x0f\n\r_total_tokens\x1a\xe1\x01\n\rTokenMetadata\x12P\n\x11input_token_count\x18\x01 \x01(\x0b\x32\x30.weaviate.v1.GenerativeGoogleMetadata.TokenCountH\x00\x88\x01\x01\x12Q\n\x12output_token_count\x18\x02 \x01(\x0b\x32\x30.weaviate.v1.GenerativeGoogleMetadata.TokenCountH\x01\x88\x01\x01\x42\x14\n\x12_input_token_countB\x15\n\x13_output_token_count\x1ao\n\x08Metadata\x12P\n\x0etoken_metadata\x18\x01 \x01(\x0b\x32\x33.weaviate.v1.GenerativeGoogleMetadata.TokenMetadataH\x00\x88\x01\x01\x42\x11\n\x0f_token_metadata\x1a\xbd\x01\n\rUsageMetadata\x12\x1f\n\x12prompt_token_count\x18\x01 \x01(\x03H\x00\x88\x01\x01\x12#\n\x16\x63\x61ndidates_token_count\x18\x02 \x01(\x03H\x01\x88\x01\x01\x12\x1e\n\x11total_token_count\x18\x03 \x01(\x03H\x02\x88\x01\x01\x42\x15\n\x13_prompt_token_countB\x19\n\x17_candidates_token_countB\x14\n\x12_total_token_countB\x0b\n\t_metadataB\x11\n\x0f_usage_metadata"\xda\x04\n\x12GenerativeMetadata\x12=\n\tanthropic\x18\x01 \x01(\x0b\x32(.weaviate.v1.GenerativeAnthropicMetadataH\x00\x12;\n\x08\x61nyscale\x18\x02 \x01(\x0b\x32\'.weaviate.v1.GenerativeAnyscaleMetadataH\x00\x12\x31\n\x03\x61ws\x18\x03 \x01(\x0b\x32".weaviate.v1.GenerativeAWSMetadataH\x00\x12\x37\n\x06\x63ohere\x18\x04 \x01(\x0b\x32%.weaviate.v1.GenerativeCohereMetadataH\x00\x12\x35\n\x05\x64ummy\x18\x05 \x01(\x0b\x32$.weaviate.v1.GenerativeDummyMetadataH\x00\x12\x39\n\x07mistral\x18\x06 \x01(\x0b\x32&.weaviate.v1.GenerativeMistralMetadataH\x00\x12\x37\n\x06octoai\x18\x07 \x01(\x0b\x32%.weaviate.v1.GenerativeOctoAIMetadataH\x00\x12\x37\n\x06ollama\x18\x08 \x01(\x0b\x32%.weaviate.v1.GenerativeOllamaMetadataH\x00\x12\x37\n\x06openai\x18\t \x01(\x0b\x32%.weaviate.v1.GenerativeOpenAIMetadataH\x00\x12\x37\n\x06google\x18\n \x01(\x0b\x32%.weaviate.v1.GenerativeGoogleMetadataH\x00\x42\x06\n\x04kind"\xa2\x01\n\x0fGenerativeReply\x12\x0e\n\x06result\x18\x01 \x01(\t\x12\x30\n\x05\x64\x65\x62ug\x18\x02 \x01(\x0b\x32\x1c.weaviate.v1.GenerativeDebugH\x00\x88\x01\x01\x12\x36\n\x08metadata\x18\x03 \x01(\x0b\x32\x1f.weaviate.v1.GenerativeMetadataH\x01\x88\x01\x01\x42\x08\n\x06_debugB\x0b\n\t_metadata"@\n\x10GenerativeResult\x12,\n\x06values\x18\x01 \x03(\x0b\x32\x1c.weaviate.v1.GenerativeReply";\n\x0fGenerativeDebug\x12\x18\n\x0b\x66ull_prompt\x18\x01 \x01(\tH\x00\x88\x01\x01\x42\x0e\n\x0c_full_promptBt\n#io.weaviate.client.grpc.protocol.v1B\x17WeaviateProtoGenerativeZ4github.com/weaviate/weaviate/grpc/generated;protocolb\x06proto3' +) + +_globals = globals() +_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals) +_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, "v1.generative_pb2", _globals) +if _descriptor._USE_C_DESCRIPTORS == False: + _globals["DESCRIPTOR"]._options = None + _globals["DESCRIPTOR"]._serialized_options = ( + b"\n#io.weaviate.client.grpc.protocol.v1B\027WeaviateProtoGenerativeZ4github.com/weaviate/weaviate/grpc/generated;protocol" + ) + _globals["_GENERATIVESEARCH"].fields_by_name["single_response_prompt"]._options = None + _globals["_GENERATIVESEARCH"].fields_by_name[ + "single_response_prompt" + ]._serialized_options = b"\030\001" + _globals["_GENERATIVESEARCH"].fields_by_name["grouped_response_task"]._options = None + _globals["_GENERATIVESEARCH"].fields_by_name[ + "grouped_response_task" + ]._serialized_options = b"\030\001" + _globals["_GENERATIVESEARCH"].fields_by_name["grouped_properties"]._options = None + _globals["_GENERATIVESEARCH"].fields_by_name[ + "grouped_properties" + ]._serialized_options = b"\030\001" + _globals["_GENERATIVESEARCH"]._serialized_start = 52 + _globals["_GENERATIVESEARCH"]._serialized_end = 463 + _globals["_GENERATIVESEARCH_SINGLE"]._serialized_start = 285 + _globals["_GENERATIVESEARCH_SINGLE"]._serialized_end = 374 + _globals["_GENERATIVESEARCH_GROUPED"]._serialized_start = 376 + _globals["_GENERATIVESEARCH_GROUPED"]._serialized_end = 463 + _globals["_GENERATIVEPROVIDER"]._serialized_start = 466 + _globals["_GENERATIVEPROVIDER"]._serialized_end = 1013 + _globals["_GENERATIVEANTHROPIC"]._serialized_start = 1016 + _globals["_GENERATIVEANTHROPIC"]._serialized_end = 1317 + _globals["_GENERATIVEANYSCALE"]._serialized_start = 1320 + _globals["_GENERATIVEANYSCALE"]._serialized_end = 1448 + _globals["_GENERATIVEAWS"]._serialized_start = 1450 + _globals["_GENERATIVEAWS"]._serialized_end = 1537 + _globals["_GENERATIVECOHERE"]._serialized_start = 1540 + _globals["_GENERATIVECOHERE"]._serialized_end = 1928 + _globals["_GENERATIVEDUMMY"]._serialized_start = 1930 + _globals["_GENERATIVEDUMMY"]._serialized_end = 1947 + _globals["_GENERATIVEMISTRAL"]._serialized_start = 1950 + _globals["_GENERATIVEMISTRAL"]._serialized_end = 2147 + _globals["_GENERATIVEOCTOAI"]._serialized_start = 2150 + _globals["_GENERATIVEOCTOAI"]._serialized_end = 2368 + _globals["_GENERATIVEOLLAMA"]._serialized_start = 2371 + _globals["_GENERATIVEOLLAMA"]._serialized_end = 2505 + _globals["_GENERATIVEOPENAI"]._serialized_start = 2508 + _globals["_GENERATIVEOPENAI"]._serialized_end = 2917 + _globals["_GENERATIVEGOOGLE"]._serialized_start = 2920 + _globals["_GENERATIVEGOOGLE"]._serialized_end = 3288 + _globals["_GENERATIVEANTHROPICMETADATA"]._serialized_start = 3291 + _globals["_GENERATIVEANTHROPICMETADATA"]._serialized_end = 3437 + _globals["_GENERATIVEANTHROPICMETADATA_USAGE"]._serialized_start = 3385 + _globals["_GENERATIVEANTHROPICMETADATA_USAGE"]._serialized_end = 3437 + _globals["_GENERATIVEANYSCALEMETADATA"]._serialized_start = 3439 + _globals["_GENERATIVEANYSCALEMETADATA"]._serialized_end = 3467 + _globals["_GENERATIVEAWSMETADATA"]._serialized_start = 3469 + _globals["_GENERATIVEAWSMETADATA"]._serialized_end = 3492 + _globals["_GENERATIVECOHEREMETADATA"]._serialized_start = 3495 + _globals["_GENERATIVECOHEREMETADATA"]._serialized_end = 4291 + _globals["_GENERATIVECOHEREMETADATA_APIVERSION"]._serialized_start = 3792 + _globals["_GENERATIVECOHEREMETADATA_APIVERSION"]._serialized_end = 3934 + _globals["_GENERATIVECOHEREMETADATA_BILLEDUNITS"]._serialized_start = 3937 + _globals["_GENERATIVECOHEREMETADATA_BILLEDUNITS"]._serialized_end = 4134 + _globals["_GENERATIVECOHEREMETADATA_TOKENS"]._serialized_start = 4136 + _globals["_GENERATIVECOHEREMETADATA_TOKENS"]._serialized_end = 4234 + _globals["_GENERATIVEDUMMYMETADATA"]._serialized_start = 4293 + _globals["_GENERATIVEDUMMYMETADATA"]._serialized_end = 4318 + _globals["_GENERATIVEMISTRALMETADATA"]._serialized_start = 4321 + _globals["_GENERATIVEMISTRALMETADATA"]._serialized_end = 4578 + _globals["_GENERATIVEMISTRALMETADATA_USAGE"]._serialized_start = 4417 + _globals["_GENERATIVEMISTRALMETADATA_USAGE"]._serialized_end = 4568 + _globals["_GENERATIVEOCTOAIMETADATA"]._serialized_start = 4581 + _globals["_GENERATIVEOCTOAIMETADATA"]._serialized_end = 4836 + _globals["_GENERATIVEOCTOAIMETADATA_USAGE"]._serialized_start = 4417 + _globals["_GENERATIVEOCTOAIMETADATA_USAGE"]._serialized_end = 4568 + _globals["_GENERATIVEOLLAMAMETADATA"]._serialized_start = 4838 + _globals["_GENERATIVEOLLAMAMETADATA"]._serialized_end = 4864 + _globals["_GENERATIVEOPENAIMETADATA"]._serialized_start = 4867 + _globals["_GENERATIVEOPENAIMETADATA"]._serialized_end = 5122 + _globals["_GENERATIVEOPENAIMETADATA_USAGE"]._serialized_start = 4417 + _globals["_GENERATIVEOPENAIMETADATA_USAGE"]._serialized_end = 4568 + _globals["_GENERATIVEGOOGLEMETADATA"]._serialized_start = 5125 + _globals["_GENERATIVEGOOGLEMETADATA"]._serialized_end = 5997 + _globals["_GENERATIVEGOOGLEMETADATA_TOKENCOUNT"]._serialized_start = 5306 + _globals["_GENERATIVEGOOGLEMETADATA_TOKENCOUNT"]._serialized_end = 5432 + _globals["_GENERATIVEGOOGLEMETADATA_TOKENMETADATA"]._serialized_start = 5435 + _globals["_GENERATIVEGOOGLEMETADATA_TOKENMETADATA"]._serialized_end = 5660 + _globals["_GENERATIVEGOOGLEMETADATA_METADATA"]._serialized_start = 5662 + _globals["_GENERATIVEGOOGLEMETADATA_METADATA"]._serialized_end = 5773 + _globals["_GENERATIVEGOOGLEMETADATA_USAGEMETADATA"]._serialized_start = 5776 + _globals["_GENERATIVEGOOGLEMETADATA_USAGEMETADATA"]._serialized_end = 5965 + _globals["_GENERATIVEMETADATA"]._serialized_start = 6000 + _globals["_GENERATIVEMETADATA"]._serialized_end = 6602 + _globals["_GENERATIVEREPLY"]._serialized_start = 6605 + _globals["_GENERATIVEREPLY"]._serialized_end = 6767 + _globals["_GENERATIVERESULT"]._serialized_start = 6769 + _globals["_GENERATIVERESULT"]._serialized_end = 6833 + _globals["_GENERATIVEDEBUG"]._serialized_start = 6835 + _globals["_GENERATIVEDEBUG"]._serialized_end = 6894 +# @@protoc_insertion_point(module_scope) diff --git a/weaviate/proto/v1/generative_pb2.pyi b/weaviate/proto/v1/generative_pb2.pyi new file mode 100644 index 000000000..63c34a58f --- /dev/null +++ b/weaviate/proto/v1/generative_pb2.pyi @@ -0,0 +1,684 @@ +from weaviate.proto.v1 import base_pb2 as _base_pb2 +from google.protobuf.internal import containers as _containers +from google.protobuf import descriptor as _descriptor +from google.protobuf import message as _message +from typing import ( + ClassVar as _ClassVar, + Iterable as _Iterable, + Mapping as _Mapping, + Optional as _Optional, + Union as _Union, +) + +DESCRIPTOR: _descriptor.FileDescriptor + +class GenerativeSearch(_message.Message): + __slots__ = ( + "single_response_prompt", + "grouped_response_task", + "grouped_properties", + "single", + "grouped", + ) + + class Single(_message.Message): + __slots__ = ("prompt", "debug", "queries") + PROMPT_FIELD_NUMBER: _ClassVar[int] + DEBUG_FIELD_NUMBER: _ClassVar[int] + QUERIES_FIELD_NUMBER: _ClassVar[int] + prompt: str + debug: bool + queries: _containers.RepeatedCompositeFieldContainer[GenerativeProvider] + def __init__( + self, + prompt: _Optional[str] = ..., + debug: bool = ..., + queries: _Optional[_Iterable[_Union[GenerativeProvider, _Mapping]]] = ..., + ) -> None: ... + + class Grouped(_message.Message): + __slots__ = ("task", "properties") + TASK_FIELD_NUMBER: _ClassVar[int] + PROPERTIES_FIELD_NUMBER: _ClassVar[int] + task: str + properties: _base_pb2.TextArray + def __init__( + self, + task: _Optional[str] = ..., + properties: _Optional[_Union[_base_pb2.TextArray, _Mapping]] = ..., + ) -> None: ... + + SINGLE_RESPONSE_PROMPT_FIELD_NUMBER: _ClassVar[int] + GROUPED_RESPONSE_TASK_FIELD_NUMBER: _ClassVar[int] + GROUPED_PROPERTIES_FIELD_NUMBER: _ClassVar[int] + SINGLE_FIELD_NUMBER: _ClassVar[int] + GROUPED_FIELD_NUMBER: _ClassVar[int] + single_response_prompt: str + grouped_response_task: str + grouped_properties: _containers.RepeatedScalarFieldContainer[str] + single: GenerativeSearch.Single + grouped: GenerativeSearch.Grouped + def __init__( + self, + single_response_prompt: _Optional[str] = ..., + grouped_response_task: _Optional[str] = ..., + grouped_properties: _Optional[_Iterable[str]] = ..., + single: _Optional[_Union[GenerativeSearch.Single, _Mapping]] = ..., + grouped: _Optional[_Union[GenerativeSearch.Grouped, _Mapping]] = ..., + ) -> None: ... + +class GenerativeProvider(_message.Message): + __slots__ = ( + "return_metadata", + "anthropic", + "anyscale", + "aws", + "cohere", + "dummy", + "mistral", + "octoai", + "ollama", + "openai", + "google", + ) + RETURN_METADATA_FIELD_NUMBER: _ClassVar[int] + ANTHROPIC_FIELD_NUMBER: _ClassVar[int] + ANYSCALE_FIELD_NUMBER: _ClassVar[int] + AWS_FIELD_NUMBER: _ClassVar[int] + COHERE_FIELD_NUMBER: _ClassVar[int] + DUMMY_FIELD_NUMBER: _ClassVar[int] + MISTRAL_FIELD_NUMBER: _ClassVar[int] + OCTOAI_FIELD_NUMBER: _ClassVar[int] + OLLAMA_FIELD_NUMBER: _ClassVar[int] + OPENAI_FIELD_NUMBER: _ClassVar[int] + GOOGLE_FIELD_NUMBER: _ClassVar[int] + return_metadata: bool + anthropic: GenerativeAnthropic + anyscale: GenerativeAnyscale + aws: GenerativeAWS + cohere: GenerativeCohere + dummy: GenerativeDummy + mistral: GenerativeMistral + octoai: GenerativeOctoAI + ollama: GenerativeOllama + openai: GenerativeOpenAI + google: GenerativeGoogle + def __init__( + self, + return_metadata: bool = ..., + anthropic: _Optional[_Union[GenerativeAnthropic, _Mapping]] = ..., + anyscale: _Optional[_Union[GenerativeAnyscale, _Mapping]] = ..., + aws: _Optional[_Union[GenerativeAWS, _Mapping]] = ..., + cohere: _Optional[_Union[GenerativeCohere, _Mapping]] = ..., + dummy: _Optional[_Union[GenerativeDummy, _Mapping]] = ..., + mistral: _Optional[_Union[GenerativeMistral, _Mapping]] = ..., + octoai: _Optional[_Union[GenerativeOctoAI, _Mapping]] = ..., + ollama: _Optional[_Union[GenerativeOllama, _Mapping]] = ..., + openai: _Optional[_Union[GenerativeOpenAI, _Mapping]] = ..., + google: _Optional[_Union[GenerativeGoogle, _Mapping]] = ..., + ) -> None: ... + +class GenerativeAnthropic(_message.Message): + __slots__ = ( + "base_url", + "max_tokens", + "model", + "temperature", + "top_k", + "top_p", + "stop_sequences", + ) + BASE_URL_FIELD_NUMBER: _ClassVar[int] + MAX_TOKENS_FIELD_NUMBER: _ClassVar[int] + MODEL_FIELD_NUMBER: _ClassVar[int] + TEMPERATURE_FIELD_NUMBER: _ClassVar[int] + TOP_K_FIELD_NUMBER: _ClassVar[int] + TOP_P_FIELD_NUMBER: _ClassVar[int] + STOP_SEQUENCES_FIELD_NUMBER: _ClassVar[int] + base_url: str + max_tokens: int + model: str + temperature: float + top_k: int + top_p: float + stop_sequences: _base_pb2.TextArray + def __init__( + self, + base_url: _Optional[str] = ..., + max_tokens: _Optional[int] = ..., + model: _Optional[str] = ..., + temperature: _Optional[float] = ..., + top_k: _Optional[int] = ..., + top_p: _Optional[float] = ..., + stop_sequences: _Optional[_Union[_base_pb2.TextArray, _Mapping]] = ..., + ) -> None: ... + +class GenerativeAnyscale(_message.Message): + __slots__ = ("base_url", "model", "temperature") + BASE_URL_FIELD_NUMBER: _ClassVar[int] + MODEL_FIELD_NUMBER: _ClassVar[int] + TEMPERATURE_FIELD_NUMBER: _ClassVar[int] + base_url: str + model: str + temperature: float + def __init__( + self, + base_url: _Optional[str] = ..., + model: _Optional[str] = ..., + temperature: _Optional[float] = ..., + ) -> None: ... + +class GenerativeAWS(_message.Message): + __slots__ = ("model", "temperature") + MODEL_FIELD_NUMBER: _ClassVar[int] + TEMPERATURE_FIELD_NUMBER: _ClassVar[int] + model: str + temperature: float + def __init__( + self, model: _Optional[str] = ..., temperature: _Optional[float] = ... + ) -> None: ... + +class GenerativeCohere(_message.Message): + __slots__ = ( + "base_url", + "frequency_penalty", + "max_tokens", + "model", + "k", + "p", + "presence_penalty", + "stop_sequences", + "temperature", + ) + BASE_URL_FIELD_NUMBER: _ClassVar[int] + FREQUENCY_PENALTY_FIELD_NUMBER: _ClassVar[int] + MAX_TOKENS_FIELD_NUMBER: _ClassVar[int] + MODEL_FIELD_NUMBER: _ClassVar[int] + K_FIELD_NUMBER: _ClassVar[int] + P_FIELD_NUMBER: _ClassVar[int] + PRESENCE_PENALTY_FIELD_NUMBER: _ClassVar[int] + STOP_SEQUENCES_FIELD_NUMBER: _ClassVar[int] + TEMPERATURE_FIELD_NUMBER: _ClassVar[int] + base_url: str + frequency_penalty: float + max_tokens: int + model: str + k: int + p: float + presence_penalty: float + stop_sequences: _base_pb2.TextArray + temperature: float + def __init__( + self, + base_url: _Optional[str] = ..., + frequency_penalty: _Optional[float] = ..., + max_tokens: _Optional[int] = ..., + model: _Optional[str] = ..., + k: _Optional[int] = ..., + p: _Optional[float] = ..., + presence_penalty: _Optional[float] = ..., + stop_sequences: _Optional[_Union[_base_pb2.TextArray, _Mapping]] = ..., + temperature: _Optional[float] = ..., + ) -> None: ... + +class GenerativeDummy(_message.Message): + __slots__ = () + def __init__(self) -> None: ... + +class GenerativeMistral(_message.Message): + __slots__ = ("base_url", "max_tokens", "model", "temperature", "top_p") + BASE_URL_FIELD_NUMBER: _ClassVar[int] + MAX_TOKENS_FIELD_NUMBER: _ClassVar[int] + MODEL_FIELD_NUMBER: _ClassVar[int] + TEMPERATURE_FIELD_NUMBER: _ClassVar[int] + TOP_P_FIELD_NUMBER: _ClassVar[int] + base_url: str + max_tokens: int + model: str + temperature: float + top_p: float + def __init__( + self, + base_url: _Optional[str] = ..., + max_tokens: _Optional[int] = ..., + model: _Optional[str] = ..., + temperature: _Optional[float] = ..., + top_p: _Optional[float] = ..., + ) -> None: ... + +class GenerativeOctoAI(_message.Message): + __slots__ = ("base_url", "max_tokens", "model", "n", "temperature", "top_p") + BASE_URL_FIELD_NUMBER: _ClassVar[int] + MAX_TOKENS_FIELD_NUMBER: _ClassVar[int] + MODEL_FIELD_NUMBER: _ClassVar[int] + N_FIELD_NUMBER: _ClassVar[int] + TEMPERATURE_FIELD_NUMBER: _ClassVar[int] + TOP_P_FIELD_NUMBER: _ClassVar[int] + base_url: str + max_tokens: int + model: str + n: int + temperature: float + top_p: float + def __init__( + self, + base_url: _Optional[str] = ..., + max_tokens: _Optional[int] = ..., + model: _Optional[str] = ..., + n: _Optional[int] = ..., + temperature: _Optional[float] = ..., + top_p: _Optional[float] = ..., + ) -> None: ... + +class GenerativeOllama(_message.Message): + __slots__ = ("api_endpoint", "model", "temperature") + API_ENDPOINT_FIELD_NUMBER: _ClassVar[int] + MODEL_FIELD_NUMBER: _ClassVar[int] + TEMPERATURE_FIELD_NUMBER: _ClassVar[int] + api_endpoint: str + model: str + temperature: float + def __init__( + self, + api_endpoint: _Optional[str] = ..., + model: _Optional[str] = ..., + temperature: _Optional[float] = ..., + ) -> None: ... + +class GenerativeOpenAI(_message.Message): + __slots__ = ( + "frequency_penalty", + "log_probs", + "max_tokens", + "model", + "n", + "presence_penalty", + "stop", + "temperature", + "top_p", + "top_log_probs", + ) + FREQUENCY_PENALTY_FIELD_NUMBER: _ClassVar[int] + LOG_PROBS_FIELD_NUMBER: _ClassVar[int] + MAX_TOKENS_FIELD_NUMBER: _ClassVar[int] + MODEL_FIELD_NUMBER: _ClassVar[int] + N_FIELD_NUMBER: _ClassVar[int] + PRESENCE_PENALTY_FIELD_NUMBER: _ClassVar[int] + STOP_FIELD_NUMBER: _ClassVar[int] + TEMPERATURE_FIELD_NUMBER: _ClassVar[int] + TOP_P_FIELD_NUMBER: _ClassVar[int] + TOP_LOG_PROBS_FIELD_NUMBER: _ClassVar[int] + frequency_penalty: float + log_probs: bool + max_tokens: int + model: str + n: int + presence_penalty: float + stop: _base_pb2.TextArray + temperature: float + top_p: float + top_log_probs: int + def __init__( + self, + frequency_penalty: _Optional[float] = ..., + log_probs: bool = ..., + max_tokens: _Optional[int] = ..., + model: _Optional[str] = ..., + n: _Optional[int] = ..., + presence_penalty: _Optional[float] = ..., + stop: _Optional[_Union[_base_pb2.TextArray, _Mapping]] = ..., + temperature: _Optional[float] = ..., + top_p: _Optional[float] = ..., + top_log_probs: _Optional[int] = ..., + ) -> None: ... + +class GenerativeGoogle(_message.Message): + __slots__ = ( + "frequency_penalty", + "max_tokens", + "model", + "presence_penalty", + "temperature", + "top_k", + "top_p", + "stop_sequences", + ) + FREQUENCY_PENALTY_FIELD_NUMBER: _ClassVar[int] + MAX_TOKENS_FIELD_NUMBER: _ClassVar[int] + MODEL_FIELD_NUMBER: _ClassVar[int] + PRESENCE_PENALTY_FIELD_NUMBER: _ClassVar[int] + TEMPERATURE_FIELD_NUMBER: _ClassVar[int] + TOP_K_FIELD_NUMBER: _ClassVar[int] + TOP_P_FIELD_NUMBER: _ClassVar[int] + STOP_SEQUENCES_FIELD_NUMBER: _ClassVar[int] + frequency_penalty: float + max_tokens: int + model: str + presence_penalty: float + temperature: float + top_k: int + top_p: float + stop_sequences: _base_pb2.TextArray + def __init__( + self, + frequency_penalty: _Optional[float] = ..., + max_tokens: _Optional[int] = ..., + model: _Optional[str] = ..., + presence_penalty: _Optional[float] = ..., + temperature: _Optional[float] = ..., + top_k: _Optional[int] = ..., + top_p: _Optional[float] = ..., + stop_sequences: _Optional[_Union[_base_pb2.TextArray, _Mapping]] = ..., + ) -> None: ... + +class GenerativeAnthropicMetadata(_message.Message): + __slots__ = ("usage",) + + class Usage(_message.Message): + __slots__ = ("input_tokens", "output_tokens") + INPUT_TOKENS_FIELD_NUMBER: _ClassVar[int] + OUTPUT_TOKENS_FIELD_NUMBER: _ClassVar[int] + input_tokens: int + output_tokens: int + def __init__( + self, input_tokens: _Optional[int] = ..., output_tokens: _Optional[int] = ... + ) -> None: ... + + USAGE_FIELD_NUMBER: _ClassVar[int] + usage: GenerativeAnthropicMetadata.Usage + def __init__( + self, usage: _Optional[_Union[GenerativeAnthropicMetadata.Usage, _Mapping]] = ... + ) -> None: ... + +class GenerativeAnyscaleMetadata(_message.Message): + __slots__ = () + def __init__(self) -> None: ... + +class GenerativeAWSMetadata(_message.Message): + __slots__ = () + def __init__(self) -> None: ... + +class GenerativeCohereMetadata(_message.Message): + __slots__ = ("api_version", "billed_units", "tokens", "warnings") + + class ApiVersion(_message.Message): + __slots__ = ("version", "is_deprecated", "is_experimental") + VERSION_FIELD_NUMBER: _ClassVar[int] + IS_DEPRECATED_FIELD_NUMBER: _ClassVar[int] + IS_EXPERIMENTAL_FIELD_NUMBER: _ClassVar[int] + version: str + is_deprecated: bool + is_experimental: bool + def __init__( + self, + version: _Optional[str] = ..., + is_deprecated: bool = ..., + is_experimental: bool = ..., + ) -> None: ... + + class BilledUnits(_message.Message): + __slots__ = ("input_tokens", "output_tokens", "search_units", "classifications") + INPUT_TOKENS_FIELD_NUMBER: _ClassVar[int] + OUTPUT_TOKENS_FIELD_NUMBER: _ClassVar[int] + SEARCH_UNITS_FIELD_NUMBER: _ClassVar[int] + CLASSIFICATIONS_FIELD_NUMBER: _ClassVar[int] + input_tokens: float + output_tokens: float + search_units: float + classifications: float + def __init__( + self, + input_tokens: _Optional[float] = ..., + output_tokens: _Optional[float] = ..., + search_units: _Optional[float] = ..., + classifications: _Optional[float] = ..., + ) -> None: ... + + class Tokens(_message.Message): + __slots__ = ("input_tokens", "output_tokens") + INPUT_TOKENS_FIELD_NUMBER: _ClassVar[int] + OUTPUT_TOKENS_FIELD_NUMBER: _ClassVar[int] + input_tokens: float + output_tokens: float + def __init__( + self, input_tokens: _Optional[float] = ..., output_tokens: _Optional[float] = ... + ) -> None: ... + + API_VERSION_FIELD_NUMBER: _ClassVar[int] + BILLED_UNITS_FIELD_NUMBER: _ClassVar[int] + TOKENS_FIELD_NUMBER: _ClassVar[int] + WARNINGS_FIELD_NUMBER: _ClassVar[int] + api_version: GenerativeCohereMetadata.ApiVersion + billed_units: GenerativeCohereMetadata.BilledUnits + tokens: GenerativeCohereMetadata.Tokens + warnings: _base_pb2.TextArray + def __init__( + self, + api_version: _Optional[_Union[GenerativeCohereMetadata.ApiVersion, _Mapping]] = ..., + billed_units: _Optional[_Union[GenerativeCohereMetadata.BilledUnits, _Mapping]] = ..., + tokens: _Optional[_Union[GenerativeCohereMetadata.Tokens, _Mapping]] = ..., + warnings: _Optional[_Union[_base_pb2.TextArray, _Mapping]] = ..., + ) -> None: ... + +class GenerativeDummyMetadata(_message.Message): + __slots__ = () + def __init__(self) -> None: ... + +class GenerativeMistralMetadata(_message.Message): + __slots__ = ("usage",) + + class Usage(_message.Message): + __slots__ = ("prompt_tokens", "completion_tokens", "total_tokens") + PROMPT_TOKENS_FIELD_NUMBER: _ClassVar[int] + COMPLETION_TOKENS_FIELD_NUMBER: _ClassVar[int] + TOTAL_TOKENS_FIELD_NUMBER: _ClassVar[int] + prompt_tokens: int + completion_tokens: int + total_tokens: int + def __init__( + self, + prompt_tokens: _Optional[int] = ..., + completion_tokens: _Optional[int] = ..., + total_tokens: _Optional[int] = ..., + ) -> None: ... + + USAGE_FIELD_NUMBER: _ClassVar[int] + usage: GenerativeMistralMetadata.Usage + def __init__( + self, usage: _Optional[_Union[GenerativeMistralMetadata.Usage, _Mapping]] = ... + ) -> None: ... + +class GenerativeOctoAIMetadata(_message.Message): + __slots__ = ("usage",) + + class Usage(_message.Message): + __slots__ = ("prompt_tokens", "completion_tokens", "total_tokens") + PROMPT_TOKENS_FIELD_NUMBER: _ClassVar[int] + COMPLETION_TOKENS_FIELD_NUMBER: _ClassVar[int] + TOTAL_TOKENS_FIELD_NUMBER: _ClassVar[int] + prompt_tokens: int + completion_tokens: int + total_tokens: int + def __init__( + self, + prompt_tokens: _Optional[int] = ..., + completion_tokens: _Optional[int] = ..., + total_tokens: _Optional[int] = ..., + ) -> None: ... + + USAGE_FIELD_NUMBER: _ClassVar[int] + usage: GenerativeOctoAIMetadata.Usage + def __init__( + self, usage: _Optional[_Union[GenerativeOctoAIMetadata.Usage, _Mapping]] = ... + ) -> None: ... + +class GenerativeOllamaMetadata(_message.Message): + __slots__ = () + def __init__(self) -> None: ... + +class GenerativeOpenAIMetadata(_message.Message): + __slots__ = ("usage",) + + class Usage(_message.Message): + __slots__ = ("prompt_tokens", "completion_tokens", "total_tokens") + PROMPT_TOKENS_FIELD_NUMBER: _ClassVar[int] + COMPLETION_TOKENS_FIELD_NUMBER: _ClassVar[int] + TOTAL_TOKENS_FIELD_NUMBER: _ClassVar[int] + prompt_tokens: int + completion_tokens: int + total_tokens: int + def __init__( + self, + prompt_tokens: _Optional[int] = ..., + completion_tokens: _Optional[int] = ..., + total_tokens: _Optional[int] = ..., + ) -> None: ... + + USAGE_FIELD_NUMBER: _ClassVar[int] + usage: GenerativeOpenAIMetadata.Usage + def __init__( + self, usage: _Optional[_Union[GenerativeOpenAIMetadata.Usage, _Mapping]] = ... + ) -> None: ... + +class GenerativeGoogleMetadata(_message.Message): + __slots__ = ("metadata", "usage_metadata") + + class TokenCount(_message.Message): + __slots__ = ("total_billable_characters", "total_tokens") + TOTAL_BILLABLE_CHARACTERS_FIELD_NUMBER: _ClassVar[int] + TOTAL_TOKENS_FIELD_NUMBER: _ClassVar[int] + total_billable_characters: int + total_tokens: int + def __init__( + self, + total_billable_characters: _Optional[int] = ..., + total_tokens: _Optional[int] = ..., + ) -> None: ... + + class TokenMetadata(_message.Message): + __slots__ = ("input_token_count", "output_token_count") + INPUT_TOKEN_COUNT_FIELD_NUMBER: _ClassVar[int] + OUTPUT_TOKEN_COUNT_FIELD_NUMBER: _ClassVar[int] + input_token_count: GenerativeGoogleMetadata.TokenCount + output_token_count: GenerativeGoogleMetadata.TokenCount + def __init__( + self, + input_token_count: _Optional[ + _Union[GenerativeGoogleMetadata.TokenCount, _Mapping] + ] = ..., + output_token_count: _Optional[ + _Union[GenerativeGoogleMetadata.TokenCount, _Mapping] + ] = ..., + ) -> None: ... + + class Metadata(_message.Message): + __slots__ = ("token_metadata",) + TOKEN_METADATA_FIELD_NUMBER: _ClassVar[int] + token_metadata: GenerativeGoogleMetadata.TokenMetadata + def __init__( + self, + token_metadata: _Optional[ + _Union[GenerativeGoogleMetadata.TokenMetadata, _Mapping] + ] = ..., + ) -> None: ... + + class UsageMetadata(_message.Message): + __slots__ = ("prompt_token_count", "candidates_token_count", "total_token_count") + PROMPT_TOKEN_COUNT_FIELD_NUMBER: _ClassVar[int] + CANDIDATES_TOKEN_COUNT_FIELD_NUMBER: _ClassVar[int] + TOTAL_TOKEN_COUNT_FIELD_NUMBER: _ClassVar[int] + prompt_token_count: int + candidates_token_count: int + total_token_count: int + def __init__( + self, + prompt_token_count: _Optional[int] = ..., + candidates_token_count: _Optional[int] = ..., + total_token_count: _Optional[int] = ..., + ) -> None: ... + + METADATA_FIELD_NUMBER: _ClassVar[int] + USAGE_METADATA_FIELD_NUMBER: _ClassVar[int] + metadata: GenerativeGoogleMetadata.Metadata + usage_metadata: GenerativeGoogleMetadata.UsageMetadata + def __init__( + self, + metadata: _Optional[_Union[GenerativeGoogleMetadata.Metadata, _Mapping]] = ..., + usage_metadata: _Optional[_Union[GenerativeGoogleMetadata.UsageMetadata, _Mapping]] = ..., + ) -> None: ... + +class GenerativeMetadata(_message.Message): + __slots__ = ( + "anthropic", + "anyscale", + "aws", + "cohere", + "dummy", + "mistral", + "octoai", + "ollama", + "openai", + "google", + ) + ANTHROPIC_FIELD_NUMBER: _ClassVar[int] + ANYSCALE_FIELD_NUMBER: _ClassVar[int] + AWS_FIELD_NUMBER: _ClassVar[int] + COHERE_FIELD_NUMBER: _ClassVar[int] + DUMMY_FIELD_NUMBER: _ClassVar[int] + MISTRAL_FIELD_NUMBER: _ClassVar[int] + OCTOAI_FIELD_NUMBER: _ClassVar[int] + OLLAMA_FIELD_NUMBER: _ClassVar[int] + OPENAI_FIELD_NUMBER: _ClassVar[int] + GOOGLE_FIELD_NUMBER: _ClassVar[int] + anthropic: GenerativeAnthropicMetadata + anyscale: GenerativeAnyscaleMetadata + aws: GenerativeAWSMetadata + cohere: GenerativeCohereMetadata + dummy: GenerativeDummyMetadata + mistral: GenerativeMistralMetadata + octoai: GenerativeOctoAIMetadata + ollama: GenerativeOllamaMetadata + openai: GenerativeOpenAIMetadata + google: GenerativeGoogleMetadata + def __init__( + self, + anthropic: _Optional[_Union[GenerativeAnthropicMetadata, _Mapping]] = ..., + anyscale: _Optional[_Union[GenerativeAnyscaleMetadata, _Mapping]] = ..., + aws: _Optional[_Union[GenerativeAWSMetadata, _Mapping]] = ..., + cohere: _Optional[_Union[GenerativeCohereMetadata, _Mapping]] = ..., + dummy: _Optional[_Union[GenerativeDummyMetadata, _Mapping]] = ..., + mistral: _Optional[_Union[GenerativeMistralMetadata, _Mapping]] = ..., + octoai: _Optional[_Union[GenerativeOctoAIMetadata, _Mapping]] = ..., + ollama: _Optional[_Union[GenerativeOllamaMetadata, _Mapping]] = ..., + openai: _Optional[_Union[GenerativeOpenAIMetadata, _Mapping]] = ..., + google: _Optional[_Union[GenerativeGoogleMetadata, _Mapping]] = ..., + ) -> None: ... + +class GenerativeReply(_message.Message): + __slots__ = ("result", "debug", "metadata") + RESULT_FIELD_NUMBER: _ClassVar[int] + DEBUG_FIELD_NUMBER: _ClassVar[int] + METADATA_FIELD_NUMBER: _ClassVar[int] + result: str + debug: GenerativeDebug + metadata: GenerativeMetadata + def __init__( + self, + result: _Optional[str] = ..., + debug: _Optional[_Union[GenerativeDebug, _Mapping]] = ..., + metadata: _Optional[_Union[GenerativeMetadata, _Mapping]] = ..., + ) -> None: ... + +class GenerativeResult(_message.Message): + __slots__ = ("values",) + VALUES_FIELD_NUMBER: _ClassVar[int] + values: _containers.RepeatedCompositeFieldContainer[GenerativeReply] + def __init__( + self, values: _Optional[_Iterable[_Union[GenerativeReply, _Mapping]]] = ... + ) -> None: ... + +class GenerativeDebug(_message.Message): + __slots__ = ("full_prompt",) + FULL_PROMPT_FIELD_NUMBER: _ClassVar[int] + full_prompt: str + def __init__(self, full_prompt: _Optional[str] = ...) -> None: ... diff --git a/weaviate/proto/v1/generative_pb2_grpc.py b/weaviate/proto/v1/generative_pb2_grpc.py new file mode 100644 index 000000000..8a9393943 --- /dev/null +++ b/weaviate/proto/v1/generative_pb2_grpc.py @@ -0,0 +1,3 @@ +# Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT! +"""Client and server classes corresponding to protobuf-defined services.""" +import grpc diff --git a/weaviate/proto/v1/search_get_pb2.py b/weaviate/proto/v1/search_get_pb2.py index dda96bdc4..d7098618e 100644 --- a/weaviate/proto/v1/search_get_pb2.py +++ b/weaviate/proto/v1/search_get_pb2.py @@ -15,11 +15,12 @@ from google.protobuf import struct_pb2 as google_dot_protobuf_dot_struct__pb2 from weaviate.proto.v1 import base_pb2 as v1_dot_base__pb2 +from weaviate.proto.v1 import generative_pb2 as v1_dot_generative__pb2 from weaviate.proto.v1 import properties_pb2 as v1_dot_properties__pb2 DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile( - b'\n\x13v1/search_get.proto\x12\x0bweaviate.v1\x1a\x1cgoogle/protobuf/struct.proto\x1a\rv1/base.proto\x1a\x13v1/properties.proto"\x82\x0b\n\rSearchRequest\x12\x12\n\ncollection\x18\x01 \x01(\t\x12\x0e\n\x06tenant\x18\n \x01(\t\x12=\n\x11\x63onsistency_level\x18\x0b \x01(\x0e\x32\x1d.weaviate.v1.ConsistencyLevelH\x00\x88\x01\x01\x12\x37\n\nproperties\x18\x14 \x01(\x0b\x32\x1e.weaviate.v1.PropertiesRequestH\x01\x88\x01\x01\x12\x33\n\x08metadata\x18\x15 \x01(\x0b\x32\x1c.weaviate.v1.MetadataRequestH\x02\x88\x01\x01\x12+\n\x08group_by\x18\x16 \x01(\x0b\x32\x14.weaviate.v1.GroupByH\x03\x88\x01\x01\x12\r\n\x05limit\x18\x1e \x01(\r\x12\x0e\n\x06offset\x18\x1f \x01(\r\x12\x0f\n\x07\x61utocut\x18 \x01(\r\x12\r\n\x05\x61\x66ter\x18! \x01(\t\x12$\n\x07sort_by\x18" \x03(\x0b\x32\x13.weaviate.v1.SortBy\x12*\n\x07\x66ilters\x18( \x01(\x0b\x32\x14.weaviate.v1.FiltersH\x04\x88\x01\x01\x12/\n\rhybrid_search\x18) \x01(\x0b\x32\x13.weaviate.v1.HybridH\x05\x88\x01\x01\x12+\n\x0b\x62m25_search\x18* \x01(\x0b\x32\x11.weaviate.v1.BM25H\x06\x88\x01\x01\x12\x31\n\x0bnear_vector\x18+ \x01(\x0b\x32\x17.weaviate.v1.NearVectorH\x07\x88\x01\x01\x12\x31\n\x0bnear_object\x18, \x01(\x0b\x32\x17.weaviate.v1.NearObjectH\x08\x88\x01\x01\x12\x33\n\tnear_text\x18- \x01(\x0b\x32\x1b.weaviate.v1.NearTextSearchH\t\x88\x01\x01\x12\x35\n\nnear_image\x18. \x01(\x0b\x32\x1c.weaviate.v1.NearImageSearchH\n\x88\x01\x01\x12\x35\n\nnear_audio\x18/ \x01(\x0b\x32\x1c.weaviate.v1.NearAudioSearchH\x0b\x88\x01\x01\x12\x35\n\nnear_video\x18\x30 \x01(\x0b\x32\x1c.weaviate.v1.NearVideoSearchH\x0c\x88\x01\x01\x12\x35\n\nnear_depth\x18\x31 \x01(\x0b\x32\x1c.weaviate.v1.NearDepthSearchH\r\x88\x01\x01\x12\x39\n\x0cnear_thermal\x18\x32 \x01(\x0b\x32\x1e.weaviate.v1.NearThermalSearchH\x0e\x88\x01\x01\x12\x31\n\x08near_imu\x18\x33 \x01(\x0b\x32\x1a.weaviate.v1.NearIMUSearchH\x0f\x88\x01\x01\x12\x36\n\ngenerative\x18< \x01(\x0b\x32\x1d.weaviate.v1.GenerativeSearchH\x10\x88\x01\x01\x12(\n\x06rerank\x18= \x01(\x0b\x32\x13.weaviate.v1.RerankH\x11\x88\x01\x01\x12\x18\n\x0cuses_123_api\x18\x64 \x01(\x08\x42\x02\x18\x01\x12\x14\n\x0cuses_125_api\x18\x65 \x01(\x08\x42\x14\n\x12_consistency_levelB\r\n\x0b_propertiesB\x0b\n\t_metadataB\x0b\n\t_group_byB\n\n\x08_filtersB\x10\n\x0e_hybrid_searchB\x0e\n\x0c_bm25_searchB\x0e\n\x0c_near_vectorB\x0e\n\x0c_near_objectB\x0c\n\n_near_textB\r\n\x0b_near_imageB\r\n\x0b_near_audioB\r\n\x0b_near_videoB\r\n\x0b_near_depthB\x0f\n\r_near_thermalB\x0b\n\t_near_imuB\r\n\x0b_generativeB\t\n\x07_rerank"L\n\x07GroupBy\x12\x0c\n\x04path\x18\x01 \x03(\t\x12\x18\n\x10number_of_groups\x18\x02 \x01(\x05\x12\x19\n\x11objects_per_group\x18\x03 \x01(\x05")\n\x06SortBy\x12\x11\n\tascending\x18\x01 \x01(\x08\x12\x0c\n\x04path\x18\x02 \x03(\t"m\n\x10GenerativeSearch\x12\x1e\n\x16single_response_prompt\x18\x01 \x01(\t\x12\x1d\n\x15grouped_response_task\x18\x02 \x01(\t\x12\x1a\n\x12grouped_properties\x18\x03 \x03(\t"\xdd\x01\n\x0fMetadataRequest\x12\x0c\n\x04uuid\x18\x01 \x01(\x08\x12\x0e\n\x06vector\x18\x02 \x01(\x08\x12\x1a\n\x12\x63reation_time_unix\x18\x03 \x01(\x08\x12\x1d\n\x15last_update_time_unix\x18\x04 \x01(\x08\x12\x10\n\x08\x64istance\x18\x05 \x01(\x08\x12\x11\n\tcertainty\x18\x06 \x01(\x08\x12\r\n\x05score\x18\x07 \x01(\x08\x12\x15\n\rexplain_score\x18\x08 \x01(\x08\x12\x15\n\ris_consistent\x18\t \x01(\x08\x12\x0f\n\x07vectors\x18\n \x03(\t"\xd1\x01\n\x11PropertiesRequest\x12\x1a\n\x12non_ref_properties\x18\x01 \x03(\t\x12\x39\n\x0eref_properties\x18\x02 \x03(\x0b\x32!.weaviate.v1.RefPropertiesRequest\x12?\n\x11object_properties\x18\x03 \x03(\x0b\x32$.weaviate.v1.ObjectPropertiesRequest\x12$\n\x1creturn_all_nonref_properties\x18\x0b \x01(\x08"\x8b\x01\n\x17ObjectPropertiesRequest\x12\x11\n\tprop_name\x18\x01 \x01(\t\x12\x1c\n\x14primitive_properties\x18\x02 \x03(\t\x12?\n\x11object_properties\x18\x03 \x03(\x0b\x32$.weaviate.v1.ObjectPropertiesRequest"2\n\x10WeightsForTarget\x12\x0e\n\x06target\x18\x01 \x01(\t\x12\x0e\n\x06weight\x18\x02 \x01(\x02"\xfa\x01\n\x07Targets\x12\x16\n\x0etarget_vectors\x18\x01 \x03(\t\x12\x33\n\x0b\x63ombination\x18\x02 \x01(\x0e\x32\x1e.weaviate.v1.CombinationMethod\x12\x36\n\x07weights\x18\x03 \x03(\x0b\x32!.weaviate.v1.Targets.WeightsEntryB\x02\x18\x01\x12:\n\x13weights_for_targets\x18\x04 \x03(\x0b\x32\x1d.weaviate.v1.WeightsForTarget\x1a.\n\x0cWeightsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x02:\x02\x38\x01"\xc5\x03\n\x06Hybrid\x12\r\n\x05query\x18\x01 \x01(\t\x12\x12\n\nproperties\x18\x02 \x03(\t\x12\x12\n\x06vector\x18\x03 \x03(\x02\x42\x02\x18\x01\x12\r\n\x05\x61lpha\x18\x04 \x01(\x02\x12\x33\n\x0b\x66usion_type\x18\x05 \x01(\x0e\x32\x1e.weaviate.v1.Hybrid.FusionType\x12\x14\n\x0cvector_bytes\x18\x06 \x01(\x0c\x12\x1a\n\x0etarget_vectors\x18\x07 \x03(\tB\x02\x18\x01\x12.\n\tnear_text\x18\x08 \x01(\x0b\x32\x1b.weaviate.v1.NearTextSearch\x12,\n\x0bnear_vector\x18\t \x01(\x0b\x32\x17.weaviate.v1.NearVector\x12%\n\x07targets\x18\n \x01(\x0b\x32\x14.weaviate.v1.Targets\x12\x19\n\x0fvector_distance\x18\x14 \x01(\x02H\x00"a\n\nFusionType\x12\x1b\n\x17\x46USION_TYPE_UNSPECIFIED\x10\x00\x12\x16\n\x12\x46USION_TYPE_RANKED\x10\x01\x12\x1e\n\x1a\x46USION_TYPE_RELATIVE_SCORE\x10\x02\x42\x0b\n\tthreshold"\xf0\x02\n\x0eNearTextSearch\x12\r\n\x05query\x18\x01 \x03(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x36\n\x07move_to\x18\x04 \x01(\x0b\x32 .weaviate.v1.NearTextSearch.MoveH\x02\x88\x01\x01\x12\x38\n\tmove_away\x18\x05 \x01(\x0b\x32 .weaviate.v1.NearTextSearch.MoveH\x03\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x06 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x07 \x01(\x0b\x32\x14.weaviate.v1.Targets\x1a\x36\n\x04Move\x12\r\n\x05\x66orce\x18\x01 \x01(\x02\x12\x10\n\x08\x63oncepts\x18\x02 \x03(\t\x12\r\n\x05uuids\x18\x03 \x03(\tB\x0c\n\n_certaintyB\x0b\n\t_distanceB\n\n\x08_move_toB\x0c\n\n_move_away"\xad\x01\n\x0fNearImageSearch\x12\r\n\x05image\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xad\x01\n\x0fNearAudioSearch\x12\r\n\x05\x61udio\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xad\x01\n\x0fNearVideoSearch\x12\r\n\x05video\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xad\x01\n\x0fNearDepthSearch\x12\r\n\x05\x64\x65pth\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xb1\x01\n\x11NearThermalSearch\x12\x0f\n\x07thermal\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xa9\x01\n\rNearIMUSearch\x12\x0b\n\x03imu\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance")\n\x04\x42M25\x12\r\n\x05query\x18\x01 \x01(\t\x12\x12\n\nproperties\x18\x02 \x03(\t"\xb1\x01\n\x14RefPropertiesRequest\x12\x1a\n\x12reference_property\x18\x01 \x01(\t\x12\x32\n\nproperties\x18\x02 \x01(\x0b\x32\x1e.weaviate.v1.PropertiesRequest\x12.\n\x08metadata\x18\x03 \x01(\x0b\x32\x1c.weaviate.v1.MetadataRequest\x12\x19\n\x11target_collection\x18\x04 \x01(\t"5\n\x0fVectorForTarget\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x14\n\x0cvector_bytes\x18\x02 \x01(\x0c"\x82\x03\n\nNearVector\x12\x12\n\x06vector\x18\x01 \x03(\x02\x42\x02\x18\x01\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x14\n\x0cvector_bytes\x18\x04 \x01(\x0c\x12\x1a\n\x0etarget_vectors\x18\x05 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x06 \x01(\x0b\x32\x14.weaviate.v1.Targets\x12K\n\x11vector_per_target\x18\x07 \x03(\x0b\x32,.weaviate.v1.NearVector.VectorPerTargetEntryB\x02\x18\x01\x12\x38\n\x12vector_for_targets\x18\x08 \x03(\x0b\x32\x1c.weaviate.v1.VectorForTarget\x1a\x36\n\x14VectorPerTargetEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x0c:\x02\x38\x01\x42\x0c\n\n_certaintyB\x0b\n\t_distance"\xa5\x01\n\nNearObject\x12\n\n\x02id\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"8\n\x06Rerank\x12\x10\n\x08property\x18\x01 \x01(\t\x12\x12\n\x05query\x18\x02 \x01(\tH\x00\x88\x01\x01\x42\x08\n\x06_query"\xc3\x01\n\x0bSearchReply\x12\x0c\n\x04took\x18\x01 \x01(\x02\x12*\n\x07results\x18\x02 \x03(\x0b\x32\x19.weaviate.v1.SearchResult\x12&\n\x19generative_grouped_result\x18\x03 \x01(\tH\x00\x88\x01\x01\x12\x34\n\x10group_by_results\x18\x04 \x03(\x0b\x32\x1a.weaviate.v1.GroupByResultB\x1c\n\x1a_generative_grouped_result"\x1c\n\x0bRerankReply\x12\r\n\x05score\x18\x01 \x01(\x01"!\n\x0fGenerativeReply\x12\x0e\n\x06result\x18\x01 \x01(\t"\x90\x02\n\rGroupByResult\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x14\n\x0cmin_distance\x18\x02 \x01(\x02\x12\x14\n\x0cmax_distance\x18\x03 \x01(\x02\x12\x19\n\x11number_of_objects\x18\x04 \x01(\x03\x12*\n\x07objects\x18\x05 \x03(\x0b\x32\x19.weaviate.v1.SearchResult\x12-\n\x06rerank\x18\x06 \x01(\x0b\x32\x18.weaviate.v1.RerankReplyH\x00\x88\x01\x01\x12\x35\n\ngenerative\x18\x07 \x01(\x0b\x32\x1c.weaviate.v1.GenerativeReplyH\x01\x88\x01\x01\x42\t\n\x07_rerankB\r\n\x0b_generative"p\n\x0cSearchResult\x12\x31\n\nproperties\x18\x01 \x01(\x0b\x32\x1d.weaviate.v1.PropertiesResult\x12-\n\x08metadata\x18\x02 \x01(\x0b\x32\x1b.weaviate.v1.MetadataResult"\xef\x04\n\x0eMetadataResult\x12\n\n\x02id\x18\x01 \x01(\t\x12\x12\n\x06vector\x18\x02 \x03(\x02\x42\x02\x18\x01\x12\x1a\n\x12\x63reation_time_unix\x18\x03 \x01(\x03\x12"\n\x1a\x63reation_time_unix_present\x18\x04 \x01(\x08\x12\x1d\n\x15last_update_time_unix\x18\x05 \x01(\x03\x12%\n\x1dlast_update_time_unix_present\x18\x06 \x01(\x08\x12\x10\n\x08\x64istance\x18\x07 \x01(\x02\x12\x18\n\x10\x64istance_present\x18\x08 \x01(\x08\x12\x11\n\tcertainty\x18\t \x01(\x02\x12\x19\n\x11\x63\x65rtainty_present\x18\n \x01(\x08\x12\r\n\x05score\x18\x0b \x01(\x02\x12\x15\n\rscore_present\x18\x0c \x01(\x08\x12\x15\n\rexplain_score\x18\r \x01(\t\x12\x1d\n\x15\x65xplain_score_present\x18\x0e \x01(\x08\x12\x1a\n\ris_consistent\x18\x0f \x01(\x08H\x00\x88\x01\x01\x12\x12\n\ngenerative\x18\x10 \x01(\t\x12\x1a\n\x12generative_present\x18\x11 \x01(\x08\x12\x1d\n\x15is_consistent_present\x18\x12 \x01(\x08\x12\x14\n\x0cvector_bytes\x18\x13 \x01(\x0c\x12\x13\n\x0bid_as_bytes\x18\x14 \x01(\x0c\x12\x14\n\x0crerank_score\x18\x15 \x01(\x01\x12\x1c\n\x14rerank_score_present\x18\x16 \x01(\x08\x12%\n\x07vectors\x18\x17 \x03(\x0b\x32\x14.weaviate.v1.VectorsB\x10\n\x0e_is_consistent"\xba\x05\n\x10PropertiesResult\x12\x37\n\x12non_ref_properties\x18\x01 \x01(\x0b\x32\x17.google.protobuf.StructB\x02\x18\x01\x12\x33\n\tref_props\x18\x02 \x03(\x0b\x32 .weaviate.v1.RefPropertiesResult\x12\x19\n\x11target_collection\x18\x03 \x01(\t\x12-\n\x08metadata\x18\x04 \x01(\x0b\x32\x1b.weaviate.v1.MetadataResult\x12G\n\x17number_array_properties\x18\x05 \x03(\x0b\x32".weaviate.v1.NumberArrayPropertiesB\x02\x18\x01\x12\x41\n\x14int_array_properties\x18\x06 \x03(\x0b\x32\x1f.weaviate.v1.IntArrayPropertiesB\x02\x18\x01\x12\x43\n\x15text_array_properties\x18\x07 \x03(\x0b\x32 .weaviate.v1.TextArrayPropertiesB\x02\x18\x01\x12I\n\x18\x62oolean_array_properties\x18\x08 \x03(\x0b\x32#.weaviate.v1.BooleanArrayPropertiesB\x02\x18\x01\x12<\n\x11object_properties\x18\t \x03(\x0b\x32\x1d.weaviate.v1.ObjectPropertiesB\x02\x18\x01\x12G\n\x17object_array_properties\x18\n \x03(\x0b\x32".weaviate.v1.ObjectArrayPropertiesB\x02\x18\x01\x12.\n\rnon_ref_props\x18\x0b \x01(\x0b\x32\x17.weaviate.v1.Properties\x12\x1b\n\x13ref_props_requested\x18\x0c \x01(\x08"[\n\x13RefPropertiesResult\x12\x31\n\nproperties\x18\x01 \x03(\x0b\x32\x1d.weaviate.v1.PropertiesResult\x12\x11\n\tprop_name\x18\x02 \x01(\t*\xee\x01\n\x11\x43ombinationMethod\x12"\n\x1e\x43OMBINATION_METHOD_UNSPECIFIED\x10\x00\x12\x1f\n\x1b\x43OMBINATION_METHOD_TYPE_SUM\x10\x01\x12\x1f\n\x1b\x43OMBINATION_METHOD_TYPE_MIN\x10\x02\x12#\n\x1f\x43OMBINATION_METHOD_TYPE_AVERAGE\x10\x03\x12*\n&COMBINATION_METHOD_TYPE_RELATIVE_SCORE\x10\x04\x12"\n\x1e\x43OMBINATION_METHOD_TYPE_MANUAL\x10\x05\x42s\n#io.weaviate.client.grpc.protocol.v1B\x16WeaviateProtoSearchGetZ4github.com/weaviate/weaviate/grpc/generated;protocolb\x06proto3' + b'\n\x13v1/search_get.proto\x12\x0bweaviate.v1\x1a\x1cgoogle/protobuf/struct.proto\x1a\rv1/base.proto\x1a\x13v1/generative.proto\x1a\x13v1/properties.proto"\x9c\x0b\n\rSearchRequest\x12\x12\n\ncollection\x18\x01 \x01(\t\x12\x0e\n\x06tenant\x18\n \x01(\t\x12=\n\x11\x63onsistency_level\x18\x0b \x01(\x0e\x32\x1d.weaviate.v1.ConsistencyLevelH\x00\x88\x01\x01\x12\x37\n\nproperties\x18\x14 \x01(\x0b\x32\x1e.weaviate.v1.PropertiesRequestH\x01\x88\x01\x01\x12\x33\n\x08metadata\x18\x15 \x01(\x0b\x32\x1c.weaviate.v1.MetadataRequestH\x02\x88\x01\x01\x12+\n\x08group_by\x18\x16 \x01(\x0b\x32\x14.weaviate.v1.GroupByH\x03\x88\x01\x01\x12\r\n\x05limit\x18\x1e \x01(\r\x12\x0e\n\x06offset\x18\x1f \x01(\r\x12\x0f\n\x07\x61utocut\x18 \x01(\r\x12\r\n\x05\x61\x66ter\x18! \x01(\t\x12$\n\x07sort_by\x18" \x03(\x0b\x32\x13.weaviate.v1.SortBy\x12*\n\x07\x66ilters\x18( \x01(\x0b\x32\x14.weaviate.v1.FiltersH\x04\x88\x01\x01\x12/\n\rhybrid_search\x18) \x01(\x0b\x32\x13.weaviate.v1.HybridH\x05\x88\x01\x01\x12+\n\x0b\x62m25_search\x18* \x01(\x0b\x32\x11.weaviate.v1.BM25H\x06\x88\x01\x01\x12\x31\n\x0bnear_vector\x18+ \x01(\x0b\x32\x17.weaviate.v1.NearVectorH\x07\x88\x01\x01\x12\x31\n\x0bnear_object\x18, \x01(\x0b\x32\x17.weaviate.v1.NearObjectH\x08\x88\x01\x01\x12\x33\n\tnear_text\x18- \x01(\x0b\x32\x1b.weaviate.v1.NearTextSearchH\t\x88\x01\x01\x12\x35\n\nnear_image\x18. \x01(\x0b\x32\x1c.weaviate.v1.NearImageSearchH\n\x88\x01\x01\x12\x35\n\nnear_audio\x18/ \x01(\x0b\x32\x1c.weaviate.v1.NearAudioSearchH\x0b\x88\x01\x01\x12\x35\n\nnear_video\x18\x30 \x01(\x0b\x32\x1c.weaviate.v1.NearVideoSearchH\x0c\x88\x01\x01\x12\x35\n\nnear_depth\x18\x31 \x01(\x0b\x32\x1c.weaviate.v1.NearDepthSearchH\r\x88\x01\x01\x12\x39\n\x0cnear_thermal\x18\x32 \x01(\x0b\x32\x1e.weaviate.v1.NearThermalSearchH\x0e\x88\x01\x01\x12\x31\n\x08near_imu\x18\x33 \x01(\x0b\x32\x1a.weaviate.v1.NearIMUSearchH\x0f\x88\x01\x01\x12\x36\n\ngenerative\x18< \x01(\x0b\x32\x1d.weaviate.v1.GenerativeSearchH\x10\x88\x01\x01\x12(\n\x06rerank\x18= \x01(\x0b\x32\x13.weaviate.v1.RerankH\x11\x88\x01\x01\x12\x18\n\x0cuses_123_api\x18\x64 \x01(\x08\x42\x02\x18\x01\x12\x18\n\x0cuses_125_api\x18\x65 \x01(\x08\x42\x02\x18\x01\x12\x14\n\x0cuses_127_api\x18\x66 \x01(\x08\x42\x14\n\x12_consistency_levelB\r\n\x0b_propertiesB\x0b\n\t_metadataB\x0b\n\t_group_byB\n\n\x08_filtersB\x10\n\x0e_hybrid_searchB\x0e\n\x0c_bm25_searchB\x0e\n\x0c_near_vectorB\x0e\n\x0c_near_objectB\x0c\n\n_near_textB\r\n\x0b_near_imageB\r\n\x0b_near_audioB\r\n\x0b_near_videoB\r\n\x0b_near_depthB\x0f\n\r_near_thermalB\x0b\n\t_near_imuB\r\n\x0b_generativeB\t\n\x07_rerank"L\n\x07GroupBy\x12\x0c\n\x04path\x18\x01 \x03(\t\x12\x18\n\x10number_of_groups\x18\x02 \x01(\x05\x12\x19\n\x11objects_per_group\x18\x03 \x01(\x05")\n\x06SortBy\x12\x11\n\tascending\x18\x01 \x01(\x08\x12\x0c\n\x04path\x18\x02 \x03(\t"\xdd\x01\n\x0fMetadataRequest\x12\x0c\n\x04uuid\x18\x01 \x01(\x08\x12\x0e\n\x06vector\x18\x02 \x01(\x08\x12\x1a\n\x12\x63reation_time_unix\x18\x03 \x01(\x08\x12\x1d\n\x15last_update_time_unix\x18\x04 \x01(\x08\x12\x10\n\x08\x64istance\x18\x05 \x01(\x08\x12\x11\n\tcertainty\x18\x06 \x01(\x08\x12\r\n\x05score\x18\x07 \x01(\x08\x12\x15\n\rexplain_score\x18\x08 \x01(\x08\x12\x15\n\ris_consistent\x18\t \x01(\x08\x12\x0f\n\x07vectors\x18\n \x03(\t"\xd1\x01\n\x11PropertiesRequest\x12\x1a\n\x12non_ref_properties\x18\x01 \x03(\t\x12\x39\n\x0eref_properties\x18\x02 \x03(\x0b\x32!.weaviate.v1.RefPropertiesRequest\x12?\n\x11object_properties\x18\x03 \x03(\x0b\x32$.weaviate.v1.ObjectPropertiesRequest\x12$\n\x1creturn_all_nonref_properties\x18\x0b \x01(\x08"\x8b\x01\n\x17ObjectPropertiesRequest\x12\x11\n\tprop_name\x18\x01 \x01(\t\x12\x1c\n\x14primitive_properties\x18\x02 \x03(\t\x12?\n\x11object_properties\x18\x03 \x03(\x0b\x32$.weaviate.v1.ObjectPropertiesRequest"2\n\x10WeightsForTarget\x12\x0e\n\x06target\x18\x01 \x01(\t\x12\x0e\n\x06weight\x18\x02 \x01(\x02"\xfa\x01\n\x07Targets\x12\x16\n\x0etarget_vectors\x18\x01 \x03(\t\x12\x33\n\x0b\x63ombination\x18\x02 \x01(\x0e\x32\x1e.weaviate.v1.CombinationMethod\x12\x36\n\x07weights\x18\x03 \x03(\x0b\x32!.weaviate.v1.Targets.WeightsEntryB\x02\x18\x01\x12:\n\x13weights_for_targets\x18\x04 \x03(\x0b\x32\x1d.weaviate.v1.WeightsForTarget\x1a.\n\x0cWeightsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x02:\x02\x38\x01"\xc5\x03\n\x06Hybrid\x12\r\n\x05query\x18\x01 \x01(\t\x12\x12\n\nproperties\x18\x02 \x03(\t\x12\x12\n\x06vector\x18\x03 \x03(\x02\x42\x02\x18\x01\x12\r\n\x05\x61lpha\x18\x04 \x01(\x02\x12\x33\n\x0b\x66usion_type\x18\x05 \x01(\x0e\x32\x1e.weaviate.v1.Hybrid.FusionType\x12\x14\n\x0cvector_bytes\x18\x06 \x01(\x0c\x12\x1a\n\x0etarget_vectors\x18\x07 \x03(\tB\x02\x18\x01\x12.\n\tnear_text\x18\x08 \x01(\x0b\x32\x1b.weaviate.v1.NearTextSearch\x12,\n\x0bnear_vector\x18\t \x01(\x0b\x32\x17.weaviate.v1.NearVector\x12%\n\x07targets\x18\n \x01(\x0b\x32\x14.weaviate.v1.Targets\x12\x19\n\x0fvector_distance\x18\x14 \x01(\x02H\x00"a\n\nFusionType\x12\x1b\n\x17\x46USION_TYPE_UNSPECIFIED\x10\x00\x12\x16\n\x12\x46USION_TYPE_RANKED\x10\x01\x12\x1e\n\x1a\x46USION_TYPE_RELATIVE_SCORE\x10\x02\x42\x0b\n\tthreshold"\xf0\x02\n\x0eNearTextSearch\x12\r\n\x05query\x18\x01 \x03(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x36\n\x07move_to\x18\x04 \x01(\x0b\x32 .weaviate.v1.NearTextSearch.MoveH\x02\x88\x01\x01\x12\x38\n\tmove_away\x18\x05 \x01(\x0b\x32 .weaviate.v1.NearTextSearch.MoveH\x03\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x06 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x07 \x01(\x0b\x32\x14.weaviate.v1.Targets\x1a\x36\n\x04Move\x12\r\n\x05\x66orce\x18\x01 \x01(\x02\x12\x10\n\x08\x63oncepts\x18\x02 \x03(\t\x12\r\n\x05uuids\x18\x03 \x03(\tB\x0c\n\n_certaintyB\x0b\n\t_distanceB\n\n\x08_move_toB\x0c\n\n_move_away"\xad\x01\n\x0fNearImageSearch\x12\r\n\x05image\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xad\x01\n\x0fNearAudioSearch\x12\r\n\x05\x61udio\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xad\x01\n\x0fNearVideoSearch\x12\r\n\x05video\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xad\x01\n\x0fNearDepthSearch\x12\r\n\x05\x64\x65pth\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xb1\x01\n\x11NearThermalSearch\x12\x0f\n\x07thermal\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xa9\x01\n\rNearIMUSearch\x12\x0b\n\x03imu\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance")\n\x04\x42M25\x12\r\n\x05query\x18\x01 \x01(\t\x12\x12\n\nproperties\x18\x02 \x03(\t"\xb1\x01\n\x14RefPropertiesRequest\x12\x1a\n\x12reference_property\x18\x01 \x01(\t\x12\x32\n\nproperties\x18\x02 \x01(\x0b\x32\x1e.weaviate.v1.PropertiesRequest\x12.\n\x08metadata\x18\x03 \x01(\x0b\x32\x1c.weaviate.v1.MetadataRequest\x12\x19\n\x11target_collection\x18\x04 \x01(\t"5\n\x0fVectorForTarget\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x14\n\x0cvector_bytes\x18\x02 \x01(\x0c"\x82\x03\n\nNearVector\x12\x12\n\x06vector\x18\x01 \x03(\x02\x42\x02\x18\x01\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x14\n\x0cvector_bytes\x18\x04 \x01(\x0c\x12\x1a\n\x0etarget_vectors\x18\x05 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x06 \x01(\x0b\x32\x14.weaviate.v1.Targets\x12K\n\x11vector_per_target\x18\x07 \x03(\x0b\x32,.weaviate.v1.NearVector.VectorPerTargetEntryB\x02\x18\x01\x12\x38\n\x12vector_for_targets\x18\x08 \x03(\x0b\x32\x1c.weaviate.v1.VectorForTarget\x1a\x36\n\x14VectorPerTargetEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x0c:\x02\x38\x01\x42\x0c\n\n_certaintyB\x0b\n\t_distance"\xa5\x01\n\nNearObject\x12\n\n\x02id\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"8\n\x06Rerank\x12\x10\n\x08property\x18\x01 \x01(\t\x12\x12\n\x05query\x18\x02 \x01(\tH\x00\x88\x01\x01\x42\x08\n\x06_query"\xae\x02\n\x0bSearchReply\x12\x0c\n\x04took\x18\x01 \x01(\x02\x12*\n\x07results\x18\x02 \x03(\x0b\x32\x19.weaviate.v1.SearchResult\x12*\n\x19generative_grouped_result\x18\x03 \x01(\tB\x02\x18\x01H\x00\x88\x01\x01\x12\x34\n\x10group_by_results\x18\x04 \x03(\x0b\x32\x1a.weaviate.v1.GroupByResult\x12\x46\n\x1agenerative_grouped_results\x18\x05 \x01(\x0b\x32\x1d.weaviate.v1.GenerativeResultH\x01\x88\x01\x01\x42\x1c\n\x1a_generative_grouped_resultB\x1d\n\x1b_generative_grouped_results"\x1c\n\x0bRerankReply\x12\r\n\x05score\x18\x01 \x01(\x01"\xe9\x02\n\rGroupByResult\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x14\n\x0cmin_distance\x18\x02 \x01(\x02\x12\x14\n\x0cmax_distance\x18\x03 \x01(\x02\x12\x19\n\x11number_of_objects\x18\x04 \x01(\x03\x12*\n\x07objects\x18\x05 \x03(\x0b\x32\x19.weaviate.v1.SearchResult\x12-\n\x06rerank\x18\x06 \x01(\x0b\x32\x18.weaviate.v1.RerankReplyH\x00\x88\x01\x01\x12\x39\n\ngenerative\x18\x07 \x01(\x0b\x32\x1c.weaviate.v1.GenerativeReplyB\x02\x18\x01H\x01\x88\x01\x01\x12=\n\x11generative_result\x18\x08 \x01(\x0b\x32\x1d.weaviate.v1.GenerativeResultH\x02\x88\x01\x01\x42\t\n\x07_rerankB\r\n\x0b_generativeB\x14\n\x12_generative_result"\xb7\x01\n\x0cSearchResult\x12\x31\n\nproperties\x18\x01 \x01(\x0b\x32\x1d.weaviate.v1.PropertiesResult\x12-\n\x08metadata\x18\x02 \x01(\x0b\x32\x1b.weaviate.v1.MetadataResult\x12\x36\n\ngenerative\x18\x03 \x01(\x0b\x32\x1d.weaviate.v1.GenerativeResultH\x00\x88\x01\x01\x42\r\n\x0b_generative"\xf7\x04\n\x0eMetadataResult\x12\n\n\x02id\x18\x01 \x01(\t\x12\x12\n\x06vector\x18\x02 \x03(\x02\x42\x02\x18\x01\x12\x1a\n\x12\x63reation_time_unix\x18\x03 \x01(\x03\x12"\n\x1a\x63reation_time_unix_present\x18\x04 \x01(\x08\x12\x1d\n\x15last_update_time_unix\x18\x05 \x01(\x03\x12%\n\x1dlast_update_time_unix_present\x18\x06 \x01(\x08\x12\x10\n\x08\x64istance\x18\x07 \x01(\x02\x12\x18\n\x10\x64istance_present\x18\x08 \x01(\x08\x12\x11\n\tcertainty\x18\t \x01(\x02\x12\x19\n\x11\x63\x65rtainty_present\x18\n \x01(\x08\x12\r\n\x05score\x18\x0b \x01(\x02\x12\x15\n\rscore_present\x18\x0c \x01(\x08\x12\x15\n\rexplain_score\x18\r \x01(\t\x12\x1d\n\x15\x65xplain_score_present\x18\x0e \x01(\x08\x12\x1a\n\ris_consistent\x18\x0f \x01(\x08H\x00\x88\x01\x01\x12\x16\n\ngenerative\x18\x10 \x01(\tB\x02\x18\x01\x12\x1e\n\x12generative_present\x18\x11 \x01(\x08\x42\x02\x18\x01\x12\x1d\n\x15is_consistent_present\x18\x12 \x01(\x08\x12\x14\n\x0cvector_bytes\x18\x13 \x01(\x0c\x12\x13\n\x0bid_as_bytes\x18\x14 \x01(\x0c\x12\x14\n\x0crerank_score\x18\x15 \x01(\x01\x12\x1c\n\x14rerank_score_present\x18\x16 \x01(\x08\x12%\n\x07vectors\x18\x17 \x03(\x0b\x32\x14.weaviate.v1.VectorsB\x10\n\x0e_is_consistent"\xba\x05\n\x10PropertiesResult\x12\x37\n\x12non_ref_properties\x18\x01 \x01(\x0b\x32\x17.google.protobuf.StructB\x02\x18\x01\x12\x33\n\tref_props\x18\x02 \x03(\x0b\x32 .weaviate.v1.RefPropertiesResult\x12\x19\n\x11target_collection\x18\x03 \x01(\t\x12-\n\x08metadata\x18\x04 \x01(\x0b\x32\x1b.weaviate.v1.MetadataResult\x12G\n\x17number_array_properties\x18\x05 \x03(\x0b\x32".weaviate.v1.NumberArrayPropertiesB\x02\x18\x01\x12\x41\n\x14int_array_properties\x18\x06 \x03(\x0b\x32\x1f.weaviate.v1.IntArrayPropertiesB\x02\x18\x01\x12\x43\n\x15text_array_properties\x18\x07 \x03(\x0b\x32 .weaviate.v1.TextArrayPropertiesB\x02\x18\x01\x12I\n\x18\x62oolean_array_properties\x18\x08 \x03(\x0b\x32#.weaviate.v1.BooleanArrayPropertiesB\x02\x18\x01\x12<\n\x11object_properties\x18\t \x03(\x0b\x32\x1d.weaviate.v1.ObjectPropertiesB\x02\x18\x01\x12G\n\x17object_array_properties\x18\n \x03(\x0b\x32".weaviate.v1.ObjectArrayPropertiesB\x02\x18\x01\x12.\n\rnon_ref_props\x18\x0b \x01(\x0b\x32\x17.weaviate.v1.Properties\x12\x1b\n\x13ref_props_requested\x18\x0c \x01(\x08"[\n\x13RefPropertiesResult\x12\x31\n\nproperties\x18\x01 \x03(\x0b\x32\x1d.weaviate.v1.PropertiesResult\x12\x11\n\tprop_name\x18\x02 \x01(\t*\xee\x01\n\x11\x43ombinationMethod\x12"\n\x1e\x43OMBINATION_METHOD_UNSPECIFIED\x10\x00\x12\x1f\n\x1b\x43OMBINATION_METHOD_TYPE_SUM\x10\x01\x12\x1f\n\x1b\x43OMBINATION_METHOD_TYPE_MIN\x10\x02\x12#\n\x1f\x43OMBINATION_METHOD_TYPE_AVERAGE\x10\x03\x12*\n&COMBINATION_METHOD_TYPE_RELATIVE_SCORE\x10\x04\x12"\n\x1e\x43OMBINATION_METHOD_TYPE_MANUAL\x10\x05\x42s\n#io.weaviate.client.grpc.protocol.v1B\x16WeaviateProtoSearchGetZ4github.com/weaviate/weaviate/grpc/generated;protocolb\x06proto3' ) _globals = globals() @@ -32,6 +33,8 @@ ) _globals["_SEARCHREQUEST"].fields_by_name["uses_123_api"]._options = None _globals["_SEARCHREQUEST"].fields_by_name["uses_123_api"]._serialized_options = b"\030\001" + _globals["_SEARCHREQUEST"].fields_by_name["uses_125_api"]._options = None + _globals["_SEARCHREQUEST"].fields_by_name["uses_125_api"]._serialized_options = b"\030\001" _globals["_TARGETS_WEIGHTSENTRY"]._options = None _globals["_TARGETS_WEIGHTSENTRY"]._serialized_options = b"8\001" _globals["_TARGETS"].fields_by_name["weights"]._options = None @@ -66,8 +69,20 @@ _globals["_NEARVECTOR"].fields_by_name["vector_per_target"]._serialized_options = b"\030\001" _globals["_NEAROBJECT"].fields_by_name["target_vectors"]._options = None _globals["_NEAROBJECT"].fields_by_name["target_vectors"]._serialized_options = b"\030\001" + _globals["_SEARCHREPLY"].fields_by_name["generative_grouped_result"]._options = None + _globals["_SEARCHREPLY"].fields_by_name[ + "generative_grouped_result" + ]._serialized_options = b"\030\001" + _globals["_GROUPBYRESULT"].fields_by_name["generative"]._options = None + _globals["_GROUPBYRESULT"].fields_by_name["generative"]._serialized_options = b"\030\001" _globals["_METADATARESULT"].fields_by_name["vector"]._options = None _globals["_METADATARESULT"].fields_by_name["vector"]._serialized_options = b"\030\001" + _globals["_METADATARESULT"].fields_by_name["generative"]._options = None + _globals["_METADATARESULT"].fields_by_name["generative"]._serialized_options = b"\030\001" + _globals["_METADATARESULT"].fields_by_name["generative_present"]._options = None + _globals["_METADATARESULT"].fields_by_name[ + "generative_present" + ]._serialized_options = b"\030\001" _globals["_PROPERTIESRESULT"].fields_by_name["non_ref_properties"]._options = None _globals["_PROPERTIESRESULT"].fields_by_name[ "non_ref_properties" @@ -96,76 +111,72 @@ _globals["_PROPERTIESRESULT"].fields_by_name[ "object_array_properties" ]._serialized_options = b"\030\001" - _globals["_COMBINATIONMETHOD"]._serialized_start = 7479 - _globals["_COMBINATIONMETHOD"]._serialized_end = 7717 - _globals["_SEARCHREQUEST"]._serialized_start = 103 - _globals["_SEARCHREQUEST"]._serialized_end = 1513 - _globals["_GROUPBY"]._serialized_start = 1515 - _globals["_GROUPBY"]._serialized_end = 1591 - _globals["_SORTBY"]._serialized_start = 1593 - _globals["_SORTBY"]._serialized_end = 1634 - _globals["_GENERATIVESEARCH"]._serialized_start = 1636 - _globals["_GENERATIVESEARCH"]._serialized_end = 1745 - _globals["_METADATAREQUEST"]._serialized_start = 1748 - _globals["_METADATAREQUEST"]._serialized_end = 1969 - _globals["_PROPERTIESREQUEST"]._serialized_start = 1972 - _globals["_PROPERTIESREQUEST"]._serialized_end = 2181 - _globals["_OBJECTPROPERTIESREQUEST"]._serialized_start = 2184 - _globals["_OBJECTPROPERTIESREQUEST"]._serialized_end = 2323 - _globals["_WEIGHTSFORTARGET"]._serialized_start = 2325 - _globals["_WEIGHTSFORTARGET"]._serialized_end = 2375 - _globals["_TARGETS"]._serialized_start = 2378 - _globals["_TARGETS"]._serialized_end = 2628 - _globals["_TARGETS_WEIGHTSENTRY"]._serialized_start = 2582 - _globals["_TARGETS_WEIGHTSENTRY"]._serialized_end = 2628 - _globals["_HYBRID"]._serialized_start = 2631 - _globals["_HYBRID"]._serialized_end = 3084 - _globals["_HYBRID_FUSIONTYPE"]._serialized_start = 2974 - _globals["_HYBRID_FUSIONTYPE"]._serialized_end = 3071 - _globals["_NEARTEXTSEARCH"]._serialized_start = 3087 - _globals["_NEARTEXTSEARCH"]._serialized_end = 3455 - _globals["_NEARTEXTSEARCH_MOVE"]._serialized_start = 3348 - _globals["_NEARTEXTSEARCH_MOVE"]._serialized_end = 3402 - _globals["_NEARIMAGESEARCH"]._serialized_start = 3458 - _globals["_NEARIMAGESEARCH"]._serialized_end = 3631 - _globals["_NEARAUDIOSEARCH"]._serialized_start = 3634 - _globals["_NEARAUDIOSEARCH"]._serialized_end = 3807 - _globals["_NEARVIDEOSEARCH"]._serialized_start = 3810 - _globals["_NEARVIDEOSEARCH"]._serialized_end = 3983 - _globals["_NEARDEPTHSEARCH"]._serialized_start = 3986 - _globals["_NEARDEPTHSEARCH"]._serialized_end = 4159 - _globals["_NEARTHERMALSEARCH"]._serialized_start = 4162 - _globals["_NEARTHERMALSEARCH"]._serialized_end = 4339 - _globals["_NEARIMUSEARCH"]._serialized_start = 4342 - _globals["_NEARIMUSEARCH"]._serialized_end = 4511 - _globals["_BM25"]._serialized_start = 4513 - _globals["_BM25"]._serialized_end = 4554 - _globals["_REFPROPERTIESREQUEST"]._serialized_start = 4557 - _globals["_REFPROPERTIESREQUEST"]._serialized_end = 4734 - _globals["_VECTORFORTARGET"]._serialized_start = 4736 - _globals["_VECTORFORTARGET"]._serialized_end = 4789 - _globals["_NEARVECTOR"]._serialized_start = 4792 - _globals["_NEARVECTOR"]._serialized_end = 5178 - _globals["_NEARVECTOR_VECTORPERTARGETENTRY"]._serialized_start = 5097 - _globals["_NEARVECTOR_VECTORPERTARGETENTRY"]._serialized_end = 5151 - _globals["_NEAROBJECT"]._serialized_start = 5181 - _globals["_NEAROBJECT"]._serialized_end = 5346 - _globals["_RERANK"]._serialized_start = 5348 - _globals["_RERANK"]._serialized_end = 5404 - _globals["_SEARCHREPLY"]._serialized_start = 5407 - _globals["_SEARCHREPLY"]._serialized_end = 5602 - _globals["_RERANKREPLY"]._serialized_start = 5604 - _globals["_RERANKREPLY"]._serialized_end = 5632 - _globals["_GENERATIVEREPLY"]._serialized_start = 5634 - _globals["_GENERATIVEREPLY"]._serialized_end = 5667 - _globals["_GROUPBYRESULT"]._serialized_start = 5670 - _globals["_GROUPBYRESULT"]._serialized_end = 5942 - _globals["_SEARCHRESULT"]._serialized_start = 5944 - _globals["_SEARCHRESULT"]._serialized_end = 6056 - _globals["_METADATARESULT"]._serialized_start = 6059 - _globals["_METADATARESULT"]._serialized_end = 6682 - _globals["_PROPERTIESRESULT"]._serialized_start = 6685 - _globals["_PROPERTIESRESULT"]._serialized_end = 7383 - _globals["_REFPROPERTIESRESULT"]._serialized_start = 7385 - _globals["_REFPROPERTIESRESULT"]._serialized_end = 7476 + _globals["_COMBINATIONMETHOD"]._serialized_start = 7656 + _globals["_COMBINATIONMETHOD"]._serialized_end = 7894 + _globals["_SEARCHREQUEST"]._serialized_start = 124 + _globals["_SEARCHREQUEST"]._serialized_end = 1560 + _globals["_GROUPBY"]._serialized_start = 1562 + _globals["_GROUPBY"]._serialized_end = 1638 + _globals["_SORTBY"]._serialized_start = 1640 + _globals["_SORTBY"]._serialized_end = 1681 + _globals["_METADATAREQUEST"]._serialized_start = 1684 + _globals["_METADATAREQUEST"]._serialized_end = 1905 + _globals["_PROPERTIESREQUEST"]._serialized_start = 1908 + _globals["_PROPERTIESREQUEST"]._serialized_end = 2117 + _globals["_OBJECTPROPERTIESREQUEST"]._serialized_start = 2120 + _globals["_OBJECTPROPERTIESREQUEST"]._serialized_end = 2259 + _globals["_WEIGHTSFORTARGET"]._serialized_start = 2261 + _globals["_WEIGHTSFORTARGET"]._serialized_end = 2311 + _globals["_TARGETS"]._serialized_start = 2314 + _globals["_TARGETS"]._serialized_end = 2564 + _globals["_TARGETS_WEIGHTSENTRY"]._serialized_start = 2518 + _globals["_TARGETS_WEIGHTSENTRY"]._serialized_end = 2564 + _globals["_HYBRID"]._serialized_start = 2567 + _globals["_HYBRID"]._serialized_end = 3020 + _globals["_HYBRID_FUSIONTYPE"]._serialized_start = 2910 + _globals["_HYBRID_FUSIONTYPE"]._serialized_end = 3007 + _globals["_NEARTEXTSEARCH"]._serialized_start = 3023 + _globals["_NEARTEXTSEARCH"]._serialized_end = 3391 + _globals["_NEARTEXTSEARCH_MOVE"]._serialized_start = 3284 + _globals["_NEARTEXTSEARCH_MOVE"]._serialized_end = 3338 + _globals["_NEARIMAGESEARCH"]._serialized_start = 3394 + _globals["_NEARIMAGESEARCH"]._serialized_end = 3567 + _globals["_NEARAUDIOSEARCH"]._serialized_start = 3570 + _globals["_NEARAUDIOSEARCH"]._serialized_end = 3743 + _globals["_NEARVIDEOSEARCH"]._serialized_start = 3746 + _globals["_NEARVIDEOSEARCH"]._serialized_end = 3919 + _globals["_NEARDEPTHSEARCH"]._serialized_start = 3922 + _globals["_NEARDEPTHSEARCH"]._serialized_end = 4095 + _globals["_NEARTHERMALSEARCH"]._serialized_start = 4098 + _globals["_NEARTHERMALSEARCH"]._serialized_end = 4275 + _globals["_NEARIMUSEARCH"]._serialized_start = 4278 + _globals["_NEARIMUSEARCH"]._serialized_end = 4447 + _globals["_BM25"]._serialized_start = 4449 + _globals["_BM25"]._serialized_end = 4490 + _globals["_REFPROPERTIESREQUEST"]._serialized_start = 4493 + _globals["_REFPROPERTIESREQUEST"]._serialized_end = 4670 + _globals["_VECTORFORTARGET"]._serialized_start = 4672 + _globals["_VECTORFORTARGET"]._serialized_end = 4725 + _globals["_NEARVECTOR"]._serialized_start = 4728 + _globals["_NEARVECTOR"]._serialized_end = 5114 + _globals["_NEARVECTOR_VECTORPERTARGETENTRY"]._serialized_start = 5033 + _globals["_NEARVECTOR_VECTORPERTARGETENTRY"]._serialized_end = 5087 + _globals["_NEAROBJECT"]._serialized_start = 5117 + _globals["_NEAROBJECT"]._serialized_end = 5282 + _globals["_RERANK"]._serialized_start = 5284 + _globals["_RERANK"]._serialized_end = 5340 + _globals["_SEARCHREPLY"]._serialized_start = 5343 + _globals["_SEARCHREPLY"]._serialized_end = 5645 + _globals["_RERANKREPLY"]._serialized_start = 5647 + _globals["_RERANKREPLY"]._serialized_end = 5675 + _globals["_GROUPBYRESULT"]._serialized_start = 5678 + _globals["_GROUPBYRESULT"]._serialized_end = 6039 + _globals["_SEARCHRESULT"]._serialized_start = 6042 + _globals["_SEARCHRESULT"]._serialized_end = 6225 + _globals["_METADATARESULT"]._serialized_start = 6228 + _globals["_METADATARESULT"]._serialized_end = 6859 + _globals["_PROPERTIESRESULT"]._serialized_start = 6862 + _globals["_PROPERTIESRESULT"]._serialized_end = 7560 + _globals["_REFPROPERTIESRESULT"]._serialized_start = 7562 + _globals["_REFPROPERTIESRESULT"]._serialized_end = 7653 # @@protoc_insertion_point(module_scope) diff --git a/weaviate/proto/v1/search_get_pb2.pyi b/weaviate/proto/v1/search_get_pb2.pyi index 9bbe9d40d..eaaa6f20b 100644 --- a/weaviate/proto/v1/search_get_pb2.pyi +++ b/weaviate/proto/v1/search_get_pb2.pyi @@ -1,5 +1,6 @@ from google.protobuf import struct_pb2 as _struct_pb2 from weaviate.proto.v1 import base_pb2 as _base_pb2 +from weaviate.proto.v1 import generative_pb2 as _generative_pb2 from weaviate.proto.v1 import properties_pb2 as _properties_pb2 from google.protobuf.internal import containers as _containers from google.protobuf.internal import enum_type_wrapper as _enum_type_wrapper @@ -60,6 +61,7 @@ class SearchRequest(_message.Message): "rerank", "uses_123_api", "uses_125_api", + "uses_127_api", ) COLLECTION_FIELD_NUMBER: _ClassVar[int] TENANT_FIELD_NUMBER: _ClassVar[int] @@ -88,6 +90,7 @@ class SearchRequest(_message.Message): RERANK_FIELD_NUMBER: _ClassVar[int] USES_123_API_FIELD_NUMBER: _ClassVar[int] USES_125_API_FIELD_NUMBER: _ClassVar[int] + USES_127_API_FIELD_NUMBER: _ClassVar[int] collection: str tenant: str consistency_level: _base_pb2.ConsistencyLevel @@ -111,10 +114,11 @@ class SearchRequest(_message.Message): near_depth: NearDepthSearch near_thermal: NearThermalSearch near_imu: NearIMUSearch - generative: GenerativeSearch + generative: _generative_pb2.GenerativeSearch rerank: Rerank uses_123_api: bool uses_125_api: bool + uses_127_api: bool def __init__( self, collection: _Optional[str] = ..., @@ -140,10 +144,11 @@ class SearchRequest(_message.Message): near_depth: _Optional[_Union[NearDepthSearch, _Mapping]] = ..., near_thermal: _Optional[_Union[NearThermalSearch, _Mapping]] = ..., near_imu: _Optional[_Union[NearIMUSearch, _Mapping]] = ..., - generative: _Optional[_Union[GenerativeSearch, _Mapping]] = ..., + generative: _Optional[_Union[_generative_pb2.GenerativeSearch, _Mapping]] = ..., rerank: _Optional[_Union[Rerank, _Mapping]] = ..., uses_123_api: bool = ..., uses_125_api: bool = ..., + uses_127_api: bool = ..., ) -> None: ... class GroupBy(_message.Message): @@ -169,21 +174,6 @@ class SortBy(_message.Message): path: _containers.RepeatedScalarFieldContainer[str] def __init__(self, ascending: bool = ..., path: _Optional[_Iterable[str]] = ...) -> None: ... -class GenerativeSearch(_message.Message): - __slots__ = ("single_response_prompt", "grouped_response_task", "grouped_properties") - SINGLE_RESPONSE_PROMPT_FIELD_NUMBER: _ClassVar[int] - GROUPED_RESPONSE_TASK_FIELD_NUMBER: _ClassVar[int] - GROUPED_PROPERTIES_FIELD_NUMBER: _ClassVar[int] - single_response_prompt: str - grouped_response_task: str - grouped_properties: _containers.RepeatedScalarFieldContainer[str] - def __init__( - self, - single_response_prompt: _Optional[str] = ..., - grouped_response_task: _Optional[str] = ..., - grouped_properties: _Optional[_Iterable[str]] = ..., - ) -> None: ... - class MetadataRequest(_message.Message): __slots__ = ( "uuid", @@ -658,21 +648,32 @@ class Rerank(_message.Message): def __init__(self, property: _Optional[str] = ..., query: _Optional[str] = ...) -> None: ... class SearchReply(_message.Message): - __slots__ = ("took", "results", "generative_grouped_result", "group_by_results") + __slots__ = ( + "took", + "results", + "generative_grouped_result", + "group_by_results", + "generative_grouped_results", + ) TOOK_FIELD_NUMBER: _ClassVar[int] RESULTS_FIELD_NUMBER: _ClassVar[int] GENERATIVE_GROUPED_RESULT_FIELD_NUMBER: _ClassVar[int] GROUP_BY_RESULTS_FIELD_NUMBER: _ClassVar[int] + GENERATIVE_GROUPED_RESULTS_FIELD_NUMBER: _ClassVar[int] took: float results: _containers.RepeatedCompositeFieldContainer[SearchResult] generative_grouped_result: str group_by_results: _containers.RepeatedCompositeFieldContainer[GroupByResult] + generative_grouped_results: _generative_pb2.GenerativeResult def __init__( self, took: _Optional[float] = ..., results: _Optional[_Iterable[_Union[SearchResult, _Mapping]]] = ..., generative_grouped_result: _Optional[str] = ..., group_by_results: _Optional[_Iterable[_Union[GroupByResult, _Mapping]]] = ..., + generative_grouped_results: _Optional[ + _Union[_generative_pb2.GenerativeResult, _Mapping] + ] = ..., ) -> None: ... class RerankReply(_message.Message): @@ -681,12 +682,6 @@ class RerankReply(_message.Message): score: float def __init__(self, score: _Optional[float] = ...) -> None: ... -class GenerativeReply(_message.Message): - __slots__ = ("result",) - RESULT_FIELD_NUMBER: _ClassVar[int] - result: str - def __init__(self, result: _Optional[str] = ...) -> None: ... - class GroupByResult(_message.Message): __slots__ = ( "name", @@ -696,6 +691,7 @@ class GroupByResult(_message.Message): "objects", "rerank", "generative", + "generative_result", ) NAME_FIELD_NUMBER: _ClassVar[int] MIN_DISTANCE_FIELD_NUMBER: _ClassVar[int] @@ -704,13 +700,15 @@ class GroupByResult(_message.Message): OBJECTS_FIELD_NUMBER: _ClassVar[int] RERANK_FIELD_NUMBER: _ClassVar[int] GENERATIVE_FIELD_NUMBER: _ClassVar[int] + GENERATIVE_RESULT_FIELD_NUMBER: _ClassVar[int] name: str min_distance: float max_distance: float number_of_objects: int objects: _containers.RepeatedCompositeFieldContainer[SearchResult] rerank: RerankReply - generative: GenerativeReply + generative: _generative_pb2.GenerativeReply + generative_result: _generative_pb2.GenerativeResult def __init__( self, name: _Optional[str] = ..., @@ -719,19 +717,23 @@ class GroupByResult(_message.Message): number_of_objects: _Optional[int] = ..., objects: _Optional[_Iterable[_Union[SearchResult, _Mapping]]] = ..., rerank: _Optional[_Union[RerankReply, _Mapping]] = ..., - generative: _Optional[_Union[GenerativeReply, _Mapping]] = ..., + generative: _Optional[_Union[_generative_pb2.GenerativeReply, _Mapping]] = ..., + generative_result: _Optional[_Union[_generative_pb2.GenerativeResult, _Mapping]] = ..., ) -> None: ... class SearchResult(_message.Message): - __slots__ = ("properties", "metadata") + __slots__ = ("properties", "metadata", "generative") PROPERTIES_FIELD_NUMBER: _ClassVar[int] METADATA_FIELD_NUMBER: _ClassVar[int] + GENERATIVE_FIELD_NUMBER: _ClassVar[int] properties: PropertiesResult metadata: MetadataResult + generative: _generative_pb2.GenerativeResult def __init__( self, properties: _Optional[_Union[PropertiesResult, _Mapping]] = ..., metadata: _Optional[_Union[MetadataResult, _Mapping]] = ..., + generative: _Optional[_Union[_generative_pb2.GenerativeResult, _Mapping]] = ..., ) -> None: ... class MetadataResult(_message.Message): From 055a93c48e733acfacd8359a806d5d804f180041 Mon Sep 17 00:00:00 2001 From: Dirk Kulawiak Date: Tue, 22 Oct 2024 09:34:46 +0200 Subject: [PATCH 2/4] Add support for special errors for 3rd party providers --- weaviate/collections/grpc/query.py | 12 ++- weaviate/exceptions.py | 26 ++++- weaviate/proto/v1/search_get_pb2.py | 138 ++++++++++++++------------- weaviate/proto/v1/search_get_pb2.pyi | 23 +++++ 4 files changed, 127 insertions(+), 72 deletions(-) diff --git a/weaviate/collections/grpc/query.py b/weaviate/collections/grpc/query.py index a2949e632..9b5eebdb3 100644 --- a/weaviate/collections/grpc/query.py +++ b/weaviate/collections/grpc/query.py @@ -53,6 +53,7 @@ WeaviateQueryError, WeaviateUnsupportedFeatureError, WeaviateInvalidInputError, + WeaviateQueryThirdPartyError, ) from weaviate.proto.v1 import search_get_pb2 from weaviate.types import NUMBER, UUID @@ -759,6 +760,7 @@ def __create_request( return search_get_pb2.SearchRequest( uses_123_api=True, uses_125_api=self.__uses_125_api, + uses_128_api=True, # sets a new return format for errors. The client can handle both collection=self._name, limit=limit, offset=offset, @@ -800,7 +802,15 @@ async def __call(self, request: search_get_pb2.SearchRequest) -> search_get_pb2. metadata=self._connection.grpc_headers(), timeout=self._connection.timeout_config.query, ) - return cast(search_get_pb2.SearchReply, res) + sr = cast(search_get_pb2.SearchReply, res) + if sr.third_party_error is not None: + raise WeaviateQueryThirdPartyError( + sr.third_party_error.full_error, + sr.third_party_error.provider_name, + sr.third_party_error.error_from_provider, + "GRPC search", + ) + return sr except AioRpcError as e: raise WeaviateQueryError(str(e), "GRPC search") # pyright: ignore diff --git a/weaviate/exceptions.py b/weaviate/exceptions.py index 8473a9030..5c8a62ab3 100644 --- a/weaviate/exceptions.py +++ b/weaviate/exceptions.py @@ -224,15 +224,35 @@ def __init__(self, message: str): class WeaviateQueryError(WeaviateBaseError): """Is raised if a query (either gRPC or GraphQL) to Weaviate fails in any way.""" - def __init__(self, message: str, protocol_type: str): - msg = f"""Query call with protocol {protocol_type} failed with message {message}.""" + def __init__(self, message: str, protocol_type: str, add_message: bool = True): + if add_message: + msg = f"""Query call with protocol {protocol_type} failed with message {message}.""" + else: + msg = message super().__init__(msg) - self.message = message + self.message = msg WeaviateQueryException = WeaviateQueryError +class WeaviateQueryThirdPartyError(WeaviateQueryError): + """Is raised if a query (either gRPC or GraphQL) to Weaviate fails in any way.""" + + def __init__( + self, full_error: str, provider_name: str, provider_error: str, protocol_type: str + ): + msg = f""" + Full error message: {full_error} + + Query failed due to an error with a third party service. + Provider: {provider_name} + Error from provider: {provider_error} + """ + super().__init__(msg, protocol_type, False) + self.message = msg + + class WeaviateBatchError(WeaviateQueryError): """Is raised if a gRPC batch query to Weaviate fails in any way.""" diff --git a/weaviate/proto/v1/search_get_pb2.py b/weaviate/proto/v1/search_get_pb2.py index d7098618e..bb5f5fd1c 100644 --- a/weaviate/proto/v1/search_get_pb2.py +++ b/weaviate/proto/v1/search_get_pb2.py @@ -20,7 +20,7 @@ DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile( - b'\n\x13v1/search_get.proto\x12\x0bweaviate.v1\x1a\x1cgoogle/protobuf/struct.proto\x1a\rv1/base.proto\x1a\x13v1/generative.proto\x1a\x13v1/properties.proto"\x9c\x0b\n\rSearchRequest\x12\x12\n\ncollection\x18\x01 \x01(\t\x12\x0e\n\x06tenant\x18\n \x01(\t\x12=\n\x11\x63onsistency_level\x18\x0b \x01(\x0e\x32\x1d.weaviate.v1.ConsistencyLevelH\x00\x88\x01\x01\x12\x37\n\nproperties\x18\x14 \x01(\x0b\x32\x1e.weaviate.v1.PropertiesRequestH\x01\x88\x01\x01\x12\x33\n\x08metadata\x18\x15 \x01(\x0b\x32\x1c.weaviate.v1.MetadataRequestH\x02\x88\x01\x01\x12+\n\x08group_by\x18\x16 \x01(\x0b\x32\x14.weaviate.v1.GroupByH\x03\x88\x01\x01\x12\r\n\x05limit\x18\x1e \x01(\r\x12\x0e\n\x06offset\x18\x1f \x01(\r\x12\x0f\n\x07\x61utocut\x18 \x01(\r\x12\r\n\x05\x61\x66ter\x18! \x01(\t\x12$\n\x07sort_by\x18" \x03(\x0b\x32\x13.weaviate.v1.SortBy\x12*\n\x07\x66ilters\x18( \x01(\x0b\x32\x14.weaviate.v1.FiltersH\x04\x88\x01\x01\x12/\n\rhybrid_search\x18) \x01(\x0b\x32\x13.weaviate.v1.HybridH\x05\x88\x01\x01\x12+\n\x0b\x62m25_search\x18* \x01(\x0b\x32\x11.weaviate.v1.BM25H\x06\x88\x01\x01\x12\x31\n\x0bnear_vector\x18+ \x01(\x0b\x32\x17.weaviate.v1.NearVectorH\x07\x88\x01\x01\x12\x31\n\x0bnear_object\x18, \x01(\x0b\x32\x17.weaviate.v1.NearObjectH\x08\x88\x01\x01\x12\x33\n\tnear_text\x18- \x01(\x0b\x32\x1b.weaviate.v1.NearTextSearchH\t\x88\x01\x01\x12\x35\n\nnear_image\x18. \x01(\x0b\x32\x1c.weaviate.v1.NearImageSearchH\n\x88\x01\x01\x12\x35\n\nnear_audio\x18/ \x01(\x0b\x32\x1c.weaviate.v1.NearAudioSearchH\x0b\x88\x01\x01\x12\x35\n\nnear_video\x18\x30 \x01(\x0b\x32\x1c.weaviate.v1.NearVideoSearchH\x0c\x88\x01\x01\x12\x35\n\nnear_depth\x18\x31 \x01(\x0b\x32\x1c.weaviate.v1.NearDepthSearchH\r\x88\x01\x01\x12\x39\n\x0cnear_thermal\x18\x32 \x01(\x0b\x32\x1e.weaviate.v1.NearThermalSearchH\x0e\x88\x01\x01\x12\x31\n\x08near_imu\x18\x33 \x01(\x0b\x32\x1a.weaviate.v1.NearIMUSearchH\x0f\x88\x01\x01\x12\x36\n\ngenerative\x18< \x01(\x0b\x32\x1d.weaviate.v1.GenerativeSearchH\x10\x88\x01\x01\x12(\n\x06rerank\x18= \x01(\x0b\x32\x13.weaviate.v1.RerankH\x11\x88\x01\x01\x12\x18\n\x0cuses_123_api\x18\x64 \x01(\x08\x42\x02\x18\x01\x12\x18\n\x0cuses_125_api\x18\x65 \x01(\x08\x42\x02\x18\x01\x12\x14\n\x0cuses_127_api\x18\x66 \x01(\x08\x42\x14\n\x12_consistency_levelB\r\n\x0b_propertiesB\x0b\n\t_metadataB\x0b\n\t_group_byB\n\n\x08_filtersB\x10\n\x0e_hybrid_searchB\x0e\n\x0c_bm25_searchB\x0e\n\x0c_near_vectorB\x0e\n\x0c_near_objectB\x0c\n\n_near_textB\r\n\x0b_near_imageB\r\n\x0b_near_audioB\r\n\x0b_near_videoB\r\n\x0b_near_depthB\x0f\n\r_near_thermalB\x0b\n\t_near_imuB\r\n\x0b_generativeB\t\n\x07_rerank"L\n\x07GroupBy\x12\x0c\n\x04path\x18\x01 \x03(\t\x12\x18\n\x10number_of_groups\x18\x02 \x01(\x05\x12\x19\n\x11objects_per_group\x18\x03 \x01(\x05")\n\x06SortBy\x12\x11\n\tascending\x18\x01 \x01(\x08\x12\x0c\n\x04path\x18\x02 \x03(\t"\xdd\x01\n\x0fMetadataRequest\x12\x0c\n\x04uuid\x18\x01 \x01(\x08\x12\x0e\n\x06vector\x18\x02 \x01(\x08\x12\x1a\n\x12\x63reation_time_unix\x18\x03 \x01(\x08\x12\x1d\n\x15last_update_time_unix\x18\x04 \x01(\x08\x12\x10\n\x08\x64istance\x18\x05 \x01(\x08\x12\x11\n\tcertainty\x18\x06 \x01(\x08\x12\r\n\x05score\x18\x07 \x01(\x08\x12\x15\n\rexplain_score\x18\x08 \x01(\x08\x12\x15\n\ris_consistent\x18\t \x01(\x08\x12\x0f\n\x07vectors\x18\n \x03(\t"\xd1\x01\n\x11PropertiesRequest\x12\x1a\n\x12non_ref_properties\x18\x01 \x03(\t\x12\x39\n\x0eref_properties\x18\x02 \x03(\x0b\x32!.weaviate.v1.RefPropertiesRequest\x12?\n\x11object_properties\x18\x03 \x03(\x0b\x32$.weaviate.v1.ObjectPropertiesRequest\x12$\n\x1creturn_all_nonref_properties\x18\x0b \x01(\x08"\x8b\x01\n\x17ObjectPropertiesRequest\x12\x11\n\tprop_name\x18\x01 \x01(\t\x12\x1c\n\x14primitive_properties\x18\x02 \x03(\t\x12?\n\x11object_properties\x18\x03 \x03(\x0b\x32$.weaviate.v1.ObjectPropertiesRequest"2\n\x10WeightsForTarget\x12\x0e\n\x06target\x18\x01 \x01(\t\x12\x0e\n\x06weight\x18\x02 \x01(\x02"\xfa\x01\n\x07Targets\x12\x16\n\x0etarget_vectors\x18\x01 \x03(\t\x12\x33\n\x0b\x63ombination\x18\x02 \x01(\x0e\x32\x1e.weaviate.v1.CombinationMethod\x12\x36\n\x07weights\x18\x03 \x03(\x0b\x32!.weaviate.v1.Targets.WeightsEntryB\x02\x18\x01\x12:\n\x13weights_for_targets\x18\x04 \x03(\x0b\x32\x1d.weaviate.v1.WeightsForTarget\x1a.\n\x0cWeightsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x02:\x02\x38\x01"\xc5\x03\n\x06Hybrid\x12\r\n\x05query\x18\x01 \x01(\t\x12\x12\n\nproperties\x18\x02 \x03(\t\x12\x12\n\x06vector\x18\x03 \x03(\x02\x42\x02\x18\x01\x12\r\n\x05\x61lpha\x18\x04 \x01(\x02\x12\x33\n\x0b\x66usion_type\x18\x05 \x01(\x0e\x32\x1e.weaviate.v1.Hybrid.FusionType\x12\x14\n\x0cvector_bytes\x18\x06 \x01(\x0c\x12\x1a\n\x0etarget_vectors\x18\x07 \x03(\tB\x02\x18\x01\x12.\n\tnear_text\x18\x08 \x01(\x0b\x32\x1b.weaviate.v1.NearTextSearch\x12,\n\x0bnear_vector\x18\t \x01(\x0b\x32\x17.weaviate.v1.NearVector\x12%\n\x07targets\x18\n \x01(\x0b\x32\x14.weaviate.v1.Targets\x12\x19\n\x0fvector_distance\x18\x14 \x01(\x02H\x00"a\n\nFusionType\x12\x1b\n\x17\x46USION_TYPE_UNSPECIFIED\x10\x00\x12\x16\n\x12\x46USION_TYPE_RANKED\x10\x01\x12\x1e\n\x1a\x46USION_TYPE_RELATIVE_SCORE\x10\x02\x42\x0b\n\tthreshold"\xf0\x02\n\x0eNearTextSearch\x12\r\n\x05query\x18\x01 \x03(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x36\n\x07move_to\x18\x04 \x01(\x0b\x32 .weaviate.v1.NearTextSearch.MoveH\x02\x88\x01\x01\x12\x38\n\tmove_away\x18\x05 \x01(\x0b\x32 .weaviate.v1.NearTextSearch.MoveH\x03\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x06 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x07 \x01(\x0b\x32\x14.weaviate.v1.Targets\x1a\x36\n\x04Move\x12\r\n\x05\x66orce\x18\x01 \x01(\x02\x12\x10\n\x08\x63oncepts\x18\x02 \x03(\t\x12\r\n\x05uuids\x18\x03 \x03(\tB\x0c\n\n_certaintyB\x0b\n\t_distanceB\n\n\x08_move_toB\x0c\n\n_move_away"\xad\x01\n\x0fNearImageSearch\x12\r\n\x05image\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xad\x01\n\x0fNearAudioSearch\x12\r\n\x05\x61udio\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xad\x01\n\x0fNearVideoSearch\x12\r\n\x05video\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xad\x01\n\x0fNearDepthSearch\x12\r\n\x05\x64\x65pth\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xb1\x01\n\x11NearThermalSearch\x12\x0f\n\x07thermal\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xa9\x01\n\rNearIMUSearch\x12\x0b\n\x03imu\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance")\n\x04\x42M25\x12\r\n\x05query\x18\x01 \x01(\t\x12\x12\n\nproperties\x18\x02 \x03(\t"\xb1\x01\n\x14RefPropertiesRequest\x12\x1a\n\x12reference_property\x18\x01 \x01(\t\x12\x32\n\nproperties\x18\x02 \x01(\x0b\x32\x1e.weaviate.v1.PropertiesRequest\x12.\n\x08metadata\x18\x03 \x01(\x0b\x32\x1c.weaviate.v1.MetadataRequest\x12\x19\n\x11target_collection\x18\x04 \x01(\t"5\n\x0fVectorForTarget\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x14\n\x0cvector_bytes\x18\x02 \x01(\x0c"\x82\x03\n\nNearVector\x12\x12\n\x06vector\x18\x01 \x03(\x02\x42\x02\x18\x01\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x14\n\x0cvector_bytes\x18\x04 \x01(\x0c\x12\x1a\n\x0etarget_vectors\x18\x05 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x06 \x01(\x0b\x32\x14.weaviate.v1.Targets\x12K\n\x11vector_per_target\x18\x07 \x03(\x0b\x32,.weaviate.v1.NearVector.VectorPerTargetEntryB\x02\x18\x01\x12\x38\n\x12vector_for_targets\x18\x08 \x03(\x0b\x32\x1c.weaviate.v1.VectorForTarget\x1a\x36\n\x14VectorPerTargetEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x0c:\x02\x38\x01\x42\x0c\n\n_certaintyB\x0b\n\t_distance"\xa5\x01\n\nNearObject\x12\n\n\x02id\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"8\n\x06Rerank\x12\x10\n\x08property\x18\x01 \x01(\t\x12\x12\n\x05query\x18\x02 \x01(\tH\x00\x88\x01\x01\x42\x08\n\x06_query"\xae\x02\n\x0bSearchReply\x12\x0c\n\x04took\x18\x01 \x01(\x02\x12*\n\x07results\x18\x02 \x03(\x0b\x32\x19.weaviate.v1.SearchResult\x12*\n\x19generative_grouped_result\x18\x03 \x01(\tB\x02\x18\x01H\x00\x88\x01\x01\x12\x34\n\x10group_by_results\x18\x04 \x03(\x0b\x32\x1a.weaviate.v1.GroupByResult\x12\x46\n\x1agenerative_grouped_results\x18\x05 \x01(\x0b\x32\x1d.weaviate.v1.GenerativeResultH\x01\x88\x01\x01\x42\x1c\n\x1a_generative_grouped_resultB\x1d\n\x1b_generative_grouped_results"\x1c\n\x0bRerankReply\x12\r\n\x05score\x18\x01 \x01(\x01"\xe9\x02\n\rGroupByResult\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x14\n\x0cmin_distance\x18\x02 \x01(\x02\x12\x14\n\x0cmax_distance\x18\x03 \x01(\x02\x12\x19\n\x11number_of_objects\x18\x04 \x01(\x03\x12*\n\x07objects\x18\x05 \x03(\x0b\x32\x19.weaviate.v1.SearchResult\x12-\n\x06rerank\x18\x06 \x01(\x0b\x32\x18.weaviate.v1.RerankReplyH\x00\x88\x01\x01\x12\x39\n\ngenerative\x18\x07 \x01(\x0b\x32\x1c.weaviate.v1.GenerativeReplyB\x02\x18\x01H\x01\x88\x01\x01\x12=\n\x11generative_result\x18\x08 \x01(\x0b\x32\x1d.weaviate.v1.GenerativeResultH\x02\x88\x01\x01\x42\t\n\x07_rerankB\r\n\x0b_generativeB\x14\n\x12_generative_result"\xb7\x01\n\x0cSearchResult\x12\x31\n\nproperties\x18\x01 \x01(\x0b\x32\x1d.weaviate.v1.PropertiesResult\x12-\n\x08metadata\x18\x02 \x01(\x0b\x32\x1b.weaviate.v1.MetadataResult\x12\x36\n\ngenerative\x18\x03 \x01(\x0b\x32\x1d.weaviate.v1.GenerativeResultH\x00\x88\x01\x01\x42\r\n\x0b_generative"\xf7\x04\n\x0eMetadataResult\x12\n\n\x02id\x18\x01 \x01(\t\x12\x12\n\x06vector\x18\x02 \x03(\x02\x42\x02\x18\x01\x12\x1a\n\x12\x63reation_time_unix\x18\x03 \x01(\x03\x12"\n\x1a\x63reation_time_unix_present\x18\x04 \x01(\x08\x12\x1d\n\x15last_update_time_unix\x18\x05 \x01(\x03\x12%\n\x1dlast_update_time_unix_present\x18\x06 \x01(\x08\x12\x10\n\x08\x64istance\x18\x07 \x01(\x02\x12\x18\n\x10\x64istance_present\x18\x08 \x01(\x08\x12\x11\n\tcertainty\x18\t \x01(\x02\x12\x19\n\x11\x63\x65rtainty_present\x18\n \x01(\x08\x12\r\n\x05score\x18\x0b \x01(\x02\x12\x15\n\rscore_present\x18\x0c \x01(\x08\x12\x15\n\rexplain_score\x18\r \x01(\t\x12\x1d\n\x15\x65xplain_score_present\x18\x0e \x01(\x08\x12\x1a\n\ris_consistent\x18\x0f \x01(\x08H\x00\x88\x01\x01\x12\x16\n\ngenerative\x18\x10 \x01(\tB\x02\x18\x01\x12\x1e\n\x12generative_present\x18\x11 \x01(\x08\x42\x02\x18\x01\x12\x1d\n\x15is_consistent_present\x18\x12 \x01(\x08\x12\x14\n\x0cvector_bytes\x18\x13 \x01(\x0c\x12\x13\n\x0bid_as_bytes\x18\x14 \x01(\x0c\x12\x14\n\x0crerank_score\x18\x15 \x01(\x01\x12\x1c\n\x14rerank_score_present\x18\x16 \x01(\x08\x12%\n\x07vectors\x18\x17 \x03(\x0b\x32\x14.weaviate.v1.VectorsB\x10\n\x0e_is_consistent"\xba\x05\n\x10PropertiesResult\x12\x37\n\x12non_ref_properties\x18\x01 \x01(\x0b\x32\x17.google.protobuf.StructB\x02\x18\x01\x12\x33\n\tref_props\x18\x02 \x03(\x0b\x32 .weaviate.v1.RefPropertiesResult\x12\x19\n\x11target_collection\x18\x03 \x01(\t\x12-\n\x08metadata\x18\x04 \x01(\x0b\x32\x1b.weaviate.v1.MetadataResult\x12G\n\x17number_array_properties\x18\x05 \x03(\x0b\x32".weaviate.v1.NumberArrayPropertiesB\x02\x18\x01\x12\x41\n\x14int_array_properties\x18\x06 \x03(\x0b\x32\x1f.weaviate.v1.IntArrayPropertiesB\x02\x18\x01\x12\x43\n\x15text_array_properties\x18\x07 \x03(\x0b\x32 .weaviate.v1.TextArrayPropertiesB\x02\x18\x01\x12I\n\x18\x62oolean_array_properties\x18\x08 \x03(\x0b\x32#.weaviate.v1.BooleanArrayPropertiesB\x02\x18\x01\x12<\n\x11object_properties\x18\t \x03(\x0b\x32\x1d.weaviate.v1.ObjectPropertiesB\x02\x18\x01\x12G\n\x17object_array_properties\x18\n \x03(\x0b\x32".weaviate.v1.ObjectArrayPropertiesB\x02\x18\x01\x12.\n\rnon_ref_props\x18\x0b \x01(\x0b\x32\x17.weaviate.v1.Properties\x12\x1b\n\x13ref_props_requested\x18\x0c \x01(\x08"[\n\x13RefPropertiesResult\x12\x31\n\nproperties\x18\x01 \x03(\x0b\x32\x1d.weaviate.v1.PropertiesResult\x12\x11\n\tprop_name\x18\x02 \x01(\t*\xee\x01\n\x11\x43ombinationMethod\x12"\n\x1e\x43OMBINATION_METHOD_UNSPECIFIED\x10\x00\x12\x1f\n\x1b\x43OMBINATION_METHOD_TYPE_SUM\x10\x01\x12\x1f\n\x1b\x43OMBINATION_METHOD_TYPE_MIN\x10\x02\x12#\n\x1f\x43OMBINATION_METHOD_TYPE_AVERAGE\x10\x03\x12*\n&COMBINATION_METHOD_TYPE_RELATIVE_SCORE\x10\x04\x12"\n\x1e\x43OMBINATION_METHOD_TYPE_MANUAL\x10\x05\x42s\n#io.weaviate.client.grpc.protocol.v1B\x16WeaviateProtoSearchGetZ4github.com/weaviate/weaviate/grpc/generated;protocolb\x06proto3' + b'\n\x13v1/search_get.proto\x12\x0bweaviate.v1\x1a\x1cgoogle/protobuf/struct.proto\x1a\rv1/base.proto\x1a\x13v1/generative.proto\x1a\x13v1/properties.proto"\xb2\x0b\n\rSearchRequest\x12\x12\n\ncollection\x18\x01 \x01(\t\x12\x0e\n\x06tenant\x18\n \x01(\t\x12=\n\x11\x63onsistency_level\x18\x0b \x01(\x0e\x32\x1d.weaviate.v1.ConsistencyLevelH\x00\x88\x01\x01\x12\x37\n\nproperties\x18\x14 \x01(\x0b\x32\x1e.weaviate.v1.PropertiesRequestH\x01\x88\x01\x01\x12\x33\n\x08metadata\x18\x15 \x01(\x0b\x32\x1c.weaviate.v1.MetadataRequestH\x02\x88\x01\x01\x12+\n\x08group_by\x18\x16 \x01(\x0b\x32\x14.weaviate.v1.GroupByH\x03\x88\x01\x01\x12\r\n\x05limit\x18\x1e \x01(\r\x12\x0e\n\x06offset\x18\x1f \x01(\r\x12\x0f\n\x07\x61utocut\x18 \x01(\r\x12\r\n\x05\x61\x66ter\x18! \x01(\t\x12$\n\x07sort_by\x18" \x03(\x0b\x32\x13.weaviate.v1.SortBy\x12*\n\x07\x66ilters\x18( \x01(\x0b\x32\x14.weaviate.v1.FiltersH\x04\x88\x01\x01\x12/\n\rhybrid_search\x18) \x01(\x0b\x32\x13.weaviate.v1.HybridH\x05\x88\x01\x01\x12+\n\x0b\x62m25_search\x18* \x01(\x0b\x32\x11.weaviate.v1.BM25H\x06\x88\x01\x01\x12\x31\n\x0bnear_vector\x18+ \x01(\x0b\x32\x17.weaviate.v1.NearVectorH\x07\x88\x01\x01\x12\x31\n\x0bnear_object\x18, \x01(\x0b\x32\x17.weaviate.v1.NearObjectH\x08\x88\x01\x01\x12\x33\n\tnear_text\x18- \x01(\x0b\x32\x1b.weaviate.v1.NearTextSearchH\t\x88\x01\x01\x12\x35\n\nnear_image\x18. \x01(\x0b\x32\x1c.weaviate.v1.NearImageSearchH\n\x88\x01\x01\x12\x35\n\nnear_audio\x18/ \x01(\x0b\x32\x1c.weaviate.v1.NearAudioSearchH\x0b\x88\x01\x01\x12\x35\n\nnear_video\x18\x30 \x01(\x0b\x32\x1c.weaviate.v1.NearVideoSearchH\x0c\x88\x01\x01\x12\x35\n\nnear_depth\x18\x31 \x01(\x0b\x32\x1c.weaviate.v1.NearDepthSearchH\r\x88\x01\x01\x12\x39\n\x0cnear_thermal\x18\x32 \x01(\x0b\x32\x1e.weaviate.v1.NearThermalSearchH\x0e\x88\x01\x01\x12\x31\n\x08near_imu\x18\x33 \x01(\x0b\x32\x1a.weaviate.v1.NearIMUSearchH\x0f\x88\x01\x01\x12\x36\n\ngenerative\x18< \x01(\x0b\x32\x1d.weaviate.v1.GenerativeSearchH\x10\x88\x01\x01\x12(\n\x06rerank\x18= \x01(\x0b\x32\x13.weaviate.v1.RerankH\x11\x88\x01\x01\x12\x18\n\x0cuses_123_api\x18\x64 \x01(\x08\x42\x02\x18\x01\x12\x18\n\x0cuses_125_api\x18\x65 \x01(\x08\x42\x02\x18\x01\x12\x14\n\x0cuses_127_api\x18\x66 \x01(\x08\x12\x14\n\x0cuses_128_api\x18g \x01(\x08\x42\x14\n\x12_consistency_levelB\r\n\x0b_propertiesB\x0b\n\t_metadataB\x0b\n\t_group_byB\n\n\x08_filtersB\x10\n\x0e_hybrid_searchB\x0e\n\x0c_bm25_searchB\x0e\n\x0c_near_vectorB\x0e\n\x0c_near_objectB\x0c\n\n_near_textB\r\n\x0b_near_imageB\r\n\x0b_near_audioB\r\n\x0b_near_videoB\r\n\x0b_near_depthB\x0f\n\r_near_thermalB\x0b\n\t_near_imuB\r\n\x0b_generativeB\t\n\x07_rerank"L\n\x07GroupBy\x12\x0c\n\x04path\x18\x01 \x03(\t\x12\x18\n\x10number_of_groups\x18\x02 \x01(\x05\x12\x19\n\x11objects_per_group\x18\x03 \x01(\x05")\n\x06SortBy\x12\x11\n\tascending\x18\x01 \x01(\x08\x12\x0c\n\x04path\x18\x02 \x03(\t"\xdd\x01\n\x0fMetadataRequest\x12\x0c\n\x04uuid\x18\x01 \x01(\x08\x12\x0e\n\x06vector\x18\x02 \x01(\x08\x12\x1a\n\x12\x63reation_time_unix\x18\x03 \x01(\x08\x12\x1d\n\x15last_update_time_unix\x18\x04 \x01(\x08\x12\x10\n\x08\x64istance\x18\x05 \x01(\x08\x12\x11\n\tcertainty\x18\x06 \x01(\x08\x12\r\n\x05score\x18\x07 \x01(\x08\x12\x15\n\rexplain_score\x18\x08 \x01(\x08\x12\x15\n\ris_consistent\x18\t \x01(\x08\x12\x0f\n\x07vectors\x18\n \x03(\t"\xd1\x01\n\x11PropertiesRequest\x12\x1a\n\x12non_ref_properties\x18\x01 \x03(\t\x12\x39\n\x0eref_properties\x18\x02 \x03(\x0b\x32!.weaviate.v1.RefPropertiesRequest\x12?\n\x11object_properties\x18\x03 \x03(\x0b\x32$.weaviate.v1.ObjectPropertiesRequest\x12$\n\x1creturn_all_nonref_properties\x18\x0b \x01(\x08"\x8b\x01\n\x17ObjectPropertiesRequest\x12\x11\n\tprop_name\x18\x01 \x01(\t\x12\x1c\n\x14primitive_properties\x18\x02 \x03(\t\x12?\n\x11object_properties\x18\x03 \x03(\x0b\x32$.weaviate.v1.ObjectPropertiesRequest"2\n\x10WeightsForTarget\x12\x0e\n\x06target\x18\x01 \x01(\t\x12\x0e\n\x06weight\x18\x02 \x01(\x02"\xfa\x01\n\x07Targets\x12\x16\n\x0etarget_vectors\x18\x01 \x03(\t\x12\x33\n\x0b\x63ombination\x18\x02 \x01(\x0e\x32\x1e.weaviate.v1.CombinationMethod\x12\x36\n\x07weights\x18\x03 \x03(\x0b\x32!.weaviate.v1.Targets.WeightsEntryB\x02\x18\x01\x12:\n\x13weights_for_targets\x18\x04 \x03(\x0b\x32\x1d.weaviate.v1.WeightsForTarget\x1a.\n\x0cWeightsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x02:\x02\x38\x01"\xc5\x03\n\x06Hybrid\x12\r\n\x05query\x18\x01 \x01(\t\x12\x12\n\nproperties\x18\x02 \x03(\t\x12\x12\n\x06vector\x18\x03 \x03(\x02\x42\x02\x18\x01\x12\r\n\x05\x61lpha\x18\x04 \x01(\x02\x12\x33\n\x0b\x66usion_type\x18\x05 \x01(\x0e\x32\x1e.weaviate.v1.Hybrid.FusionType\x12\x14\n\x0cvector_bytes\x18\x06 \x01(\x0c\x12\x1a\n\x0etarget_vectors\x18\x07 \x03(\tB\x02\x18\x01\x12.\n\tnear_text\x18\x08 \x01(\x0b\x32\x1b.weaviate.v1.NearTextSearch\x12,\n\x0bnear_vector\x18\t \x01(\x0b\x32\x17.weaviate.v1.NearVector\x12%\n\x07targets\x18\n \x01(\x0b\x32\x14.weaviate.v1.Targets\x12\x19\n\x0fvector_distance\x18\x14 \x01(\x02H\x00"a\n\nFusionType\x12\x1b\n\x17\x46USION_TYPE_UNSPECIFIED\x10\x00\x12\x16\n\x12\x46USION_TYPE_RANKED\x10\x01\x12\x1e\n\x1a\x46USION_TYPE_RELATIVE_SCORE\x10\x02\x42\x0b\n\tthreshold"\xf0\x02\n\x0eNearTextSearch\x12\r\n\x05query\x18\x01 \x03(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x36\n\x07move_to\x18\x04 \x01(\x0b\x32 .weaviate.v1.NearTextSearch.MoveH\x02\x88\x01\x01\x12\x38\n\tmove_away\x18\x05 \x01(\x0b\x32 .weaviate.v1.NearTextSearch.MoveH\x03\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x06 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x07 \x01(\x0b\x32\x14.weaviate.v1.Targets\x1a\x36\n\x04Move\x12\r\n\x05\x66orce\x18\x01 \x01(\x02\x12\x10\n\x08\x63oncepts\x18\x02 \x03(\t\x12\r\n\x05uuids\x18\x03 \x03(\tB\x0c\n\n_certaintyB\x0b\n\t_distanceB\n\n\x08_move_toB\x0c\n\n_move_away"\xad\x01\n\x0fNearImageSearch\x12\r\n\x05image\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xad\x01\n\x0fNearAudioSearch\x12\r\n\x05\x61udio\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xad\x01\n\x0fNearVideoSearch\x12\r\n\x05video\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xad\x01\n\x0fNearDepthSearch\x12\r\n\x05\x64\x65pth\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xb1\x01\n\x11NearThermalSearch\x12\x0f\n\x07thermal\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xa9\x01\n\rNearIMUSearch\x12\x0b\n\x03imu\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance")\n\x04\x42M25\x12\r\n\x05query\x18\x01 \x01(\t\x12\x12\n\nproperties\x18\x02 \x03(\t"\xb1\x01\n\x14RefPropertiesRequest\x12\x1a\n\x12reference_property\x18\x01 \x01(\t\x12\x32\n\nproperties\x18\x02 \x01(\x0b\x32\x1e.weaviate.v1.PropertiesRequest\x12.\n\x08metadata\x18\x03 \x01(\x0b\x32\x1c.weaviate.v1.MetadataRequest\x12\x19\n\x11target_collection\x18\x04 \x01(\t"5\n\x0fVectorForTarget\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x14\n\x0cvector_bytes\x18\x02 \x01(\x0c"\x82\x03\n\nNearVector\x12\x12\n\x06vector\x18\x01 \x03(\x02\x42\x02\x18\x01\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x14\n\x0cvector_bytes\x18\x04 \x01(\x0c\x12\x1a\n\x0etarget_vectors\x18\x05 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x06 \x01(\x0b\x32\x14.weaviate.v1.Targets\x12K\n\x11vector_per_target\x18\x07 \x03(\x0b\x32,.weaviate.v1.NearVector.VectorPerTargetEntryB\x02\x18\x01\x12\x38\n\x12vector_for_targets\x18\x08 \x03(\x0b\x32\x1c.weaviate.v1.VectorForTarget\x1a\x36\n\x14VectorPerTargetEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x0c:\x02\x38\x01\x42\x0c\n\n_certaintyB\x0b\n\t_distance"\xa5\x01\n\nNearObject\x12\n\n\x02id\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"8\n\x06Rerank\x12\x10\n\x08property\x18\x01 \x01(\t\x12\x12\n\x05query\x18\x02 \x01(\tH\x00\x88\x01\x01\x42\x08\n\x06_query"Y\n\x0fThirdPartyError\x12\x15\n\rprovider_name\x18\x01 \x01(\t\x12\x1b\n\x13\x65rror_from_provider\x18\x02 \x01(\t\x12\x12\n\nfull_error\x18\x03 \x01(\t"\xf3\x02\n\x0bSearchReply\x12\x0c\n\x04took\x18\x01 \x01(\x02\x12*\n\x07results\x18\x02 \x03(\x0b\x32\x19.weaviate.v1.SearchResult\x12*\n\x19generative_grouped_result\x18\x03 \x01(\tB\x02\x18\x01H\x01\x88\x01\x01\x12\x34\n\x10group_by_results\x18\x04 \x03(\x0b\x32\x1a.weaviate.v1.GroupByResult\x12\x46\n\x1agenerative_grouped_results\x18\x05 \x01(\x0b\x32\x1d.weaviate.v1.GenerativeResultH\x02\x88\x01\x01\x12\x39\n\x11third_party_error\x18\x06 \x01(\x0b\x32\x1c.weaviate.v1.ThirdPartyErrorH\x00\x42\x08\n\x06\x65rrorsB\x1c\n\x1a_generative_grouped_resultB\x1d\n\x1b_generative_grouped_results"\x1c\n\x0bRerankReply\x12\r\n\x05score\x18\x01 \x01(\x01"\xe9\x02\n\rGroupByResult\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x14\n\x0cmin_distance\x18\x02 \x01(\x02\x12\x14\n\x0cmax_distance\x18\x03 \x01(\x02\x12\x19\n\x11number_of_objects\x18\x04 \x01(\x03\x12*\n\x07objects\x18\x05 \x03(\x0b\x32\x19.weaviate.v1.SearchResult\x12-\n\x06rerank\x18\x06 \x01(\x0b\x32\x18.weaviate.v1.RerankReplyH\x00\x88\x01\x01\x12\x39\n\ngenerative\x18\x07 \x01(\x0b\x32\x1c.weaviate.v1.GenerativeReplyB\x02\x18\x01H\x01\x88\x01\x01\x12=\n\x11generative_result\x18\x08 \x01(\x0b\x32\x1d.weaviate.v1.GenerativeResultH\x02\x88\x01\x01\x42\t\n\x07_rerankB\r\n\x0b_generativeB\x14\n\x12_generative_result"\xb7\x01\n\x0cSearchResult\x12\x31\n\nproperties\x18\x01 \x01(\x0b\x32\x1d.weaviate.v1.PropertiesResult\x12-\n\x08metadata\x18\x02 \x01(\x0b\x32\x1b.weaviate.v1.MetadataResult\x12\x36\n\ngenerative\x18\x03 \x01(\x0b\x32\x1d.weaviate.v1.GenerativeResultH\x00\x88\x01\x01\x42\r\n\x0b_generative"\xf7\x04\n\x0eMetadataResult\x12\n\n\x02id\x18\x01 \x01(\t\x12\x12\n\x06vector\x18\x02 \x03(\x02\x42\x02\x18\x01\x12\x1a\n\x12\x63reation_time_unix\x18\x03 \x01(\x03\x12"\n\x1a\x63reation_time_unix_present\x18\x04 \x01(\x08\x12\x1d\n\x15last_update_time_unix\x18\x05 \x01(\x03\x12%\n\x1dlast_update_time_unix_present\x18\x06 \x01(\x08\x12\x10\n\x08\x64istance\x18\x07 \x01(\x02\x12\x18\n\x10\x64istance_present\x18\x08 \x01(\x08\x12\x11\n\tcertainty\x18\t \x01(\x02\x12\x19\n\x11\x63\x65rtainty_present\x18\n \x01(\x08\x12\r\n\x05score\x18\x0b \x01(\x02\x12\x15\n\rscore_present\x18\x0c \x01(\x08\x12\x15\n\rexplain_score\x18\r \x01(\t\x12\x1d\n\x15\x65xplain_score_present\x18\x0e \x01(\x08\x12\x1a\n\ris_consistent\x18\x0f \x01(\x08H\x00\x88\x01\x01\x12\x16\n\ngenerative\x18\x10 \x01(\tB\x02\x18\x01\x12\x1e\n\x12generative_present\x18\x11 \x01(\x08\x42\x02\x18\x01\x12\x1d\n\x15is_consistent_present\x18\x12 \x01(\x08\x12\x14\n\x0cvector_bytes\x18\x13 \x01(\x0c\x12\x13\n\x0bid_as_bytes\x18\x14 \x01(\x0c\x12\x14\n\x0crerank_score\x18\x15 \x01(\x01\x12\x1c\n\x14rerank_score_present\x18\x16 \x01(\x08\x12%\n\x07vectors\x18\x17 \x03(\x0b\x32\x14.weaviate.v1.VectorsB\x10\n\x0e_is_consistent"\xba\x05\n\x10PropertiesResult\x12\x37\n\x12non_ref_properties\x18\x01 \x01(\x0b\x32\x17.google.protobuf.StructB\x02\x18\x01\x12\x33\n\tref_props\x18\x02 \x03(\x0b\x32 .weaviate.v1.RefPropertiesResult\x12\x19\n\x11target_collection\x18\x03 \x01(\t\x12-\n\x08metadata\x18\x04 \x01(\x0b\x32\x1b.weaviate.v1.MetadataResult\x12G\n\x17number_array_properties\x18\x05 \x03(\x0b\x32".weaviate.v1.NumberArrayPropertiesB\x02\x18\x01\x12\x41\n\x14int_array_properties\x18\x06 \x03(\x0b\x32\x1f.weaviate.v1.IntArrayPropertiesB\x02\x18\x01\x12\x43\n\x15text_array_properties\x18\x07 \x03(\x0b\x32 .weaviate.v1.TextArrayPropertiesB\x02\x18\x01\x12I\n\x18\x62oolean_array_properties\x18\x08 \x03(\x0b\x32#.weaviate.v1.BooleanArrayPropertiesB\x02\x18\x01\x12<\n\x11object_properties\x18\t \x03(\x0b\x32\x1d.weaviate.v1.ObjectPropertiesB\x02\x18\x01\x12G\n\x17object_array_properties\x18\n \x03(\x0b\x32".weaviate.v1.ObjectArrayPropertiesB\x02\x18\x01\x12.\n\rnon_ref_props\x18\x0b \x01(\x0b\x32\x17.weaviate.v1.Properties\x12\x1b\n\x13ref_props_requested\x18\x0c \x01(\x08"[\n\x13RefPropertiesResult\x12\x31\n\nproperties\x18\x01 \x03(\x0b\x32\x1d.weaviate.v1.PropertiesResult\x12\x11\n\tprop_name\x18\x02 \x01(\t*\xee\x01\n\x11\x43ombinationMethod\x12"\n\x1e\x43OMBINATION_METHOD_UNSPECIFIED\x10\x00\x12\x1f\n\x1b\x43OMBINATION_METHOD_TYPE_SUM\x10\x01\x12\x1f\n\x1b\x43OMBINATION_METHOD_TYPE_MIN\x10\x02\x12#\n\x1f\x43OMBINATION_METHOD_TYPE_AVERAGE\x10\x03\x12*\n&COMBINATION_METHOD_TYPE_RELATIVE_SCORE\x10\x04\x12"\n\x1e\x43OMBINATION_METHOD_TYPE_MANUAL\x10\x05\x42s\n#io.weaviate.client.grpc.protocol.v1B\x16WeaviateProtoSearchGetZ4github.com/weaviate/weaviate/grpc/generated;protocolb\x06proto3' ) _globals = globals() @@ -111,72 +111,74 @@ _globals["_PROPERTIESRESULT"].fields_by_name[ "object_array_properties" ]._serialized_options = b"\030\001" - _globals["_COMBINATIONMETHOD"]._serialized_start = 7656 - _globals["_COMBINATIONMETHOD"]._serialized_end = 7894 + _globals["_COMBINATIONMETHOD"]._serialized_start = 7838 + _globals["_COMBINATIONMETHOD"]._serialized_end = 8076 _globals["_SEARCHREQUEST"]._serialized_start = 124 - _globals["_SEARCHREQUEST"]._serialized_end = 1560 - _globals["_GROUPBY"]._serialized_start = 1562 - _globals["_GROUPBY"]._serialized_end = 1638 - _globals["_SORTBY"]._serialized_start = 1640 - _globals["_SORTBY"]._serialized_end = 1681 - _globals["_METADATAREQUEST"]._serialized_start = 1684 - _globals["_METADATAREQUEST"]._serialized_end = 1905 - _globals["_PROPERTIESREQUEST"]._serialized_start = 1908 - _globals["_PROPERTIESREQUEST"]._serialized_end = 2117 - _globals["_OBJECTPROPERTIESREQUEST"]._serialized_start = 2120 - _globals["_OBJECTPROPERTIESREQUEST"]._serialized_end = 2259 - _globals["_WEIGHTSFORTARGET"]._serialized_start = 2261 - _globals["_WEIGHTSFORTARGET"]._serialized_end = 2311 - _globals["_TARGETS"]._serialized_start = 2314 - _globals["_TARGETS"]._serialized_end = 2564 - _globals["_TARGETS_WEIGHTSENTRY"]._serialized_start = 2518 - _globals["_TARGETS_WEIGHTSENTRY"]._serialized_end = 2564 - _globals["_HYBRID"]._serialized_start = 2567 - _globals["_HYBRID"]._serialized_end = 3020 - _globals["_HYBRID_FUSIONTYPE"]._serialized_start = 2910 - _globals["_HYBRID_FUSIONTYPE"]._serialized_end = 3007 - _globals["_NEARTEXTSEARCH"]._serialized_start = 3023 - _globals["_NEARTEXTSEARCH"]._serialized_end = 3391 - _globals["_NEARTEXTSEARCH_MOVE"]._serialized_start = 3284 - _globals["_NEARTEXTSEARCH_MOVE"]._serialized_end = 3338 - _globals["_NEARIMAGESEARCH"]._serialized_start = 3394 - _globals["_NEARIMAGESEARCH"]._serialized_end = 3567 - _globals["_NEARAUDIOSEARCH"]._serialized_start = 3570 - _globals["_NEARAUDIOSEARCH"]._serialized_end = 3743 - _globals["_NEARVIDEOSEARCH"]._serialized_start = 3746 - _globals["_NEARVIDEOSEARCH"]._serialized_end = 3919 - _globals["_NEARDEPTHSEARCH"]._serialized_start = 3922 - _globals["_NEARDEPTHSEARCH"]._serialized_end = 4095 - _globals["_NEARTHERMALSEARCH"]._serialized_start = 4098 - _globals["_NEARTHERMALSEARCH"]._serialized_end = 4275 - _globals["_NEARIMUSEARCH"]._serialized_start = 4278 - _globals["_NEARIMUSEARCH"]._serialized_end = 4447 - _globals["_BM25"]._serialized_start = 4449 - _globals["_BM25"]._serialized_end = 4490 - _globals["_REFPROPERTIESREQUEST"]._serialized_start = 4493 - _globals["_REFPROPERTIESREQUEST"]._serialized_end = 4670 - _globals["_VECTORFORTARGET"]._serialized_start = 4672 - _globals["_VECTORFORTARGET"]._serialized_end = 4725 - _globals["_NEARVECTOR"]._serialized_start = 4728 - _globals["_NEARVECTOR"]._serialized_end = 5114 - _globals["_NEARVECTOR_VECTORPERTARGETENTRY"]._serialized_start = 5033 - _globals["_NEARVECTOR_VECTORPERTARGETENTRY"]._serialized_end = 5087 - _globals["_NEAROBJECT"]._serialized_start = 5117 - _globals["_NEAROBJECT"]._serialized_end = 5282 - _globals["_RERANK"]._serialized_start = 5284 - _globals["_RERANK"]._serialized_end = 5340 - _globals["_SEARCHREPLY"]._serialized_start = 5343 - _globals["_SEARCHREPLY"]._serialized_end = 5645 - _globals["_RERANKREPLY"]._serialized_start = 5647 - _globals["_RERANKREPLY"]._serialized_end = 5675 - _globals["_GROUPBYRESULT"]._serialized_start = 5678 - _globals["_GROUPBYRESULT"]._serialized_end = 6039 - _globals["_SEARCHRESULT"]._serialized_start = 6042 - _globals["_SEARCHRESULT"]._serialized_end = 6225 - _globals["_METADATARESULT"]._serialized_start = 6228 - _globals["_METADATARESULT"]._serialized_end = 6859 - _globals["_PROPERTIESRESULT"]._serialized_start = 6862 - _globals["_PROPERTIESRESULT"]._serialized_end = 7560 - _globals["_REFPROPERTIESRESULT"]._serialized_start = 7562 - _globals["_REFPROPERTIESRESULT"]._serialized_end = 7653 + _globals["_SEARCHREQUEST"]._serialized_end = 1582 + _globals["_GROUPBY"]._serialized_start = 1584 + _globals["_GROUPBY"]._serialized_end = 1660 + _globals["_SORTBY"]._serialized_start = 1662 + _globals["_SORTBY"]._serialized_end = 1703 + _globals["_METADATAREQUEST"]._serialized_start = 1706 + _globals["_METADATAREQUEST"]._serialized_end = 1927 + _globals["_PROPERTIESREQUEST"]._serialized_start = 1930 + _globals["_PROPERTIESREQUEST"]._serialized_end = 2139 + _globals["_OBJECTPROPERTIESREQUEST"]._serialized_start = 2142 + _globals["_OBJECTPROPERTIESREQUEST"]._serialized_end = 2281 + _globals["_WEIGHTSFORTARGET"]._serialized_start = 2283 + _globals["_WEIGHTSFORTARGET"]._serialized_end = 2333 + _globals["_TARGETS"]._serialized_start = 2336 + _globals["_TARGETS"]._serialized_end = 2586 + _globals["_TARGETS_WEIGHTSENTRY"]._serialized_start = 2540 + _globals["_TARGETS_WEIGHTSENTRY"]._serialized_end = 2586 + _globals["_HYBRID"]._serialized_start = 2589 + _globals["_HYBRID"]._serialized_end = 3042 + _globals["_HYBRID_FUSIONTYPE"]._serialized_start = 2932 + _globals["_HYBRID_FUSIONTYPE"]._serialized_end = 3029 + _globals["_NEARTEXTSEARCH"]._serialized_start = 3045 + _globals["_NEARTEXTSEARCH"]._serialized_end = 3413 + _globals["_NEARTEXTSEARCH_MOVE"]._serialized_start = 3306 + _globals["_NEARTEXTSEARCH_MOVE"]._serialized_end = 3360 + _globals["_NEARIMAGESEARCH"]._serialized_start = 3416 + _globals["_NEARIMAGESEARCH"]._serialized_end = 3589 + _globals["_NEARAUDIOSEARCH"]._serialized_start = 3592 + _globals["_NEARAUDIOSEARCH"]._serialized_end = 3765 + _globals["_NEARVIDEOSEARCH"]._serialized_start = 3768 + _globals["_NEARVIDEOSEARCH"]._serialized_end = 3941 + _globals["_NEARDEPTHSEARCH"]._serialized_start = 3944 + _globals["_NEARDEPTHSEARCH"]._serialized_end = 4117 + _globals["_NEARTHERMALSEARCH"]._serialized_start = 4120 + _globals["_NEARTHERMALSEARCH"]._serialized_end = 4297 + _globals["_NEARIMUSEARCH"]._serialized_start = 4300 + _globals["_NEARIMUSEARCH"]._serialized_end = 4469 + _globals["_BM25"]._serialized_start = 4471 + _globals["_BM25"]._serialized_end = 4512 + _globals["_REFPROPERTIESREQUEST"]._serialized_start = 4515 + _globals["_REFPROPERTIESREQUEST"]._serialized_end = 4692 + _globals["_VECTORFORTARGET"]._serialized_start = 4694 + _globals["_VECTORFORTARGET"]._serialized_end = 4747 + _globals["_NEARVECTOR"]._serialized_start = 4750 + _globals["_NEARVECTOR"]._serialized_end = 5136 + _globals["_NEARVECTOR_VECTORPERTARGETENTRY"]._serialized_start = 5055 + _globals["_NEARVECTOR_VECTORPERTARGETENTRY"]._serialized_end = 5109 + _globals["_NEAROBJECT"]._serialized_start = 5139 + _globals["_NEAROBJECT"]._serialized_end = 5304 + _globals["_RERANK"]._serialized_start = 5306 + _globals["_RERANK"]._serialized_end = 5362 + _globals["_THIRDPARTYERROR"]._serialized_start = 5364 + _globals["_THIRDPARTYERROR"]._serialized_end = 5453 + _globals["_SEARCHREPLY"]._serialized_start = 5456 + _globals["_SEARCHREPLY"]._serialized_end = 5827 + _globals["_RERANKREPLY"]._serialized_start = 5829 + _globals["_RERANKREPLY"]._serialized_end = 5857 + _globals["_GROUPBYRESULT"]._serialized_start = 5860 + _globals["_GROUPBYRESULT"]._serialized_end = 6221 + _globals["_SEARCHRESULT"]._serialized_start = 6224 + _globals["_SEARCHRESULT"]._serialized_end = 6407 + _globals["_METADATARESULT"]._serialized_start = 6410 + _globals["_METADATARESULT"]._serialized_end = 7041 + _globals["_PROPERTIESRESULT"]._serialized_start = 7044 + _globals["_PROPERTIESRESULT"]._serialized_end = 7742 + _globals["_REFPROPERTIESRESULT"]._serialized_start = 7744 + _globals["_REFPROPERTIESRESULT"]._serialized_end = 7835 # @@protoc_insertion_point(module_scope) diff --git a/weaviate/proto/v1/search_get_pb2.pyi b/weaviate/proto/v1/search_get_pb2.pyi index eaaa6f20b..4154c74f4 100644 --- a/weaviate/proto/v1/search_get_pb2.pyi +++ b/weaviate/proto/v1/search_get_pb2.pyi @@ -62,6 +62,7 @@ class SearchRequest(_message.Message): "uses_123_api", "uses_125_api", "uses_127_api", + "uses_128_api", ) COLLECTION_FIELD_NUMBER: _ClassVar[int] TENANT_FIELD_NUMBER: _ClassVar[int] @@ -91,6 +92,7 @@ class SearchRequest(_message.Message): USES_123_API_FIELD_NUMBER: _ClassVar[int] USES_125_API_FIELD_NUMBER: _ClassVar[int] USES_127_API_FIELD_NUMBER: _ClassVar[int] + USES_128_API_FIELD_NUMBER: _ClassVar[int] collection: str tenant: str consistency_level: _base_pb2.ConsistencyLevel @@ -119,6 +121,7 @@ class SearchRequest(_message.Message): uses_123_api: bool uses_125_api: bool uses_127_api: bool + uses_128_api: bool def __init__( self, collection: _Optional[str] = ..., @@ -149,6 +152,7 @@ class SearchRequest(_message.Message): uses_123_api: bool = ..., uses_125_api: bool = ..., uses_127_api: bool = ..., + uses_128_api: bool = ..., ) -> None: ... class GroupBy(_message.Message): @@ -647,6 +651,21 @@ class Rerank(_message.Message): query: str def __init__(self, property: _Optional[str] = ..., query: _Optional[str] = ...) -> None: ... +class ThirdPartyError(_message.Message): + __slots__ = ("provider_name", "error_from_provider", "full_error") + PROVIDER_NAME_FIELD_NUMBER: _ClassVar[int] + ERROR_FROM_PROVIDER_FIELD_NUMBER: _ClassVar[int] + FULL_ERROR_FIELD_NUMBER: _ClassVar[int] + provider_name: str + error_from_provider: str + full_error: str + def __init__( + self, + provider_name: _Optional[str] = ..., + error_from_provider: _Optional[str] = ..., + full_error: _Optional[str] = ..., + ) -> None: ... + class SearchReply(_message.Message): __slots__ = ( "took", @@ -654,17 +673,20 @@ class SearchReply(_message.Message): "generative_grouped_result", "group_by_results", "generative_grouped_results", + "third_party_error", ) TOOK_FIELD_NUMBER: _ClassVar[int] RESULTS_FIELD_NUMBER: _ClassVar[int] GENERATIVE_GROUPED_RESULT_FIELD_NUMBER: _ClassVar[int] GROUP_BY_RESULTS_FIELD_NUMBER: _ClassVar[int] GENERATIVE_GROUPED_RESULTS_FIELD_NUMBER: _ClassVar[int] + THIRD_PARTY_ERROR_FIELD_NUMBER: _ClassVar[int] took: float results: _containers.RepeatedCompositeFieldContainer[SearchResult] generative_grouped_result: str group_by_results: _containers.RepeatedCompositeFieldContainer[GroupByResult] generative_grouped_results: _generative_pb2.GenerativeResult + third_party_error: ThirdPartyError def __init__( self, took: _Optional[float] = ..., @@ -674,6 +696,7 @@ class SearchReply(_message.Message): generative_grouped_results: _Optional[ _Union[_generative_pb2.GenerativeResult, _Mapping] ] = ..., + third_party_error: _Optional[_Union[ThirdPartyError, _Mapping]] = ..., ) -> None: ... class RerankReply(_message.Message): From 09e30ed9e3d5155aebfe31f91459a608d2973d78 Mon Sep 17 00:00:00 2001 From: Dirk Kulawiak Date: Wed, 23 Oct 2024 15:14:35 +0200 Subject: [PATCH 3/4] latest adaption --- weaviate/collections/grpc/query.py | 2 ++ weaviate/exceptions.py | 14 ++++++++-- weaviate/proto/v1/search_get_pb2.py | 38 ++++++++++++++-------------- weaviate/proto/v1/search_get_pb2.pyi | 8 +++++- 4 files changed, 40 insertions(+), 22 deletions(-) diff --git a/weaviate/collections/grpc/query.py b/weaviate/collections/grpc/query.py index 9b5eebdb3..d627d50c3 100644 --- a/weaviate/collections/grpc/query.py +++ b/weaviate/collections/grpc/query.py @@ -808,6 +808,8 @@ async def __call(self, request: search_get_pb2.SearchRequest) -> search_get_pb2. sr.third_party_error.full_error, sr.third_party_error.provider_name, sr.third_party_error.error_from_provider, + sr.third_party_error.status_code, + sr.third_party_error.request_id, "GRPC search", ) return sr diff --git a/weaviate/exceptions.py b/weaviate/exceptions.py index 5c8a62ab3..3ce04be14 100644 --- a/weaviate/exceptions.py +++ b/weaviate/exceptions.py @@ -240,14 +240,24 @@ class WeaviateQueryThirdPartyError(WeaviateQueryError): """Is raised if a query (either gRPC or GraphQL) to Weaviate fails in any way.""" def __init__( - self, full_error: str, provider_name: str, provider_error: str, protocol_type: str + self, + full_error: str, + provider_name: str, + provider_error: str, + error_code: int, + request_id: str, + protocol_type: str, ): + request_id_str = f"with request_id {request_id} " if request_id else "" + msg = f""" Full error message: {full_error} - Query failed due to an error with a third party service. + Query {request_id_str}failed due to an error with a third party service: Provider: {provider_name} + Error code: {error_code} Error from provider: {provider_error} + """ super().__init__(msg, protocol_type, False) self.message = msg diff --git a/weaviate/proto/v1/search_get_pb2.py b/weaviate/proto/v1/search_get_pb2.py index bb5f5fd1c..0231f9909 100644 --- a/weaviate/proto/v1/search_get_pb2.py +++ b/weaviate/proto/v1/search_get_pb2.py @@ -20,7 +20,7 @@ DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile( - b'\n\x13v1/search_get.proto\x12\x0bweaviate.v1\x1a\x1cgoogle/protobuf/struct.proto\x1a\rv1/base.proto\x1a\x13v1/generative.proto\x1a\x13v1/properties.proto"\xb2\x0b\n\rSearchRequest\x12\x12\n\ncollection\x18\x01 \x01(\t\x12\x0e\n\x06tenant\x18\n \x01(\t\x12=\n\x11\x63onsistency_level\x18\x0b \x01(\x0e\x32\x1d.weaviate.v1.ConsistencyLevelH\x00\x88\x01\x01\x12\x37\n\nproperties\x18\x14 \x01(\x0b\x32\x1e.weaviate.v1.PropertiesRequestH\x01\x88\x01\x01\x12\x33\n\x08metadata\x18\x15 \x01(\x0b\x32\x1c.weaviate.v1.MetadataRequestH\x02\x88\x01\x01\x12+\n\x08group_by\x18\x16 \x01(\x0b\x32\x14.weaviate.v1.GroupByH\x03\x88\x01\x01\x12\r\n\x05limit\x18\x1e \x01(\r\x12\x0e\n\x06offset\x18\x1f \x01(\r\x12\x0f\n\x07\x61utocut\x18 \x01(\r\x12\r\n\x05\x61\x66ter\x18! \x01(\t\x12$\n\x07sort_by\x18" \x03(\x0b\x32\x13.weaviate.v1.SortBy\x12*\n\x07\x66ilters\x18( \x01(\x0b\x32\x14.weaviate.v1.FiltersH\x04\x88\x01\x01\x12/\n\rhybrid_search\x18) \x01(\x0b\x32\x13.weaviate.v1.HybridH\x05\x88\x01\x01\x12+\n\x0b\x62m25_search\x18* \x01(\x0b\x32\x11.weaviate.v1.BM25H\x06\x88\x01\x01\x12\x31\n\x0bnear_vector\x18+ \x01(\x0b\x32\x17.weaviate.v1.NearVectorH\x07\x88\x01\x01\x12\x31\n\x0bnear_object\x18, \x01(\x0b\x32\x17.weaviate.v1.NearObjectH\x08\x88\x01\x01\x12\x33\n\tnear_text\x18- \x01(\x0b\x32\x1b.weaviate.v1.NearTextSearchH\t\x88\x01\x01\x12\x35\n\nnear_image\x18. \x01(\x0b\x32\x1c.weaviate.v1.NearImageSearchH\n\x88\x01\x01\x12\x35\n\nnear_audio\x18/ \x01(\x0b\x32\x1c.weaviate.v1.NearAudioSearchH\x0b\x88\x01\x01\x12\x35\n\nnear_video\x18\x30 \x01(\x0b\x32\x1c.weaviate.v1.NearVideoSearchH\x0c\x88\x01\x01\x12\x35\n\nnear_depth\x18\x31 \x01(\x0b\x32\x1c.weaviate.v1.NearDepthSearchH\r\x88\x01\x01\x12\x39\n\x0cnear_thermal\x18\x32 \x01(\x0b\x32\x1e.weaviate.v1.NearThermalSearchH\x0e\x88\x01\x01\x12\x31\n\x08near_imu\x18\x33 \x01(\x0b\x32\x1a.weaviate.v1.NearIMUSearchH\x0f\x88\x01\x01\x12\x36\n\ngenerative\x18< \x01(\x0b\x32\x1d.weaviate.v1.GenerativeSearchH\x10\x88\x01\x01\x12(\n\x06rerank\x18= \x01(\x0b\x32\x13.weaviate.v1.RerankH\x11\x88\x01\x01\x12\x18\n\x0cuses_123_api\x18\x64 \x01(\x08\x42\x02\x18\x01\x12\x18\n\x0cuses_125_api\x18\x65 \x01(\x08\x42\x02\x18\x01\x12\x14\n\x0cuses_127_api\x18\x66 \x01(\x08\x12\x14\n\x0cuses_128_api\x18g \x01(\x08\x42\x14\n\x12_consistency_levelB\r\n\x0b_propertiesB\x0b\n\t_metadataB\x0b\n\t_group_byB\n\n\x08_filtersB\x10\n\x0e_hybrid_searchB\x0e\n\x0c_bm25_searchB\x0e\n\x0c_near_vectorB\x0e\n\x0c_near_objectB\x0c\n\n_near_textB\r\n\x0b_near_imageB\r\n\x0b_near_audioB\r\n\x0b_near_videoB\r\n\x0b_near_depthB\x0f\n\r_near_thermalB\x0b\n\t_near_imuB\r\n\x0b_generativeB\t\n\x07_rerank"L\n\x07GroupBy\x12\x0c\n\x04path\x18\x01 \x03(\t\x12\x18\n\x10number_of_groups\x18\x02 \x01(\x05\x12\x19\n\x11objects_per_group\x18\x03 \x01(\x05")\n\x06SortBy\x12\x11\n\tascending\x18\x01 \x01(\x08\x12\x0c\n\x04path\x18\x02 \x03(\t"\xdd\x01\n\x0fMetadataRequest\x12\x0c\n\x04uuid\x18\x01 \x01(\x08\x12\x0e\n\x06vector\x18\x02 \x01(\x08\x12\x1a\n\x12\x63reation_time_unix\x18\x03 \x01(\x08\x12\x1d\n\x15last_update_time_unix\x18\x04 \x01(\x08\x12\x10\n\x08\x64istance\x18\x05 \x01(\x08\x12\x11\n\tcertainty\x18\x06 \x01(\x08\x12\r\n\x05score\x18\x07 \x01(\x08\x12\x15\n\rexplain_score\x18\x08 \x01(\x08\x12\x15\n\ris_consistent\x18\t \x01(\x08\x12\x0f\n\x07vectors\x18\n \x03(\t"\xd1\x01\n\x11PropertiesRequest\x12\x1a\n\x12non_ref_properties\x18\x01 \x03(\t\x12\x39\n\x0eref_properties\x18\x02 \x03(\x0b\x32!.weaviate.v1.RefPropertiesRequest\x12?\n\x11object_properties\x18\x03 \x03(\x0b\x32$.weaviate.v1.ObjectPropertiesRequest\x12$\n\x1creturn_all_nonref_properties\x18\x0b \x01(\x08"\x8b\x01\n\x17ObjectPropertiesRequest\x12\x11\n\tprop_name\x18\x01 \x01(\t\x12\x1c\n\x14primitive_properties\x18\x02 \x03(\t\x12?\n\x11object_properties\x18\x03 \x03(\x0b\x32$.weaviate.v1.ObjectPropertiesRequest"2\n\x10WeightsForTarget\x12\x0e\n\x06target\x18\x01 \x01(\t\x12\x0e\n\x06weight\x18\x02 \x01(\x02"\xfa\x01\n\x07Targets\x12\x16\n\x0etarget_vectors\x18\x01 \x03(\t\x12\x33\n\x0b\x63ombination\x18\x02 \x01(\x0e\x32\x1e.weaviate.v1.CombinationMethod\x12\x36\n\x07weights\x18\x03 \x03(\x0b\x32!.weaviate.v1.Targets.WeightsEntryB\x02\x18\x01\x12:\n\x13weights_for_targets\x18\x04 \x03(\x0b\x32\x1d.weaviate.v1.WeightsForTarget\x1a.\n\x0cWeightsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x02:\x02\x38\x01"\xc5\x03\n\x06Hybrid\x12\r\n\x05query\x18\x01 \x01(\t\x12\x12\n\nproperties\x18\x02 \x03(\t\x12\x12\n\x06vector\x18\x03 \x03(\x02\x42\x02\x18\x01\x12\r\n\x05\x61lpha\x18\x04 \x01(\x02\x12\x33\n\x0b\x66usion_type\x18\x05 \x01(\x0e\x32\x1e.weaviate.v1.Hybrid.FusionType\x12\x14\n\x0cvector_bytes\x18\x06 \x01(\x0c\x12\x1a\n\x0etarget_vectors\x18\x07 \x03(\tB\x02\x18\x01\x12.\n\tnear_text\x18\x08 \x01(\x0b\x32\x1b.weaviate.v1.NearTextSearch\x12,\n\x0bnear_vector\x18\t \x01(\x0b\x32\x17.weaviate.v1.NearVector\x12%\n\x07targets\x18\n \x01(\x0b\x32\x14.weaviate.v1.Targets\x12\x19\n\x0fvector_distance\x18\x14 \x01(\x02H\x00"a\n\nFusionType\x12\x1b\n\x17\x46USION_TYPE_UNSPECIFIED\x10\x00\x12\x16\n\x12\x46USION_TYPE_RANKED\x10\x01\x12\x1e\n\x1a\x46USION_TYPE_RELATIVE_SCORE\x10\x02\x42\x0b\n\tthreshold"\xf0\x02\n\x0eNearTextSearch\x12\r\n\x05query\x18\x01 \x03(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x36\n\x07move_to\x18\x04 \x01(\x0b\x32 .weaviate.v1.NearTextSearch.MoveH\x02\x88\x01\x01\x12\x38\n\tmove_away\x18\x05 \x01(\x0b\x32 .weaviate.v1.NearTextSearch.MoveH\x03\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x06 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x07 \x01(\x0b\x32\x14.weaviate.v1.Targets\x1a\x36\n\x04Move\x12\r\n\x05\x66orce\x18\x01 \x01(\x02\x12\x10\n\x08\x63oncepts\x18\x02 \x03(\t\x12\r\n\x05uuids\x18\x03 \x03(\tB\x0c\n\n_certaintyB\x0b\n\t_distanceB\n\n\x08_move_toB\x0c\n\n_move_away"\xad\x01\n\x0fNearImageSearch\x12\r\n\x05image\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xad\x01\n\x0fNearAudioSearch\x12\r\n\x05\x61udio\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xad\x01\n\x0fNearVideoSearch\x12\r\n\x05video\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xad\x01\n\x0fNearDepthSearch\x12\r\n\x05\x64\x65pth\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xb1\x01\n\x11NearThermalSearch\x12\x0f\n\x07thermal\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xa9\x01\n\rNearIMUSearch\x12\x0b\n\x03imu\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance")\n\x04\x42M25\x12\r\n\x05query\x18\x01 \x01(\t\x12\x12\n\nproperties\x18\x02 \x03(\t"\xb1\x01\n\x14RefPropertiesRequest\x12\x1a\n\x12reference_property\x18\x01 \x01(\t\x12\x32\n\nproperties\x18\x02 \x01(\x0b\x32\x1e.weaviate.v1.PropertiesRequest\x12.\n\x08metadata\x18\x03 \x01(\x0b\x32\x1c.weaviate.v1.MetadataRequest\x12\x19\n\x11target_collection\x18\x04 \x01(\t"5\n\x0fVectorForTarget\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x14\n\x0cvector_bytes\x18\x02 \x01(\x0c"\x82\x03\n\nNearVector\x12\x12\n\x06vector\x18\x01 \x03(\x02\x42\x02\x18\x01\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x14\n\x0cvector_bytes\x18\x04 \x01(\x0c\x12\x1a\n\x0etarget_vectors\x18\x05 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x06 \x01(\x0b\x32\x14.weaviate.v1.Targets\x12K\n\x11vector_per_target\x18\x07 \x03(\x0b\x32,.weaviate.v1.NearVector.VectorPerTargetEntryB\x02\x18\x01\x12\x38\n\x12vector_for_targets\x18\x08 \x03(\x0b\x32\x1c.weaviate.v1.VectorForTarget\x1a\x36\n\x14VectorPerTargetEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x0c:\x02\x38\x01\x42\x0c\n\n_certaintyB\x0b\n\t_distance"\xa5\x01\n\nNearObject\x12\n\n\x02id\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"8\n\x06Rerank\x12\x10\n\x08property\x18\x01 \x01(\t\x12\x12\n\x05query\x18\x02 \x01(\tH\x00\x88\x01\x01\x42\x08\n\x06_query"Y\n\x0fThirdPartyError\x12\x15\n\rprovider_name\x18\x01 \x01(\t\x12\x1b\n\x13\x65rror_from_provider\x18\x02 \x01(\t\x12\x12\n\nfull_error\x18\x03 \x01(\t"\xf3\x02\n\x0bSearchReply\x12\x0c\n\x04took\x18\x01 \x01(\x02\x12*\n\x07results\x18\x02 \x03(\x0b\x32\x19.weaviate.v1.SearchResult\x12*\n\x19generative_grouped_result\x18\x03 \x01(\tB\x02\x18\x01H\x01\x88\x01\x01\x12\x34\n\x10group_by_results\x18\x04 \x03(\x0b\x32\x1a.weaviate.v1.GroupByResult\x12\x46\n\x1agenerative_grouped_results\x18\x05 \x01(\x0b\x32\x1d.weaviate.v1.GenerativeResultH\x02\x88\x01\x01\x12\x39\n\x11third_party_error\x18\x06 \x01(\x0b\x32\x1c.weaviate.v1.ThirdPartyErrorH\x00\x42\x08\n\x06\x65rrorsB\x1c\n\x1a_generative_grouped_resultB\x1d\n\x1b_generative_grouped_results"\x1c\n\x0bRerankReply\x12\r\n\x05score\x18\x01 \x01(\x01"\xe9\x02\n\rGroupByResult\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x14\n\x0cmin_distance\x18\x02 \x01(\x02\x12\x14\n\x0cmax_distance\x18\x03 \x01(\x02\x12\x19\n\x11number_of_objects\x18\x04 \x01(\x03\x12*\n\x07objects\x18\x05 \x03(\x0b\x32\x19.weaviate.v1.SearchResult\x12-\n\x06rerank\x18\x06 \x01(\x0b\x32\x18.weaviate.v1.RerankReplyH\x00\x88\x01\x01\x12\x39\n\ngenerative\x18\x07 \x01(\x0b\x32\x1c.weaviate.v1.GenerativeReplyB\x02\x18\x01H\x01\x88\x01\x01\x12=\n\x11generative_result\x18\x08 \x01(\x0b\x32\x1d.weaviate.v1.GenerativeResultH\x02\x88\x01\x01\x42\t\n\x07_rerankB\r\n\x0b_generativeB\x14\n\x12_generative_result"\xb7\x01\n\x0cSearchResult\x12\x31\n\nproperties\x18\x01 \x01(\x0b\x32\x1d.weaviate.v1.PropertiesResult\x12-\n\x08metadata\x18\x02 \x01(\x0b\x32\x1b.weaviate.v1.MetadataResult\x12\x36\n\ngenerative\x18\x03 \x01(\x0b\x32\x1d.weaviate.v1.GenerativeResultH\x00\x88\x01\x01\x42\r\n\x0b_generative"\xf7\x04\n\x0eMetadataResult\x12\n\n\x02id\x18\x01 \x01(\t\x12\x12\n\x06vector\x18\x02 \x03(\x02\x42\x02\x18\x01\x12\x1a\n\x12\x63reation_time_unix\x18\x03 \x01(\x03\x12"\n\x1a\x63reation_time_unix_present\x18\x04 \x01(\x08\x12\x1d\n\x15last_update_time_unix\x18\x05 \x01(\x03\x12%\n\x1dlast_update_time_unix_present\x18\x06 \x01(\x08\x12\x10\n\x08\x64istance\x18\x07 \x01(\x02\x12\x18\n\x10\x64istance_present\x18\x08 \x01(\x08\x12\x11\n\tcertainty\x18\t \x01(\x02\x12\x19\n\x11\x63\x65rtainty_present\x18\n \x01(\x08\x12\r\n\x05score\x18\x0b \x01(\x02\x12\x15\n\rscore_present\x18\x0c \x01(\x08\x12\x15\n\rexplain_score\x18\r \x01(\t\x12\x1d\n\x15\x65xplain_score_present\x18\x0e \x01(\x08\x12\x1a\n\ris_consistent\x18\x0f \x01(\x08H\x00\x88\x01\x01\x12\x16\n\ngenerative\x18\x10 \x01(\tB\x02\x18\x01\x12\x1e\n\x12generative_present\x18\x11 \x01(\x08\x42\x02\x18\x01\x12\x1d\n\x15is_consistent_present\x18\x12 \x01(\x08\x12\x14\n\x0cvector_bytes\x18\x13 \x01(\x0c\x12\x13\n\x0bid_as_bytes\x18\x14 \x01(\x0c\x12\x14\n\x0crerank_score\x18\x15 \x01(\x01\x12\x1c\n\x14rerank_score_present\x18\x16 \x01(\x08\x12%\n\x07vectors\x18\x17 \x03(\x0b\x32\x14.weaviate.v1.VectorsB\x10\n\x0e_is_consistent"\xba\x05\n\x10PropertiesResult\x12\x37\n\x12non_ref_properties\x18\x01 \x01(\x0b\x32\x17.google.protobuf.StructB\x02\x18\x01\x12\x33\n\tref_props\x18\x02 \x03(\x0b\x32 .weaviate.v1.RefPropertiesResult\x12\x19\n\x11target_collection\x18\x03 \x01(\t\x12-\n\x08metadata\x18\x04 \x01(\x0b\x32\x1b.weaviate.v1.MetadataResult\x12G\n\x17number_array_properties\x18\x05 \x03(\x0b\x32".weaviate.v1.NumberArrayPropertiesB\x02\x18\x01\x12\x41\n\x14int_array_properties\x18\x06 \x03(\x0b\x32\x1f.weaviate.v1.IntArrayPropertiesB\x02\x18\x01\x12\x43\n\x15text_array_properties\x18\x07 \x03(\x0b\x32 .weaviate.v1.TextArrayPropertiesB\x02\x18\x01\x12I\n\x18\x62oolean_array_properties\x18\x08 \x03(\x0b\x32#.weaviate.v1.BooleanArrayPropertiesB\x02\x18\x01\x12<\n\x11object_properties\x18\t \x03(\x0b\x32\x1d.weaviate.v1.ObjectPropertiesB\x02\x18\x01\x12G\n\x17object_array_properties\x18\n \x03(\x0b\x32".weaviate.v1.ObjectArrayPropertiesB\x02\x18\x01\x12.\n\rnon_ref_props\x18\x0b \x01(\x0b\x32\x17.weaviate.v1.Properties\x12\x1b\n\x13ref_props_requested\x18\x0c \x01(\x08"[\n\x13RefPropertiesResult\x12\x31\n\nproperties\x18\x01 \x03(\x0b\x32\x1d.weaviate.v1.PropertiesResult\x12\x11\n\tprop_name\x18\x02 \x01(\t*\xee\x01\n\x11\x43ombinationMethod\x12"\n\x1e\x43OMBINATION_METHOD_UNSPECIFIED\x10\x00\x12\x1f\n\x1b\x43OMBINATION_METHOD_TYPE_SUM\x10\x01\x12\x1f\n\x1b\x43OMBINATION_METHOD_TYPE_MIN\x10\x02\x12#\n\x1f\x43OMBINATION_METHOD_TYPE_AVERAGE\x10\x03\x12*\n&COMBINATION_METHOD_TYPE_RELATIVE_SCORE\x10\x04\x12"\n\x1e\x43OMBINATION_METHOD_TYPE_MANUAL\x10\x05\x42s\n#io.weaviate.client.grpc.protocol.v1B\x16WeaviateProtoSearchGetZ4github.com/weaviate/weaviate/grpc/generated;protocolb\x06proto3' + b'\n\x13v1/search_get.proto\x12\x0bweaviate.v1\x1a\x1cgoogle/protobuf/struct.proto\x1a\rv1/base.proto\x1a\x13v1/generative.proto\x1a\x13v1/properties.proto"\xb2\x0b\n\rSearchRequest\x12\x12\n\ncollection\x18\x01 \x01(\t\x12\x0e\n\x06tenant\x18\n \x01(\t\x12=\n\x11\x63onsistency_level\x18\x0b \x01(\x0e\x32\x1d.weaviate.v1.ConsistencyLevelH\x00\x88\x01\x01\x12\x37\n\nproperties\x18\x14 \x01(\x0b\x32\x1e.weaviate.v1.PropertiesRequestH\x01\x88\x01\x01\x12\x33\n\x08metadata\x18\x15 \x01(\x0b\x32\x1c.weaviate.v1.MetadataRequestH\x02\x88\x01\x01\x12+\n\x08group_by\x18\x16 \x01(\x0b\x32\x14.weaviate.v1.GroupByH\x03\x88\x01\x01\x12\r\n\x05limit\x18\x1e \x01(\r\x12\x0e\n\x06offset\x18\x1f \x01(\r\x12\x0f\n\x07\x61utocut\x18 \x01(\r\x12\r\n\x05\x61\x66ter\x18! \x01(\t\x12$\n\x07sort_by\x18" \x03(\x0b\x32\x13.weaviate.v1.SortBy\x12*\n\x07\x66ilters\x18( \x01(\x0b\x32\x14.weaviate.v1.FiltersH\x04\x88\x01\x01\x12/\n\rhybrid_search\x18) \x01(\x0b\x32\x13.weaviate.v1.HybridH\x05\x88\x01\x01\x12+\n\x0b\x62m25_search\x18* \x01(\x0b\x32\x11.weaviate.v1.BM25H\x06\x88\x01\x01\x12\x31\n\x0bnear_vector\x18+ \x01(\x0b\x32\x17.weaviate.v1.NearVectorH\x07\x88\x01\x01\x12\x31\n\x0bnear_object\x18, \x01(\x0b\x32\x17.weaviate.v1.NearObjectH\x08\x88\x01\x01\x12\x33\n\tnear_text\x18- \x01(\x0b\x32\x1b.weaviate.v1.NearTextSearchH\t\x88\x01\x01\x12\x35\n\nnear_image\x18. \x01(\x0b\x32\x1c.weaviate.v1.NearImageSearchH\n\x88\x01\x01\x12\x35\n\nnear_audio\x18/ \x01(\x0b\x32\x1c.weaviate.v1.NearAudioSearchH\x0b\x88\x01\x01\x12\x35\n\nnear_video\x18\x30 \x01(\x0b\x32\x1c.weaviate.v1.NearVideoSearchH\x0c\x88\x01\x01\x12\x35\n\nnear_depth\x18\x31 \x01(\x0b\x32\x1c.weaviate.v1.NearDepthSearchH\r\x88\x01\x01\x12\x39\n\x0cnear_thermal\x18\x32 \x01(\x0b\x32\x1e.weaviate.v1.NearThermalSearchH\x0e\x88\x01\x01\x12\x31\n\x08near_imu\x18\x33 \x01(\x0b\x32\x1a.weaviate.v1.NearIMUSearchH\x0f\x88\x01\x01\x12\x36\n\ngenerative\x18< \x01(\x0b\x32\x1d.weaviate.v1.GenerativeSearchH\x10\x88\x01\x01\x12(\n\x06rerank\x18= \x01(\x0b\x32\x13.weaviate.v1.RerankH\x11\x88\x01\x01\x12\x18\n\x0cuses_123_api\x18\x64 \x01(\x08\x42\x02\x18\x01\x12\x18\n\x0cuses_125_api\x18\x65 \x01(\x08\x42\x02\x18\x01\x12\x14\n\x0cuses_127_api\x18\x66 \x01(\x08\x12\x14\n\x0cuses_128_api\x18g \x01(\x08\x42\x14\n\x12_consistency_levelB\r\n\x0b_propertiesB\x0b\n\t_metadataB\x0b\n\t_group_byB\n\n\x08_filtersB\x10\n\x0e_hybrid_searchB\x0e\n\x0c_bm25_searchB\x0e\n\x0c_near_vectorB\x0e\n\x0c_near_objectB\x0c\n\n_near_textB\r\n\x0b_near_imageB\r\n\x0b_near_audioB\r\n\x0b_near_videoB\r\n\x0b_near_depthB\x0f\n\r_near_thermalB\x0b\n\t_near_imuB\r\n\x0b_generativeB\t\n\x07_rerank"L\n\x07GroupBy\x12\x0c\n\x04path\x18\x01 \x03(\t\x12\x18\n\x10number_of_groups\x18\x02 \x01(\x05\x12\x19\n\x11objects_per_group\x18\x03 \x01(\x05")\n\x06SortBy\x12\x11\n\tascending\x18\x01 \x01(\x08\x12\x0c\n\x04path\x18\x02 \x03(\t"\xdd\x01\n\x0fMetadataRequest\x12\x0c\n\x04uuid\x18\x01 \x01(\x08\x12\x0e\n\x06vector\x18\x02 \x01(\x08\x12\x1a\n\x12\x63reation_time_unix\x18\x03 \x01(\x08\x12\x1d\n\x15last_update_time_unix\x18\x04 \x01(\x08\x12\x10\n\x08\x64istance\x18\x05 \x01(\x08\x12\x11\n\tcertainty\x18\x06 \x01(\x08\x12\r\n\x05score\x18\x07 \x01(\x08\x12\x15\n\rexplain_score\x18\x08 \x01(\x08\x12\x15\n\ris_consistent\x18\t \x01(\x08\x12\x0f\n\x07vectors\x18\n \x03(\t"\xd1\x01\n\x11PropertiesRequest\x12\x1a\n\x12non_ref_properties\x18\x01 \x03(\t\x12\x39\n\x0eref_properties\x18\x02 \x03(\x0b\x32!.weaviate.v1.RefPropertiesRequest\x12?\n\x11object_properties\x18\x03 \x03(\x0b\x32$.weaviate.v1.ObjectPropertiesRequest\x12$\n\x1creturn_all_nonref_properties\x18\x0b \x01(\x08"\x8b\x01\n\x17ObjectPropertiesRequest\x12\x11\n\tprop_name\x18\x01 \x01(\t\x12\x1c\n\x14primitive_properties\x18\x02 \x03(\t\x12?\n\x11object_properties\x18\x03 \x03(\x0b\x32$.weaviate.v1.ObjectPropertiesRequest"2\n\x10WeightsForTarget\x12\x0e\n\x06target\x18\x01 \x01(\t\x12\x0e\n\x06weight\x18\x02 \x01(\x02"\xfa\x01\n\x07Targets\x12\x16\n\x0etarget_vectors\x18\x01 \x03(\t\x12\x33\n\x0b\x63ombination\x18\x02 \x01(\x0e\x32\x1e.weaviate.v1.CombinationMethod\x12\x36\n\x07weights\x18\x03 \x03(\x0b\x32!.weaviate.v1.Targets.WeightsEntryB\x02\x18\x01\x12:\n\x13weights_for_targets\x18\x04 \x03(\x0b\x32\x1d.weaviate.v1.WeightsForTarget\x1a.\n\x0cWeightsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x02:\x02\x38\x01"\xc5\x03\n\x06Hybrid\x12\r\n\x05query\x18\x01 \x01(\t\x12\x12\n\nproperties\x18\x02 \x03(\t\x12\x12\n\x06vector\x18\x03 \x03(\x02\x42\x02\x18\x01\x12\r\n\x05\x61lpha\x18\x04 \x01(\x02\x12\x33\n\x0b\x66usion_type\x18\x05 \x01(\x0e\x32\x1e.weaviate.v1.Hybrid.FusionType\x12\x14\n\x0cvector_bytes\x18\x06 \x01(\x0c\x12\x1a\n\x0etarget_vectors\x18\x07 \x03(\tB\x02\x18\x01\x12.\n\tnear_text\x18\x08 \x01(\x0b\x32\x1b.weaviate.v1.NearTextSearch\x12,\n\x0bnear_vector\x18\t \x01(\x0b\x32\x17.weaviate.v1.NearVector\x12%\n\x07targets\x18\n \x01(\x0b\x32\x14.weaviate.v1.Targets\x12\x19\n\x0fvector_distance\x18\x14 \x01(\x02H\x00"a\n\nFusionType\x12\x1b\n\x17\x46USION_TYPE_UNSPECIFIED\x10\x00\x12\x16\n\x12\x46USION_TYPE_RANKED\x10\x01\x12\x1e\n\x1a\x46USION_TYPE_RELATIVE_SCORE\x10\x02\x42\x0b\n\tthreshold"\xf0\x02\n\x0eNearTextSearch\x12\r\n\x05query\x18\x01 \x03(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x36\n\x07move_to\x18\x04 \x01(\x0b\x32 .weaviate.v1.NearTextSearch.MoveH\x02\x88\x01\x01\x12\x38\n\tmove_away\x18\x05 \x01(\x0b\x32 .weaviate.v1.NearTextSearch.MoveH\x03\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x06 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x07 \x01(\x0b\x32\x14.weaviate.v1.Targets\x1a\x36\n\x04Move\x12\r\n\x05\x66orce\x18\x01 \x01(\x02\x12\x10\n\x08\x63oncepts\x18\x02 \x03(\t\x12\r\n\x05uuids\x18\x03 \x03(\tB\x0c\n\n_certaintyB\x0b\n\t_distanceB\n\n\x08_move_toB\x0c\n\n_move_away"\xad\x01\n\x0fNearImageSearch\x12\r\n\x05image\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xad\x01\n\x0fNearAudioSearch\x12\r\n\x05\x61udio\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xad\x01\n\x0fNearVideoSearch\x12\r\n\x05video\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xad\x01\n\x0fNearDepthSearch\x12\r\n\x05\x64\x65pth\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xb1\x01\n\x11NearThermalSearch\x12\x0f\n\x07thermal\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"\xa9\x01\n\rNearIMUSearch\x12\x0b\n\x03imu\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance")\n\x04\x42M25\x12\r\n\x05query\x18\x01 \x01(\t\x12\x12\n\nproperties\x18\x02 \x03(\t"\xb1\x01\n\x14RefPropertiesRequest\x12\x1a\n\x12reference_property\x18\x01 \x01(\t\x12\x32\n\nproperties\x18\x02 \x01(\x0b\x32\x1e.weaviate.v1.PropertiesRequest\x12.\n\x08metadata\x18\x03 \x01(\x0b\x32\x1c.weaviate.v1.MetadataRequest\x12\x19\n\x11target_collection\x18\x04 \x01(\t"5\n\x0fVectorForTarget\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x14\n\x0cvector_bytes\x18\x02 \x01(\x0c"\x82\x03\n\nNearVector\x12\x12\n\x06vector\x18\x01 \x03(\x02\x42\x02\x18\x01\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x14\n\x0cvector_bytes\x18\x04 \x01(\x0c\x12\x1a\n\x0etarget_vectors\x18\x05 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x06 \x01(\x0b\x32\x14.weaviate.v1.Targets\x12K\n\x11vector_per_target\x18\x07 \x03(\x0b\x32,.weaviate.v1.NearVector.VectorPerTargetEntryB\x02\x18\x01\x12\x38\n\x12vector_for_targets\x18\x08 \x03(\x0b\x32\x1c.weaviate.v1.VectorForTarget\x1a\x36\n\x14VectorPerTargetEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\x0c:\x02\x38\x01\x42\x0c\n\n_certaintyB\x0b\n\t_distance"\xa5\x01\n\nNearObject\x12\n\n\x02id\x18\x01 \x01(\t\x12\x16\n\tcertainty\x18\x02 \x01(\x01H\x00\x88\x01\x01\x12\x15\n\x08\x64istance\x18\x03 \x01(\x01H\x01\x88\x01\x01\x12\x1a\n\x0etarget_vectors\x18\x04 \x03(\tB\x02\x18\x01\x12%\n\x07targets\x18\x05 \x01(\x0b\x32\x14.weaviate.v1.TargetsB\x0c\n\n_certaintyB\x0b\n\t_distance"8\n\x06Rerank\x12\x10\n\x08property\x18\x01 \x01(\t\x12\x12\n\x05query\x18\x02 \x01(\tH\x00\x88\x01\x01\x42\x08\n\x06_query"\x82\x01\n\x0fThirdPartyError\x12\x15\n\rprovider_name\x18\x01 \x01(\t\x12\x1b\n\x13\x65rror_from_provider\x18\x02 \x01(\t\x12\x12\n\nfull_error\x18\x03 \x01(\t\x12\x13\n\x0bstatus_code\x18\x04 \x01(\x05\x12\x12\n\nrequest_id\x18\x05 \x01(\t"\xf3\x02\n\x0bSearchReply\x12\x0c\n\x04took\x18\x01 \x01(\x02\x12*\n\x07results\x18\x02 \x03(\x0b\x32\x19.weaviate.v1.SearchResult\x12*\n\x19generative_grouped_result\x18\x03 \x01(\tB\x02\x18\x01H\x01\x88\x01\x01\x12\x34\n\x10group_by_results\x18\x04 \x03(\x0b\x32\x1a.weaviate.v1.GroupByResult\x12\x46\n\x1agenerative_grouped_results\x18\x05 \x01(\x0b\x32\x1d.weaviate.v1.GenerativeResultH\x02\x88\x01\x01\x12\x39\n\x11third_party_error\x18\x06 \x01(\x0b\x32\x1c.weaviate.v1.ThirdPartyErrorH\x00\x42\x08\n\x06\x65rrorsB\x1c\n\x1a_generative_grouped_resultB\x1d\n\x1b_generative_grouped_results"\x1c\n\x0bRerankReply\x12\r\n\x05score\x18\x01 \x01(\x01"\xe9\x02\n\rGroupByResult\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x14\n\x0cmin_distance\x18\x02 \x01(\x02\x12\x14\n\x0cmax_distance\x18\x03 \x01(\x02\x12\x19\n\x11number_of_objects\x18\x04 \x01(\x03\x12*\n\x07objects\x18\x05 \x03(\x0b\x32\x19.weaviate.v1.SearchResult\x12-\n\x06rerank\x18\x06 \x01(\x0b\x32\x18.weaviate.v1.RerankReplyH\x00\x88\x01\x01\x12\x39\n\ngenerative\x18\x07 \x01(\x0b\x32\x1c.weaviate.v1.GenerativeReplyB\x02\x18\x01H\x01\x88\x01\x01\x12=\n\x11generative_result\x18\x08 \x01(\x0b\x32\x1d.weaviate.v1.GenerativeResultH\x02\x88\x01\x01\x42\t\n\x07_rerankB\r\n\x0b_generativeB\x14\n\x12_generative_result"\xb7\x01\n\x0cSearchResult\x12\x31\n\nproperties\x18\x01 \x01(\x0b\x32\x1d.weaviate.v1.PropertiesResult\x12-\n\x08metadata\x18\x02 \x01(\x0b\x32\x1b.weaviate.v1.MetadataResult\x12\x36\n\ngenerative\x18\x03 \x01(\x0b\x32\x1d.weaviate.v1.GenerativeResultH\x00\x88\x01\x01\x42\r\n\x0b_generative"\xf7\x04\n\x0eMetadataResult\x12\n\n\x02id\x18\x01 \x01(\t\x12\x12\n\x06vector\x18\x02 \x03(\x02\x42\x02\x18\x01\x12\x1a\n\x12\x63reation_time_unix\x18\x03 \x01(\x03\x12"\n\x1a\x63reation_time_unix_present\x18\x04 \x01(\x08\x12\x1d\n\x15last_update_time_unix\x18\x05 \x01(\x03\x12%\n\x1dlast_update_time_unix_present\x18\x06 \x01(\x08\x12\x10\n\x08\x64istance\x18\x07 \x01(\x02\x12\x18\n\x10\x64istance_present\x18\x08 \x01(\x08\x12\x11\n\tcertainty\x18\t \x01(\x02\x12\x19\n\x11\x63\x65rtainty_present\x18\n \x01(\x08\x12\r\n\x05score\x18\x0b \x01(\x02\x12\x15\n\rscore_present\x18\x0c \x01(\x08\x12\x15\n\rexplain_score\x18\r \x01(\t\x12\x1d\n\x15\x65xplain_score_present\x18\x0e \x01(\x08\x12\x1a\n\ris_consistent\x18\x0f \x01(\x08H\x00\x88\x01\x01\x12\x16\n\ngenerative\x18\x10 \x01(\tB\x02\x18\x01\x12\x1e\n\x12generative_present\x18\x11 \x01(\x08\x42\x02\x18\x01\x12\x1d\n\x15is_consistent_present\x18\x12 \x01(\x08\x12\x14\n\x0cvector_bytes\x18\x13 \x01(\x0c\x12\x13\n\x0bid_as_bytes\x18\x14 \x01(\x0c\x12\x14\n\x0crerank_score\x18\x15 \x01(\x01\x12\x1c\n\x14rerank_score_present\x18\x16 \x01(\x08\x12%\n\x07vectors\x18\x17 \x03(\x0b\x32\x14.weaviate.v1.VectorsB\x10\n\x0e_is_consistent"\xba\x05\n\x10PropertiesResult\x12\x37\n\x12non_ref_properties\x18\x01 \x01(\x0b\x32\x17.google.protobuf.StructB\x02\x18\x01\x12\x33\n\tref_props\x18\x02 \x03(\x0b\x32 .weaviate.v1.RefPropertiesResult\x12\x19\n\x11target_collection\x18\x03 \x01(\t\x12-\n\x08metadata\x18\x04 \x01(\x0b\x32\x1b.weaviate.v1.MetadataResult\x12G\n\x17number_array_properties\x18\x05 \x03(\x0b\x32".weaviate.v1.NumberArrayPropertiesB\x02\x18\x01\x12\x41\n\x14int_array_properties\x18\x06 \x03(\x0b\x32\x1f.weaviate.v1.IntArrayPropertiesB\x02\x18\x01\x12\x43\n\x15text_array_properties\x18\x07 \x03(\x0b\x32 .weaviate.v1.TextArrayPropertiesB\x02\x18\x01\x12I\n\x18\x62oolean_array_properties\x18\x08 \x03(\x0b\x32#.weaviate.v1.BooleanArrayPropertiesB\x02\x18\x01\x12<\n\x11object_properties\x18\t \x03(\x0b\x32\x1d.weaviate.v1.ObjectPropertiesB\x02\x18\x01\x12G\n\x17object_array_properties\x18\n \x03(\x0b\x32".weaviate.v1.ObjectArrayPropertiesB\x02\x18\x01\x12.\n\rnon_ref_props\x18\x0b \x01(\x0b\x32\x17.weaviate.v1.Properties\x12\x1b\n\x13ref_props_requested\x18\x0c \x01(\x08"[\n\x13RefPropertiesResult\x12\x31\n\nproperties\x18\x01 \x03(\x0b\x32\x1d.weaviate.v1.PropertiesResult\x12\x11\n\tprop_name\x18\x02 \x01(\t*\xee\x01\n\x11\x43ombinationMethod\x12"\n\x1e\x43OMBINATION_METHOD_UNSPECIFIED\x10\x00\x12\x1f\n\x1b\x43OMBINATION_METHOD_TYPE_SUM\x10\x01\x12\x1f\n\x1b\x43OMBINATION_METHOD_TYPE_MIN\x10\x02\x12#\n\x1f\x43OMBINATION_METHOD_TYPE_AVERAGE\x10\x03\x12*\n&COMBINATION_METHOD_TYPE_RELATIVE_SCORE\x10\x04\x12"\n\x1e\x43OMBINATION_METHOD_TYPE_MANUAL\x10\x05\x42s\n#io.weaviate.client.grpc.protocol.v1B\x16WeaviateProtoSearchGetZ4github.com/weaviate/weaviate/grpc/generated;protocolb\x06proto3' ) _globals = globals() @@ -111,8 +111,8 @@ _globals["_PROPERTIESRESULT"].fields_by_name[ "object_array_properties" ]._serialized_options = b"\030\001" - _globals["_COMBINATIONMETHOD"]._serialized_start = 7838 - _globals["_COMBINATIONMETHOD"]._serialized_end = 8076 + _globals["_COMBINATIONMETHOD"]._serialized_start = 7880 + _globals["_COMBINATIONMETHOD"]._serialized_end = 8118 _globals["_SEARCHREQUEST"]._serialized_start = 124 _globals["_SEARCHREQUEST"]._serialized_end = 1582 _globals["_GROUPBY"]._serialized_start = 1584 @@ -165,20 +165,20 @@ _globals["_NEAROBJECT"]._serialized_end = 5304 _globals["_RERANK"]._serialized_start = 5306 _globals["_RERANK"]._serialized_end = 5362 - _globals["_THIRDPARTYERROR"]._serialized_start = 5364 - _globals["_THIRDPARTYERROR"]._serialized_end = 5453 - _globals["_SEARCHREPLY"]._serialized_start = 5456 - _globals["_SEARCHREPLY"]._serialized_end = 5827 - _globals["_RERANKREPLY"]._serialized_start = 5829 - _globals["_RERANKREPLY"]._serialized_end = 5857 - _globals["_GROUPBYRESULT"]._serialized_start = 5860 - _globals["_GROUPBYRESULT"]._serialized_end = 6221 - _globals["_SEARCHRESULT"]._serialized_start = 6224 - _globals["_SEARCHRESULT"]._serialized_end = 6407 - _globals["_METADATARESULT"]._serialized_start = 6410 - _globals["_METADATARESULT"]._serialized_end = 7041 - _globals["_PROPERTIESRESULT"]._serialized_start = 7044 - _globals["_PROPERTIESRESULT"]._serialized_end = 7742 - _globals["_REFPROPERTIESRESULT"]._serialized_start = 7744 - _globals["_REFPROPERTIESRESULT"]._serialized_end = 7835 + _globals["_THIRDPARTYERROR"]._serialized_start = 5365 + _globals["_THIRDPARTYERROR"]._serialized_end = 5495 + _globals["_SEARCHREPLY"]._serialized_start = 5498 + _globals["_SEARCHREPLY"]._serialized_end = 5869 + _globals["_RERANKREPLY"]._serialized_start = 5871 + _globals["_RERANKREPLY"]._serialized_end = 5899 + _globals["_GROUPBYRESULT"]._serialized_start = 5902 + _globals["_GROUPBYRESULT"]._serialized_end = 6263 + _globals["_SEARCHRESULT"]._serialized_start = 6266 + _globals["_SEARCHRESULT"]._serialized_end = 6449 + _globals["_METADATARESULT"]._serialized_start = 6452 + _globals["_METADATARESULT"]._serialized_end = 7083 + _globals["_PROPERTIESRESULT"]._serialized_start = 7086 + _globals["_PROPERTIESRESULT"]._serialized_end = 7784 + _globals["_REFPROPERTIESRESULT"]._serialized_start = 7786 + _globals["_REFPROPERTIESRESULT"]._serialized_end = 7877 # @@protoc_insertion_point(module_scope) diff --git a/weaviate/proto/v1/search_get_pb2.pyi b/weaviate/proto/v1/search_get_pb2.pyi index 4154c74f4..d3638dd12 100644 --- a/weaviate/proto/v1/search_get_pb2.pyi +++ b/weaviate/proto/v1/search_get_pb2.pyi @@ -652,18 +652,24 @@ class Rerank(_message.Message): def __init__(self, property: _Optional[str] = ..., query: _Optional[str] = ...) -> None: ... class ThirdPartyError(_message.Message): - __slots__ = ("provider_name", "error_from_provider", "full_error") + __slots__ = ("provider_name", "error_from_provider", "full_error", "status_code", "request_id") PROVIDER_NAME_FIELD_NUMBER: _ClassVar[int] ERROR_FROM_PROVIDER_FIELD_NUMBER: _ClassVar[int] FULL_ERROR_FIELD_NUMBER: _ClassVar[int] + STATUS_CODE_FIELD_NUMBER: _ClassVar[int] + REQUEST_ID_FIELD_NUMBER: _ClassVar[int] provider_name: str error_from_provider: str full_error: str + status_code: int + request_id: str def __init__( self, provider_name: _Optional[str] = ..., error_from_provider: _Optional[str] = ..., full_error: _Optional[str] = ..., + status_code: _Optional[int] = ..., + request_id: _Optional[str] = ..., ) -> None: ... class SearchReply(_message.Message): From 235783d130c5495d0b5448eea99937006d4281f0 Mon Sep 17 00:00:00 2001 From: Dirk Kulawiak Date: Thu, 24 Oct 2024 06:38:08 +0200 Subject: [PATCH 4/4] Fixup error detection in client --- weaviate/collections/grpc/query.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/weaviate/collections/grpc/query.py b/weaviate/collections/grpc/query.py index d627d50c3..c7be1ea16 100644 --- a/weaviate/collections/grpc/query.py +++ b/weaviate/collections/grpc/query.py @@ -803,7 +803,7 @@ async def __call(self, request: search_get_pb2.SearchRequest) -> search_get_pb2. timeout=self._connection.timeout_config.query, ) sr = cast(search_get_pb2.SearchReply, res) - if sr.third_party_error is not None: + if sr.third_party_error is not None and sr.third_party_error.provider_name != "": raise WeaviateQueryThirdPartyError( sr.third_party_error.full_error, sr.third_party_error.provider_name,