Skip to content

Commit

Permalink
move region tags so that the beta page only include codes from the re…
Browse files Browse the repository at this point in the history
…levant file
  • Loading branch information
dizcology authored and busunkim96 committed Sep 29, 2020
1 parent 862e27d commit e8d1527
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,16 +18,12 @@
def run_quickstart():
# [START language_quickstart]
# Imports the Google Cloud client library
# [START beta_import_client]
# [START beta_import]
from google.cloud import language_v1beta2
from google.cloud.language_v1beta2 import enums
from google.cloud.language_v1beta2 import types
# [END beta_import]

# Instantiates a client with the v1beta2 version
client = language_v1beta2.LanguageServiceClient()
# [END beta_import_client]

# The text to analyze
text = u'Hallo Welt!'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,11 @@
import argparse
import sys

# [START beta_import]
from google.cloud import language_v1beta2
from google.cloud.language_v1beta2 import enums
from google.cloud.language_v1beta2 import types
# [END beta_import]
import six


Expand Down Expand Up @@ -166,7 +168,9 @@ def syntax_file(gcs_uri):
# [START def_entity_sentiment_text]
def entity_sentiment_text(text):
"""Detects entity sentiment in the provided text."""
# [START beta_client]
client = language_v1beta2.LanguageServiceClient()
# [END beta_client]

if isinstance(text, six.binary_type):
text = text.decode('utf-8')
Expand Down

0 comments on commit e8d1527

Please sign in to comment.