google-apis-discoveryengine_v1alpha 0.41.0 → 0.43.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1068,6 +1068,11 @@ module Google
1068
1068
  # @return [Fixnum]
1069
1069
  attr_accessor :success_count
1070
1070
 
1071
+ # Total count of entries that were processed.
1072
+ # Corresponds to the JSON property `totalCount`
1073
+ # @return [Fixnum]
1074
+ attr_accessor :total_count
1075
+
1071
1076
  # Operation last update time. If the operation is done, this is also the finish
1072
1077
  # time.
1073
1078
  # Corresponds to the JSON property `updateTime`
@@ -1083,6 +1088,7 @@ module Google
1083
1088
  @create_time = args[:create_time] if args.key?(:create_time)
1084
1089
  @failure_count = args[:failure_count] if args.key?(:failure_count)
1085
1090
  @success_count = args[:success_count] if args.key?(:success_count)
1091
+ @total_count = args[:total_count] if args.key?(:total_count)
1086
1092
  @update_time = args[:update_time] if args.key?(:update_time)
1087
1093
  end
1088
1094
  end
@@ -1650,20 +1656,1161 @@ module Google
1650
1656
 
1651
1657
  # Update properties of this object
1652
1658
  def update!(**args)
1653
- @idp_config = args[:idp_config] if args.key?(:idp_config)
1654
- @name = args[:name] if args.key?(:name)
1659
+ @idp_config = args[:idp_config] if args.key?(:idp_config)
1660
+ @name = args[:name] if args.key?(:name)
1661
+ end
1662
+ end
1663
+
1664
+ # AdditionalParams message for WidgetService methods for security and privacy
1665
+ # enhancement.
1666
+ class GoogleCloudDiscoveryengineV1alphaAdditionalParams
1667
+ include Google::Apis::Core::Hashable
1668
+
1669
+ # Token that used for non-human user check.
1670
+ # Corresponds to the JSON property `token`
1671
+ # @return [String]
1672
+ attr_accessor :token
1673
+
1674
+ def initialize(**args)
1675
+ update!(**args)
1676
+ end
1677
+
1678
+ # Update properties of this object
1679
+ def update!(**args)
1680
+ @token = args[:token] if args.key?(:token)
1681
+ end
1682
+ end
1683
+
1684
+ # Defines an answer.
1685
+ class GoogleCloudDiscoveryengineV1alphaAnswer
1686
+ include Google::Apis::Core::Hashable
1687
+
1688
+ # Additional answer-skipped reasons. This provides the reason for ignored cases.
1689
+ # If nothing is skipped, this field is not set.
1690
+ # Corresponds to the JSON property `answerSkippedReasons`
1691
+ # @return [Array<String>]
1692
+ attr_accessor :answer_skipped_reasons
1693
+
1694
+ # The textual answer.
1695
+ # Corresponds to the JSON property `answerText`
1696
+ # @return [String]
1697
+ attr_accessor :answer_text
1698
+
1699
+ # Citations.
1700
+ # Corresponds to the JSON property `citations`
1701
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerCitation>]
1702
+ attr_accessor :citations
1703
+
1704
+ # Output only. Answer completed timestamp.
1705
+ # Corresponds to the JSON property `completeTime`
1706
+ # @return [String]
1707
+ attr_accessor :complete_time
1708
+
1709
+ # Output only. Answer creation timestamp.
1710
+ # Corresponds to the JSON property `createTime`
1711
+ # @return [String]
1712
+ attr_accessor :create_time
1713
+
1714
+ # Immutable. Fully qualified name `project/*/locations/global/collections/`
1715
+ # collection`/engines/`engine`/sessions/*/answers/*`
1716
+ # Corresponds to the JSON property `name`
1717
+ # @return [String]
1718
+ attr_accessor :name
1719
+
1720
+ # Query understanding information.
1721
+ # Corresponds to the JSON property `queryUnderstandingInfo`
1722
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerQueryUnderstandingInfo]
1723
+ attr_accessor :query_understanding_info
1724
+
1725
+ # References.
1726
+ # Corresponds to the JSON property `references`
1727
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerReference>]
1728
+ attr_accessor :references
1729
+
1730
+ # Suggested related questions.
1731
+ # Corresponds to the JSON property `relatedQuestions`
1732
+ # @return [Array<String>]
1733
+ attr_accessor :related_questions
1734
+
1735
+ # The state of the answer generation.
1736
+ # Corresponds to the JSON property `state`
1737
+ # @return [String]
1738
+ attr_accessor :state
1739
+
1740
+ # Answer generation steps.
1741
+ # Corresponds to the JSON property `steps`
1742
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerStep>]
1743
+ attr_accessor :steps
1744
+
1745
+ def initialize(**args)
1746
+ update!(**args)
1747
+ end
1748
+
1749
+ # Update properties of this object
1750
+ def update!(**args)
1751
+ @answer_skipped_reasons = args[:answer_skipped_reasons] if args.key?(:answer_skipped_reasons)
1752
+ @answer_text = args[:answer_text] if args.key?(:answer_text)
1753
+ @citations = args[:citations] if args.key?(:citations)
1754
+ @complete_time = args[:complete_time] if args.key?(:complete_time)
1755
+ @create_time = args[:create_time] if args.key?(:create_time)
1756
+ @name = args[:name] if args.key?(:name)
1757
+ @query_understanding_info = args[:query_understanding_info] if args.key?(:query_understanding_info)
1758
+ @references = args[:references] if args.key?(:references)
1759
+ @related_questions = args[:related_questions] if args.key?(:related_questions)
1760
+ @state = args[:state] if args.key?(:state)
1761
+ @steps = args[:steps] if args.key?(:steps)
1762
+ end
1763
+ end
1764
+
1765
+ # Citation info for a segment.
1766
+ class GoogleCloudDiscoveryengineV1alphaAnswerCitation
1767
+ include Google::Apis::Core::Hashable
1768
+
1769
+ # End of the attributed segment, exclusive.
1770
+ # Corresponds to the JSON property `endIndex`
1771
+ # @return [Fixnum]
1772
+ attr_accessor :end_index
1773
+
1774
+ # Citation sources for the attributed segment.
1775
+ # Corresponds to the JSON property `sources`
1776
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerCitationSource>]
1777
+ attr_accessor :sources
1778
+
1779
+ # Index indicates the start of the segment, measured in bytes (UTF-8 unicode).
1780
+ # Corresponds to the JSON property `startIndex`
1781
+ # @return [Fixnum]
1782
+ attr_accessor :start_index
1783
+
1784
+ def initialize(**args)
1785
+ update!(**args)
1786
+ end
1787
+
1788
+ # Update properties of this object
1789
+ def update!(**args)
1790
+ @end_index = args[:end_index] if args.key?(:end_index)
1791
+ @sources = args[:sources] if args.key?(:sources)
1792
+ @start_index = args[:start_index] if args.key?(:start_index)
1793
+ end
1794
+ end
1795
+
1796
+ # Citation source.
1797
+ class GoogleCloudDiscoveryengineV1alphaAnswerCitationSource
1798
+ include Google::Apis::Core::Hashable
1799
+
1800
+ # ID of the citation source.
1801
+ # Corresponds to the JSON property `referenceId`
1802
+ # @return [String]
1803
+ attr_accessor :reference_id
1804
+
1805
+ def initialize(**args)
1806
+ update!(**args)
1807
+ end
1808
+
1809
+ # Update properties of this object
1810
+ def update!(**args)
1811
+ @reference_id = args[:reference_id] if args.key?(:reference_id)
1812
+ end
1813
+ end
1814
+
1815
+ # Request message for ConversationalSearchService.AnswerQuery method.
1816
+ class GoogleCloudDiscoveryengineV1alphaAnswerQueryRequest
1817
+ include Google::Apis::Core::Hashable
1818
+
1819
+ # Answer generation specification.
1820
+ # Corresponds to the JSON property `answerGenerationSpec`
1821
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestAnswerGenerationSpec]
1822
+ attr_accessor :answer_generation_spec
1823
+
1824
+ # Asynchronous mode control. If enabled, the response will be returned with
1825
+ # answer/session resource name without final answer. The API users need to do
1826
+ # the polling to get the latest status of answer/session by calling
1827
+ # ConversationalSearchService.GetAnswer or ConversationalSearchService.
1828
+ # GetSession method.
1829
+ # Corresponds to the JSON property `asynchronousMode`
1830
+ # @return [Boolean]
1831
+ attr_accessor :asynchronous_mode
1832
+ alias_method :asynchronous_mode?, :asynchronous_mode
1833
+
1834
+ # Defines a user inputed query.
1835
+ # Corresponds to the JSON property `query`
1836
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaQuery]
1837
+ attr_accessor :query
1838
+
1839
+ # Query understanding specification.
1840
+ # Corresponds to the JSON property `queryUnderstandingSpec`
1841
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestQueryUnderstandingSpec]
1842
+ attr_accessor :query_understanding_spec
1843
+
1844
+ # Related questions specification.
1845
+ # Corresponds to the JSON property `relatedQuestionsSpec`
1846
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestRelatedQuestionsSpec]
1847
+ attr_accessor :related_questions_spec
1848
+
1849
+ # Safety specification.
1850
+ # Corresponds to the JSON property `safetySpec`
1851
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestSafetySpec]
1852
+ attr_accessor :safety_spec
1853
+
1854
+ # Search specification.
1855
+ # Corresponds to the JSON property `searchSpec`
1856
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestSearchSpec]
1857
+ attr_accessor :search_spec
1858
+
1859
+ # The session resource name. Not required. When session field is not set, the
1860
+ # API is in sessionless mode. We support auto session mode: users can use the
1861
+ # wildcard symbol “-” as session id. A new id will be automatically generated
1862
+ # and assigned.
1863
+ # Corresponds to the JSON property `session`
1864
+ # @return [String]
1865
+ attr_accessor :session
1866
+
1867
+ # A unique identifier for tracking visitors. For example, this could be
1868
+ # implemented with an HTTP cookie, which should be able to uniquely identify a
1869
+ # visitor on a single device. This unique identifier should not change if the
1870
+ # visitor logs in or out of the website. This field should NOT have a fixed
1871
+ # value such as `unknown_visitor`. The field must be a UTF-8 encoded string with
1872
+ # a length limit of 128 characters. Otherwise, an `INVALID_ARGUMENT` error is
1873
+ # returned.
1874
+ # Corresponds to the JSON property `userPseudoId`
1875
+ # @return [String]
1876
+ attr_accessor :user_pseudo_id
1877
+
1878
+ def initialize(**args)
1879
+ update!(**args)
1880
+ end
1881
+
1882
+ # Update properties of this object
1883
+ def update!(**args)
1884
+ @answer_generation_spec = args[:answer_generation_spec] if args.key?(:answer_generation_spec)
1885
+ @asynchronous_mode = args[:asynchronous_mode] if args.key?(:asynchronous_mode)
1886
+ @query = args[:query] if args.key?(:query)
1887
+ @query_understanding_spec = args[:query_understanding_spec] if args.key?(:query_understanding_spec)
1888
+ @related_questions_spec = args[:related_questions_spec] if args.key?(:related_questions_spec)
1889
+ @safety_spec = args[:safety_spec] if args.key?(:safety_spec)
1890
+ @search_spec = args[:search_spec] if args.key?(:search_spec)
1891
+ @session = args[:session] if args.key?(:session)
1892
+ @user_pseudo_id = args[:user_pseudo_id] if args.key?(:user_pseudo_id)
1893
+ end
1894
+ end
1895
+
1896
+ # Answer generation specification.
1897
+ class GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestAnswerGenerationSpec
1898
+ include Google::Apis::Core::Hashable
1899
+
1900
+ # Language code for Answer. Use language tags defined by [BCP47](https://www.rfc-
1901
+ # editor.org/rfc/bcp/bcp47.txt). Note: This is an experimental feature.
1902
+ # Corresponds to the JSON property `answerLanguageCode`
1903
+ # @return [String]
1904
+ attr_accessor :answer_language_code
1905
+
1906
+ # Specifies whether to filter out adversarial queries. The default value is `
1907
+ # false`. Google employs search-query classification to detect adversarial
1908
+ # queries. No answer is returned if the search query is classified as an
1909
+ # adversarial query. For example, a user might ask a question regarding negative
1910
+ # comments about the company or submit a query designed to generate unsafe,
1911
+ # policy-violating output. If this field is set to `true`, we skip generating
1912
+ # answers for adversarial queries and return fallback messages instead.
1913
+ # Corresponds to the JSON property `ignoreAdversarialQuery`
1914
+ # @return [Boolean]
1915
+ attr_accessor :ignore_adversarial_query
1916
+ alias_method :ignore_adversarial_query?, :ignore_adversarial_query
1917
+
1918
+ # Specifies whether to filter out queries that are not answer-seeking. The
1919
+ # default value is `false`. Google employs search-query classification to detect
1920
+ # answer-seeking queries. No answer is returned if the search query is
1921
+ # classified as a non-answer seeking query. If this field is set to `true`, we
1922
+ # skip generating answers for non-answer seeking queries and return fallback
1923
+ # messages instead.
1924
+ # Corresponds to the JSON property `ignoreNonAnswerSeekingQuery`
1925
+ # @return [Boolean]
1926
+ attr_accessor :ignore_non_answer_seeking_query
1927
+ alias_method :ignore_non_answer_seeking_query?, :ignore_non_answer_seeking_query
1928
+
1929
+ # Specifies whether to include citation metadata in the answer. The default
1930
+ # value is `false`.
1931
+ # Corresponds to the JSON property `includeCitations`
1932
+ # @return [Boolean]
1933
+ attr_accessor :include_citations
1934
+ alias_method :include_citations?, :include_citations
1935
+
1936
+ # Answer Generation Model specification.
1937
+ # Corresponds to the JSON property `modelSpec`
1938
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestAnswerGenerationSpecModelSpec]
1939
+ attr_accessor :model_spec
1940
+
1941
+ # Answer generation prompt specification.
1942
+ # Corresponds to the JSON property `promptSpec`
1943
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestAnswerGenerationSpecPromptSpec]
1944
+ attr_accessor :prompt_spec
1945
+
1946
+ def initialize(**args)
1947
+ update!(**args)
1948
+ end
1949
+
1950
+ # Update properties of this object
1951
+ def update!(**args)
1952
+ @answer_language_code = args[:answer_language_code] if args.key?(:answer_language_code)
1953
+ @ignore_adversarial_query = args[:ignore_adversarial_query] if args.key?(:ignore_adversarial_query)
1954
+ @ignore_non_answer_seeking_query = args[:ignore_non_answer_seeking_query] if args.key?(:ignore_non_answer_seeking_query)
1955
+ @include_citations = args[:include_citations] if args.key?(:include_citations)
1956
+ @model_spec = args[:model_spec] if args.key?(:model_spec)
1957
+ @prompt_spec = args[:prompt_spec] if args.key?(:prompt_spec)
1958
+ end
1959
+ end
1960
+
1961
+ # Answer Generation Model specification.
1962
+ class GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestAnswerGenerationSpecModelSpec
1963
+ include Google::Apis::Core::Hashable
1964
+
1965
+ # Model version. If not set, it will use the default stable model. Allowed
1966
+ # values are: stable, preview.
1967
+ # Corresponds to the JSON property `modelVersion`
1968
+ # @return [String]
1969
+ attr_accessor :model_version
1970
+
1971
+ def initialize(**args)
1972
+ update!(**args)
1973
+ end
1974
+
1975
+ # Update properties of this object
1976
+ def update!(**args)
1977
+ @model_version = args[:model_version] if args.key?(:model_version)
1978
+ end
1979
+ end
1980
+
1981
+ # Answer generation prompt specification.
1982
+ class GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestAnswerGenerationSpecPromptSpec
1983
+ include Google::Apis::Core::Hashable
1984
+
1985
+ # Customized preamble.
1986
+ # Corresponds to the JSON property `preamble`
1987
+ # @return [String]
1988
+ attr_accessor :preamble
1989
+
1990
+ def initialize(**args)
1991
+ update!(**args)
1992
+ end
1993
+
1994
+ # Update properties of this object
1995
+ def update!(**args)
1996
+ @preamble = args[:preamble] if args.key?(:preamble)
1997
+ end
1998
+ end
1999
+
2000
+ # Query understanding specification.
2001
+ class GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestQueryUnderstandingSpec
2002
+ include Google::Apis::Core::Hashable
2003
+
2004
+ # Query classification specification.
2005
+ # Corresponds to the JSON property `queryClassificationSpec`
2006
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestQueryUnderstandingSpecQueryClassificationSpec]
2007
+ attr_accessor :query_classification_spec
2008
+
2009
+ # Query rephraser specification.
2010
+ # Corresponds to the JSON property `queryRephraserSpec`
2011
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestQueryUnderstandingSpecQueryRephraserSpec]
2012
+ attr_accessor :query_rephraser_spec
2013
+
2014
+ def initialize(**args)
2015
+ update!(**args)
2016
+ end
2017
+
2018
+ # Update properties of this object
2019
+ def update!(**args)
2020
+ @query_classification_spec = args[:query_classification_spec] if args.key?(:query_classification_spec)
2021
+ @query_rephraser_spec = args[:query_rephraser_spec] if args.key?(:query_rephraser_spec)
2022
+ end
2023
+ end
2024
+
2025
+ # Query classification specification.
2026
+ class GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestQueryUnderstandingSpecQueryClassificationSpec
2027
+ include Google::Apis::Core::Hashable
2028
+
2029
+ # Enabled query classification types.
2030
+ # Corresponds to the JSON property `types`
2031
+ # @return [Array<String>]
2032
+ attr_accessor :types
2033
+
2034
+ def initialize(**args)
2035
+ update!(**args)
2036
+ end
2037
+
2038
+ # Update properties of this object
2039
+ def update!(**args)
2040
+ @types = args[:types] if args.key?(:types)
2041
+ end
2042
+ end
2043
+
2044
+ # Query rephraser specification.
2045
+ class GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestQueryUnderstandingSpecQueryRephraserSpec
2046
+ include Google::Apis::Core::Hashable
2047
+
2048
+ # Disable query rephraser.
2049
+ # Corresponds to the JSON property `disable`
2050
+ # @return [Boolean]
2051
+ attr_accessor :disable
2052
+ alias_method :disable?, :disable
2053
+
2054
+ # Max rephrase steps. The max number is 10 steps. If not set or set to < 1, it
2055
+ # will be set to 1 by default.
2056
+ # Corresponds to the JSON property `maxRephraseSteps`
2057
+ # @return [Fixnum]
2058
+ attr_accessor :max_rephrase_steps
2059
+
2060
+ def initialize(**args)
2061
+ update!(**args)
2062
+ end
2063
+
2064
+ # Update properties of this object
2065
+ def update!(**args)
2066
+ @disable = args[:disable] if args.key?(:disable)
2067
+ @max_rephrase_steps = args[:max_rephrase_steps] if args.key?(:max_rephrase_steps)
2068
+ end
2069
+ end
2070
+
2071
+ # Related questions specification.
2072
+ class GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestRelatedQuestionsSpec
2073
+ include Google::Apis::Core::Hashable
2074
+
2075
+ # Enable related questions feature if true.
2076
+ # Corresponds to the JSON property `enable`
2077
+ # @return [Boolean]
2078
+ attr_accessor :enable
2079
+ alias_method :enable?, :enable
2080
+
2081
+ def initialize(**args)
2082
+ update!(**args)
2083
+ end
2084
+
2085
+ # Update properties of this object
2086
+ def update!(**args)
2087
+ @enable = args[:enable] if args.key?(:enable)
2088
+ end
2089
+ end
2090
+
2091
+ # Safety specification.
2092
+ class GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestSafetySpec
2093
+ include Google::Apis::Core::Hashable
2094
+
2095
+ # Enable the safety filtering on the answer response. It is false by default.
2096
+ # Corresponds to the JSON property `enable`
2097
+ # @return [Boolean]
2098
+ attr_accessor :enable
2099
+ alias_method :enable?, :enable
2100
+
2101
+ def initialize(**args)
2102
+ update!(**args)
2103
+ end
2104
+
2105
+ # Update properties of this object
2106
+ def update!(**args)
2107
+ @enable = args[:enable] if args.key?(:enable)
2108
+ end
2109
+ end
2110
+
2111
+ # Search specification.
2112
+ class GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestSearchSpec
2113
+ include Google::Apis::Core::Hashable
2114
+
2115
+ # Search parameters.
2116
+ # Corresponds to the JSON property `searchParams`
2117
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestSearchSpecSearchParams]
2118
+ attr_accessor :search_params
2119
+
2120
+ # Search result list.
2121
+ # Corresponds to the JSON property `searchResultList`
2122
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestSearchSpecSearchResultList]
2123
+ attr_accessor :search_result_list
2124
+
2125
+ def initialize(**args)
2126
+ update!(**args)
2127
+ end
2128
+
2129
+ # Update properties of this object
2130
+ def update!(**args)
2131
+ @search_params = args[:search_params] if args.key?(:search_params)
2132
+ @search_result_list = args[:search_result_list] if args.key?(:search_result_list)
2133
+ end
2134
+ end
2135
+
2136
+ # Search parameters.
2137
+ class GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestSearchSpecSearchParams
2138
+ include Google::Apis::Core::Hashable
2139
+
2140
+ # Boost specification to boost certain documents.
2141
+ # Corresponds to the JSON property `boostSpec`
2142
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpec]
2143
+ attr_accessor :boost_spec
2144
+
2145
+ # The filter syntax consists of an expression language for constructing a
2146
+ # predicate from one or more fields of the documents being filtered. Filter
2147
+ # expression is case-sensitive. This will be used to filter search results which
2148
+ # may affect the Answer response. If this field is unrecognizable, an `
2149
+ # INVALID_ARGUMENT` is returned. Filtering in Vertex AI Search is done by
2150
+ # mapping the LHS filter key to a key property defined in the Vertex AI Search
2151
+ # backend -- this mapping is defined by the customer in their schema. For
2152
+ # example a media customers might have a field 'name' in their schema. In this
2153
+ # case the filter would look like this: filter --> name:'ANY("king kong")' For
2154
+ # more information about filtering including syntax and filter operators, see [
2155
+ # Filter](https://cloud.google.com/generative-ai-app-builder/docs/filter-search-
2156
+ # metadata)
2157
+ # Corresponds to the JSON property `filter`
2158
+ # @return [String]
2159
+ attr_accessor :filter
2160
+
2161
+ # Number of search results to return. The default value is 10.
2162
+ # Corresponds to the JSON property `maxReturnResults`
2163
+ # @return [Fixnum]
2164
+ attr_accessor :max_return_results
2165
+
2166
+ # The order in which documents are returned. Documents can be ordered by a field
2167
+ # in an Document object. Leave it unset if ordered by relevance. `order_by`
2168
+ # expression is case-sensitive. For more information on ordering, see [Ordering](
2169
+ # https://cloud.google.com/retail/docs/filter-and-order#order) If this field is
2170
+ # unrecognizable, an `INVALID_ARGUMENT` is returned.
2171
+ # Corresponds to the JSON property `orderBy`
2172
+ # @return [String]
2173
+ attr_accessor :order_by
2174
+
2175
+ # Specifies the search result mode. If unspecified, the search result mode is
2176
+ # based on DataStore.DocumentProcessingConfig.chunking_config: * If DataStore.
2177
+ # DocumentProcessingConfig.chunking_config is specified, it defaults to `CHUNKS`.
2178
+ # * Otherwise, it defaults to `DOCUMENTS`. See [parse and chunk documents](
2179
+ # https://cloud.google.com/generative-ai-app-builder/docs/parse-chunk-documents)
2180
+ # Corresponds to the JSON property `searchResultMode`
2181
+ # @return [String]
2182
+ attr_accessor :search_result_mode
2183
+
2184
+ def initialize(**args)
2185
+ update!(**args)
2186
+ end
2187
+
2188
+ # Update properties of this object
2189
+ def update!(**args)
2190
+ @boost_spec = args[:boost_spec] if args.key?(:boost_spec)
2191
+ @filter = args[:filter] if args.key?(:filter)
2192
+ @max_return_results = args[:max_return_results] if args.key?(:max_return_results)
2193
+ @order_by = args[:order_by] if args.key?(:order_by)
2194
+ @search_result_mode = args[:search_result_mode] if args.key?(:search_result_mode)
2195
+ end
2196
+ end
2197
+
2198
+ # Search result list.
2199
+ class GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestSearchSpecSearchResultList
2200
+ include Google::Apis::Core::Hashable
2201
+
2202
+ # Search results.
2203
+ # Corresponds to the JSON property `searchResults`
2204
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestSearchSpecSearchResultListSearchResult>]
2205
+ attr_accessor :search_results
2206
+
2207
+ def initialize(**args)
2208
+ update!(**args)
2209
+ end
2210
+
2211
+ # Update properties of this object
2212
+ def update!(**args)
2213
+ @search_results = args[:search_results] if args.key?(:search_results)
2214
+ end
2215
+ end
2216
+
2217
+ # Search result.
2218
+ class GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestSearchSpecSearchResultListSearchResult
2219
+ include Google::Apis::Core::Hashable
2220
+
2221
+ # Chunk information.
2222
+ # Corresponds to the JSON property `chunkInfo`
2223
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestSearchSpecSearchResultListSearchResultChunkInfo]
2224
+ attr_accessor :chunk_info
2225
+
2226
+ # Unstructured document information.
2227
+ # Corresponds to the JSON property `unstructuredDocumentInfo`
2228
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestSearchSpecSearchResultListSearchResultUnstructuredDocumentInfo]
2229
+ attr_accessor :unstructured_document_info
2230
+
2231
+ def initialize(**args)
2232
+ update!(**args)
2233
+ end
2234
+
2235
+ # Update properties of this object
2236
+ def update!(**args)
2237
+ @chunk_info = args[:chunk_info] if args.key?(:chunk_info)
2238
+ @unstructured_document_info = args[:unstructured_document_info] if args.key?(:unstructured_document_info)
2239
+ end
2240
+ end
2241
+
2242
+ # Chunk information.
2243
+ class GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestSearchSpecSearchResultListSearchResultChunkInfo
2244
+ include Google::Apis::Core::Hashable
2245
+
2246
+ # Chunk resource name.
2247
+ # Corresponds to the JSON property `chunk`
2248
+ # @return [String]
2249
+ attr_accessor :chunk
2250
+
2251
+ # Chunk textual content.
2252
+ # Corresponds to the JSON property `content`
2253
+ # @return [String]
2254
+ attr_accessor :content
2255
+
2256
+ def initialize(**args)
2257
+ update!(**args)
2258
+ end
2259
+
2260
+ # Update properties of this object
2261
+ def update!(**args)
2262
+ @chunk = args[:chunk] if args.key?(:chunk)
2263
+ @content = args[:content] if args.key?(:content)
2264
+ end
2265
+ end
2266
+
2267
+ # Unstructured document information.
2268
+ class GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestSearchSpecSearchResultListSearchResultUnstructuredDocumentInfo
2269
+ include Google::Apis::Core::Hashable
2270
+
2271
+ # Document resource name.
2272
+ # Corresponds to the JSON property `document`
2273
+ # @return [String]
2274
+ attr_accessor :document
2275
+
2276
+ # List of document contexts.
2277
+ # Corresponds to the JSON property `documentContexts`
2278
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestSearchSpecSearchResultListSearchResultUnstructuredDocumentInfoDocumentContext>]
2279
+ attr_accessor :document_contexts
2280
+
2281
+ # List of extractive answers.
2282
+ # Corresponds to the JSON property `extractiveAnswers`
2283
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestSearchSpecSearchResultListSearchResultUnstructuredDocumentInfoExtractiveAnswer>]
2284
+ attr_accessor :extractive_answers
2285
+
2286
+ # List of extractive segments.
2287
+ # Corresponds to the JSON property `extractiveSegments`
2288
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestSearchSpecSearchResultListSearchResultUnstructuredDocumentInfoExtractiveSegment>]
2289
+ attr_accessor :extractive_segments
2290
+
2291
+ # Title.
2292
+ # Corresponds to the JSON property `title`
2293
+ # @return [String]
2294
+ attr_accessor :title
2295
+
2296
+ # URI for the document.
2297
+ # Corresponds to the JSON property `uri`
2298
+ # @return [String]
2299
+ attr_accessor :uri
2300
+
2301
+ def initialize(**args)
2302
+ update!(**args)
2303
+ end
2304
+
2305
+ # Update properties of this object
2306
+ def update!(**args)
2307
+ @document = args[:document] if args.key?(:document)
2308
+ @document_contexts = args[:document_contexts] if args.key?(:document_contexts)
2309
+ @extractive_answers = args[:extractive_answers] if args.key?(:extractive_answers)
2310
+ @extractive_segments = args[:extractive_segments] if args.key?(:extractive_segments)
2311
+ @title = args[:title] if args.key?(:title)
2312
+ @uri = args[:uri] if args.key?(:uri)
2313
+ end
2314
+ end
2315
+
2316
+ # Document context.
2317
+ class GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestSearchSpecSearchResultListSearchResultUnstructuredDocumentInfoDocumentContext
2318
+ include Google::Apis::Core::Hashable
2319
+
2320
+ # Document content.
2321
+ # Corresponds to the JSON property `content`
2322
+ # @return [String]
2323
+ attr_accessor :content
2324
+
2325
+ # Page identifier.
2326
+ # Corresponds to the JSON property `pageIdentifier`
2327
+ # @return [String]
2328
+ attr_accessor :page_identifier
2329
+
2330
+ def initialize(**args)
2331
+ update!(**args)
2332
+ end
2333
+
2334
+ # Update properties of this object
2335
+ def update!(**args)
2336
+ @content = args[:content] if args.key?(:content)
2337
+ @page_identifier = args[:page_identifier] if args.key?(:page_identifier)
2338
+ end
2339
+ end
2340
+
2341
+ # Extractive answer. [Guide](https://cloud.google.com/generative-ai-app-builder/
2342
+ # docs/snippets#get-answers)
2343
+ class GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestSearchSpecSearchResultListSearchResultUnstructuredDocumentInfoExtractiveAnswer
2344
+ include Google::Apis::Core::Hashable
2345
+
2346
+ # Extractive answer content.
2347
+ # Corresponds to the JSON property `content`
2348
+ # @return [String]
2349
+ attr_accessor :content
2350
+
2351
+ # Page identifier.
2352
+ # Corresponds to the JSON property `pageIdentifier`
2353
+ # @return [String]
2354
+ attr_accessor :page_identifier
2355
+
2356
+ def initialize(**args)
2357
+ update!(**args)
2358
+ end
2359
+
2360
+ # Update properties of this object
2361
+ def update!(**args)
2362
+ @content = args[:content] if args.key?(:content)
2363
+ @page_identifier = args[:page_identifier] if args.key?(:page_identifier)
2364
+ end
2365
+ end
2366
+
2367
+ # Extractive segment. [Guide](https://cloud.google.com/generative-ai-app-builder/
2368
+ # docs/snippets#extractive-segments)
2369
+ class GoogleCloudDiscoveryengineV1alphaAnswerQueryRequestSearchSpecSearchResultListSearchResultUnstructuredDocumentInfoExtractiveSegment
2370
+ include Google::Apis::Core::Hashable
2371
+
2372
+ # Extractive segment content.
2373
+ # Corresponds to the JSON property `content`
2374
+ # @return [String]
2375
+ attr_accessor :content
2376
+
2377
+ # Page identifier.
2378
+ # Corresponds to the JSON property `pageIdentifier`
2379
+ # @return [String]
2380
+ attr_accessor :page_identifier
2381
+
2382
+ def initialize(**args)
2383
+ update!(**args)
2384
+ end
2385
+
2386
+ # Update properties of this object
2387
+ def update!(**args)
2388
+ @content = args[:content] if args.key?(:content)
2389
+ @page_identifier = args[:page_identifier] if args.key?(:page_identifier)
2390
+ end
2391
+ end
2392
+
2393
+ # Response message for ConversationalSearchService.AnswerQuery method.
2394
+ class GoogleCloudDiscoveryengineV1alphaAnswerQueryResponse
2395
+ include Google::Apis::Core::Hashable
2396
+
2397
+ # Defines an answer.
2398
+ # Corresponds to the JSON property `answer`
2399
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswer]
2400
+ attr_accessor :answer
2401
+
2402
+ # External session proto definition.
2403
+ # Corresponds to the JSON property `session`
2404
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaSession]
2405
+ attr_accessor :session
2406
+
2407
+ def initialize(**args)
2408
+ update!(**args)
2409
+ end
2410
+
2411
+ # Update properties of this object
2412
+ def update!(**args)
2413
+ @answer = args[:answer] if args.key?(:answer)
2414
+ @session = args[:session] if args.key?(:session)
2415
+ end
2416
+ end
2417
+
2418
+ # Query understanding information.
2419
+ class GoogleCloudDiscoveryengineV1alphaAnswerQueryUnderstandingInfo
2420
+ include Google::Apis::Core::Hashable
2421
+
2422
+ # Query classification information.
2423
+ # Corresponds to the JSON property `queryClassificationInfo`
2424
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerQueryUnderstandingInfoQueryClassificationInfo>]
2425
+ attr_accessor :query_classification_info
2426
+
2427
+ def initialize(**args)
2428
+ update!(**args)
2429
+ end
2430
+
2431
+ # Update properties of this object
2432
+ def update!(**args)
2433
+ @query_classification_info = args[:query_classification_info] if args.key?(:query_classification_info)
2434
+ end
2435
+ end
2436
+
2437
+ # Query classification information.
2438
+ class GoogleCloudDiscoveryengineV1alphaAnswerQueryUnderstandingInfoQueryClassificationInfo
2439
+ include Google::Apis::Core::Hashable
2440
+
2441
+ # Classification output.
2442
+ # Corresponds to the JSON property `positive`
2443
+ # @return [Boolean]
2444
+ attr_accessor :positive
2445
+ alias_method :positive?, :positive
2446
+
2447
+ # Query classification type.
2448
+ # Corresponds to the JSON property `type`
2449
+ # @return [String]
2450
+ attr_accessor :type
2451
+
2452
+ def initialize(**args)
2453
+ update!(**args)
2454
+ end
2455
+
2456
+ # Update properties of this object
2457
+ def update!(**args)
2458
+ @positive = args[:positive] if args.key?(:positive)
2459
+ @type = args[:type] if args.key?(:type)
2460
+ end
2461
+ end
2462
+
2463
+ # Reference.
2464
+ class GoogleCloudDiscoveryengineV1alphaAnswerReference
2465
+ include Google::Apis::Core::Hashable
2466
+
2467
+ # Chunk information.
2468
+ # Corresponds to the JSON property `chunkInfo`
2469
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerReferenceChunkInfo]
2470
+ attr_accessor :chunk_info
2471
+
2472
+ # Unstructured document information.
2473
+ # Corresponds to the JSON property `unstructuredDocumentInfo`
2474
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerReferenceUnstructuredDocumentInfo]
2475
+ attr_accessor :unstructured_document_info
2476
+
2477
+ def initialize(**args)
2478
+ update!(**args)
2479
+ end
2480
+
2481
+ # Update properties of this object
2482
+ def update!(**args)
2483
+ @chunk_info = args[:chunk_info] if args.key?(:chunk_info)
2484
+ @unstructured_document_info = args[:unstructured_document_info] if args.key?(:unstructured_document_info)
2485
+ end
2486
+ end
2487
+
2488
+ # Chunk information.
2489
+ class GoogleCloudDiscoveryengineV1alphaAnswerReferenceChunkInfo
2490
+ include Google::Apis::Core::Hashable
2491
+
2492
+ # Chunk resource name.
2493
+ # Corresponds to the JSON property `chunk`
2494
+ # @return [String]
2495
+ attr_accessor :chunk
2496
+
2497
+ # Chunk textual content.
2498
+ # Corresponds to the JSON property `content`
2499
+ # @return [String]
2500
+ attr_accessor :content
2501
+
2502
+ # Document metadata.
2503
+ # Corresponds to the JSON property `documentMetadata`
2504
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerReferenceChunkInfoDocumentMetadata]
2505
+ attr_accessor :document_metadata
2506
+
2507
+ # Relevance score.
2508
+ # Corresponds to the JSON property `relevanceScore`
2509
+ # @return [Float]
2510
+ attr_accessor :relevance_score
2511
+
2512
+ def initialize(**args)
2513
+ update!(**args)
2514
+ end
2515
+
2516
+ # Update properties of this object
2517
+ def update!(**args)
2518
+ @chunk = args[:chunk] if args.key?(:chunk)
2519
+ @content = args[:content] if args.key?(:content)
2520
+ @document_metadata = args[:document_metadata] if args.key?(:document_metadata)
2521
+ @relevance_score = args[:relevance_score] if args.key?(:relevance_score)
2522
+ end
2523
+ end
2524
+
2525
+ # Document metadata.
2526
+ class GoogleCloudDiscoveryengineV1alphaAnswerReferenceChunkInfoDocumentMetadata
2527
+ include Google::Apis::Core::Hashable
2528
+
2529
+ # Document resource name.
2530
+ # Corresponds to the JSON property `document`
2531
+ # @return [String]
2532
+ attr_accessor :document
2533
+
2534
+ # Page identifier.
2535
+ # Corresponds to the JSON property `pageIdentifier`
2536
+ # @return [String]
2537
+ attr_accessor :page_identifier
2538
+
2539
+ # Title.
2540
+ # Corresponds to the JSON property `title`
2541
+ # @return [String]
2542
+ attr_accessor :title
2543
+
2544
+ # URI for the document.
2545
+ # Corresponds to the JSON property `uri`
2546
+ # @return [String]
2547
+ attr_accessor :uri
2548
+
2549
+ def initialize(**args)
2550
+ update!(**args)
2551
+ end
2552
+
2553
+ # Update properties of this object
2554
+ def update!(**args)
2555
+ @document = args[:document] if args.key?(:document)
2556
+ @page_identifier = args[:page_identifier] if args.key?(:page_identifier)
2557
+ @title = args[:title] if args.key?(:title)
2558
+ @uri = args[:uri] if args.key?(:uri)
2559
+ end
2560
+ end
2561
+
2562
+ # Unstructured document information.
2563
+ class GoogleCloudDiscoveryengineV1alphaAnswerReferenceUnstructuredDocumentInfo
2564
+ include Google::Apis::Core::Hashable
2565
+
2566
+ # List of cited chunk contents derived from document content.
2567
+ # Corresponds to the JSON property `chunkContents`
2568
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerReferenceUnstructuredDocumentInfoChunkContent>]
2569
+ attr_accessor :chunk_contents
2570
+
2571
+ # Document resource name.
2572
+ # Corresponds to the JSON property `document`
2573
+ # @return [String]
2574
+ attr_accessor :document
2575
+
2576
+ # Title.
2577
+ # Corresponds to the JSON property `title`
2578
+ # @return [String]
2579
+ attr_accessor :title
2580
+
2581
+ # URI for the document.
2582
+ # Corresponds to the JSON property `uri`
2583
+ # @return [String]
2584
+ attr_accessor :uri
2585
+
2586
+ def initialize(**args)
2587
+ update!(**args)
2588
+ end
2589
+
2590
+ # Update properties of this object
2591
+ def update!(**args)
2592
+ @chunk_contents = args[:chunk_contents] if args.key?(:chunk_contents)
2593
+ @document = args[:document] if args.key?(:document)
2594
+ @title = args[:title] if args.key?(:title)
2595
+ @uri = args[:uri] if args.key?(:uri)
2596
+ end
2597
+ end
2598
+
2599
+ # Chunk content.
2600
+ class GoogleCloudDiscoveryengineV1alphaAnswerReferenceUnstructuredDocumentInfoChunkContent
2601
+ include Google::Apis::Core::Hashable
2602
+
2603
+ # Chunk textual content.
2604
+ # Corresponds to the JSON property `content`
2605
+ # @return [String]
2606
+ attr_accessor :content
2607
+
2608
+ # Page identifier.
2609
+ # Corresponds to the JSON property `pageIdentifier`
2610
+ # @return [String]
2611
+ attr_accessor :page_identifier
2612
+
2613
+ def initialize(**args)
2614
+ update!(**args)
2615
+ end
2616
+
2617
+ # Update properties of this object
2618
+ def update!(**args)
2619
+ @content = args[:content] if args.key?(:content)
2620
+ @page_identifier = args[:page_identifier] if args.key?(:page_identifier)
2621
+ end
2622
+ end
2623
+
2624
+ # Step information.
2625
+ class GoogleCloudDiscoveryengineV1alphaAnswerStep
2626
+ include Google::Apis::Core::Hashable
2627
+
2628
+ # Actions.
2629
+ # Corresponds to the JSON property `actions`
2630
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerStepAction>]
2631
+ attr_accessor :actions
2632
+
2633
+ # The description of the step.
2634
+ # Corresponds to the JSON property `description`
2635
+ # @return [String]
2636
+ attr_accessor :description
2637
+
2638
+ # The state of the step.
2639
+ # Corresponds to the JSON property `state`
2640
+ # @return [String]
2641
+ attr_accessor :state
2642
+
2643
+ # The thought of the step.
2644
+ # Corresponds to the JSON property `thought`
2645
+ # @return [String]
2646
+ attr_accessor :thought
2647
+
2648
+ def initialize(**args)
2649
+ update!(**args)
2650
+ end
2651
+
2652
+ # Update properties of this object
2653
+ def update!(**args)
2654
+ @actions = args[:actions] if args.key?(:actions)
2655
+ @description = args[:description] if args.key?(:description)
2656
+ @state = args[:state] if args.key?(:state)
2657
+ @thought = args[:thought] if args.key?(:thought)
2658
+ end
2659
+ end
2660
+
2661
+ # Action.
2662
+ class GoogleCloudDiscoveryengineV1alphaAnswerStepAction
2663
+ include Google::Apis::Core::Hashable
2664
+
2665
+ # Observation.
2666
+ # Corresponds to the JSON property `observation`
2667
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerStepActionObservation]
2668
+ attr_accessor :observation
2669
+
2670
+ # Search action.
2671
+ # Corresponds to the JSON property `searchAction`
2672
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerStepActionSearchAction]
2673
+ attr_accessor :search_action
2674
+
2675
+ def initialize(**args)
2676
+ update!(**args)
2677
+ end
2678
+
2679
+ # Update properties of this object
2680
+ def update!(**args)
2681
+ @observation = args[:observation] if args.key?(:observation)
2682
+ @search_action = args[:search_action] if args.key?(:search_action)
2683
+ end
2684
+ end
2685
+
2686
+ # Observation.
2687
+ class GoogleCloudDiscoveryengineV1alphaAnswerStepActionObservation
2688
+ include Google::Apis::Core::Hashable
2689
+
2690
+ # Search results observed by the search action, it can be snippets info or chunk
2691
+ # info, depending on the citation type set by the user.
2692
+ # Corresponds to the JSON property `searchResults`
2693
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerStepActionObservationSearchResult>]
2694
+ attr_accessor :search_results
2695
+
2696
+ def initialize(**args)
2697
+ update!(**args)
2698
+ end
2699
+
2700
+ # Update properties of this object
2701
+ def update!(**args)
2702
+ @search_results = args[:search_results] if args.key?(:search_results)
2703
+ end
2704
+ end
2705
+
2706
+ #
2707
+ class GoogleCloudDiscoveryengineV1alphaAnswerStepActionObservationSearchResult
2708
+ include Google::Apis::Core::Hashable
2709
+
2710
+ # If citation_type is CHUNK_LEVEL_CITATION and chunk mode is on, populate chunk
2711
+ # info.
2712
+ # Corresponds to the JSON property `chunkInfo`
2713
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerStepActionObservationSearchResultChunkInfo>]
2714
+ attr_accessor :chunk_info
2715
+
2716
+ # Document resource name.
2717
+ # Corresponds to the JSON property `document`
2718
+ # @return [String]
2719
+ attr_accessor :document
2720
+
2721
+ # If citation_type is DOCUMENT_LEVEL_CITATION, populate document level snippets.
2722
+ # Corresponds to the JSON property `snippetInfo`
2723
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaAnswerStepActionObservationSearchResultSnippetInfo>]
2724
+ attr_accessor :snippet_info
2725
+
2726
+ # Title.
2727
+ # Corresponds to the JSON property `title`
2728
+ # @return [String]
2729
+ attr_accessor :title
2730
+
2731
+ # URI for the document.
2732
+ # Corresponds to the JSON property `uri`
2733
+ # @return [String]
2734
+ attr_accessor :uri
2735
+
2736
+ def initialize(**args)
2737
+ update!(**args)
2738
+ end
2739
+
2740
+ # Update properties of this object
2741
+ def update!(**args)
2742
+ @chunk_info = args[:chunk_info] if args.key?(:chunk_info)
2743
+ @document = args[:document] if args.key?(:document)
2744
+ @snippet_info = args[:snippet_info] if args.key?(:snippet_info)
2745
+ @title = args[:title] if args.key?(:title)
2746
+ @uri = args[:uri] if args.key?(:uri)
2747
+ end
2748
+ end
2749
+
2750
+ # Chunk information.
2751
+ class GoogleCloudDiscoveryengineV1alphaAnswerStepActionObservationSearchResultChunkInfo
2752
+ include Google::Apis::Core::Hashable
2753
+
2754
+ # Chunk resource name.
2755
+ # Corresponds to the JSON property `chunk`
2756
+ # @return [String]
2757
+ attr_accessor :chunk
2758
+
2759
+ # Chunk textual content.
2760
+ # Corresponds to the JSON property `content`
2761
+ # @return [String]
2762
+ attr_accessor :content
2763
+
2764
+ # Relevance score.
2765
+ # Corresponds to the JSON property `relevanceScore`
2766
+ # @return [Float]
2767
+ attr_accessor :relevance_score
2768
+
2769
+ def initialize(**args)
2770
+ update!(**args)
2771
+ end
2772
+
2773
+ # Update properties of this object
2774
+ def update!(**args)
2775
+ @chunk = args[:chunk] if args.key?(:chunk)
2776
+ @content = args[:content] if args.key?(:content)
2777
+ @relevance_score = args[:relevance_score] if args.key?(:relevance_score)
2778
+ end
2779
+ end
2780
+
2781
+ # Snippet information.
2782
+ class GoogleCloudDiscoveryengineV1alphaAnswerStepActionObservationSearchResultSnippetInfo
2783
+ include Google::Apis::Core::Hashable
2784
+
2785
+ # Snippet content.
2786
+ # Corresponds to the JSON property `snippet`
2787
+ # @return [String]
2788
+ attr_accessor :snippet
2789
+
2790
+ # Status of the snippet defined by the search team.
2791
+ # Corresponds to the JSON property `snippetStatus`
2792
+ # @return [String]
2793
+ attr_accessor :snippet_status
2794
+
2795
+ def initialize(**args)
2796
+ update!(**args)
2797
+ end
2798
+
2799
+ # Update properties of this object
2800
+ def update!(**args)
2801
+ @snippet = args[:snippet] if args.key?(:snippet)
2802
+ @snippet_status = args[:snippet_status] if args.key?(:snippet_status)
1655
2803
  end
