# frozen_string_literal: true

# Copyright 2023 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# Auto-generated by gapic-generator-ruby. DO NOT EDIT!


module Google
  module Cloud
    module DiscoveryEngine
      module V1beta
        # External conversation proto definition.
        # @!attribute [rw] name
        #   @return [::String]
        #     Immutable. Fully qualified name
        #     `projects/{project}/locations/global/collections/{collection}/dataStore/*/conversations/*`
        #     or
        #     `projects/{project}/locations/global/collections/{collection}/engines/*/conversations/*`.
        # @!attribute [rw] state
        #   @return [::Google::Cloud::DiscoveryEngine::V1beta::Conversation::State]
        #     The state of the Conversation.
        # @!attribute [rw] user_pseudo_id
        #   @return [::String]
        #     A unique identifier for tracking users.
        # @!attribute [rw] messages
        #   @return [::Array<::Google::Cloud::DiscoveryEngine::V1beta::ConversationMessage>]
        #     Conversation messages.
        # @!attribute [r] start_time
        #   @return [::Google::Protobuf::Timestamp]
        #     Output only. The time the conversation started.
        # @!attribute [r] end_time
        #   @return [::Google::Protobuf::Timestamp]
        #     Output only. The time the conversation finished.
        class Conversation
          include ::Google::Protobuf::MessageExts
          extend ::Google::Protobuf::MessageExts::ClassMethods

          # Enumeration of the state of the conversation.
          module State
            # Unknown.
            STATE_UNSPECIFIED = 0

            # Conversation is currently open.
            IN_PROGRESS = 1

            # Conversation has been completed.
            COMPLETED = 2
          end
        end

        # Defines a reply message to user.
        # @!attribute [rw] reply
        #   @deprecated This field is deprecated and may be removed in the next major version update.
        #   @return [::String]
        #     DEPRECATED: use `summary` instead.
        #     Text reply.
        # @!attribute [rw] references
        #   @deprecated This field is deprecated and may be removed in the next major version update.
        #   @return [::Array<::Google::Cloud::DiscoveryEngine::V1beta::Reply::Reference>]
        #     References in the reply.
        # @!attribute [rw] summary
        #   @return [::Google::Cloud::DiscoveryEngine::V1beta::SearchResponse::Summary]
        #     Summary based on search results.
        class Reply
          include ::Google::Protobuf::MessageExts
          extend ::Google::Protobuf::MessageExts::ClassMethods

          # Defines reference in reply.
          # @deprecated This message is deprecated and may be removed in the next major version update.
          # @!attribute [rw] uri
          #   @return [::String]
          #     URI link reference.
          # @!attribute [rw] anchor_text
          #   @return [::String]
          #     Anchor text.
          # @!attribute [rw] start
          #   @return [::Integer]
          #     Anchor text start index.
          # @!attribute [rw] end
          #   @return [::Integer]
          #     Anchor text end index.
          class Reference
            include ::Google::Protobuf::MessageExts
            extend ::Google::Protobuf::MessageExts::ClassMethods
          end
        end

        # Defines context of the conversation
        # @!attribute [rw] context_documents
        #   @return [::Array<::String>]
        #     The current list of documents the user is seeing.
        #     It contains the document resource references.
        # @!attribute [rw] active_document
        #   @return [::String]
        #     The current active document the user opened.
        #     It contains the document resource reference.
        class ConversationContext
          include ::Google::Protobuf::MessageExts
          extend ::Google::Protobuf::MessageExts::ClassMethods
        end

        # Defines text input.
        # @!attribute [rw] input
        #   @return [::String]
        #     Text input.
        # @!attribute [rw] context
        #   @return [::Google::Cloud::DiscoveryEngine::V1beta::ConversationContext]
        #     Conversation context of the input.
        class TextInput
          include ::Google::Protobuf::MessageExts
          extend ::Google::Protobuf::MessageExts::ClassMethods
        end

        # Defines a conversation message.
        # @!attribute [rw] user_input
        #   @return [::Google::Cloud::DiscoveryEngine::V1beta::TextInput]
        #     User text input.
        # @!attribute [rw] reply
        #   @return [::Google::Cloud::DiscoveryEngine::V1beta::Reply]
        #     Search reply.
        # @!attribute [r] create_time
        #   @return [::Google::Protobuf::Timestamp]
        #     Output only. Message creation timestamp.
        class ConversationMessage
          include ::Google::Protobuf::MessageExts
          extend ::Google::Protobuf::MessageExts::ClassMethods
        end
      end
    end
  end
end