"""
@generated by mypy-protobuf.  Do not edit manually!
isort:skip_file
"""

import builtins
import collections.abc
import google.protobuf.descriptor
import google.protobuf.field_mask_pb2
import google.protobuf.internal.containers
import google.protobuf.internal.enum_type_wrapper
import google.protobuf.message
import sys
import typing
import yandex.cloud.speechsense.v1.audio_pb2
import yandex.cloud.speechsense.v1.search_pb2
import yandex.cloud.speechsense.v1.talk_pb2
import yandex.cloud.speechsense.v1.text_pb2

if sys.version_info >= (3, 10):
    import typing as typing_extensions
else:
    import typing_extensions

DESCRIPTOR: google.protobuf.descriptor.FileDescriptor

class _UserRole:
    ValueType = typing.NewType("ValueType", builtins.int)
    V: typing_extensions.TypeAlias = ValueType

class _UserRoleEnumTypeWrapper(google.protobuf.internal.enum_type_wrapper._EnumTypeWrapper[_UserRole.ValueType], builtins.type):
    DESCRIPTOR: google.protobuf.descriptor.EnumDescriptor
    USER_ROLE_UNSPECIFIED: _UserRole.ValueType  # 0
    USER_ROLE_OPERATOR: _UserRole.ValueType  # 1
    USER_ROLE_CLIENT: _UserRole.ValueType  # 2
    USER_ROLE_BOT: _UserRole.ValueType  # 3

class UserRole(_UserRole, metaclass=_UserRoleEnumTypeWrapper): ...

USER_ROLE_UNSPECIFIED: UserRole.ValueType  # 0
USER_ROLE_OPERATOR: UserRole.ValueType  # 1
USER_ROLE_CLIENT: UserRole.ValueType  # 2
USER_ROLE_BOT: UserRole.ValueType  # 3
global___UserRole = UserRole

@typing.final
class StreamTalkRequest(google.protobuf.message.Message):
    """streaming request to create audio dialog"""

    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    METADATA_FIELD_NUMBER: builtins.int
    AUDIO_FIELD_NUMBER: builtins.int
    @property
    def metadata(self) -> global___TalkMetadata:
        """talk document metadata containing channel id and channel field values"""

    @property
    def audio(self) -> yandex.cloud.speechsense.v1.audio_pb2.AudioStreamingRequest:
        """audio metadata or chunk"""

    def __init__(
        self,
        *,
        metadata: global___TalkMetadata | None = ...,
        audio: yandex.cloud.speechsense.v1.audio_pb2.AudioStreamingRequest | None = ...,
    ) -> None: ...
    def HasField(self, field_name: typing.Literal["Event", b"Event", "audio", b"audio", "metadata", b"metadata"]) -> builtins.bool: ...
    def ClearField(self, field_name: typing.Literal["Event", b"Event", "audio", b"audio", "metadata", b"metadata"]) -> None: ...
    def WhichOneof(self, oneof_group: typing.Literal["Event", b"Event"]) -> typing.Literal["metadata", "audio"] | None: ...

global___StreamTalkRequest = StreamTalkRequest

@typing.final
class UploadTalkRequest(google.protobuf.message.Message):
    """request to create audio dialog"""

    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    TALK_ID_FIELD_NUMBER: builtins.int
    METADATA_FIELD_NUMBER: builtins.int
    AUDIO_FIELD_NUMBER: builtins.int
    talk_id: builtins.str
    """talk_id, blank if initial upload request and present on metadata update"""
    @property
    def metadata(self) -> global___TalkMetadata: ...
    @property
    def audio(self) -> yandex.cloud.speechsense.v1.audio_pb2.AudioRequest:
        """audio payload"""

    def __init__(
        self,
        *,
        talk_id: builtins.str = ...,
        metadata: global___TalkMetadata | None = ...,
        audio: yandex.cloud.speechsense.v1.audio_pb2.AudioRequest | None = ...,
    ) -> None: ...
    def HasField(self, field_name: typing.Literal["audio", b"audio", "metadata", b"metadata"]) -> builtins.bool: ...
    def ClearField(self, field_name: typing.Literal["audio", b"audio", "metadata", b"metadata", "talk_id", b"talk_id"]) -> None: ...

global___UploadTalkRequest = UploadTalkRequest