1656
2804
  end
1657
2805
 
1658
- # AdditionalParams message for WidgetService methods for security and privacy
1659
- # enhancement.
1660
- class GoogleCloudDiscoveryengineV1alphaAdditionalParams
2806
+ # Search action.
2807
+ class GoogleCloudDiscoveryengineV1alphaAnswerStepActionSearchAction
1661
2808
  include Google::Apis::Core::Hashable
1662
2809
 
1663
- # Token that used for non-human user check.
1664
- # Corresponds to the JSON property `token`
2810
+ # The query to search.
2811
+ # Corresponds to the JSON property `query`
1665
2812
  # @return [String]
1666
- attr_accessor :token
2813
+ attr_accessor :query
1667
2814
 
1668
2815
  def initialize(**args)
1669
2816
  update!(**args)
@@ -1671,7 +2818,7 @@ module Google
1671
2818
 
1672
2819
  # Update properties of this object
1673
2820
  def update!(**args)
1674
- @token = args[:token] if args.key?(:token)
2821
+ @query = args[:query] if args.key?(:query)
1675
2822
  end
1676
2823
  end
1677
2824
 
@@ -1765,7 +2912,7 @@ module Google
1765
2912
  # row. Each document must have a valid Document.id and one of Document.json_data
1766
2913
  # or Document.struct_data. * `custom`: One custom data per row in arbitrary
