google-apis-discoveryengine_v1alpha 0.42.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
@@ -1660,10 +1666,1151 @@ module Google
1660
1666
  class GoogleCloudDiscoveryengineV1alphaAdditionalParams
1661
1667
  include Google::Apis::Core::Hashable
1662
1668
 
1663
- # Token that used for non-human user check.
1664
- # Corresponds to the JSON property `token`
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)
2803
+ end
2804
+ end
2805
+
2806
+ # Search action.
2807
+ class GoogleCloudDiscoveryengineV1alphaAnswerStepActionSearchAction
2808
+ include Google::Apis::Core::Hashable
2809
+
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
@@ -1834,8 +2981,8 @@ module Google
1834
2981
  # @return [Hash<String,Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaBigtableOptionsBigtableColumnFamily>]
1835
2982
  attr_accessor :families
1836
2983
 
1837
- # The field name used for saving row key value in the UCS document. The name has
1838
- # to match a-zA-Z0-9*
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*`.
1839
2986
  # Corresponds to the JSON property `keyFieldName`
1840
2987
  # @return [String]
1841
2988
  attr_accessor :key_field_name
@@ -1851,37 +2998,37 @@ module Google
1851
2998
  end
1852
2999
  end
1853
3000
 
1854
- #
3001
+ # The column of the Bigtable.
1855
3002
  class GoogleCloudDiscoveryengineV1alphaBigtableOptionsBigtableColumn
1856
3003
  include Google::Apis::Core::Hashable
1857
3004
 
1858
- # Optional. The encoding mode of the values when the type is not STRING.
1859
- # Acceptable encoding values are: TEXT - indicates values are alphanumeric text
1860
- # strings. BINARY - indicates values are encoded using HBase Bytes.toBytes
1861
- # family of functions. This can be overridden for a specific column by listing
1862
- # that column in 'columns' and specifying an encoding for it.
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.
1863
3010
  # Corresponds to the JSON property `encoding`
1864
3011
  # @return [String]
1865
3012
  attr_accessor :encoding
1866
3013
 
1867
- # The field name to use for this column in the UCS document. The name has to
1868
- # match a-zA-Z0-9* If not set, we will parse it from the qualifier bytes with
1869
- # best effort. However, field name collisions could happen, where parsing
1870
- # behavior is undefined.
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.
1871
3018
  # Corresponds to the JSON property `fieldName`
1872
3019
  # @return [String]
1873
3020
  attr_accessor :field_name
1874
3021
 
1875
- # Required. Qualifier of the column. If cannot decode with utf-8, store a base-
1876
- # 64 encoded string.
3022
+ # Required. Qualifier of the column. If it cannot be decoded with utf-8, use a
3023
+ # base-64 encoded string instead.
1877
3024
  # Corresponds to the JSON property `qualifier`
1878
3025
  # NOTE: Values are automatically base64 encoded/decoded in the client library.
1879
3026
  # @return [String]
1880
3027
  attr_accessor :qualifier
1881
3028
 
1882
- # Optional. The type of values in this column family. The values are expected to
1883
- # be encoded using HBase Bytes.toBytes function when the encoding value is set
1884
- # to BINARY.
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`.
1885
3032
  # Corresponds to the JSON property `type`
1886
3033
  # @return [String]
1887
3034
  attr_accessor :type
@@ -1899,7 +3046,7 @@ module Google
1899
3046
  end
1900
3047
  end
1901
3048
 
1902
- #
3049
+ # The column family of the Bigtable.
1903
3050
  class GoogleCloudDiscoveryengineV1alphaBigtableOptionsBigtableColumnFamily
1904
3051
  include Google::Apis::Core::Hashable
1905
3052
 
@@ -1909,26 +3056,26 @@ module Google
1909
3056
  # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaBigtableOptionsBigtableColumn>]
1910
3057
  attr_accessor :columns
1911
3058
 
1912
- # Optional. The encoding mode of the values when the type is not STRING.
1913
- # Acceptable encoding values are: TEXT - indicates values are alphanumeric text
1914
- # strings. BINARY - indicates values are encoded using HBase Bytes.toBytes
1915
- # family of functions. This can be overridden for a specific column by listing
1916
- # that column in 'columns' and specifying an encoding for it.
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.
1917
3064
  # Corresponds to the JSON property `encoding`
1918
3065
  # @return [String]
1919
3066
  attr_accessor :encoding
1920
3067
 
1921
- # The field name to use for this column family in the UCS document. The name has
1922
- # to match a-zA-Z0-9* If not set, we will parse it from the family name with
1923
- # best effort. However, due to difference naming pattern, there could be field
1924
- # name collisions, where parsing behavior is undefined.
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.
1925
3072
  # Corresponds to the JSON property `fieldName`
