Skip to content

Commit

Permalink
feat: Automated regeneration of language v2 client (#20344)
Browse files Browse the repository at this point in the history
Auto-created at 2024-10-06 09:44:31 +0000 using the toys pull request generator.
  • Loading branch information
yoshi-code-bot authored Oct 6, 2024
1 parent 97618d5 commit 2112cf5
Show file tree
Hide file tree
Showing 5 changed files with 26 additions and 3 deletions.
2 changes: 2 additions & 0 deletions api_names_out.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -244612,6 +244612,7 @@
"/language:v2/ClassificationCategory": classification_category
"/language:v2/ClassificationCategory/confidence": confidence
"/language:v2/ClassificationCategory/name": name
"/language:v2/ClassificationCategory/severity": severity
"/language:v2/ClassifyTextRequest": classify_text_request
"/language:v2/ClassifyTextRequest/document": document
"/language:v2/ClassifyTextResponse": classify_text_response
Expand Down Expand Up @@ -244676,6 +244677,7 @@
"/language:v2/InfraUsage/tpuMetrics/tpu_metric": tpu_metric
"/language:v2/ModerateTextRequest": moderate_text_request
"/language:v2/ModerateTextRequest/document": document
"/language:v2/ModerateTextRequest/modelVersion": model_version
"/language:v2/ModerateTextResponse": moderate_text_response
"/language:v2/ModerateTextResponse/languageCode": language_code
"/language:v2/ModerateTextResponse/languageSupported": language_supported
Expand Down
5 changes: 5 additions & 0 deletions generated/google-apis-language_v2/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Release history for google-apis-language_v2

### v0.7.0 (2024-10-06)

* Regenerated from discovery document revision 20240929
* Regenerated using generator version 0.15.1

### v0.6.0 (2024-05-19)

* Regenerated from discovery document revision 20240303
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -301,6 +301,13 @@ class ClassificationCategory
# @return [String]
attr_accessor :name

# Optional. The classifier's severity of the category. This is only present when
# the ModerateTextRequest.ModelVersion is set to MODEL_VERSION_2, and the
# corresponding category has a severity score.
# Corresponds to the JSON property `severity`
# @return [Float]
attr_accessor :severity

def initialize(**args)
update!(**args)
end
Expand All @@ -309,6 +316,7 @@ def initialize(**args)
def update!(**args)
@confidence = args[:confidence] if args.key?(:confidence)
@name = args[:name] if args.key?(:name)
@severity = args[:severity] if args.key?(:severity)
end
end

Expand Down Expand Up @@ -750,13 +758,19 @@ class ModerateTextRequest
# @return [Google::Apis::LanguageV2::Document]
attr_accessor :document

# Optional. The model version to use for ModerateText.
# Corresponds to the JSON property `modelVersion`
# @return [String]
attr_accessor :model_version

def initialize(**args)
update!(**args)
end

# Update properties of this object
def update!(**args)
@document = args[:document] if args.key?(:document)
@model_version = args[:model_version] if args.key?(:model_version)
end
end

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,13 @@ module Google
module Apis
module LanguageV2
# Version of the google-apis-language_v2 gem
GEM_VERSION = "0.6.0"
GEM_VERSION = "0.7.0"

# Version of the code generator used to generate this client
GENERATOR_VERSION = "0.15.0"
GENERATOR_VERSION = "0.15.1"

# Revision of the discovery document this client was generated from
REVISION = "20240303"
REVISION = "20240929"
end
end
end
Original file line number Diff line number Diff line change
Expand Up @@ -934,6 +934,7 @@ class ClassificationCategory
class Representation < Google::Apis::Core::JsonRepresentation
property :confidence, as: 'confidence'
property :name, as: 'name'
property :severity, as: 'severity'
end
end

Expand Down Expand Up @@ -1050,6 +1051,7 @@ class ModerateTextRequest
class Representation < Google::Apis::Core::JsonRepresentation
property :document, as: 'document', class: Google::Apis::LanguageV2::Document, decorator: Google::Apis::LanguageV2::Document::Representation

property :model_version, as: 'modelVersion'
end
end

Expand Down

0 comments on commit 2112cf5

Please sign in to comment.