1767
2914
  # format that conforms to the defined Schema of the data store. This can only be
1768
- # used by Gen App Builder.
2915
+ # used by the GENERIC Data Store vertical.
1769
2916
  # Corresponds to the JSON property `dataSchema`
1770
2917
  # @return [String]
1771
2918
  attr_accessor :data_schema
@@ -1823,11 +2970,308 @@ module Google
1823
2970
  end
1824
2971
  end
1825
2972
 
2973
+ # The Bigtable Options object that contains information to support the import.
2974
+ class GoogleCloudDiscoveryengineV1alphaBigtableOptions
2975
+ include Google::Apis::Core::Hashable
2976
+
2977
+ # The mapping from family names to an object that contains column families level
2978
+ # information for the given column family. If a family is not present in this
2979
+ # map it will be ignored.
2980
+ # Corresponds to the JSON property `families`
2981
+ # @return [Hash<String,Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaBigtableOptionsBigtableColumnFamily>]
2982
+ attr_accessor :families
2983
+
2984
+ # The field name used for saving row key value in the document. The name has to
2985
+ # match the pattern `a-zA-Z0-9*`.
2986
+ # Corresponds to the JSON property `keyFieldName`
2987
+ # @return [String]
2988
+ attr_accessor :key_field_name
2989
+
2990
+ def initialize(**args)
2991
+ update!(**args)
2992
+ end
2993
+
2994
+ # Update properties of this object
2995
+ def update!(**args)
2996
+ @families = args[:families] if args.key?(:families)
2997
+ @key_field_name = args[:key_field_name] if args.key?(:key_field_name)
2998
+ end
2999
+ end
3000
+
3001
+ # The column of the Bigtable.
3002
+ class GoogleCloudDiscoveryengineV1alphaBigtableOptionsBigtableColumn
3003
+ include Google::Apis::Core::Hashable
3004
+
3005
+ # The encoding mode of the values when the type is not `STRING`. Acceptable
3006
+ # encoding values are: * `TEXT`: indicates values are alphanumeric text strings.
3007
+ # * `BINARY`: indicates values are encoded using `HBase Bytes.toBytes` family of
3008
+ # functions. This can be overridden for a specific column by listing that column
3009
+ # in `columns` and specifying an encoding for it.
3010
+ # Corresponds to the JSON property `encoding`
3011
+ # @return [String]
3012
+ attr_accessor :encoding
3013
+
3014
+ # The field name to use for this column in the document. The name has to match
3015
+ # the pattern `a-zA-Z0-9*`. If not set, it is parsed from the qualifier bytes
3016
+ # with best effort. However, due to different naming patterns, field name
3017
+ # collisions could happen, where parsing behavior is undefined.
3018
+ # Corresponds to the JSON property `fieldName`
3019
+ # @return [String]
3020
+ attr_accessor :field_name
3021
+
3022
+ # Required. Qualifier of the column. If it cannot be decoded with utf-8, use a
3023
+ # base-64 encoded string instead.
3024
+ # Corresponds to the JSON property `qualifier`
3025
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
3026
+ # @return [String]
3027
+ attr_accessor :qualifier
3028
+
3029
+ # The type of values in this column family. The values are expected to be
3030
+ # encoded using `HBase Bytes.toBytes` function when the encoding value is set to
3031
+ # `BINARY`.
3032
+ # Corresponds to the JSON property `type`
3033
+ # @return [String]
3034
+ attr_accessor :type
3035
+
3036
+ def initialize(**args)
3037
+ update!(**args)
3038
+ end
3039
+
3040
+ # Update properties of this object
3041
+ def update!(**args)
3042
+ @encoding = args[:encoding] if args.key?(:encoding)
3043
+ @field_name = args[:field_name] if args.key?(:field_name)
3044
+ @qualifier = args[:qualifier] if args.key?(:qualifier)
3045
+ @type = args[:type] if args.key?(:type)
3046
+ end
3047
+ end
3048
+
3049
+ # The column family of the Bigtable.
3050
+ class GoogleCloudDiscoveryengineV1alphaBigtableOptionsBigtableColumnFamily
3051
+ include Google::Apis::Core::Hashable
3052
+
3053
+ # The list of objects that contains column level information for each column. If
3054
+ # a column is not present in this list it will be ignored.
3055
+ # Corresponds to the JSON property `columns`
3056
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaBigtableOptionsBigtableColumn>]
3057
+ attr_accessor :columns
3058
+
3059
+ # The encoding mode of the values when the type is not STRING. Acceptable
3060
+ # encoding values are: * `TEXT`: indicates values are alphanumeric text strings.
3061
+ # * `BINARY`: indicates values are encoded using `HBase Bytes.toBytes` family of
3062
+ # functions. This can be overridden for a specific column by listing that column
3063
+ # in `columns` and specifying an encoding for it.
3064
+ # Corresponds to the JSON property `encoding`
3065
+ # @return [String]
3066
+ attr_accessor :encoding
3067
+
3068
+ # The field name to use for this column family in the document. The name has to
3069
+ # match the pattern `a-zA-Z0-9*`. If not set, it is parsed from the family name
3070
+ # with best effort. However, due to different naming patterns, field name
3071
+ # collisions could happen, where parsing behavior is undefined.
3072
+ # Corresponds to the JSON property `fieldName`
3073
+ # @return [String]
3074
+ attr_accessor :field_name
3075
+
3076
+ # The type of values in this column family. The values are expected to be
3077
+ # encoded using `HBase Bytes.toBytes` function when the encoding value is set to
3078
+ # `BINARY`.
3079
+ # Corresponds to the JSON property `type`
3080
+ # @return [String]
3081
+ attr_accessor :type
3082
+
3083
+ def initialize(**args)
3084
+ update!(**args)
3085
+ end
3086
+
3087
+ # Update properties of this object
3088
+ def update!(**args)
3089
+ @columns = args[:columns] if args.key?(:columns)
3090
+ @encoding = args[:encoding] if args.key?(:encoding)
3091
+ @field_name = args[:field_name] if args.key?(:field_name)
3092
+ @type = args[:type] if args.key?(:type)
3093
+ end
3094
+ end
3095
+
3096
+ # The Cloud Bigtable source for importing data.
3097
+ class GoogleCloudDiscoveryengineV1alphaBigtableSource
3098
+ include Google::Apis::Core::Hashable
3099
+
3100
+ # The Bigtable Options object that contains information to support the import.
3101
+ # Corresponds to the JSON property `bigtableOptions`
3102
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaBigtableOptions]
3103
+ attr_accessor :bigtable_options
3104
+
3105
+ # Required. The instance ID of the Cloud Bigtable that needs to be imported.
3106
+ # Corresponds to the JSON property `instanceId`
3107
+ # @return [String]
3108
+ attr_accessor :instance_id
3109
+
3110
+ # The project ID that the Bigtable source is in with a length limit of 128
3111
+ # characters. If not specified, inherits the project ID from the parent request.
3112
+ # Corresponds to the JSON property `projectId`
3113
+ # @return [String]
3114
+ attr_accessor :project_id
3115
+
3116
+ # Required. The table ID of the Cloud Bigtable that needs to be imported.
3117
+ # Corresponds to the JSON property `tableId`
3118
+ # @return [String]
3119
+ attr_accessor :table_id
3120
+
3121
+ def initialize(**args)
3122
+ update!(**args)
3123
+ end
3124
+
3125
+ # Update properties of this object
3126
+ def update!(**args)
3127
+ @bigtable_options = args[:bigtable_options] if args.key?(:bigtable_options)
3128
+ @instance_id = args[:instance_id] if args.key?(:instance_id)
3129
+ @project_id = args[:project_id] if args.key?(:project_id)
3130
+ @table_id = args[:table_id] if args.key?(:table_id)
3131
+ end
3132
+ end
3133
+
3134
+ # Request message for GroundedGenerationService.CheckGrounding method.
3135
+ class GoogleCloudDiscoveryengineV1alphaCheckGroundingRequest
3136
+ include Google::Apis::Core::Hashable
3137
+
3138
+ # Answer candidate to check.
3139
+ # Corresponds to the JSON property `answerCandidate`
3140
+ # @return [String]
3141
+ attr_accessor :answer_candidate
3142
+
3143
+ # List of facts for the grounding check. We support up to 200 facts.
3144
+ # Corresponds to the JSON property `facts`
3145
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaGroundingFact>]
3146
+ attr_accessor :facts
3147
+
3148
+ # Specification for the grounding check.
3149
+ # Corresponds to the JSON property `groundingSpec`
3150
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaCheckGroundingSpec]
3151
+ attr_accessor :grounding_spec
3152
+
3153
+ def initialize(**args)
3154
+ update!(**args)
3155
+ end
3156
+
3157
+ # Update properties of this object
3158
+ def update!(**args)
3159
+ @answer_candidate = args[:answer_candidate] if args.key?(:answer_candidate)
3160
+ @facts = args[:facts] if args.key?(:facts)
3161
+ @grounding_spec = args[:grounding_spec] if args.key?(:grounding_spec)
3162
+ end
3163
+ end
3164
+
3165
+ # Response message for the GroundedGenerationService.CheckGrounding method.
3166
+ class GoogleCloudDiscoveryengineV1alphaCheckGroundingResponse
3167
+ include Google::Apis::Core::Hashable
3168
+
3169
+ # List of facts cited across all claims in the answer candidate. These are
3170
+ # derived from the facts supplied in the request.
3171
+ # Corresponds to the JSON property `citedChunks`
3172
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaFactChunk>]
3173
+ attr_accessor :cited_chunks
3174
+
3175
+ # Claim texts and citation info across all claims in the answer candidate.
3176
+ # Corresponds to the JSON property `claims`
3177
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaCheckGroundingResponseClaim>]
3178
+ attr_accessor :claims
3179
+
3180
+ # The support score for the input answer candidate. Higher the score, higher is
3181
+ # the fraction of claims that are supported by the provided facts. This is
3182
+ # always set when a response is returned.
3183
+ # Corresponds to the JSON property `supportScore`
3184
+ # @return [Float]
3185
+ attr_accessor :support_score
3186
+
3187
+ def initialize(**args)
3188
+ update!(**args)
3189
+ end
3190
+
3191
+ # Update properties of this object
3192
+ def update!(**args)
3193
+ @cited_chunks = args[:cited_chunks] if args.key?(:cited_chunks)
3194
+ @claims = args[:claims] if args.key?(:claims)
3195
+ @support_score = args[:support_score] if args.key?(:support_score)
3196
+ end
3197
+ end
3198
+
3199
+ # Text and citation info for a claim in the answer candidate.
3200
+ class GoogleCloudDiscoveryengineV1alphaCheckGroundingResponseClaim
3201
+ include Google::Apis::Core::Hashable
3202
+
3203
+ # A list of indices (into 'cited_chunks') specifying the citations associated
3204
+ # with the claim. For instance [1,3,4] means that cited_chunks[1], cited_chunks[
3205
+ # 3], cited_chunks[4] are the facts cited supporting for the claim. A citation
3206
+ # to a fact indicates that the claim is supported by the fact.
3207
+ # Corresponds to the JSON property `citationIndices`
3208
+ # @return [Array<Fixnum>]
3209
+ attr_accessor :citation_indices
3210
+
3211
+ # Text for the claim in the answer candidate. Always provided regardless of
3212
+ # whether citations or anti-citations are found.
3213
+ # Corresponds to the JSON property `claimText`
3214
+ # @return [String]
3215
+ attr_accessor :claim_text
3216
+
3217
+ # Position indicating the end of the claim in the answer candidate, exclusive.
3218
+ # Corresponds to the JSON property `endPos`
3219
+ # @return [Fixnum]
3220
+ attr_accessor :end_pos
3221
+
3222
+ # Position indicating the start of the claim in the answer candidate, measured
3223
+ # in bytes/unicode.
3224
+ # Corresponds to the JSON property `startPos`
3225
+ # @return [Fixnum]
3226
+ attr_accessor :start_pos
3227
+
3228
+ def initialize(**args)
3229
+ update!(**args)
3230
+ end
3231
+
3232
+ # Update properties of this object
3233
+ def update!(**args)
3234
+ @citation_indices = args[:citation_indices] if args.key?(:citation_indices)
3235
+ @claim_text = args[:claim_text] if args.key?(:claim_text)
3236
+ @end_pos = args[:end_pos] if args.key?(:end_pos)
3237
+ @start_pos = args[:start_pos] if args.key?(:start_pos)
3238
+ end
3239
+ end
3240
+
3241
+ # Specification for the grounding check.
3242
+ class GoogleCloudDiscoveryengineV1alphaCheckGroundingSpec
3243
+ include Google::Apis::Core::Hashable
3244
+
3245
+ # The threshold (in [0,1]) used for determining whether a fact must be cited for
3246
+ # a claim in the answer candidate. Choosing a higher threshold will lead to
3247
+ # fewer but very strong citations, while choosing a lower threshold may lead to
3248
+ # more but somewhat weaker citations. If unset, the threshold will default to 0.
3249
+ # 6.
3250
+ # Corresponds to the JSON property `citationThreshold`
3251
+ # @return [Float]
3252
+ attr_accessor :citation_threshold
3253
+
3254
+ def initialize(**args)
3255
+ update!(**args)
3256
+ end
3257
+
3258
+ # Update properties of this object
3259
+ def update!(**args)
3260
+ @citation_threshold = args[:citation_threshold] if args.key?(:citation_threshold)
3261
+ end
3262
+ end
3263
+
1826
3264
  # Chunk captures all raw metadata information of items to be recommended or
