mirror of
https://github.com/imjasonh/gcloud-help
synced 2026-07-10 19:31:55 +00:00
65 lines
2.2 KiB
Text
65 lines
2.2 KiB
Text
NAME
|
|
gcloud beta ml translate detect-language - use the Google Cloud Translation
|
|
API to detect languages
|
|
|
|
SYNOPSIS
|
|
gcloud beta ml translate detect-language
|
|
(--content=CONTENT | --content-file=CONTENT_FILE)
|
|
[--mime-type=MIME_TYPE] [--model=MODEL] [--zone=ZONE; default="global"]
|
|
[GCLOUD_WIDE_FLAG ...]
|
|
|
|
DESCRIPTION
|
|
(BETA) Detects the language of text in a request.
|
|
|
|
EXAMPLES
|
|
The following command detects the language of 'What beautiful weather!'
|
|
|
|
$ gcloud beta ml translate detect-language \
|
|
--content='What beautiful weather!' --zone=us-central1
|
|
|
|
REQUIRED FLAGS
|
|
Contents group.
|
|
|
|
Exactly one of these must be specified:
|
|
|
|
--content=CONTENT
|
|
Content of the input in string format.
|
|
|
|
--content-file=CONTENT_FILE
|
|
Specify a local file path with content.
|
|
|
|
OPTIONAL FLAGS
|
|
--mime-type=MIME_TYPE
|
|
Format of the source text, for example, 'text/html', 'text/plain'.
|
|
Defaults to 'text/html'.
|
|
|
|
--model=MODEL
|
|
Language detection model to be used. If not specified, the default
|
|
(language-detection/default) model is used. Authorization requires the
|
|
following Google IAM permission on the specified resource model:
|
|
|
|
cloudtranslate.languageDetectionModels.predict
|
|
|
|
--zone=ZONE; default="global"
|
|
Location to make calls. Non-global location is required for requests
|
|
using AutoML models. Currently, only 'us-central1' is supported as a
|
|
non-global location. Defaults to 'global'.
|
|
|
|
GCLOUD WIDE FLAGS
|
|
These flags are available to all commands: --access-token-file, --account,
|
|
--billing-project, --configuration, --flags-file, --flatten, --format,
|
|
--help, --impersonate-service-account, --log-http, --project, --quiet,
|
|
--trace-token, --user-output-enabled, --verbosity.
|
|
|
|
Run $ gcloud help for details.
|
|
|
|
API REFERENCE
|
|
This command uses the translate/v3 API. The full documentation for this API
|
|
can be found at: https://cloud.google.com/translate/docs/quickstarts
|
|
|
|
NOTES
|
|
This command is currently in beta and might change without notice. This
|
|
variant is also available:
|
|
|
|
$ gcloud alpha ml translate detect-language
|
|
|