Google provides neat examples on how to interact with the Natural Language API and its content classification methods. To suit our needs we need to condense these examples to produce a json-like output, which can be directly fed into the Realtime Database and hence also into BigQuery.
Proposal
Using the examples found online to create a toolset consisting of:
analyse -> return overall and sentence-wise sentiment and magnitude
classify -> return the content classification, i.e. content category, like societal issue
jsonify -> helper function to condense the above output into a json-like object
How to test the implementation
Call the functions, stick the result into the Realtime DB and thus also into BigQuery. If everything goes right, the test succeeded.
Toolset for Google Natural Language API
Description
Google provides neat examples on how to interact with the Natural Language API and its content classification methods. To suit our needs we need to condense these examples to produce a
json
-like output, which can be directly fed into the Realtime Database and hence also into BigQuery.Proposal
Using the examples found online to create a toolset consisting of:
analyse
-> return overall and sentence-wise sentiment and magnitudeclassify
-> return the content classification, i.e. content category, likesocietal issue
jsonify
-> helper function to condense the above output into ajson
-like objectHow to test the implementation
Call the functions, stick the result into the Realtime DB and thus also into BigQuery. If everything goes right, the test succeeded.
Related Issues
7 #4