1827
3265
  # searched in the chunk mode.
1828
3266
  class GoogleCloudDiscoveryengineV1alphaChunk
1829
3267
  include Google::Apis::Core::Hashable
1830
3268
 
3269
+ # Metadata of the current chunk. This field is only populated on SearchService.
3270
+ # Search API.
3271
+ # Corresponds to the JSON property `chunkMetadata`
3272
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaChunkChunkMetadata]
3273
+ attr_accessor :chunk_metadata
3274
+
1831
3275
  # Content is a string from a document (parsed content).
1832
3276
  # Corresponds to the JSON property `content`
1833
3277
  # @return [String]
@@ -1845,7 +3289,7 @@ module Google
1845
3289
  # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaChunkDocumentMetadata]
1846
3290
  attr_accessor :document_metadata
1847
3291
 
1848
- # Unique chunk id of the current chunk.
3292
+ # Unique chunk ID of the current chunk.
1849
3293
  # Corresponds to the JSON property `id`
1850
3294
  # @return [String]
1851
3295
  attr_accessor :id
@@ -1858,17 +3302,54 @@ module Google
1858
3302
  # @return [String]
1859
3303
  attr_accessor :name
1860
3304
 
3305
+ # Page span of the chunk.
3306
+ # Corresponds to the JSON property `pageSpan`
3307
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaChunkPageSpan]
3308
+ attr_accessor :page_span
3309
+
1861
3310
  def initialize(**args)
1862
3311
  update!(**args)
1863
3312
  end
1864
3313
 
1865
3314
  # Update properties of this object
1866
3315
  def update!(**args)
3316
+ @chunk_metadata = args[:chunk_metadata] if args.key?(:chunk_metadata)
1867
3317
  @content = args[:content] if args.key?(:content)
1868
3318
  @derived_struct_data = args[:derived_struct_data] if args.key?(:derived_struct_data)
1869
3319
  @document_metadata = args[:document_metadata] if args.key?(:document_metadata)