@typing.final
class UploadTalkResponse(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    TALK_ID_FIELD_NUMBER: builtins.int
    talk_id: builtins.str
    """id of created talk document"""
    def __init__(
        self,
        *,
        talk_id: builtins.str = ...,
    ) -> None: ...
    def ClearField(self, field_name: typing.Literal["talk_id", b"talk_id"]) -> None: ...

global___UploadTalkResponse = UploadTalkResponse

@typing.final
class UploadTextRequest(google.protobuf.message.Message):
    """request to create text based dialog"""

    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    TALK_ID_FIELD_NUMBER: builtins.int
    METADATA_FIELD_NUMBER: builtins.int
    TEXT_CONTENT_FIELD_NUMBER: builtins.int
    talk_id: builtins.str
    """talk_id, blank if initial upload request and present on metadata update"""
    @property
    def metadata(self) -> global___TalkMetadata: ...
    @property
    def text_content(self) -> yandex.cloud.speechsense.v1.text_pb2.TextContent: ...
    def __init__(
        self,
        *,
        talk_id: builtins.str = ...,
        metadata: global___TalkMetadata | None = ...,
        text_content: yandex.cloud.speechsense.v1.text_pb2.TextContent | None = ...,
    ) -> None: ...
    def HasField(self, field_name: typing.Literal["metadata", b"metadata", "text_content", b"text_content"]) -> builtins.bool: ...
    def ClearField(self, field_name: typing.Literal["metadata", b"metadata", "talk_id", b"talk_id", "text_content", b"text_content"]) -> None: ...

global___UploadTextRequest = UploadTextRequest

@typing.final
class UploadTextResponse(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    TALK_ID_FIELD_NUMBER: builtins.int
    talk_id: builtins.str
    """id of created talk document"""
    def __init__(
        self,
        *,
        talk_id: builtins.str = ...,
    ) -> None: ...
    def ClearField(self, field_name: typing.Literal["talk_id", b"talk_id"]) -> None: ...

global___UploadTextResponse = UploadTextResponse

@typing.final
class TalkMetadata(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    @typing.final
    class FieldsEntry(google.protobuf.message.Message):
        DESCRIPTOR: google.protobuf.descriptor.Descriptor

        KEY_FIELD_NUMBER: builtins.int
        VALUE_FIELD_NUMBER: builtins.int
        key: builtins.str
        value: builtins.str
        def __init__(
            self,
            *,
            key: builtins.str = ...,
            value: builtins.str = ...,
        ) -> None: ...
        def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...

    CONNECTION_ID_FIELD_NUMBER: builtins.int
    FIELDS_FIELD_NUMBER: builtins.int
    USERS_FIELD_NUMBER: builtins.int
    connection_id: builtins.str
    """id of connection this talk belongs too"""
    @property
    def fields(self) -> google.protobuf.internal.containers.ScalarMap[builtins.str, builtins.str]:
        """channel defined fields"""

    @property
    def users(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___UserMetadata]:
        """per user specific metadata"""

    def __init__(
        self,
        *,
        connection_id: builtins.str = ...,
        fields: collections.abc.Mapping[builtins.str, builtins.str] | None = ...,
        users: collections.abc.Iterable[global___UserMetadata] | None = ...,
    ) -> None: ...
    def ClearField(self, field_name: typing.Literal["connection_id", b"connection_id", "fields", b"fields", "users", b"users"]) -> None: ...

global___TalkMetadata = TalkMetadata

@typing.final
class UserMetadata(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    @typing.final
    class FieldsEntry(google.protobuf.message.Message):
        DESCRIPTOR: google.protobuf.descriptor.Descriptor

        KEY_FIELD_NUMBER: builtins.int
        VALUE_FIELD_NUMBER: builtins.int
        key: builtins.str
        value: builtins.str
        def __init__(
            self,
            *,
            key: builtins.str = ...,
            value: builtins.str = ...,
        ) -> None: ...
        def ClearField(self, field_name: typing.Literal["key", b"key", "value", b"value"]) -> None: ...

    ID_FIELD_NUMBER: builtins.int
    ROLE_FIELD_NUMBER: builtins.int
    FIELDS_FIELD_NUMBER: builtins.int
    id: builtins.str
    role: global___UserRole.ValueType
    @property
    def fields(self) -> google.protobuf.internal.containers.ScalarMap[builtins.str, builtins.str]: ...
    def __init__(
        self,
        *,
        id: builtins.str = ...,
        role: global___UserRole.ValueType = ...,
        fields: collections.abc.Mapping[builtins.str, builtins.str] | None = ...,
    ) -> None: ...
    def ClearField(self, field_name: typing.Literal["fields", b"fields", "id", b"id", "role", b"role"]) -> None: ...

global___UserMetadata = UserMetadata

@typing.final
class SearchTalkRequest(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    ORGANIZATION_ID_FIELD_NUMBER: builtins.int
    SPACE_ID_FIELD_NUMBER: builtins.int
    CONNECTION_ID_FIELD_NUMBER: builtins.int
    PROJECT_ID_FIELD_NUMBER: builtins.int
    FILTERS_FIELD_NUMBER: builtins.int
    QUERY_FIELD_NUMBER: builtins.int
    PAGE_SIZE_FIELD_NUMBER: builtins.int
    PAGE_TOKEN_FIELD_NUMBER: builtins.int
    SORT_DATA_FIELD_NUMBER: builtins.int
    organization_id: builtins.str
    """id of organization"""
    space_id: builtins.str
    """id of space"""
    connection_id: builtins.str
    """id of connection"""
    project_id: builtins.str
    """id of project"""
    page_size: builtins.int
    """page size, from 1 to 1000, default 100"""
    page_token: builtins.str
    """next page token, if page is not first"""
    @property
    def filters(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[yandex.cloud.speechsense.v1.search_pb2.Filter]:
        """metadata keys filters (user and system)"""

    @property
    def query(self) -> yandex.cloud.speechsense.v1.search_pb2.Query:
        """Full-text search query"""

    @property
    def sort_data(self) -> yandex.cloud.speechsense.v1.search_pb2.SortData:
        """talks sorting options"""

    def __init__(
        self,
        *,
        organization_id: builtins.str = ...,
        space_id: builtins.str = ...,
        connection_id: builtins.str = ...,
        project_id: builtins.str = ...,
        filters: collections.abc.Iterable[yandex.cloud.speechsense.v1.search_pb2.Filter] | None = ...,
        query: yandex.cloud.speechsense.v1.search_pb2.Query | None = ...,
        page_size: builtins.int = ...,
        page_token: builtins.str = ...,
        sort_data: yandex.cloud.speechsense.v1.search_pb2.SortData | None = ...,
    ) -> None: ...
    def HasField(self, field_name: typing.Literal["query", b"query", "sort_data", b"sort_data"]) -> builtins.bool: ...
    def ClearField(self, field_name: typing.Literal["connection_id", b"connection_id", "filters", b"filters", "organization_id", b"organization_id", "page_size", b"page_size", "page_token", b"page_token", "project_id", b"project_id", "query", b"query", "sort_data", b"sort_data", "space_id", b"space_id"]) -> None: ...

global___SearchTalkRequest = SearchTalkRequest

@typing.final
class SearchTalkResponse(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    TALK_IDS_FIELD_NUMBER: builtins.int
    TALKS_COUNT_FIELD_NUMBER: builtins.int
    NEXT_PAGE_TOKEN_FIELD_NUMBER: builtins.int
    talks_count: builtins.int
    """total documents matched"""
    next_page_token: builtins.str
    """page token for next request"""
    @property
    def talk_ids(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
        """page results entries"""

    def __init__(
        self,
        *,
        talk_ids: collections.abc.Iterable[builtins.str] | None = ...,
        talks_count: builtins.int = ...,
        next_page_token: builtins.str = ...,
    ) -> None: ...
    def ClearField(self, field_name: typing.Literal["next_page_token", b"next_page_token", "talk_ids", b"talk_ids", "talks_count", b"talks_count"]) -> None: ...

global___SearchTalkResponse = SearchTalkResponse

@typing.final
class GetTalkRequest(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    ORGANIZATION_ID_FIELD_NUMBER: builtins.int
    SPACE_ID_FIELD_NUMBER: builtins.int
    CONNECTION_ID_FIELD_NUMBER: builtins.int
    PROJECT_ID_FIELD_NUMBER: builtins.int
    TALK_IDS_FIELD_NUMBER: builtins.int
    RESULTS_MASK_FIELD_NUMBER: builtins.int
    organization_id: builtins.str
    """id of organization"""
    space_id: builtins.str
    """id of space"""
    connection_id: builtins.str
    """id of connection to search data"""
    project_id: builtins.str
    """id of project to search data"""
    @property
    def talk_ids(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]:
        """ids of talks to return. Requesting too many talks may result in "message exceeds maximum size" error.
        Up to 100 of talks per request is recommended.
        """

    @property
    def results_mask(self) -> google.protobuf.field_mask_pb2.FieldMask:
        """All types of analysis will be returned if not set."""

    def __init__(
        self,
        *,
        organization_id: builtins.str = ...,
        space_id: builtins.str = ...,
        connection_id: builtins.str = ...,
        project_id: builtins.str = ...,
        talk_ids: collections.abc.Iterable[builtins.str] | None = ...,
        results_mask: google.protobuf.field_mask_pb2.FieldMask | None = ...,
    ) -> None: ...
    def HasField(self, field_name: typing.Literal["results_mask", b"results_mask"]) -> builtins.bool: ...
    def ClearField(self, field_name: typing.Literal["connection_id", b"connection_id", "organization_id", b"organization_id", "project_id", b"project_id", "results_mask", b"results_mask", "space_id", b"space_id", "talk_ids", b"talk_ids"]) -> None: ...

global___GetTalkRequest = GetTalkRequest

@typing.final
class GetTalkResponse(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    TALK_FIELD_NUMBER: builtins.int
    @property
    def talk(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[yandex.cloud.speechsense.v1.talk_pb2.Talk]: ...
    def __init__(
        self,
        *,
        talk: collections.abc.Iterable[yandex.cloud.speechsense.v1.talk_pb2.Talk] | None = ...,
    ) -> None: ...
    def ClearField(self, field_name: typing.Literal["talk", b"talk"]) -> None: ...

global___GetTalkResponse = GetTalkResponse