1926
3073
  # @return [String]
1927
3074
  attr_accessor :field_name
1928
3075
 
1929
- # Optional. The type of values in this column family. The values are expected to
1930
- # be encoded using HBase Bytes.toBytes function when the encoding value is set
1931
- # to BINARY.
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`.
1932
3079
  # Corresponds to the JSON property `type`
1933
3080
  # @return [String]
1934
3081
  attr_accessor :type
@@ -1946,7 +3093,7 @@ module Google
1946
3093
  end
1947
3094
  end
1948
3095
 
1949
- # The Cloud Bigtable source for importing data
3096
+ # The Cloud Bigtable source for importing data.
1950
3097
  class GoogleCloudDiscoveryengineV1alphaBigtableSource
1951
3098
  include Google::Apis::Core::Hashable
1952
3099
 
@@ -1955,19 +3102,18 @@ module Google
1955
3102
  # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaBigtableOptions]
1956
3103
  attr_accessor :bigtable_options
1957
3104
 
1958
- # Required. The instance ID of the Cloud Bigtable that needs to be exported.
3105
+ # Required. The instance ID of the Cloud Bigtable that needs to be imported.
1959
3106
  # Corresponds to the JSON property `instanceId`
1960
3107
  # @return [String]
1961
3108
  attr_accessor :instance_id
1962
3109
 
1963
- # The project ID (can be project # or ID) that the Bigtable source is in with a
1964
- # length limit of 128 characters. If not specified, inherits the project ID from
1965
- # the parent request.
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.
1966
3112
  # Corresponds to the JSON property `projectId`
1967
3113
  # @return [String]
1968
3114
  attr_accessor :project_id
1969
3115
 
1970
- # Required. The table ID of the Cloud Bigtable that needs to be exported.
3116
+ # Required. The table ID of the Cloud Bigtable that needs to be imported.
1971
3117
  # Corresponds to the JSON property `tableId`
1972
3118
  # @return [String]
1973
3119
  attr_accessor :table_id
@@ -1985,6 +3131,136 @@ module Google
1985
3131
  end
1986
3132
  end
1987
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
+
1988
3264
  # Chunk captures all raw metadata information of items to be recommended or
1989
3265
  # searched in the chunk mode.
1990
3266
  class GoogleCloudDiscoveryengineV1alphaChunk
@@ -2013,7 +3289,7 @@ module Google
2013
3289
  # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaChunkDocumentMetadata]
2014
3290
  attr_accessor :document_metadata
2015
3291
 
2016
- # Unique chunk id of the current chunk.
3292
+ # Unique chunk ID of the current chunk.
2017
3293
  # Corresponds to the JSON property `id`
2018
3294
  # @return [String]
2019
3295
  attr_accessor :id
@@ -2138,11 +3414,11 @@ module Google
2138
3414
  # @return [String]
2139
3415
  attr_accessor :database_id
2140
3416
 
2141
- # Optional. Intermediate Cloud Storage directory used for the import with a
2142
- # length limit of 2,000 characters. Can be specified if one wants to have the
2143
- # Cloud SQL export to a specific Cloud Storage directory. Please ensure that the
2144
- # Cloud SQL service account has the necessary GCS Storage Admin permissions to
2145
- # access the specified GCS directory.
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.
2146
3422
  # Corresponds to the JSON property `gcsStagingDir`
2147
3423
  # @return [String]
2148
3424
  attr_accessor :gcs_staging_dir
@@ -2153,16 +3429,15 @@ module Google
2153
3429
  # @return [String]
2154
3430
  attr_accessor :instance_id
2155
3431
 
2156
- # Optional. Option for serverless export. Enabling this option will incur
2157
- # additional cost. More info: https://cloud.google.com/sql/pricing#serverless
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).
2158
3434
  # Corresponds to the JSON property `offload`
2159
3435
  # @return [Boolean]
2160
3436
  attr_accessor :offload
2161
3437
  alias_method :offload?, :offload
2162
3438
 
2163
- # Optional. The project ID (can be project # or ID) that the Cloud SQL source is
2164
- # in with a length limit of 128 characters. If not specified, inherits the
2165
- # project ID from the parent request.
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.
2166
3441
  # Corresponds to the JSON property `projectId`
2167
3442
  # @return [String]
2168
3443
  attr_accessor :project_id
@@ -4070,6 +5345,39 @@ module Google
4070
5345
  end
4071
5346
  end
4072
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
+
4073
5381
  # Response message for SiteSearchEngineService.FetchDomainVerificationStatus
4074
5382
  # method.
4075
5383
  class GoogleCloudDiscoveryengineV1alphaFetchDomainVerificationStatusResponse
@@ -4255,7 +5563,7 @@ module Google
4255
5563
  include Google::Apis::Core::Hashable
4256
5564
 
4257
5565
  # Required. The Firestore collection to copy the data from with a length limit
4258
- # of 1500 characters.
5566
+ # of 1,500 characters.
4259
5567
  # Corresponds to the JSON property `collectionId`
4260
5568
  # @return [String]
4261
5569
  attr_accessor :collection_id
@@ -4266,18 +5574,17 @@ module Google
4266
5574
  # @return [String]
4267
5575
  attr_accessor :database_id
4268
5576
 
4269
- # Optional. Intermediate Cloud Storage directory used for the import with a
4270
- # length limit of 2,000 characters. Can be specified if one wants to have the
4271
- # Firestore export to a specific Cloud Storage directory. Please ensure that the
4272
- # Firestore service account has the necessary GCS Storage Admin permissions to
4273
- # access the specified GCS directory.
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.
4274
5582
  # Corresponds to the JSON property `gcsStagingDir`
4275
5583
  # @return [String]
4276
5584
  attr_accessor :gcs_staging_dir
4277
5585
 
4278
- # Optional. The project ID (can be project # or ID) that the Cloud SQL source is
4279
- # in with a length limit of 128 characters. If not specified, inherits the
4280
- # project ID from the parent request.
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.
4281
5588
  # Corresponds to the JSON property `projectId`
4282
5589
  # @return [String]
4283
5590
  attr_accessor :project_id
@@ -4305,11 +5612,11 @@ module Google
4305
5612
  # PDF, HTML). Each file matched by `input_uris` becomes a document, with the ID
4306
5613
  # set to the first 128 bits of SHA256(URI) encoded as a hex string. * `custom`:
4307
5614
  # One custom data JSON per row in arbitrary format that conforms to the defined
4308
- # Schema of the data store. This can only be used by Gen App Builder. * `csv`: A
4309
- # CSV file with header conforming to the defined Schema of the data store. Each
4310
- # entry after the header is imported as a Document. This can only be used by Gen
4311
- # App Builder. Supported values for user even imports: * `user_event` (default):
4312
- # 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.
4313
5620
  # Corresponds to the JSON property `dataSchema`
4314
5621
  # @return [String]
4315
5622
  attr_accessor :data_schema
@@ -4335,15 +5642,21 @@ module Google
4335
5642
  end
4336
5643
  end
4337
5644
 
4338
- # Grounding configuration.
4339
- class GoogleCloudDiscoveryengineV1alphaGroundingConfig
5645
+ # Grounding Fact.
5646
+ class GoogleCloudDiscoveryengineV1alphaGroundingFact
4340
5647
  include Google::Apis::Core::Hashable
4341
5648
 
4342
- # Required. Name of the GroundingConfig, of the form `projects/`project`/
4343
- # locations/`location`/groundingConfig`.
4344
- # Corresponds to the JSON property `name`
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`
4345
5658
  # @return [String]
4346
- attr_accessor :name
5659
+ attr_accessor :fact_text
4347
5660
 
4348
5661
  def initialize(**args)
4349
5662
  update!(**args)
@@ -4351,7 +5664,8 @@ module Google
4351
5664
 
4352
5665
  # Update properties of this object
4353
5666
  def update!(**args)
4354
- @name = args[:name] if args.key?(:name)
5667
+ @attributes = args[:attributes] if args.key?(:attributes)
5668
+ @fact_text = args[:fact_text] if args.key?(:fact_text)
4355
5669
  end
4356
5670
  end
4357
5671
 
@@ -4514,6 +5828,11 @@ module Google
4514
5828
  # @return [Fixnum]
4515
5829
  attr_accessor :success_count
4516
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
+
4517
5836
  # Operation last update time. If the operation is done, this is also the finish
4518
5837
  # time.
4519
5838
  # Corresponds to the JSON property `updateTime`
@@ -4529,6 +5848,7 @@ module Google
4529
5848
  @create_time = args[:create_time] if args.key?(:create_time)
4530
5849
  @failure_count = args[:failure_count] if args.key?(:failure_count)
4531
5850
  @success_count = args[:success_count] if args.key?(:success_count)
5851
+ @total_count = args[:total_count] if args.key?(:total_count)
4532
5852
  @update_time = args[:update_time] if args.key?(:update_time)
4533
5853
  end
4534
5854
  end
@@ -4546,7 +5866,7 @@ module Google
4546
5866
  # GcsSource. GcsSource.data_schema must be `custom` or `csv`. Otherwise, an
4547
5867
  # INVALID_ARGUMENT error is thrown. * BigQuerySource. BigQuerySource.data_schema
4548
5868
  # must be `custom` or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown. *
4549
- # SpannerSource * CloudSqlSource * FirestoreSource * BigtableSource
5869
+ # SpannerSource. * CloudSqlSource. * FirestoreSource. * BigtableSource.
4550
5870
  # Corresponds to the JSON property `autoGenerateIds`
4551
5871
  # @return [Boolean]
4552
5872
  attr_accessor :auto_generate_ids
@@ -4557,7 +5877,7 @@ module Google
4557
5877
  # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaBigQuerySource]
4558
5878
  attr_accessor :bigquery_source
4559
5879
 
4560
- # The Cloud Bigtable source for importing data
5880
+ # The Cloud Bigtable source for importing data.
4561
5881
  # Corresponds to the JSON property `bigtableSource`
4562
5882
  # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaBigtableSource]
4563
5883
  attr_accessor :bigtable_source
@@ -4601,7 +5921,7 @@ module Google
4601
5921
  # GcsSource. GcsSource.data_schema must be `custom` or `csv`. Otherwise, an
4602
5922
  # INVALID_ARGUMENT error is thrown. * BigQuerySource. BigQuerySource.data_schema
4603
5923
  # must be `custom` or `csv`. Otherwise, an INVALID_ARGUMENT error is thrown. *
4604
- # SpannerSource * CloudSqlSource * FirestoreSource * BigtableSource
5924
+ # SpannerSource. * CloudSqlSource. * FirestoreSource. * BigtableSource.
4605
5925
  # Corresponds to the JSON property `idField`
4606
5926
  # @return [String]
4607
5927
  attr_accessor :id_field
@@ -4622,6 +5942,12 @@ module Google
4622
5942
  # @return [Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaSpannerSource]
4623
5943
  attr_accessor :spanner_source
4624
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
+
4625
5951
  def initialize(**args)
4626
5952
  update!(**args)
4627
5953
  end
@@ -4640,6 +5966,7 @@ module Google
4640
5966
  @inline_source = args[:inline_source] if args.key?(:inline_source)
4641
5967
  @reconciliation_mode = args[:reconciliation_mode] if args.key?(:reconciliation_mode)
4642
5968
  @spanner_source = args[:spanner_source] if args.key?(:spanner_source)
5969
+ @update_mask = args[:update_mask] if args.key?(:update_mask)
4643
5970
  end
4644
5971
  end
4645
5972
 
@@ -5164,6 +6491,31 @@ module Google
5164
6491
  end
5165
6492
  end
5166
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
+
5167
6519
  # Response message for SiteSearchEngineService.ListTargetSites method.
5168
6520
  class GoogleCloudDiscoveryengineV1alphaListTargetSitesResponse
5169
6521
  include Google::Apis::Core::Hashable
@@ -5730,6 +7082,31 @@ module Google
5730
7082
  end
5731
7083
  end
5732
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
+
5733
7110
  # Request message for RankService.Rank method.
5734
7111
  class GoogleCloudDiscoveryengineV1alphaRankRequest
5735
7112
  include Google::Apis::Core::Hashable
@@ -5753,7 +7130,7 @@ module Google
5753
7130
  # @return [String]
5754
7131
  attr_accessor :query
5755
7132
 
5756
- # Required. A list of records to rank.
7133
+ # Required. A list of records to rank. At most 100 records to rank.
5757
7134
  # Corresponds to the JSON property `records`
5758
7135
  # @return [Array<Google::Apis::DiscoveryengineV1alpha::GoogleCloudDiscoveryengineV1alphaRankingRecord>]
5759
7136
  attr_accessor :records
@@ -6425,9 +7802,11 @@ module Google
6425
7802
  # @return [String]
6426
7803
  attr_accessor :order_by
6427
7804
 
6428
- # Maximum number of Documents to return. If unspecified, defaults to a
6429
- # reasonable value. The maximum allowed value is 100. Values above 100 are
6430
- # 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.
6431
7810
  # Corresponds to the JSON property `pageSize`
6432
7811
  # @return [Fixnum]
6433
7812
  attr_accessor :page_size
@@ -6606,6 +7985,13 @@ module Google
6606
7985
  # @return [Float]
6607
7986
  attr_accessor :boost
6608
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
+
6609
7995
  # An expression which specifies a boost condition. The syntax and supported
6610
7996
  # fields are the same as a filter expression. See SearchRequest.filter for
6611
7997
  # detail syntax and limitations. Examples: * To boost documents with document ID
@@ -6622,10 +8008,88 @@ module Google
6622
8008
  # Update properties of this object
6623
8009
  def update!(**args)
6624
8010
  @boost = args[:boost] if args.key?(:boost)
8011
+ @boost_control_spec = args[:boost_control_spec] if args.key?(:boost_control_spec)
6625
8012
  @condition = args[:condition] if args.key?(:condition)
6626
8013
  end
6627
8014
  end
6628
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
+
6629
8093
  # A specification for configuring the behavior of content search.
6630
8094
  class GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpec
6631
8095
  include Google::Apis::Core::Hashable
@@ -8024,6 +9488,81 @@ module Google
8024
9488
  end
8025
9489
  end
8026
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
+
8027
9566
  # SiteSearchEngine captures DataStore level site search persisting
8028
9567
  # configurations. It is a singleton value per data store.
8029
9568
  class GoogleCloudDiscoveryengineV1alphaSiteSearchEngine
@@ -8079,9 +9618,9 @@ module Google
8079
9618
  # @return [String]
8080
9619
  attr_accessor :database_id
8081
9620
 
8082
- # Optional. Whether to apply data boost on Spanner export. Enabling this option
8083
- # will incur additional cost. More info: https://cloud.google.com/spanner/docs/
8084
- # databoost/databoost-overview#billing_and_quotas
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).
8085
9624
  # Corresponds to the JSON property `enableDataBoost`
8086
9625
  # @return [Boolean]
8087
9626
  attr_accessor :enable_data_boost
@@ -8417,8 +9956,10 @@ module Google
8417
9956
 
8418
9957
  # The trained model status. Possible values are: * **bad-data**: The training
8419
9958
  # data quality is bad. * **no-improvement**: Tuning didn't improve performance.
8420
- # Won't deploy. * **in-progress**: Model training is in progress. * **ready**:
8421
- # 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.
8422
9963
  # Corresponds to the JSON property `modelStatus`
8423
9964
  # @return [String]
8424
9965
  attr_accessor :model_status
@@ -10198,26 +11739,6 @@ module Google
10198
11739
  end
10199
11740
  end
10200
11741
 
10201
- # Grounding configuration.
10202
- class GoogleCloudDiscoveryengineV1betaGroundingConfig
10203
- include Google::Apis::Core::Hashable
10204
-
10205
- # Required. Name of the GroundingConfig, of the form `projects/`project`/
10206
- # locations/`location`/groundingConfig`.
10207
- # Corresponds to the JSON property `name`
10208
- # @return [String]
10209
- attr_accessor :name
10210
-
10211
- def initialize(**args)
10212
- update!(**args)
10213
- end
10214
-
10215
- # Update properties of this object
10216
- def update!(**args)
10217
- @name = args[:name] if args.key?(:name)
10218
- end
10219
- end
10220
-
10221
11742
  # Metadata related to the progress of the ImportDocuments operation. This is