1870
3320
  @id = args[:id] if args.key?(:id)
1871
3321
  @name = args[:name] if args.key?(:name)
3322
+ @page_span = args[:page_span] if args.key?(:page_span)
3323
+ end
3324
+ end
3325
+
3326
+ # Metadata of the current chunk. This field is only populated on SearchService.
3327
+ # Search API.
3328
+ class GoogleCloudDiscoveryengineV1alphaChunkChunkMetadata
3329
+ include Google::Apis::Core::Hashable
3330
+
3331
+ # The next chunks of the current chunk. The number is controlled by
3332
+ # SearchRequest.ContentSearchSpec.ChunkSpec.num_next_chunks. This field is only
3333
+ # populated on SearchService.Search API.
3334
+ # Corresponds to the JSON property `nextChunks`
3335
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaChunk>]
3336
+ attr_accessor :next_chunks
3337
+
3338
+ # The previous chunks of the current chunk. The number is controlled by
3339
+ # SearchRequest.ContentSearchSpec.ChunkSpec.num_previous_chunks. This field is
3340
+ # only populated on SearchService.Search API.
3341
+ # Corresponds to the JSON property `previousChunks`
3342
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaChunk>]
3343
+ attr_accessor :previous_chunks
3344
+
3345
+ def initialize(**args)
3346
+ update!(**args)
3347
+ end
3348
+
3349
+ # Update properties of this object
3350
+ def update!(**args)
3351
+ @next_chunks = args[:next_chunks] if args.key?(:next_chunks)
3352
+ @previous_chunks = args[:previous_chunks] if args.key?(:previous_chunks)
1872
3353
  end
1873
3354
  end
1874
3355
 
@@ -1898,6 +3379,90 @@ module Google
1898
3379
  end
1899
3380
  end
1900
3381
 
3382
+ # Page span of the chunk.
3383
+ class GoogleCloudDiscoveryengineV1alphaChunkPageSpan
3384
+ include Google::Apis::Core::Hashable
3385
+
3386
+ # The end page of the chunk.
3387
+ # Corresponds to the JSON property `pageEnd`
3388
+ # @return [Fixnum]
3389
+ attr_accessor :page_end
3390
+
3391
+ # The start page of the chunk.
3392
+ # Corresponds to the JSON property `pageStart`
3393
+ # @return [Fixnum]
3394
+ attr_accessor :page_start
3395
+
3396
+ def initialize(**args)
3397
+ update!(**args)
3398
+ end
3399
+
3400
+ # Update properties of this object
3401
+ def update!(**args)
3402
+ @page_end = args[:page_end] if args.key?(:page_end)
3403
+ @page_start = args[:page_start] if args.key?(:page_start)
3404
+ end
3405
+ end
3406
+
3407
+ # Cloud SQL source import data from.
3408
+ class GoogleCloudDiscoveryengineV1alphaCloudSqlSource
3409
+ include Google::Apis::Core::Hashable
3410
+
3411
+ # Required. The Cloud SQL database to copy the data from with a length limit of
3412
+ # 256 characters.
3413
+ # Corresponds to the JSON property `databaseId`
3414
+ # @return [String]
3415
+ attr_accessor :database_id
3416
+
3417
+ # Intermediate Cloud Storage directory used for the import with a length limit
3418
+ # of 2,000 characters. Can be specified if one wants to have the Cloud SQL
3419
+ # export to a specific Cloud Storage directory. Please ensure that the Cloud SQL
3420
+ # service account has the necessary Cloud Storage Admin permissions to access
3421
+ # the specified Cloud Storage directory.
3422
+ # Corresponds to the JSON property `gcsStagingDir`
3423
+ # @return [String]
3424
+ attr_accessor :gcs_staging_dir
3425
+
3426
+ # Required. The Cloud SQL instance to copy the data from with a length limit of
3427
+ # 256 characters.
3428
+ # Corresponds to the JSON property `instanceId`
3429
+ # @return [String]
3430
+ attr_accessor :instance_id
3431
+
3432
+ # Option for serverless export. Enabling this option will incur additional cost.
3433
+ # More info can be found [here](https://cloud.google.com/sql/pricing#serverless).
3434
+ # Corresponds to the JSON property `offload`
3435
+ # @return [Boolean]
3436
+ attr_accessor :offload
3437
+ alias_method :offload?, :offload
3438
+
3439
+ # The project ID that the Cloud SQL source is in with a length limit of 128
3440
+ # characters. If not specified, inherits the project ID from the parent request.
3441
+ # Corresponds to the JSON property `projectId`
3442
+ # @return [String]
3443
+ attr_accessor :project_id
3444
+
3445
+ # Required. The Cloud SQL table to copy the data from with a length limit of 256
3446
+ # characters.
3447
+ # Corresponds to the JSON property `tableId`
3448
+ # @return [String]
3449
+ attr_accessor :table_id
3450
+
3451
+ def initialize(**args)
3452
+ update!(**args)
3453
+ end
3454
+
3455
+ # Update properties of this object
3456
+ def update!(**args)
3457
+ @database_id = args[:database_id] if args.key?(:database_id)
3458
+ @gcs_staging_dir = args[:gcs_staging_dir] if args.key?(:gcs_staging_dir)
3459
+ @instance_id = args[:instance_id] if args.key?(:instance_id)
3460
+ @offload = args[:offload] if args.key?(:offload)
3461
+ @project_id = args[:project_id] if args.key?(:project_id)
3462
+ @table_id = args[:table_id] if args.key?(:table_id)
3463
+ end
3464
+ end
3465
+
1901
3466
  # Request message for CompletionService.CompleteQuery method.
1902
3467
  class GoogleCloudDiscoveryengineV1alphaCompleteQueryRequest
1903
3468
  include Google::Apis::Core::Hashable
@@ -3780,6 +5345,39 @@ module Google
3780
5345
  end
3781
5346
  end
3782
5347
 
5348
+ # Fact Chunk.
5349
+ class GoogleCloudDiscoveryengineV1alphaFactChunk
5350
+ include Google::Apis::Core::Hashable
5351
+
5352
+ # Text content of the fact chunk. Can be at most 10K characters long.
5353
+ # Corresponds to the JSON property `chunkText`
5354
+ # @return [String]
5355
+ attr_accessor :chunk_text
5356
+
5357
+ # Source from which this fact chunk was retrieved. If it was retrieved from the
5358
+ # GroundingFacts provided in the request then this field will contain the index
5359
+ # of the specific fact from which this chunk was retrieved.
5360
+ # Corresponds to the JSON property `source`
5361
+ # @return [String]
5362
+ attr_accessor :source
5363
+
5364
+ # More fine-grained information for the source reference.
5365
+ # Corresponds to the JSON property `sourceMetadata`
5366
+ # @return [Hash<String,String>]
5367
+ attr_accessor :source_metadata
5368
+
5369
+ def initialize(**args)
5370
+ update!(**args)
5371
+ end
5372
+
5373
+ # Update properties of this object
5374
+ def update!(**args)
5375
+ @chunk_text = args[:chunk_text] if args.key?(:chunk_text)
5376
+ @source = args[:source] if args.key?(:source)
5377
+ @source_metadata = args[:source_metadata] if args.key?(:source_metadata)
5378
+ end
5379
+ end
5380
+
3783
5381
  # Response message for SiteSearchEngineService.FetchDomainVerificationStatus
3784
5382
  # method.
3785
5383
  class GoogleCloudDiscoveryengineV1alphaFetchDomainVerificationStatusResponse
@@ -3796,11 +5394,41 @@ module Google
3796
5394
  # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaTargetSite>]
3797
5395
  attr_accessor :target_sites
3798
5396
 
3799
- # The total number of items matching the request. This will always be populated
3800
- # in the response.
3801
- # Corresponds to the JSON property `totalSize`
3802
- # @return [Fixnum]
3803
- attr_accessor :total_size
5397
+ # The total number of items matching the request. This will always be populated
5398
+ # in the response.
5399
+ # Corresponds to the JSON property `totalSize`
5400
+ # @return [Fixnum]
5401
+ attr_accessor :total_size
5402
+
5403
+ def initialize(**args)
5404
+ update!(**args)
5405
+ end
5406
+
5407
+ # Update properties of this object
5408
+ def update!(**args)
5409
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
5410
+ @target_sites = args[:target_sites] if args.key?(:target_sites)
5411
+ @total_size = args[:total_size] if args.key?(:total_size)
5412
+ end
5413
+ end
5414
+
5415
+ # Cloud FhirStore source import data from.
5416
+ class GoogleCloudDiscoveryengineV1alphaFhirStoreSource
5417
+ include Google::Apis::Core::Hashable
5418
+
5419
+ # Required. The full resource name of the FHIR store to import data from, in the
5420
+ # format of `projects/`project`/locations/`location`/datasets/`dataset`/
5421
+ # fhirStores/`fhir_store``.
5422
+ # Corresponds to the JSON property `fhirStore`
5423
+ # @return [String]
5424
+ attr_accessor :fhir_store
5425
+
5426
+ # Intermediate Cloud Storage directory used for the import with a length limit
5427
+ # of 2,000 characters. Can be specified if one wants to have the FhirStore
5428
+ # export to a specific Cloud Storage directory.
5429
+ # Corresponds to the JSON property `gcsStagingDir`
5430
+ # @return [String]
5431
+ attr_accessor :gcs_staging_dir
3804
5432
 
3805
5433
  def initialize(**args)
3806
5434
  update!(**args)
@@ -3808,9 +5436,8 @@ module Google
3808
5436
 
3809
5437
  # Update properties of this object
3810
5438
  def update!(**args)
3811
- @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
3812
- @target_sites = args[:target_sites] if args.key?(:target_sites)
3813
- @total_size = args[:total_size] if args.key?(:total_size)
5439
+ @fhir_store = args[:fhir_store] if args.key?(:fhir_store)
5440
+ @gcs_staging_dir = args[:gcs_staging_dir] if args.key?(:gcs_staging_dir)
3814
5441
  end
3815
5442
  end
3816
5443
 
@@ -3931,6 +5558,50 @@ module Google
3931
5558
  end
3932
5559
  end
3933
5560
 
5561
+ # Firestore source import data from.
5562
+ class GoogleCloudDiscoveryengineV1alphaFirestoreSource
5563
+ include Google::Apis::Core::Hashable
5564
+
5565
+ # Required. The Firestore collection to copy the data from with a length limit
5566
+ # of 1,500 characters.
5567
+ # Corresponds to the JSON property `collectionId`
5568
+ # @return [String]
5569
+ attr_accessor :collection_id
5570
+
5571
+ # Required. The Firestore database to copy the data from with a length limit of
5572
+ # 256 characters.
5573
+ # Corresponds to the JSON property `databaseId`
5574
+ # @return [String]
5575
+ attr_accessor :database_id
5576
+
5577
+ # Intermediate Cloud Storage directory used for the import with a length limit
5578
+ # of 2,000 characters. Can be specified if one wants to have the Firestore
5579
+ # export to a specific Cloud Storage directory. Please ensure that the Firestore
5580
+ # service account has the necessary Cloud Storage Admin permissions to access
5581
+ # the specified Cloud Storage directory.
5582
+ # Corresponds to the JSON property `gcsStagingDir`
5583
+ # @return [String]
5584
+ attr_accessor :gcs_staging_dir
5585
+
5586
+ # The project ID that the Cloud SQL source is in with a length limit of 128
5587
+ # characters. If not specified, inherits the project ID from the parent request.
5588
+ # Corresponds to the JSON property `projectId`
5589
+ # @return [String]
5590
+ attr_accessor :project_id
5591
+
5592
+ def initialize(**args)
5593
+ update!(**args)
5594
+ end
5595
+
5596
+ # Update properties of this object
5597
+ def update!(**args)
5598
+ @collection_id = args[:collection_id] if args.key?(:collection_id)
5599
+ @database_id = args[:database_id] if args.key?(:database_id)
5600
+ @gcs_staging_dir = args[:gcs_staging_dir] if args.key?(:gcs_staging_dir)
5601
+ @project_id = args[:project_id] if args.key?(:project_id)
5602
+ end
5603
+ end
5604
+
3934
5605
  # Cloud Storage location for input content.
3935
5606
  class GoogleCloudDiscoveryengineV1alphaGcsSource
3936
5607
  include Google::Apis::Core::Hashable
@@ -3941,11 +5612,11 @@ module Google
3941
5612
  # PDF, HTML). Each file matched by `input_uris` becomes a document, with the ID
3942
5613
  # set to the first 128 bits of SHA256(URI) encoded as a hex string. * `custom`:
3943
5614
  # One custom data JSON per row in arbitrary format that conforms to the defined
3944
- # Schema of the data store. This can only be used by Gen App Builder. * `csv`: A
3945
- # CSV file with header conforming to the defined Schema of the data store. Each
3946
- # entry after the header is imported as a Document. This can only be used by Gen
3947
- # App Builder. Supported values for user even imports: * `user_event` (default):
3948
- # One JSON UserEvent per line.
5615
+ # Schema of the data store. This can only be used by the GENERIC Data Store
5616
+ # vertical. * `csv`: A CSV file with header conforming to the defined Schema of
5617
+ # the data store. Each entry after the header is imported as a Document. This
5618
+ # can only be used by the GENERIC Data Store vertical. Supported values for user
5619
+ # even imports: * `user_event` (default): One JSON UserEvent per line.
3949
5620
  # Corresponds to the JSON property `dataSchema`
3950
5621
  # @return [String]
3951
5622
  attr_accessor :data_schema
@@ -3971,6 +5642,33 @@ module Google
3971
5642
  end
3972
5643
  end
3973
5644
 
5645
+ # Grounding Fact.
5646
+ class GoogleCloudDiscoveryengineV1alphaGroundingFact
5647
+ include Google::Apis::Core::Hashable
5648
+
5649
+ # Attributes associated with the fact. Common attributes include `source` (
5650
+ # indicating where the fact was sourced from), `author` (indicating the author
5651
+ # of the fact), and so on.
5652
+ # Corresponds to the JSON property `attributes`
5653
+ # @return [Hash<String,String>]
5654
+ attr_accessor :attributes
5655
+
5656
+ # Text content of the fact. Can be at most 10K characters long.
5657
+ # Corresponds to the JSON property `factText`
5658
+ # @return [String]
5659
+ attr_accessor :fact_text
5660
+
5661
+ def initialize(**args)
5662
+ update!(**args)
5663
+ end
5664
+
5665
+ # Update properties of this object
5666
+ def update!(**args)
5667
+ @attributes = args[:attributes] if args.key?(:attributes)
5668
+ @fact_text = args[:fact_text] if args.key?(:fact_text)
5669
+ end
5670
+ end
5671
+
3974
5672
  # Defines guided search spec.
3975
5673
  class GoogleCloudDiscoveryengineV1alphaGuidedSearchSpec
3976
5674
  include Google::Apis::Core::Hashable
@@ -4050,6 +5748,66 @@ module Google
4050
5748
  end
4051
5749
  end
4052
5750
 
