google-cloud-dialogflow 1.13.0 → 1.14.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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f35fc14178264ee2dcb5b5f5c6761a89710bfa1822f0a36a0c00650227b11394
4
- data.tar.gz: 58f410606a04527e23d659643cb865ee2b5dbe6700323054bb06957c6c6ad69d
3
+ metadata.gz: 47b6e5ce829da16ca7b00530229011c269a794be6d0dfa85d1d79f9f5bf4d376
4
+ data.tar.gz: 65f79a6dffe04cc4d5d7e4d0b40057d1681a1135e237ab867ffc2630eff64570
5
5
  SHA512:
6
- metadata.gz: abffa68384fe2afe5878109bec06199d6c80e13170d8dcc1533e6506b09bb54f9cd125ef8370a573bbc6d0a901e921025bccd39c0df9bab8fe4f74cfacf1011d
7
- data.tar.gz: 79656fc2feebafe0b58c422696f945e33f5204f5f26d8bb600d0ba08ece9123e43ca5921fbc8178eda21ec8daa080bc1b19b81daa5a2129aae58b4f9a008c3a9
6
+ metadata.gz: d6285bece0fa1023e35c66db4c516772fc08dd92040e2f5740d47d16d0fce5c226fb4816718509200098a4d74a0c3e890ee22f0d306d7ef9b89402962c03977b
7
+ data.tar.gz: b9cb8dc0d20b6a5b432a3aed7c6672b5ba852d8b5ba56db826b51fd482325b4e6fb7164bf632e54036bf3a5e78e9a48558cea9e6485408af9cb4c7a9c605a51f
@@ -16,7 +16,7 @@
16
16
  module Google
17
17
  module Cloud
18
18
  module Dialogflow
19
- VERSION = "1.13.0".freeze
19
+ VERSION = "1.14.0".freeze
20
20
  end
21
21
  end
22
22
  end
@@ -115,6 +115,78 @@ module Google
115
115
  false
116
116
  end
117
117
 
118
+ ##
119
+ # Create a new client object for Tools.
120
+ #
121
+ # By default, this returns an instance of
122
+ # [Google::Cloud::Dialogflow::V2::Tools::Client](https://cloud.google.com/ruby/docs/reference/google-cloud-dialogflow-v2/latest/Google-Cloud-Dialogflow-V2-Tools-Client)
123
+ # for a gRPC client for version V2 of the API.
124
+ # However, you can specify a different API version by passing it in the
125
+ # `version` parameter. If the Tools service is
126
+ # supported by that API version, and the corresponding gem is available, the
127
+ # appropriate versioned client will be returned.
128
+ # You can also specify a different transport by passing `:rest` or `:grpc` in
129
+ # the `transport` parameter.
130
+ #
131
+ # Raises an exception if the currently installed versioned client gem for the
132
+ # given API version does not support the given transport of the Tools service.
133
+ # You can determine whether the method will succeed by calling
134
+ # {Google::Cloud::Dialogflow.tools_available?}.
135
+ #
136
+ # ## About Tools
137
+ #
138
+ # Tool Service for LLM powered Agent Assist. Tools can be used to interact with
139
+ # remote APIs (e.g. fetching orders) to retrieve additional information as
140
+ # input to LLM.
141
+ #
142
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
143
+ # Defaults to `:v2`.
144
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
145
+ # @return [::Object] A client object for the specified version.
146
+ #
147
+ def self.tools version: :v2, transport: :grpc, &block
148
+ require "google/cloud/dialogflow/#{version.to_s.downcase}"
149
+
150
+ package_name = Google::Cloud::Dialogflow
151
+ .constants
152
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
153
+ .first
154
+ service_module = Google::Cloud::Dialogflow.const_get(package_name).const_get(:Tools)
155
+ service_module = service_module.const_get(:Rest) if transport == :rest
156
+ service_module.const_get(:Client).new(&block)
157
+ end
158
+
159
+ ##
160
+ # Determines whether the Tools service is supported by the current client.
161
+ # If true, you can retrieve a client object by calling {Google::Cloud::Dialogflow.tools}.
162
+ # If false, that method will raise an exception. This could happen if the given
163
+ # API version does not exist or does not support the Tools service,
164
+ # or if the versioned client gem needs an update to support the Tools service.
165
+ #
166
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
167
+ # Defaults to `:v2`.
168
+ # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
169
+ # @return [boolean] Whether the service is available.
170
+ #
171
+ def self.tools_available? version: :v2, transport: :grpc
172
+ require "google/cloud/dialogflow/#{version.to_s.downcase}"
173
+ package_name = Google::Cloud::Dialogflow
174
+ .constants
175
+ .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
176
+ .first
177
+ return false unless package_name
178
+ service_module = Google::Cloud::Dialogflow.const_get package_name
179
+ return false unless service_module.const_defined? :Tools
180
+ service_module = service_module.const_get :Tools
181
+ if transport == :rest
182
+ return false unless service_module.const_defined? :Rest
183
+ service_module = service_module.const_get :Rest
184
+ end
185
+ service_module.const_defined? :Client
186
+ rescue ::LoadError
187
+ false
188
+ end
189
+
118
190
  ##