10222
11743
  # returned by the google.longrunning.Operation.metadata field.
10223
11744
  class GoogleCloudDiscoveryengineV1betaImportDocumentsMetadata
@@ -10238,6 +11759,11 @@ module Google
10238
11759
  # @return [Fixnum]
10239
11760
  attr_accessor :success_count
10240
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
+
10241
11767
  # Operation last update time. If the operation is done, this is also the finish
10242
11768
  # time.
10243
11769
  # Corresponds to the JSON property `updateTime`
@@ -10253,6 +11779,7 @@ module Google
10253
11779
  @create_time = args[:create_time] if args.key?(:create_time)
10254
11780
  @failure_count = args[:failure_count] if args.key?(:failure_count)
10255
11781
  @success_count = args[:success_count] if args.key?(:success_count)
11782
+ @total_count = args[:total_count] if args.key?(:total_count)
10256
11783
  @update_time = args[:update_time] if args.key?(:update_time)
10257
11784
  end
10258
11785
  end
@@ -10793,8 +12320,10 @@ module Google
10793
12320
 
10794
12321
  # The trained model status. Possible values are: * **bad-data**: The training
10795
12322
  # data quality is bad. * **no-improvement**: Tuning didn't improve performance.
10796
- # Won't deploy. * **in-progress**: Model training is in progress. * **ready**:
10797
- # 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.
10798
12327
  # Corresponds to the JSON property `modelStatus`
10799
12328
  # @return [String]
10800
12329
  attr_accessor :model_status