5751
+ # Metadata related to the progress of the ImportCompletionSuggestions operation.
5752
+ # This will be returned by the google.longrunning.Operation.metadata field.
5753
+ class GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsMetadata
5754
+ include Google::Apis::Core::Hashable
5755
+
5756
+ # Operation create time.
5757
+ # Corresponds to the JSON property `createTime`
5758
+ # @return [String]
5759
+ attr_accessor :create_time
5760
+
5761
+ # Operation last update time. If the operation is done, this is also the finish
5762
+ # time.
5763
+ # Corresponds to the JSON property `updateTime`
5764
+ # @return [String]
5765
+ attr_accessor :update_time
5766
+
5767
+ def initialize(**args)
5768
+ update!(**args)
5769
+ end
5770
+
5771
+ # Update properties of this object
5772
+ def update!(**args)
5773
+ @create_time = args[:create_time] if args.key?(:create_time)
5774
+ @update_time = args[:update_time] if args.key?(:update_time)
5775
+ end
5776
+ end
5777
+
5778
+ # Response of the CompletionService.ImportCompletionSuggestions method. If the
5779
+ # long running operation is done, this message is returned by the google.
5780
+ # longrunning.Operations.response field if the operation is successful.
5781
+ class GoogleCloudDiscoveryengineV1alphaImportCompletionSuggestionsResponse
5782
+ include Google::Apis::Core::Hashable
5783
+
5784
+ # A sample of errors encountered while processing the request.
5785
+ # Corresponds to the JSON property `errorSamples`
5786
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleRpcStatus>]
5787
+ attr_accessor :error_samples
5788
+
5789
+ # Count of CompletionSuggestions that failed to be imported.
5790
+ # Corresponds to the JSON property `failureCount`
5791
+ # @return [Fixnum]
5792
+ attr_accessor :failure_count
5793
+
5794
+ # Count of CompletionSuggestions successfully imported.
5795
+ # Corresponds to the JSON property `successCount`
5796
+ # @return [Fixnum]
5797
+ attr_accessor :success_count
5798
+
5799
+ def initialize(**args)
5800
+ update!(**args)
5801
+ end
5802
+
5803
+ # Update properties of this object
5804
+ def update!(**args)
5805
+ @error_samples = args[:error_samples] if args.key?(:error_samples)
5806
+ @failure_count = args[:failure_count] if args.key?(:failure_count)
5807
+ @success_count = args[:success_count] if args.key?(:success_count)
5808
+ end
5809
+ end
5810
+
4053
5811
  # Metadata related to the progress of the ImportDocuments operation. This is
4054
5812
  # returned by the google.longrunning.Operation.metadata field.
4055
5813
  class GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata
@@ -4070,6 +5828,11 @@ module Google
4070
5828
  # @return [Fixnum]
4071
5829
  attr_accessor :success_count
4072
5830
 
5831
+ # Total count of entries that were processed.
5832
+ # Corresponds to the JSON property `totalCount`
5833
+ # @return [Fixnum]
5834
+ attr_accessor :total_count
5835
+
4073
5836
  # Operation last update time. If the operation is done, this is also the finish
4074
5837
  # time.
4075
5838
  # Corresponds to the JSON property `updateTime`
@@ -4085,6 +5848,7 @@ module Google
4085
5848
  @create_time = args[:create_time] if args.key?(:create_time)
4086
5849
  @failure_count = args[:failure_count] if args.key?(:failure_count)
4087
5850
  @success_count = args[:success_count] if args.key?(:success_count)
5851
+ @total_count = args[:total_count] if args.key?(:total_count)
4088
5852
  @update_time = args[:update_time] if args.key?(:update_time)
4089
5853
  end
4090
5854
  end
@@ -4098,10 +5862,11 @@ module Google
4098
5862
  # payload, where IDs may not be consistent during multiple imports. In which
4099
5863
  # case ReconciliationMode.FULL is highly recommended to avoid duplicate contents.
4100
5864
  # If unset or set to `false`, Document.ids have to be specified using id_field,
4101
- # otherwise, documents without IDs fail to be imported. Only set this field when
4102
- # using GcsSource or BigQuerySource, and when GcsSource.data_schema or
4103
- # BigQuerySource.data_schema is `custom` or `csv`. Otherwise, an
4104
- # INVALID_ARGUMENT error is thrown.
5865
+ # otherwise, documents without IDs fail to be imported. Supported data sources: *
5866
+ # GcsSource. GcsSource.data_schema must be `custom` or `csv`. Otherwise, an
5867
+ # INVALID_ARGUMENT error is thrown. * BigQuerySource. BigQuerySource.data_schema
5868
+ # must be `custom` or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown. *
5869
+ # SpannerSource. * CloudSqlSource. * FirestoreSource. * BigtableSource.
4105
5870
  # Corresponds to the JSON property `autoGenerateIds`
4106
5871
  # @return [Boolean]
4107
5872
  attr_accessor :auto_generate_ids
@@ -4112,29 +5877,51 @@ module Google
4112
5877
  # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaBigQuerySource]
4113
5878
  attr_accessor :bigquery_source
4114
5879
 
5880
+ # The Cloud Bigtable source for importing data.
5881
+ # Corresponds to the JSON property `bigtableSource`
5882
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaBigtableSource]
5883
+ attr_accessor :bigtable_source
5884
+
5885
+ # Cloud SQL source import data from.
5886
+ # Corresponds to the JSON property `cloudSqlSource`
5887
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaCloudSqlSource]
5888
+ attr_accessor :cloud_sql_source
5889
+
4115
5890
  # Configuration of destination for Import related errors.
4116
5891
  # Corresponds to the JSON property `errorConfig`
4117
5892
  # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaImportErrorConfig]
4118
5893
  attr_accessor :error_config
4119
5894
 
5895
+ # Cloud FhirStore source import data from.
5896
+ # Corresponds to the JSON property `fhirStoreSource`
5897
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaFhirStoreSource]
5898
+ attr_accessor :fhir_store_source
5899
+
5900
+ # Firestore source import data from.
5901
+ # Corresponds to the JSON property `firestoreSource`
5902
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaFirestoreSource]
5903
+ attr_accessor :firestore_source
5904
+
4120
5905
  # Cloud Storage location for input content.
4121
5906
  # Corresponds to the JSON property `gcsSource`
4122
5907
  # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaGcsSource]
4123
5908
  attr_accessor :gcs_source
4124
5909
 
4125
- # The field in the Cloud Storage and BigQuery sources that indicates the unique
4126
- # IDs of the documents. For GcsSource it is the key of the JSON field. For
4127
- # instance, `my_id` for JSON ``"my_id": "some_uuid"``. For BigQuerySource it is
4128
- # the column name of the BigQuery table where the unique ids are stored. The
4129
- # values of the JSON field or the BigQuery column are used as the Document.ids.
4130
- # The JSON field or the BigQuery column must be of string type, and the values
4131
- # must be set as valid strings conform to [RFC-1034](https://tools.ietf.org/html/
4132
- # rfc1034) with 1-63 characters. Otherwise, documents without valid IDs fail to
4133
- # be imported. Only set this field when using GcsSource or BigQuerySource, and
4134
- # when GcsSource.data_schema or BigQuerySource.data_schema is `custom`. And only
4135
- # set this field when auto_generate_ids is unset or set as `false`. Otherwise,
4136
- # an INVALID_ARGUMENT error is thrown. If it is unset, a default value `_id` is
4137
- # used when importing from the allowed data sources.
5910
+ # The field indicates the ID field or column to be used as unique IDs of the
5911
+ # documents. For GcsSource it is the key of the JSON field. For instance, `my_id`
5912
+ # for JSON ``"my_id": "some_uuid"``. For others, it may be the column name of
5913
+ # the table where the unique ids are stored. The values of the JSON field or the
5914
+ # table column are used as the Document.ids. The JSON field or the table column
5915
+ # must be of string type, and the values must be set as valid strings conform to
5916
+ # [RFC-1034](https://tools.ietf.org/html/rfc1034) with 1-63 characters.
5917
+ # Otherwise, documents without valid IDs fail to be imported. Only set this
5918
+ # field when auto_generate_ids is unset or set as `false`. Otherwise, an
5919
+ # INVALID_ARGUMENT error is thrown. If it is unset, a default value `_id` is
5920
+ # used when importing from the allowed data sources. Supported data sources: *
5921
+ # GcsSource. GcsSource.data_schema must be `custom` or `csv`. Otherwise, an
5922
+ # INVALID_ARGUMENT error is thrown. * BigQuerySource. BigQuerySource.data_schema
5923
+ # must be `custom` or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown. *
5924
+ # SpannerSource. * CloudSqlSource. * FirestoreSource. * BigtableSource.
4138
5925
  # Corresponds to the JSON property `idField`
4139
5926
  # @return [String]
4140
5927
  attr_accessor :id_field
@@ -4150,6 +5937,17 @@ module Google
4150
5937
  # @return [String]
4151
5938
  attr_accessor :reconciliation_mode
4152
5939
 
5940
+ # The Spanner source for importing data
5941
+ # Corresponds to the JSON property `spannerSource`
5942
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaSpannerSource]
5943
+ attr_accessor :spanner_source
5944
+
5945
+ # Indicates which fields in the provided imported documents to update. If not
5946
+ # set, the default is to update all fields.
5947
+ # Corresponds to the JSON property `updateMask`
5948
+ # @return [String]
5949
+ attr_accessor :update_mask
5950
+
4153
5951
  def initialize(**args)
4154
5952
  update!(**args)
4155
5953
  end
@@ -4158,11 +5956,17 @@ module Google
4158
5956
  def update!(**args)
4159
5957
  @auto_generate_ids = args[:auto_generate_ids] if args.key?(:auto_generate_ids)
4160
5958
  @bigquery_source = args[:bigquery_source] if args.key?(:bigquery_source)
5959
+ @bigtable_source = args[:bigtable_source] if args.key?(:bigtable_source)
5960
+ @cloud_sql_source = args[:cloud_sql_source] if args.key?(:cloud_sql_source)
4161
5961
  @error_config = args[:error_config] if args.key?(:error_config)
5962
+ @fhir_store_source = args[:fhir_store_source] if args.key?(:fhir_store_source)
5963
+ @firestore_source = args[:firestore_source] if args.key?(:firestore_source)
4162
5964
  @gcs_source = args[:gcs_source] if args.key?(:gcs_source)
4163
5965
  @id_field = args[:id_field] if args.key?(:id_field)
4164
5966
  @inline_source = args[:inline_source] if args.key?(:inline_source)
4165
5967
  @reconciliation_mode = args[:reconciliation_mode] if args.key?(:reconciliation_mode)
5968
+ @spanner_source = args[:spanner_source] if args.key?(:spanner_source)
5969
+ @update_mask = args[:update_mask] if args.key?(:update_mask)
4166
5970
  end
4167
5971
  end
4168
5972
 
@@ -4687,6 +6491,31 @@ module Google
4687
6491
  end
4688
6492
  end
4689
6493
 
6494
+ # Response for ListSessions method.
6495
+ class GoogleCloudDiscoveryengineV1alphaListSessionsResponse
6496
+ include Google::Apis::Core::Hashable
6497
+
6498
+ # Pagination token, if not returned indicates the last page.
6499
+ # Corresponds to the JSON property `nextPageToken`
6500
+ # @return [String]
6501
+ attr_accessor :next_page_token
6502
+
6503
+ # All the Sessions for a given data store.
6504
+ # Corresponds to the JSON property `sessions`
6505
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaSession>]
6506
+ attr_accessor :sessions
6507
+
6508
+ def initialize(**args)
6509
+ update!(**args)
6510
+ end
6511
+
6512
+ # Update properties of this object
6513
+ def update!(**args)
6514
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
6515
+ @sessions = args[:sessions] if args.key?(:sessions)
6516
+ end
6517
+ end
6518
+
4690
6519
  # Response message for SiteSearchEngineService.ListTargetSites method.
4691
6520
  class GoogleCloudDiscoveryengineV1alphaListTargetSitesResponse
4692
6521
  include Google::Apis::Core::Hashable
@@ -5161,23 +6990,156 @@ module Google
5161
6990
  # Operation create time.
5162
6991
  # Corresponds to the JSON property `createTime`
5163
6992
  # @return [String]
5164
- attr_accessor :create_time
6993
+ attr_accessor :create_time
6994
+
6995
+ # Count of entries that encountered errors while processing.
6996
+ # Corresponds to the JSON property `failureCount`
6997
+ # @return [Fixnum]
6998
+ attr_accessor :failure_count
6999
+
7000
+ # Count of entries that were deleted successfully.
7001
+ # Corresponds to the JSON property `successCount`
7002
+ # @return [Fixnum]
7003
+ attr_accessor :success_count
7004
+
7005
+ # Operation last update time. If the operation is done, this is also the finish
7006
+ # time.
7007
+ # Corresponds to the JSON property `updateTime`
7008
+ # @return [String]
7009
+ attr_accessor :update_time
7010
+
7011
+ def initialize(**args)
7012
+ update!(**args)
7013
+ end
7014
+
7015
+ # Update properties of this object
7016
+ def update!(**args)
7017
+ @create_time = args[:create_time] if args.key?(:create_time)
7018
+ @failure_count = args[:failure_count] if args.key?(:failure_count)
7019
+ @success_count = args[:success_count] if args.key?(:success_count)
7020
+ @update_time = args[:update_time] if args.key?(:update_time)
7021
+ end
7022
+ end
7023
+
7024
+ # Request message for PurgeUserEvents method.
7025
+ class GoogleCloudDiscoveryengineV1alphaPurgeUserEventsRequest
7026
+ include Google::Apis::Core::Hashable
7027
+
7028
+ # Required. The filter string to specify the events to be deleted with a length
7029
+ # limit of 5,000 characters. The eligible fields for filtering are: * `eventType`
7030
+ # : Double quoted UserEvent.event_type string. * `eventTime`: in ISO 8601 "zulu"
7031
+ # format. * `userPseudoId`: Double quoted string. Specifying this will delete
7032
+ # all events associated with a visitor. * `userId`: Double quoted string.
7033
+ # Specifying this will delete all events associated with a user. Examples: *
7034
+ # Deleting all events in a time range: `eventTime > "2012-04-23T18:25:43.511Z"
7035
+ # eventTime < "2012-04-23T18:30:43.511Z"` * Deleting specific eventType: `
7036
+ # eventType = "search"` * Deleting all events for a specific visitor: `
7037
+ # userPseudoId = "visitor1024"` * Deleting all events inside a DataStore: `*`
7038
+ # The filtering fields are assumed to have an implicit AND.
7039
+ # Corresponds to the JSON property `filter`
7040
+ # @return [String]
7041
+ attr_accessor :filter
7042
+
7043
+ # The `force` field is currently not supported. Purge user event requests will
7044
+ # permanently delete all purgeable events. Once the development is complete: If `
7045
+ # force` is set to false, the method will return the expected purge count
7046
+ # without deleting any user events. This field will default to false if not
7047
+ # included in the request.
7048
+ # Corresponds to the JSON property `force`
7049
+ # @return [Boolean]
7050
+ attr_accessor :force
7051
+ alias_method :force?, :force
7052
+
7053
+ def initialize(**args)
7054
+ update!(**args)
7055
+ end
7056
+
7057
+ # Update properties of this object
7058
+ def update!(**args)
7059
+ @filter = args[:filter] if args.key?(:filter)
7060
+ @force = args[:force] if args.key?(:force)
7061
+ end
7062
+ end
7063
+
7064
+ # Response of the PurgeUserEventsRequest. If the long running operation is
7065
+ # successfully done, then this message is returned by the google.longrunning.
7066
+ # Operations.response field.
7067
+ class GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse
7068
+ include Google::Apis::Core::Hashable
7069
+
7070
+ # The total count of events purged as a result of the operation.
7071
+ # Corresponds to the JSON property `purgeCount`
7072
+ # @return [Fixnum]
7073
+ attr_accessor :purge_count
7074
+
7075
+ def initialize(**args)
7076
+ update!(**args)
7077
+ end
7078
+
7079
+ # Update properties of this object
7080
+ def update!(**args)
7081
+ @purge_count = args[:purge_count] if args.key?(:purge_count)
7082
+ end
7083
+ end
7084
+
7085
+ # Defines a user inputed query.
7086
+ class GoogleCloudDiscoveryengineV1alphaQuery
7087
+ include Google::Apis::Core::Hashable
7088
+
7089
+ # Unique Id for the query.
7090
+ # Corresponds to the JSON property `queryId`
7091
+ # @return [String]
7092
+ attr_accessor :query_id
7093
+
7094
+ # Plain text.
7095
+ # Corresponds to the JSON property `text`
7096
+ # @return [String]
7097
+ attr_accessor :text
7098
+
7099
+ def initialize(**args)
7100
+ update!(**args)
7101
+ end
7102
+
7103
+ # Update properties of this object
7104
+ def update!(**args)
7105
+ @query_id = args[:query_id] if args.key?(:query_id)
7106
+ @text = args[:text] if args.key?(:text)
7107
+ end
7108
+ end
7109
+
7110
+ # Request message for RankService.Rank method.
7111
+ class GoogleCloudDiscoveryengineV1alphaRankRequest
7112
+ include Google::Apis::Core::Hashable
7113
+
7114
+ # If true, the response will contain only record ID and score. By default, it is
7115
+ # false, the response will contain record details.
7116
+ # Corresponds to the JSON property `ignoreRecordDetailsInResponse`
7117
+ # @return [Boolean]
7118
+ attr_accessor :ignore_record_details_in_response
7119
+ alias_method :ignore_record_details_in_response?, :ignore_record_details_in_response
7120
+
7121
+ # The identifier of the model to use. It is one of: * `semantic-ranker-512@
7122
+ # latest`: Semantic ranking model with maxiumn input token size 512. It is set
7123
+ # to `semantic-ranker-512@latest` by default if unspecified.
7124
+ # Corresponds to the JSON property `model`
7125
+ # @return [String]
7126
+ attr_accessor :model
7127
+
7128
+ # The query to use.
7129
+ # Corresponds to the JSON property `query`
7130
+ # @return [String]
7131
+ attr_accessor :query
5165
7132
 