119
191
  # Create a new client object for Generators.
120
192
  #
@@ -1461,78 +1533,6 @@ module Google
1461
1533
  false
1462
1534
  end
1463
1535
 
1464
- ##
1465
- # Create a new client object for Tools.
1466
- #
1467
- # By default, this returns an instance of
1468
- # [Google::Cloud::Dialogflow::V2::Tools::Client](https://cloud.google.com/ruby/docs/reference/google-cloud-dialogflow-v2/latest/Google-Cloud-Dialogflow-V2-Tools-Client)
1469
- # for a gRPC client for version V2 of the API.
1470
- # However, you can specify a different API version by passing it in the
1471
- # `version` parameter. If the Tools service is
1472
- # supported by that API version, and the corresponding gem is available, the
1473
- # appropriate versioned client will be returned.
1474
- # You can also specify a different transport by passing `:rest` or `:grpc` in
1475
- # the `transport` parameter.
1476
- #
1477
- # Raises an exception if the currently installed versioned client gem for the
1478
- # given API version does not support the given transport of the Tools service.
1479
- # You can determine whether the method will succeed by calling
1480
- # {Google::Cloud::Dialogflow.tools_available?}.
1481
- #
1482
- # ## About Tools
1483
- #
1484
- # Tool Service for LLM powered Agent Assist. Tools can be used to interact with
1485
- # remote APIs (e.g. fetching orders) to retrieve additional information as
1486
- # input to LLM.
1487
- #
1488
- # @param version [::String, ::Symbol] The API version to connect to. Optional.
1489
- # Defaults to `:v2`.
1490
- # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
1491
- # @return [::Object] A client object for the specified version.
1492
- #
1493
- def self.tools version: :v2, transport: :grpc, &block
1494
- require "google/cloud/dialogflow/#{version.to_s.downcase}"
1495
-
1496
- package_name = Google::Cloud::Dialogflow
1497
- .constants
1498
- .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1499
- .first
1500
- service_module = Google::Cloud::Dialogflow.const_get(package_name).const_get(:Tools)
1501
- service_module = service_module.const_get(:Rest) if transport == :rest
1502
- service_module.const_get(:Client).new(&block)
1503
- end
1504
-
1505
- ##
1506
- # Determines whether the Tools service is supported by the current client.
1507
- # If true, you can retrieve a client object by calling {Google::Cloud::Dialogflow.tools}.
1508
- # If false, that method will raise an exception. This could happen if the given
1509
- # API version does not exist or does not support the Tools service,
1510
- # or if the versioned client gem needs an update to support the Tools service.
1511
- #
1512
- # @param version [::String, ::Symbol] The API version to connect to. Optional.
1513
- # Defaults to `:v2`.
1514
- # @param transport [:grpc, :rest] The transport to use. Defaults to `:grpc`.
1515
- # @return [boolean] Whether the service is available.
1516
- #
1517
- def self.tools_available? version: :v2, transport: :grpc
1518
- require "google/cloud/dialogflow/#{version.to_s.downcase}"
1519
- package_name = Google::Cloud::Dialogflow
1520
- .constants
1521
- .select { |sym| sym.to_s.downcase == version.to_s.downcase.tr("_", "") }
1522
- .first
1523
- return false unless package_name
1524
- service_module = Google::Cloud::Dialogflow.const_get package_name
1525
- return false unless service_module.const_defined? :Tools
1526
- service_module = service_module.const_get :Tools
1527
- if transport == :rest
1528
- return false unless service_module.const_defined? :Rest
1529
- service_module = service_module.const_get :Rest
1530
- end
1531
- service_module.const_defined? :Client
1532
- rescue ::LoadError
1533
- false
1534
- end
1535
-
1536
1536
  ##
1537
1537
  # Create a new client object for Versions.
1538
1538
  #
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-cloud-dialogflow
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.13.0
4
+ version: 1.14.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Google LLC