Classify Text into Categories with the Natural Language API Reviews
73300 reviews
failed to check progress on items 2 & 3, classify-text.py uses deprecated API, the minimal patch is the following: --- classify-text.py.ORIG 2020-10-27 15:55:22.808463793 +0000 +++ classify-text.py 2020-10-27 15:55:00.819818113 +0000 @@ -1,8 +1,8 @@ -from google.cloud import storage, language, bigquery +from google.cloud import storage, language_v1, bigquery # Set up our GCS, NL, and BigQuery clients storage_client = storage.Client() -nl_client = language.LanguageServiceClient() +nl_client = language_v1.LanguageServiceClient() # TODO: replace YOUR_PROJECT with your project name below bq_client = bigquery.Client(project='YOUR_PROJECT') @@ -14,9 +14,9 @@ # Send article text to the NL API's classifyText method def classify_text(article): response = nl_client.classify_text( - document=language.types.Document( + document=language_v1.Document( content=article, - type=language.enums.Document.Type.PLAIN_TEXT + type_=language_v1.Document.Type.PLAIN_TEXT ) ) return response
Vladislav K. · Reviewed about 6 years ago
ABINASH P. · Reviewed about 6 years ago
Akundi P. · Reviewed about 6 years ago
Suryaveer R. · Reviewed about 6 years ago
Tejaswini M. · Reviewed about 6 years ago
Muhammad F. · Reviewed about 6 years ago
very good
Sriparna S. · Reviewed about 6 years ago
VIJAYANT P. · Reviewed about 6 years ago
shashank m. · Reviewed about 6 years ago
Wamika J. · Reviewed about 6 years ago
Srivari C. · Reviewed about 6 years ago
Viren M. · Reviewed about 6 years ago
Shubham J. · Reviewed about 6 years ago
Satisfied.
Satya Swaroop P. · Reviewed about 6 years ago
Classify Text into Categories with the Natural Language API was amazing
Pratik P. · Reviewed about 6 years ago
kritika r. · Reviewed about 6 years ago
stuck with hung cloud shell, after shell restart with progress check
Vladislav K. · Reviewed about 6 years ago
Prasanjit M. · Reviewed about 6 years ago
Avinash Naidu M. · Reviewed about 6 years ago
Akhil S. · Reviewed about 6 years ago
Joel J. · Reviewed about 6 years ago
Ming Qi L. · Reviewed about 6 years ago
Swagato P. · Reviewed about 6 years ago
Paritosh S. · Reviewed about 6 years ago
Sumit A. · Reviewed about 6 years ago
We do not ensure the published reviews originate from consumers who have purchased or used the products. Reviews are not verified by Google.