5166
- # Count of entries that encountered errors while processing.
5167
- # Corresponds to the JSON property `failureCount`
5168
- # @return [Fixnum]
5169
- attr_accessor :failure_count
7133
+ # Required. A list of records to rank. At most 100 records to rank.
7134
+ # Corresponds to the JSON property `records`
7135
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaRankingRecord>]
7136
+ attr_accessor :records
5170
7137
 
5171
- # Count of entries that were deleted successfully.
5172
- # Corresponds to the JSON property `successCount`
7138
+ # The number of results to return. If this is unset or no bigger than zero,
7139
+ # returns all results.
7140
+ # Corresponds to the JSON property `topN`
5173
7141
  # @return [Fixnum]
5174
- attr_accessor :success_count
5175
-
5176
- # Operation last update time. If the operation is done, this is also the finish
5177
- # time.
5178
- # Corresponds to the JSON property `updateTime`
5179
- # @return [String]
5180
- attr_accessor :update_time
7142
+ attr_accessor :top_n
5181
7143
 
5182
7144
  def initialize(**args)
5183
7145
  update!(**args)
@@ -5185,41 +7147,22 @@ module Google
5185
7147
 
5186
7148
  # Update properties of this object
5187
7149
  def update!(**args)
5188
- @create_time = args[:create_time] if args.key?(:create_time)
5189
- @failure_count = args[:failure_count] if args.key?(:failure_count)
5190
- @success_count = args[:success_count] if args.key?(:success_count)
5191
- @update_time = args[:update_time] if args.key?(:update_time)
7150
+ @ignore_record_details_in_response = args[:ignore_record_details_in_response] if args.key?(:ignore_record_details_in_response)
7151
+ @model = args[:model] if args.key?(:model)
7152
+ @query = args[:query] if args.key?(:query)
7153
+ @records = args[:records] if args.key?(:records)
7154
+ @top_n = args[:top_n] if args.key?(:top_n)
5192
7155
  end
5193
7156
  end
5194
7157
 
5195
- # Request message for PurgeUserEvents method.
5196
- class GoogleCloudDiscoveryengineV1alphaPurgeUserEventsRequest
7158
+ # Response message for RankService.Rank method.
7159
+ class GoogleCloudDiscoveryengineV1alphaRankResponse
5197
7160
  include Google::Apis::Core::Hashable
5198
7161
 
5199
- # Required. The filter string to specify the events to be deleted with a length
5200
- # limit of 5,000 characters. The eligible fields for filtering are: * `eventType`
5201
- # : Double quoted UserEvent.event_type string. * `eventTime`: in ISO 8601 "zulu"
5202
- # format. * `userPseudoId`: Double quoted string. Specifying this will delete
5203
- # all events associated with a visitor. * `userId`: Double quoted string.
5204
- # Specifying this will delete all events associated with a user. Examples: *
5205
- # Deleting all events in a time range: `eventTime > "2012-04-23T18:25:43.511Z"
5206
- # eventTime < "2012-04-23T18:30:43.511Z"` * Deleting specific eventType: `
5207
- # eventType = "search"` * Deleting all events for a specific visitor: `
5208
- # userPseudoId = "visitor1024"` * Deleting all events inside a DataStore: `*`
5209
- # The filtering fields are assumed to have an implicit AND.
5210
- # Corresponds to the JSON property `filter`
5211
- # @return [String]
5212
- attr_accessor :filter
5213
-
5214
- # The `force` field is currently not supported. Purge user event requests will
5215
- # permanently delete all purgeable events. Once the development is complete: If `
5216
- # force` is set to false, the method will return the expected purge count
5217
- # without deleting any user events. This field will default to false if not
5218
- # included in the request.
5219
- # Corresponds to the JSON property `force`
5220
- # @return [Boolean]
5221
- attr_accessor :force
5222
- alias_method :force?, :force
7162
+ # A list of records sorted by descending score.
7163
+ # Corresponds to the JSON property `records`
7164
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaRankingRecord>]
7165
+ attr_accessor :records
5223
7166
 
5224
7167
  def initialize(**args)
5225
7168
  update!(**args)
@@ -5227,21 +7170,35 @@ module Google
5227
7170
 
5228
7171
  # Update properties of this object
5229
7172
  def update!(**args)
5230
- @filter = args[:filter] if args.key?(:filter)
5231
- @force = args[:force] if args.key?(:force)
7173
+ @records = args[:records] if args.key?(:records)
5232
7174
  end
5233
7175
  end
5234
7176
 
5235
- # Response of the PurgeUserEventsRequest. If the long running operation is
5236
- # successfully done, then this message is returned by the google.longrunning.
5237
- # Operations.response field.
5238
- class GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse
7177
+ # Record message for RankService.Rank method.
7178
+ class GoogleCloudDiscoveryengineV1alphaRankingRecord
5239
7179
  include Google::Apis::Core::Hashable
5240
7180
 
5241
- # The total count of events purged as a result of the operation.
5242
- # Corresponds to the JSON property `purgeCount`
5243
- # @return [Fixnum]
5244
- attr_accessor :purge_count
7181
+ # The content of the record. Empty by default. At least one of title or content
7182
+ # should be set otherwise an INVALID_ARGUMENT error is thrown.
7183
+ # Corresponds to the JSON property `content`
7184
+ # @return [String]
7185
+ attr_accessor :content
7186
+
7187
+ # The unique ID to represent the record.
7188
+ # Corresponds to the JSON property `id`
7189
+ # @return [String]
7190
+ attr_accessor :id
7191
+
7192
+ # The score of this record based on the given query and selected model.
7193
+ # Corresponds to the JSON property `score`
7194
+ # @return [Float]
7195
+ attr_accessor :score
7196
+
7197
+ # The title of the record. Empty by default. At least one of title or content
7198
+ # should be set otherwise an INVALID_ARGUMENT error is thrown.
7199
+ # Corresponds to the JSON property `title`
7200
+ # @return [String]
7201
+ attr_accessor :title
5245
7202
 
5246
7203
  def initialize(**args)
5247
7204
  update!(**args)
@@ -5249,7 +7206,10 @@ module Google
5249
7206
 
5250
7207
  # Update properties of this object
5251
7208
  def update!(**args)
5252
- @purge_count = args[:purge_count] if args.key?(:purge_count)
7209
+ @content = args[:content] if args.key?(:content)
7210
+ @id = args[:id] if args.key?(:id)
7211
+ @score = args[:score] if args.key?(:score)
7212
+ @title = args[:title] if args.key?(:title)
5253
7213
  end
5254
7214
  end
5255
7215
 
@@ -5842,9 +7802,11 @@ module Google
5842
7802
  # @return [String]
5843
7803
  attr_accessor :order_by
5844
7804
 
5845
- # Maximum number of Documents to return. If unspecified, defaults to a
5846
- # reasonable value. The maximum allowed value is 100. Values above 100 are
5847
- # coerced to 100. If this field is negative, an `INVALID_ARGUMENT` is returned.
7805
+ # Maximum number of Documents to return. The maximum allowed value depends on
7806
+ # the data type. Values above the maximum value are coerced to the maximum value.
7807
+ # * Websites with basic indexing: Default `10`, Maximum `25`. * Websites with
7808
+ # advanced indexing: Default `25`, Maximum `50`. * Other: Default `50`, Maximum `
7809
+ # 100`. If this field is negative, an `INVALID_ARGUMENT` is returned.
5848
7810
  # Corresponds to the JSON property `pageSize`
5849
7811
  # @return [Fixnum]
5850
7812
  attr_accessor :page_size
@@ -6023,6 +7985,13 @@ module Google
6023
7985
  # @return [Float]
6024
7986
  attr_accessor :boost
6025
7987
 
7988
+ # Specification for custom ranking based on customer specified attribute value.
7989
+ # It provides more controls for customized ranking than the simple (condition,
7990
+ # boost) combination above.
7991
+ # Corresponds to the JSON property `boostControlSpec`
7992
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpec]
7993
+ attr_accessor :boost_control_spec
7994
+
6026
7995
  # An expression which specifies a boost condition. The syntax and supported
6027
7996
  # fields are the same as a filter expression. See SearchRequest.filter for
6028
7997
  # detail syntax and limitations. Examples: * To boost documents with document ID
@@ -6039,14 +8008,99 @@ module Google
6039
8008
  # Update properties of this object
6040
8009
  def update!(**args)
6041
8010
  @boost = args[:boost] if args.key?(:boost)
8011
+ @boost_control_spec = args[:boost_control_spec] if args.key?(:boost_control_spec)
6042
8012
  @condition = args[:condition] if args.key?(:condition)
6043
8013
  end
6044
8014
  end
6045
8015
 
8016
+ # Specification for custom ranking based on customer specified attribute value.
8017
+ # It provides more controls for customized ranking than the simple (condition,
8018
+ # boost) combination above.
8019
+ class GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpec
8020
+ include Google::Apis::Core::Hashable
8021
+
8022
+ # The attribute type to be used to determine the boost amount. The attribute
8023
+ # value can be derived from the field value of the specified field_name. In the
8024
+ # case of numerical it is straightforward i.e. attribute_value =
8025
+ # numerical_field_value. In the case of freshness however, attribute_value = (
8026
+ # time.now() - datetime_field_value).
8027
+ # Corresponds to the JSON property `attributeType`
8028
+ # @return [String]
8029
+ attr_accessor :attribute_type
8030
+
8031
+ # The control points used to define the curve. The monotonic function (defined
8032
+ # through the interpolation_type above) passes through the control points listed
8033
+ # here.
8034
+ # Corresponds to the JSON property `controlPoints`
8035
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint>]
8036
+ attr_accessor :control_points
8037
+
8038
+ # The name of the field whose value will be used to determine the boost amount.
8039
+ # Corresponds to the JSON property `fieldName`
8040
+ # @return [String]
8041
+ attr_accessor :field_name
8042
+
8043
+ # The interpolation type to be applied to connect the control points listed
8044
+ # below.
8045
+ # Corresponds to the JSON property `interpolationType`
8046
+ # @return [String]
8047
+ attr_accessor :interpolation_type
8048
+
8049
+ def initialize(**args)
8050
+ update!(**args)
8051
+ end
8052
+
8053
+ # Update properties of this object
8054
+ def update!(**args)
8055
+ @attribute_type = args[:attribute_type] if args.key?(:attribute_type)
8056
+ @control_points = args[:control_points] if args.key?(:control_points)
8057
+ @field_name = args[:field_name] if args.key?(:field_name)
8058
+ @interpolation_type = args[:interpolation_type] if args.key?(:interpolation_type)
8059
+ end
8060
+ end
8061
+
8062
+ # The control points used to define the curve. The curve defined through these
8063
+ # control points can only be monotonically increasing or decreasing(constant
8064
+ # values are acceptable).
8065
+ class GoogleCloudDiscoveryengineV1alphaSearchRequestBoostSpecConditionBoostSpecBoostControlSpecControlPoint
8066
+ include Google::Apis::Core::Hashable
8067
+
8068
+ # Can be one of: 1. The numerical field value. 2. The duration spec for
8069
+ # freshness: The value must be formatted as an XSD `dayTimeDuration` value (a
8070
+ # restricted subset of an ISO 8601 duration value). The pattern for this is: `
8071
+ # nDnM]`.
8072
+ # Corresponds to the JSON property `attributeValue`
8073
+ # @return [String]
8074
+ attr_accessor :attribute_value
8075
+
8076
+ # The value between -1 to 1 by which to boost the score if the attribute_value
8077
+ # evaluates to the value specified above.
8078
+ # Corresponds to the JSON property `boostAmount`
8079
+ # @return [Float]
8080
+ attr_accessor :boost_amount
8081
+
8082
+ def initialize(**args)
8083
+ update!(**args)
8084
+ end
8085
+
8086
+ # Update properties of this object
8087
+ def update!(**args)
8088
+ @attribute_value = args[:attribute_value] if args.key?(:attribute_value)
8089
+ @boost_amount = args[:boost_amount] if args.key?(:boost_amount)
8090
+ end
8091
+ end
8092
+
6046
8093
  # A specification for configuring the behavior of content search.
6047
8094
  class GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec
6048
8095
  include Google::Apis::Core::Hashable
6049
8096
 
8097
+ # Specifies the chunk spec to be returned from the search response. Only
8098
+ # available if the SearchRequest.ContentSearchSpec.search_result_mode is set to
8099
+ # CHUNKS
8100
+ # Corresponds to the JSON property `chunkSpec`
8101
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecChunkSpec]
8102
+ attr_accessor :chunk_spec
8103
+
6050
8104
  # A specification for configuring the extractive content in a search response.
6051
8105
  # Corresponds to the JSON property `extractiveContentSpec`
6052
8106
  # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec]
@@ -6076,6 +8130,7 @@ module Google
6076
8130
 
6077
8131
  # Update properties of this object
6078
8132
  def update!(**args)
8133
+ @chunk_spec = args[:chunk_spec] if args.key?(:chunk_spec)
6079
8134
  @extractive_content_spec = args[:extractive_content_spec] if args.key?(:extractive_content_spec)
6080
8135
  @search_result_mode = args[:search_result_mode] if args.key?(:search_result_mode)
6081
8136
  @snippet_spec = args[:snippet_spec] if args.key?(:snippet_spec)
@@ -6083,6 +8138,35 @@ module Google
6083
8138
  end
6084
8139
  end
6085
8140
 
8141
+ # Specifies the chunk spec to be returned from the search response. Only
8142
+ # available if the SearchRequest.ContentSearchSpec.search_result_mode is set to
8143
+ # CHUNKS
8144
+ class GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecChunkSpec
8145
+ include Google::Apis::Core::Hashable
8146
+
8147
+ # The number of next chunks to be returned of the current chunk. The maximum
8148
+ # allowed value is 3. If not specified, no next chunks will be returned.
8149
+ # Corresponds to the JSON property `numNextChunks`
8150
+ # @return [Fixnum]
8151
+ attr_accessor :num_next_chunks
8152
+
8153
+ # The number of previous chunks to be returned of the current chunk. The maximum
8154
+ # allowed value is 3. If not specified, no previous chunks will be returned.
8155
+ # Corresponds to the JSON property `numPreviousChunks`
8156
+ # @return [Fixnum]
8157
+ attr_accessor :num_previous_chunks
8158
+
8159
+ def initialize(**args)
8160
+ update!(**args)
8161
+ end
8162
+
8163
+ # Update properties of this object
8164
+ def update!(**args)
8165
+ @num_next_chunks = args[:num_next_chunks] if args.key?(:num_next_chunks)
8166
+ @num_previous_chunks = args[:num_previous_chunks] if args.key?(:num_previous_chunks)
8167
+ end
8168
+ end
8169
+
6086
8170
  # A specification for configuring the extractive content in a search response.
6087
8171
  class GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecExtractiveContentSpec
6088
8172
  include Google::Apis::Core::Hashable
@@ -7018,6 +9102,11 @@ module Google
7018
9102
  class GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference
7019
9103
  include Google::Apis::Core::Hashable
7020
9104
 
