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 +4 -4
- data/lib/google/cloud/dialogflow/version.rb +1 -1
- data/lib/google/cloud/dialogflow.rb +72 -72
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 47b6e5ce829da16ca7b00530229011c269a794be6d0dfa85d1d79f9f5bf4d376
|
|
4
|
+
data.tar.gz: 65f79a6dffe04cc4d5d7e4d0b40057d1681a1135e237ab867ffc2630eff64570
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: d6285bece0fa1023e35c66db4c516772fc08dd92040e2f5740d47d16d0fce5c226fb4816718509200098a4d74a0c3e890ee22f0d306d7ef9b89402962c03977b
|
|
7
|
+
data.tar.gz: b9cb8dc0d20b6a5b432a3aed7c6672b5ba852d8b5ba56db826b51fd482325b4e6fb7164bf632e54036bf3a5e78e9a48558cea9e6485408af9cb4c7a9c605a51f
|
|
@@ -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
|
#
|