Classify Text into Categories with the Natural Language API Reviews
Loading...
No results found.

Apply your skills in Google Cloud console

Classify Text into Categories with the Natural Language API Reviews

66496 reviews

Matheus s. · Reviewed מעל שנה אחת ago

Ігор М. · Reviewed מעל שנה אחת ago

Yurii D. · Reviewed מעל שנה אחת ago

Jessa Mae S. · Reviewed מעל שנה אחת ago

Task 6 python script is not formated

Vitaly U. · Reviewed מעל שנה אחת ago

Ihor K. · Reviewed מעל שנה אחת ago

Roman R. · Reviewed מעל שנה אחת ago

Iryna V. · Reviewed מעל שנה אחת ago

providnui p. · Reviewed מעל שנה אחת ago

Oleh T. · Reviewed מעל שנה אחת ago

very nice.

Arcanjo G. · Reviewed מעל שנה אחת ago

I think, you know, that the second part, related to classify-text.py does not work need to install pip install google.cloud for python pip install --user google-cloud-bigquery==2.34.4 "shapely<2" google-cloud-storage google-cloud-language fix errors in classify-text.py insert Project ID but thanks anyway for the interesting challenge

BuYn M. · Reviewed מעל שנה אחת ago

Kritika G. · Reviewed מעל שנה אחת ago

Camilo P. · Reviewed מעל שנה אחת ago

Deepnita M. · Reviewed מעל שנה אחת ago

Bad formatted bigquery python script with some errors not working Script must be like: ``` # Import necessary libraries from google.cloud import storage, language, bigquery # Set up your GCS, NL, and BigQuery clients storage_client = storage.Client() nl_client = language.LanguageServiceClient() bq_client = bigquery.Client(project='qwiklabs-gcp-01-b8b997bbdb2b') # Define dataset and table dataset_ref = bq_client.dataset('news_classification_dataset') dataset = bigquery.Dataset(dataset_ref) table_ref = dataset.table('article_data') table = bq_client.get_table(table_ref) # Function to classify the text def classify_text(article): response = nl_client.classify_text( document=language.Document( content=article, type_=language.Document.Type.PLAIN_TEXT ) ) return response rows_for_bq = [] files = storage_client.bucket('qwiklabs-test-bucket-gsp063').list_blobs() print("Got article files from GCS, sending them to the NL API (this will take ~2 minutes)...") # Send files to the NL API and save the result to send to BigQuery for file in files: if file.name.endswith('txt'): article_text = file.download_as_bytes() nl_response = classify_text(article_text) if len(nl_response.categories) > 0: rows_for_bq.append((str(article_text), nl_response.categories[0].name, nl_response.categories[0].confidence)) print("Writing NL API article data to BigQuery...") # Write article text + category data to BQ errors = bq_client.insert_rows(table, rows_for_bq) assert errors == [] ```

OLEG M. · Reviewed מעל שנה אחת ago

семен И. · Reviewed מעל שנה אחת ago

Nickolay K. · Reviewed מעל שנה אחת ago

Denys V. · Reviewed מעל שנה אחת ago

Volodymyr P. · Reviewed מעל שנה אחת ago

Дмитро М. · Reviewed מעל שנה אחת ago

Vinicius G. · Reviewed מעל שנה אחת ago

Данило Ч. · Reviewed מעל שנה אחת ago

Satrajit S. · Reviewed מעל שנה אחת ago

In task 6. The Python code is copied with a syntax error. Namely, the declaration of variables is not on a new line

Oleksandr K. · Reviewed מעל שנה אחת ago

We do not ensure the published reviews originate from consumers who have purchased or used the products. Reviews are not verified by Google.