# Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT! """Client and server classes corresponding to protobuf-defined services.""" import grpc import warnings from . import voice_agent_pb2 as voice__agent__pb2 GRPC_GENERATED_VERSION = '1.65.0rc1' GRPC_VERSION = grpc.__version__ EXPECTED_ERROR_RELEASE = '1.65.0' SCHEDULED_RELEASE_DATE = 'June 25, 2024' _version_not_supported = False try: from grpc._utilities import first_version_is_lower _version_not_supported = first_version_is_lower(GRPC_VERSION, GRPC_GENERATED_VERSION) except ImportError: _version_not_supported = True if _version_not_supported: warnings.warn( f'The grpc package installed is at version {GRPC_VERSION},' + f' but the generated code in voice_agent_pb2_grpc.py depends on' + f' grpcio>={GRPC_GENERATED_VERSION}.' + f' Please upgrade your grpc module to grpcio>={GRPC_GENERATED_VERSION}' + f' or downgrade your generated code using grpcio-tools<={GRPC_VERSION}.' + f' This warning will become an error in {EXPECTED_ERROR_RELEASE},' + f' scheduled for release on {SCHEDULED_RELEASE_DATE}.', RuntimeWarning ) class VoiceAgentServiceStub(object): """Missing associated documentation comment in .proto file.""" def __init__(self, channel): """Constructor. Args: channel: A grpc.Channel. """ self.CheckServiceStatus = channel.unary_unary( '/VoiceAgentService/CheckServiceStatus', request_serializer=voice__agent__pb2.Empty.SerializeToString, response_deserializer=voice__agent__pb2.ServiceStatus.FromString, _registered_method=True) self.S_DetectWakeWord = channel.stream_stream( '/VoiceAgentService/S_DetectWakeWord', request_serializer=voice__agent__pb2.VoiceAudio.SerializeToString, response_deserializer=voice__agent__pb2.WakeWordStatus.FromString, _registered_method=True) self.DetectWakeWord = channel.unary_stream( '/VoiceAgentService/DetectWakeWord', request_serializer=voice__agent__pb2.Empty.SerializeToString, response_deserializer=voice__agent__pb2.WakeWordStatus.FromString, _registered_method=True) self.S_RecognizeVoiceCommand = channel.stream_unary( '/VoiceAgentService/S_RecognizeVoiceCommand', request_serializer=voice__agent__pb2.S_RecognizeVoiceControl.SerializeToString, response_deserializer=voice__agent__pb2.RecognizeResult.FromString, _registered_method=True) self.RecognizeVoiceCommand = channel.stream_unary( '/VoiceAgentService/RecognizeVoiceCommand', request_serializer=voice__agent__pb2.RecognizeVoiceControl.SerializeToString, response_deserializer=voice__agent__pb2.RecognizeResult.FromString, _registered_method=True) self.RecognizeTextCommand = channel.unary_unary( '/VoiceAgentService/RecognizeTextCommand', request_serializer=voice__agent__pb2.RecognizeTextControl.SerializeToString, response_deserializer=voice__agent__pb2.RecognizeResult.FromString, _registered_method=True) self.ExecuteCommand = channel.unary_unary( '/VoiceAgentService/ExecuteCommand', request_serializer=voice__agent__pb2.ExecuteInput.SerializeToString, response_deserializer=voice__agent__pb2.ExecuteResult.FromString, _registered_method=True) class VoiceAgentServiceServicer(object): """Missing associated documentation comment in .proto file.""" def CheckServiceStatus(self, request, context): """Missing associated documentation comment in .proto file.""" context.set_code(grpc.StatusCode.UNIMPLEMENTED) context.set_details('Method not implemented!') raise NotImplementedError('Method not implemented!') def S_DetectWakeWord(self, request_iterator, context): """Stream version of DetectWakeWord, assumes audio is coming from client """ context.set_code(grpc.StatusCode.UNIMPLEMENTED) context.set_details('Method not implemented!') raise NotImplementedError('Method not implemented!') def DetectWakeWord(self, request, context): """Missing associated documentation comment in .proto file.""" context.set_code(grpc.StatusCode.UNIMPLEMENTED) context.set_details('Method not implemented!') raise NotImplementedError('Method not implemented!') def S_RecognizeVoiceCommand(self, request_iterator, context): """Stream version of RecognizeVoiceCommand, assumes audio is coming from client """ context.set_code(grpc.StatusCode.UNIMPLEMENTED) context.set_details('Method not implemented!') raise NotImplementedError('Method not implemented!') def RecognizeVoiceCommand(self, request_iterator, context): """Missing associated documentation comment in .proto file.""" context.set_code(grpc.StatusCode.UNIMPLEMENTED) context.set_details('Method not implemented!') raise NotImplementedError('Method not implemented!') def RecognizeTextCommand(self, request, context): """Missing associated documentation comment in .proto file.""" context.set_code(grpc.StatusCode.UNIMPLEMENTED) context.set_details('Method not implemented!') raise NotImplementedError('Method not implemented!') def ExecuteCommand(self, request, context): """Missing associated documentation comment in .proto file.""" context.set_code(grpc.StatusCode.UNIMPLEMENTED) context.set_details('Method not implemented!') raise NotImplementedError('Method not implemented!') def add_VoiceAgentServiceServicer_to_server(servicer, server): rpc_method_handlers = { 'CheckServiceStatus': grpc.unary_unary_rpc_method_handler( servicer.CheckServiceStatus, request_deserializer=voice__agent__pb2.Empty.FromString, response_serializer=voice__agent__pb2.ServiceStatus.SerializeToString, ), 'S_DetectWakeWord': grpc.stream_stream_rpc_method_handler( servicer.S_DetectWakeWord, request_deserializer=voice__agent__pb2.VoiceAudio.FromString, response_serializer=voice__agent__pb2.WakeWordStatus.SerializeToString, ), 'DetectWakeWord': grpc.unary_stream_rpc_method_handler( servicer.DetectWakeWord, request_deserializer=voice__agent__pb2.Empty.FromString, response_serializer=voice__agent__pb2.WakeWordStatus.SerializeToString, ), 'S_RecognizeVoiceCommand': grpc.stream_unary_rpc_method_handler( servicer.S_RecognizeVoiceCommand, request_deserializer=voice__agent__pb2.S_RecognizeVoiceControl.FromString, response_serializer=voice__agent__pb2.RecognizeResult.SerializeToString, ), 'RecognizeVoiceCommand': grpc.stream_unary_rpc_method_handler( servicer.RecognizeVoiceCommand, request_deserializer=voice__agent__pb2.RecognizeVoiceControl.FromString, response_serializer=voice__agent__pb2.RecognizeResult.SerializeToString, ), 'RecognizeTextCommand': grpc.unary_unary_rpc_method_handler( servicer.RecognizeTextCommand, request_deserializer=voice__agent__pb2.RecognizeTextControl.FromString, response_serializer=voice__agent__pb2.RecognizeResult.SerializeToString, ), 'ExecuteCommand': grpc.unary_unary_rpc_method_handler( servicer.ExecuteCommand, request_deserializer=voice__agent__pb2.ExecuteInput.FromString, response_serializer=voice__agent__pb2.ExecuteResult.SerializeToString, ), } generic_handler = grpc.method_handlers_generic_handler( 'VoiceAgentService', rpc_method_handlers) server.add_generic_rpc_handlers((generic_handler,)) server.add_registered_method_handlers('VoiceAgentService', rpc_method_handlers) # This class is part of an EXPERIMENTAL API. class VoiceAgentService(object): """Missing associated documentation comment in .proto file.""" @staticmethod def CheckServiceStatus(request, target, options=(), channel_credentials=None, call_credentials=None, insecure=False, compression=None, wait_for_ready=None, timeout=None, metadata=None): return grpc.experimental.unary_unary( request, target, '/VoiceAgentService/CheckServiceStatus', voice__agent__pb2.Empty.SerializeToString, voice__agent__pb2.ServiceStatus.FromString, options, channel_credentials, insecure, call_credentials, compression, wait_for_ready, timeout, metadata, _registered_method=True) @staticmethod def S_DetectWakeWord(request_iterator, target, options=(), channel_credentials=None, call_credentials=None, insecure=False, compression=None, wait_for_ready=None, timeout=None, metadata=None): return grpc.experimental.stream_stream( request_iterator, target, '/VoiceAgentService/S_DetectWakeWord', voice__agent__pb2.VoiceAudio.SerializeToString, voice__agent__pb2.WakeWordStatus.FromString, options, channel_credentials, insecure, call_credentials, compression, wait_for_ready, timeout, metadata, _registered_method=True) @staticmethod def DetectWakeWord(request, target, options=(), channel_credentials=None, call_credentials=None, insecure=False, compression=None, wait_for_ready=None, timeout=None, metadata=None): return grpc.experimental.unary_stream( request, target, '/VoiceAgentService/DetectWakeWord', voice__agent__pb2.Empty.SerializeToString, voice__agent__pb2.WakeWordStatus.FromString, options, channel_credentials, insecure, call_credentials, compression, wait_for_ready, timeout, metadata, _registered_method=True) @staticmethod def S_RecognizeVoiceCommand(request_iterator, target, options=(), channel_credentials=None, call_credentials=None, insecure=False, compression=None, wait_for_ready=None, timeout=None, metadata=None): return grpc.experimental.stream_unary( request_iterator, target, '/VoiceAgentService/S_RecognizeVoiceCommand', voice__agent__pb2.S_RecognizeVoiceControl.SerializeToString, voice__agent__pb2.RecognizeResult.FromString, options, channel_credentials, insecure, call_credentials, compression, wait_for_ready, timeout, metadata, _registered_method=True) @staticmethod def RecognizeVoiceCommand(request_iterator, target, options=(), channel_credentials=None, call_credentials=None, insecure=False, compression=None, wait_for_ready=None, timeout=None, metadata=None): return grpc.experimental.stream_unary( request_iterator, target, '/VoiceAgentService/RecognizeVoiceCommand', voice__agent__pb2.RecognizeVoiceControl.SerializeToString, voice__agent__pb2.RecognizeResult.FromString, options, channel_credentials, insecure, call_credentials, compression, wait_for_ready, timeout, metadata, _registered_method=True) @staticmethod def RecognizeTextCommand(request, target, options=(), channel_credentials=None, call_credentials=None, insecure=False, compression=None, wait_for_ready=None, timeout=None, metadata=None): return grpc.experimental.unary_unary( request, target, '/VoiceAgentService/RecognizeTextCommand', voice__agent__pb2.RecognizeTextControl.SerializeToString, voice__agent__pb2.RecognizeResult.FromString, options, channel_credentials, insecure, call_credentials, compression, wait_for_ready, timeout, metadata, _registered_method=True) @staticmethod def ExecuteCommand(request, target, options=(), channel_credentials=None, call_credentials=None, insecure=False, compression=None, wait_for_ready=None, timeout=None, metadata=None): return grpc.experimental.unary_unary( request, target, '/VoiceAgentService/ExecuteCommand', voice__agent__pb2.ExecuteInput.SerializeToString, voice__agent__pb2.ExecuteResult.FromString, options, channel_credentials, insecure, call_credentials, compression, wait_for_ready, timeout, metadata, _registered_method=True)