-
Notifications
You must be signed in to change notification settings - Fork 467
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Create Cloud Natural Language API: Qwik Start
- Loading branch information
1 parent
f22df63
commit fd2fb16
Showing
1 changed file
with
10 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
export GOOGLE_CLOUD_PROJECT=$(gcloud config get-value core/project) | ||
gcloud iam service-accounts create my-natlang-sa \ | ||
--display-name "my natural language service account" | ||
gcloud iam service-accounts keys create ~/key.json \ | ||
--iam-account my-natlang-sa@${GOOGLE_CLOUD_PROJECT}.iam.gserviceaccount.com | ||
export GOOGLE_APPLICATION_CREDENTIALS="/home/USER/key.json" | ||
|
||
SSH and then run below command | ||
|
||
gcloud ml language analyze-entities --content="Michelangelo Caravaggio, Italian painter, is known for 'The Calling of Saint Matthew'." > result.json |