GitHunt
GE

geigerj/ruby-language

Ruby Client for Google Cloud Natural Language API (Beta)

Google Cloud Natural Language API:
Google Cloud Natural Language API provides natural language understanding
technologies to developers. Examples include sentiment analysis, entity
recognition, and text annotations.

The 0.28.0 release introduced breaking changes relative to the previous
release, 0.27.1. For more details and instructions to migrate your code, please
visit the migration guide.

Quick Start

In order to use this library, you first need to go through the following
steps:

  1. Select or create a Cloud Platform project.
  2. Enable the Google Cloud Natural Language API.
  3. Setup Authentication.

Installation

$ gem install google-cloud-language

Preview

LanguageServiceClient

require "google/cloud/language"

language_service_client = Google::Cloud::Language.new
content = "Hello, world!"
type = :PLAIN_TEXT
document = { content: content, type: type }
response = language_service_client.analyze_sentiment(document)

Next Steps

Languages

Ruby100.0%
Apache License 2.0
Created November 30, 2017
Updated November 30, 2017
geigerj/ruby-language | GitHunt