9105
+ # List of cited chunk contents derived from document content.
9106
+ # Corresponds to the JSON property `chunkContents`
9107
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReferenceChunkContent>]
9108
+ attr_accessor :chunk_contents
9109
+
7021
9110
  # Required. Document.name of the document. Full resource name of the referenced
7022
9111
  # document, in the format `projects/*/locations/*/collections/*/dataStores/*/
7023
9112
  # branches/*/documents/*`.
@@ -7041,12 +9130,38 @@ module Google
7041
9130
 
7042
9131
  # Update properties of this object
7043
9132
  def update!(**args)
9133
+ @chunk_contents = args[:chunk_contents] if args.key?(:chunk_contents)
7044
9134
  @document = args[:document] if args.key?(:document)
7045
9135
  @title = args[:title] if args.key?(:title)
7046
9136
  @uri = args[:uri] if args.key?(:uri)
7047
9137
  end
7048
9138
  end
7049
9139
 
9140
+ # Chunk content.
9141
+ class GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReferenceChunkContent
9142
+ include Google::Apis::Core::Hashable
9143
+
9144
+ # Chunk textual content.
9145
+ # Corresponds to the JSON property `content`
9146
+ # @return [String]
9147
+ attr_accessor :content
9148
+
9149
+ # Page identifier.
9150
+ # Corresponds to the JSON property `pageIdentifier`
9151
+ # @return [String]
9152
+ attr_accessor :page_identifier
9153
+
9154
+ def initialize(**args)
9155
+ update!(**args)
9156
+ end
9157
+
9158
+ # Update properties of this object
9159
+ def update!(**args)
9160
+ @content = args[:content] if args.key?(:content)
9161
+ @page_identifier = args[:page_identifier] if args.key?(:page_identifier)
9162
+ end
9163
+ end
9164
+
7050
9165
  # Safety Attribute categories and their associated confidence scores.
7051
9166
  class GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySafetyAttributes
7052
9167
  include Google::Apis::Core::Hashable
@@ -7373,6 +9488,81 @@ module Google
7373
9488
  end
7374
9489
  end
7375
9490
 
9491
+ # External session proto definition.
9492
+ class GoogleCloudDiscoveryengineV1alphaSession
9493
+ include Google::Apis::Core::Hashable
9494
+
9495
+ # Output only. The time the session finished.
9496
+ # Corresponds to the JSON property `endTime`
9497
+ # @return [String]
9498
+ attr_accessor :end_time
9499
+
9500
+ # Immutable. Fully qualified name `project/*/locations/global/collections/`
9501
+ # collection`/engines/`engine`/sessions/*`
9502
+ # Corresponds to the JSON property `name`
9503
+ # @return [String]
9504
+ attr_accessor :name
9505
+
9506
+ # Output only. The time the session started.
9507
+ # Corresponds to the JSON property `startTime`
9508
+ # @return [String]
9509
+ attr_accessor :start_time
9510
+
9511
+ # The state of the session.
9512
+ # Corresponds to the JSON property `state`
9513
+ # @return [String]
9514
+ attr_accessor :state
9515
+
9516
+ # Turns.
9517
+ # Corresponds to the JSON property `turns`
9518
+ # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaSessionTurn>]
9519
+ attr_accessor :turns
9520
+
9521
+ # A unique identifier for tracking users.
9522
+ # Corresponds to the JSON property `userPseudoId`
9523
+ # @return [String]
9524
+ attr_accessor :user_pseudo_id
9525
+
9526
+ def initialize(**args)
9527
+ update!(**args)
9528
+ end
9529
+
9530
+ # Update properties of this object
9531
+ def update!(**args)
9532
+ @end_time = args[:end_time] if args.key?(:end_time)
9533
+ @name = args[:name] if args.key?(:name)
9534
+ @start_time = args[:start_time] if args.key?(:start_time)
9535
+ @state = args[:state] if args.key?(:state)
9536
+ @turns = args[:turns] if args.key?(:turns)
9537
+ @user_pseudo_id = args[:user_pseudo_id] if args.key?(:user_pseudo_id)
9538
+ end
9539
+ end
9540
+
9541
+ # Represents a turn, including a query from the user and a answer from service.
9542
+ class GoogleCloudDiscoveryengineV1alphaSessionTurn
9543
+ include Google::Apis::Core::Hashable
9544
+
9545
+ # The resource name of the answer to the user query.
9546
+ # Corresponds to the JSON property `answer`
9547
+ # @return [String]
9548
+ attr_accessor :answer
9549
+
9550
+ # Defines a user inputed query.
9551
+ # Corresponds to the JSON property `query`
9552
+ # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaQuery]
9553
+ attr_accessor :query
9554
+
9555
+ def initialize(**args)
9556
+ update!(**args)
9557
+ end
9558
+
9559
+ # Update properties of this object
9560
+ def update!(**args)
9561
+ @answer = args[:answer] if args.key?(:answer)
9562
+ @query = args[:query] if args.key?(:query)
9563
+ end
9564
+ end
9565
+
7376
9566
  # SiteSearchEngine captures DataStore level site search persisting
7377
9567
  # configurations. It is a singleton value per data store.
7378
9568
  class GoogleCloudDiscoveryengineV1alphaSiteSearchEngine
@@ -7419,6 +9609,53 @@ module Google
7419
9609
  end
7420
9610
  end
7421
9611
 
9612
+ # The Spanner source for importing data
9613
+ class GoogleCloudDiscoveryengineV1alphaSpannerSource
9614
+ include Google::Apis::Core::Hashable
9615
+
9616
+ # Required. The database ID of the source Spanner table.
9617
+ # Corresponds to the JSON property `databaseId`
9618
+ # @return [String]
9619
+ attr_accessor :database_id
9620
+
9621
+ # Whether to apply data boost on Spanner export. Enabling this option will incur
9622
+ # additional cost. More info can be found [here](https://cloud.google.com/
9623
+ # spanner/docs/databoost/databoost-overview#billing_and_quotas).
9624
+ # Corresponds to the JSON property `enableDataBoost`
9625
+ # @return [Boolean]
9626
+ attr_accessor :enable_data_boost
9627
+ alias_method :enable_data_boost?, :enable_data_boost
9628
+
9629
+ # Required. The instance ID of the source Spanner table.
9630
+ # Corresponds to the JSON property `instanceId`
9631
+ # @return [String]
9632
+ attr_accessor :instance_id
9633
+
9634
+ # The project ID that the Spanner source is in with a length limit of 128
9635
+ # characters. If not specified, inherits the project ID from the parent request.
9636
+ # Corresponds to the JSON property `projectId`
9637
+ # @return [String]
9638
+ attr_accessor :project_id
9639
+
9640
+ # Required. The table name of the Spanner database that needs to be imported.
9641
+ # Corresponds to the JSON property `tableId`
9642
+ # @return [String]
9643
+ attr_accessor :table_id
9644
+
9645
+ def initialize(**args)
9646
+ update!(**args)
9647
+ end
9648
+
9649
+ # Update properties of this object
9650
+ def update!(**args)
9651
+ @database_id = args[:database_id] if args.key?(:database_id)
9652
+ @enable_data_boost = args[:enable_data_boost] if args.key?(:enable_data_boost)
9653
+ @instance_id = args[:instance_id] if args.key?(:instance_id)
9654
+ @project_id = args[:project_id] if args.key?(:project_id)
9655
+ @table_id = args[:table_id] if args.key?(:table_id)
9656
+ end
9657
+ end
9658
+
7422
9659
  # Suggestion deny list entry identifying the phrase to block from suggestions
7423
9660
  # and the applied operation for the phrase.
7424
9661
  class GoogleCloudDiscoveryengineV1alphaSuggestionDenyListEntry
@@ -7712,10 +9949,17 @@ module Google
7712
9949
  # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleRpcStatus>]
7713
9950
  attr_accessor :error_samples
7714
9951
 
9952
+ # The metrics of the trained model.
9953
+ # Corresponds to the JSON property `metrics`
9954
+ # @return [Hash<String,Float>]
9955
+ attr_accessor :metrics
9956
+
7715
9957
  # The trained model status. Possible values are: * **bad-data**: The training
7716
9958
  # data quality is bad. * **no-improvement**: Tuning didn't improve performance.
7717
- # Won't deploy. * **in-progress**: Model training is in progress. * **ready**:
7718
- # The model is ready for serving.
9959
+ # Won't deploy. * **in-progress**: Model training job creation is in progress. *
9960
+ # **training**: Model is actively training. * **evaluating**: The model is
9961
+ # evaluating trained metrics. * **indexing**: The model trained metrics are
9962
+ # indexing. * **ready**: The model is ready for serving.
7719
9963
  # Corresponds to the JSON property `modelStatus`
7720
9964
  # @return [String]
7721
9965
  attr_accessor :model_status
@@ -7728,6 +9972,7 @@ module Google
7728
9972
  def update!(**args)
7729
9973
  @error_config = args[:error_config] if args.key?(:error_config)
7730
9974
  @error_samples = args[:error_samples] if args.key?(:error_samples)
9975
+ @metrics = args[:metrics] if args.key?(:metrics)
7731
9976
  @model_status = args[:model_status] if args.key?(:model_status)
7732
9977
  end
7733
9978
  end
@@ -8289,6 +10534,12 @@ module Google
8289
10534
  attr_accessor :enable_safe_search
8290
10535
  alias_method :enable_safe_search?, :enable_safe_search
8291
10536
 
10537
+ # Whether to enable search-as-you-type behavior for the search widget
10538
+ # Corresponds to the JSON property `enableSearchAsYouType`
10539
+ # @return [Boolean]
10540
+ attr_accessor :enable_search_as_you_type
10541
+ alias_method :enable_search_as_you_type?, :enable_search_as_you_type
10542
+
8292
10543
  # Turn on or off summary for each snippets result.
8293
10544
  # Corresponds to the JSON property `enableSnippetResultSummary`
8294
10545
  # @return [Boolean]
@@ -8385,6 +10636,7 @@ module Google
8385
10636
  @enable_quality_feedback = args[:enable_quality_feedback] if args.key?(:enable_quality_feedback)
8386
10637
  @enable_result_score = args[:enable_result_score] if args.key?(:enable_result_score)
8387
10638
  @enable_safe_search = args[:enable_safe_search] if args.key?(:enable_safe_search)
10639
+ @enable_search_as_you_type = args[:enable_search_as_you_type] if args.key?(:enable_search_as_you_type)
8388
10640
  @enable_snippet_result_summary = args[:enable_snippet_result_summary] if args.key?(:enable_snippet_result_summary)
8389
10641
  @enable_summarization = args[:enable_summarization] if args.key?(:enable_summarization)
8390
10642
  @enable_web_app = args[:enable_web_app] if args.key?(:enable_web_app)
@@ -8424,8 +10676,8 @@ module Google
8424
10676
 
8425
10677
  # The name of the collection. It should be collection resource name. Format: `
8426
10678
  # projects/`project_number`/locations/`location`/collections/`collection_id``.
8427
- # For widget service usage, such look up widget config, returned name should be
8428
- # skipped.
10679
+ # For APIs under WidgetService, such as LookUpWidgetConfig, the project number
10680
+ # and location part is erased in this field.
8429
10681
  # Corresponds to the JSON property `name`
8430
10682
  # @return [String]
8431
10683
  attr_accessor :name
@@ -8462,8 +10714,9 @@ module Google
8462
10714
 
8463
10715
  # The name of the data store. It should be data store resource name Format: `
8464
10716
  # projects/`project_number`/locations/`location`/collections/`collection_id`/
8465
- # dataStores/`data_store_id``. For widget service usage, such look up widget
8466
- # config, returned name should be skipped.
10717
+ # dataStores/`data_store_id``. For APIs under WidgetService, such as
10718
+ # LookUpWidgetConfig, the project number and location part is erased in this
10719
+ # field.
8467
10720
  # Corresponds to the JSON property `name`
8468
10721
  # @return [String]
8469
10722
  attr_accessor :name
@@ -8507,8 +10760,9 @@ module Google
8507
10760
 
8508
10761
  # The name of the data store. It should be data store resource name Format: `
8509
10762
  # projects/`project_number`/locations/`location`/collections/`collection_id`/
8510
- # dataStores/`data_store_id``. For widget service usage, such look up widget
8511
- # config, returned name should be skipped.
10763
+ # dataStores/`data_store_id``. For APIs under WidgetService, such as
10764
+ # LookUpWidgetConfig, the project number and location part is erased in this
10765
+ # field.
8512
10766
  # Corresponds to the JSON property `name`
8513
10767
  # @return [String]
8514
10768
  attr_accessor :name
@@ -9505,6 +11759,11 @@ module Google
9505
11759
  # @return [Fixnum]
9506
11760
  attr_accessor :success_count
9507
11761
 
11762
+ # Total count of entries that were processed.
11763
+ # Corresponds to the JSON property `totalCount`
11764
+ # @return [Fixnum]
11765
+ attr_accessor :total_count
11766
+
9508
11767
  # Operation last update time. If the operation is done, this is also the finish
9509
11768
  # time.
9510
11769
  # Corresponds to the JSON property `updateTime`
@@ -9520,6 +11779,7 @@ module Google
9520
11779
  @create_time = args[:create_time] if args.key?(:create_time)
9521
11780
  @failure_count = args[:failure_count] if args.key?(:failure_count)
9522
11781
  @success_count = args[:success_count] if args.key?(:success_count)
11782
+ @total_count = args[:total_count] if args.key?(:total_count)
9523
11783
  @update_time = args[:update_time] if args.key?(:update_time)
9524
11784
  end
9525
11785
  end
@@ -10053,10 +12313,17 @@ module Google
10053
12313
  # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleRpcStatus>]
10054
12314
  attr_accessor :error_samples
10055
12315
 
12316
+ # The metrics of the trained model.
12317
+ # Corresponds to the JSON property `metrics`
12318
+ # @return [Hash<String,Float>]
12319
+ attr_accessor :metrics
12320
+
10056
12321
  # The trained model status. Possible values are: * **bad-data**: The training
10057
12322
  # data quality is bad. * **no-improvement**: Tuning didn't improve performance.
10058
- # Won't deploy. * **in-progress**: Model training is in progress. * **ready**:
10059
- # The model is ready for serving.
12323
+ # Won't deploy. * **in-progress**: Model training job creation is in progress. *
12324
+ # **training**: Model is actively training. * **evaluating**: The model is
12325
+ # evaluating trained metrics. * **indexing**: The model trained metrics are
12326
+ # indexing. * **ready**: The model is ready for serving.
10060
12327
  # Corresponds to the JSON property `modelStatus`
10061
12328
  # @return [String]
10062
12329
  attr_accessor :model_status
@@ -10069,10 +12336,32 @@ module Google
10069
12336
  def update!(**args)
10070
12337
  @error_config = args[:error_config] if args.key?(:error_config)
10071
12338
  @error_samples = args[:error_samples] if args.key?(:error_samples)
12339
+ @metrics = args[:metrics] if args.key?(:metrics)
10072
12340
  @model_status = args[:model_status] if args.key?(:model_status)
10073
12341
  end
10074
12342
  end
10075
12343
 
12344
+ # Metadata associated with a tune operation.
12345
+ class GoogleCloudDiscoveryengineV1betaTuneEngineMetadata
12346
+ include Google::Apis::Core::Hashable
12347
+
12348
+ # Required. The resource name of the engine that this tune applies to. Format: `
12349
+ # projects/`project_number`/locations/`location_id`/collections/`collection_id`/
12350
+ # engines/`engine_id``
12351
+ # Corresponds to the JSON property `engine`
12352
+ # @return [String]
12353
+ attr_accessor :engine
12354
+
12355
+ def initialize(**args)
12356
+ update!(**args)
12357
+ end
12358
+
12359
+ # Update properties of this object
12360
+ def update!(**args)
12361
+ @engine = args[:engine] if args.key?(:engine)
12362
+ end
12363
+ end
12364
+
10076
12365
  # Metadata for UpdateSchema LRO.
10077
12366
  class GoogleCloudDiscoveryengineV1betaUpdateSchemaMetadata
10078
12367
  include Google::Apis::Core::Hashable