@google-cloud/language
Version:
Google Cloud Natural Language API client for Node.js
1,243 lines (1,242 loc) • 147 kB
JSON
{
"nested": {
"google": {
"nested": {
"cloud": {
"nested": {
"language": {
"nested": {
"v1": {
"options": {
"go_package": "cloud.google.com/go/language/apiv1/languagepb;languagepb",
"java_multiple_files": true,
"java_outer_classname": "LanguageServiceProto",
"java_package": "com.google.cloud.language.v1"
},
"nested": {
"LanguageService": {
"options": {
"(google.api.default_host)": "language.googleapis.com",
"(google.api.oauth_scopes)": "https://www.googleapis.com/auth/cloud-language,https://www.googleapis.com/auth/cloud-platform"
},
"methods": {
"AnalyzeSentiment": {
"requestType": "AnalyzeSentimentRequest",
"responseType": "AnalyzeSentimentResponse",
"options": {
"(google.api.http).post": "/v1/documents:analyzeSentiment",
"(google.api.http).body": "*",
"(google.api.method_signature)": "document"
},
"parsedOptions": [
{
"(google.api.http)": {
"post": "/v1/documents:analyzeSentiment",
"body": "*"
}
},
{
"(google.api.method_signature)": "document,encoding_type"
},
{
"(google.api.method_signature)": "document"
}
]
},
"AnalyzeEntities": {
"requestType": "AnalyzeEntitiesRequest",
"responseType": "AnalyzeEntitiesResponse",
"options": {
"(google.api.http).post": "/v1/documents:analyzeEntities",
"(google.api.http).body": "*",
"(google.api.method_signature)": "document"
},
"parsedOptions": [
{
"(google.api.http)": {
"post": "/v1/documents:analyzeEntities",
"body": "*"
}
},
{
"(google.api.method_signature)": "document,encoding_type"
},
{
"(google.api.method_signature)": "document"
}
]
},
"AnalyzeEntitySentiment": {
"requestType": "AnalyzeEntitySentimentRequest",
"responseType": "AnalyzeEntitySentimentResponse",
"options": {
"(google.api.http).post": "/v1/documents:analyzeEntitySentiment",
"(google.api.http).body": "*",
"(google.api.method_signature)": "document"
},
"parsedOptions": [
{
"(google.api.http)": {
"post": "/v1/documents:analyzeEntitySentiment",
"body": "*"
}
},
{
"(google.api.method_signature)": "document,encoding_type"
},
{
"(google.api.method_signature)": "document"
}
]
},
"AnalyzeSyntax": {
"requestType": "AnalyzeSyntaxRequest",
"responseType": "AnalyzeSyntaxResponse",
"options": {
"(google.api.http).post": "/v1/documents:analyzeSyntax",
"(google.api.http).body": "*",
"(google.api.method_signature)": "document"
},
"parsedOptions": [
{
"(google.api.http)": {
"post": "/v1/documents:analyzeSyntax",
"body": "*"
}
},
{
"(google.api.method_signature)": "document,encoding_type"
},
{
"(google.api.method_signature)": "document"
}
]
},
"ClassifyText": {
"requestType": "ClassifyTextRequest",
"responseType": "ClassifyTextResponse",
"options": {
"(google.api.http).post": "/v1/documents:classifyText",
"(google.api.http).body": "*",
"(google.api.method_signature)": "document"
},
"parsedOptions": [
{
"(google.api.http)": {
"post": "/v1/documents:classifyText",
"body": "*"
}
},
{
"(google.api.method_signature)": "document"
}
]
},
"ModerateText": {
"requestType": "ModerateTextRequest",
"responseType": "ModerateTextResponse",
"options": {
"(google.api.http).post": "/v1/documents:moderateText",
"(google.api.http).body": "*",
"(google.api.method_signature)": "document"
},
"parsedOptions": [
{
"(google.api.http)": {
"post": "/v1/documents:moderateText",
"body": "*"
}
},
{
"(google.api.method_signature)": "document"
}
]
},
"AnnotateText": {
"requestType": "AnnotateTextRequest",
"responseType": "AnnotateTextResponse",
"options": {
"(google.api.http).post": "/v1/documents:annotateText",
"(google.api.http).body": "*",
"(google.api.method_signature)": "document,features"
},
"parsedOptions": [
{
"(google.api.http)": {
"post": "/v1/documents:annotateText",
"body": "*"
}
},
{
"(google.api.method_signature)": "document,features,encoding_type"
},
{
"(google.api.method_signature)": "document,features"
}
]
}
}
},
"Document": {
"oneofs": {
"source": {
"oneof": [
"content",
"gcsContentUri"
]
}
},
"fields": {
"type": {
"type": "Type",
"id": 1
},
"content": {
"type": "string",
"id": 2
},
"gcsContentUri": {
"type": "string",
"id": 3
},
"language": {
"type": "string",
"id": 4
}
},
"nested": {
"Type": {
"values": {
"TYPE_UNSPECIFIED": 0,
"PLAIN_TEXT": 1,
"HTML": 2
}
}
}
},
"Sentence": {
"fields": {
"text": {
"type": "TextSpan",
"id": 1
},
"sentiment": {
"type": "Sentiment",
"id": 2
}
}
},
"EncodingType": {
"values": {
"NONE": 0,
"UTF8": 1,
"UTF16": 2,
"UTF32": 3
}
},
"Entity": {
"fields": {
"name": {
"type": "string",
"id": 1
},
"type": {
"type": "Type",
"id": 2
},
"metadata": {
"keyType": "string",
"type": "string",
"id": 3
},
"salience": {
"type": "float",
"id": 4
},
"mentions": {
"rule": "repeated",
"type": "EntityMention",
"id": 5
},
"sentiment": {
"type": "Sentiment",
"id": 6
}
},
"nested": {
"Type": {
"values": {
"UNKNOWN": 0,
"PERSON": 1,
"LOCATION": 2,
"ORGANIZATION": 3,
"EVENT": 4,
"WORK_OF_ART": 5,
"CONSUMER_GOOD": 6,
"OTHER": 7,
"PHONE_NUMBER": 9,
"ADDRESS": 10,
"DATE": 11,
"NUMBER": 12,
"PRICE": 13
}
}
}
},
"Token": {
"fields": {
"text": {
"type": "TextSpan",
"id": 1
},
"partOfSpeech": {
"type": "PartOfSpeech",
"id": 2
},
"dependencyEdge": {
"type": "DependencyEdge",
"id": 3
},
"lemma": {
"type": "string",
"id": 4
}
}
},
"Sentiment": {
"fields": {
"magnitude": {
"type": "float",
"id": 2
},
"score": {
"type": "float",
"id": 3
}
}
},
"PartOfSpeech": {
"fields": {
"tag": {
"type": "Tag",
"id": 1
},
"aspect": {
"type": "Aspect",
"id": 2
},
"case": {
"type": "Case",
"id": 3
},
"form": {
"type": "Form",
"id": 4
},
"gender": {
"type": "Gender",
"id": 5
},
"mood": {
"type": "Mood",
"id": 6
},
"number": {
"type": "Number",
"id": 7
},
"person": {
"type": "Person",
"id": 8
},
"proper": {
"type": "Proper",
"id": 9
},
"reciprocity": {
"type": "Reciprocity",
"id": 10
},
"tense": {
"type": "Tense",
"id": 11
},
"voice": {
"type": "Voice",
"id": 12
}
},
"nested": {
"Tag": {
"values": {
"UNKNOWN": 0,
"ADJ": 1,
"ADP": 2,
"ADV": 3,
"CONJ": 4,
"DET": 5,
"NOUN": 6,
"NUM": 7,
"PRON": 8,
"PRT": 9,
"PUNCT": 10,
"VERB": 11,
"X": 12,
"AFFIX": 13
}
},
"Aspect": {
"values": {
"ASPECT_UNKNOWN": 0,
"PERFECTIVE": 1,
"IMPERFECTIVE": 2,
"PROGRESSIVE": 3
}
},
"Case": {
"values": {
"CASE_UNKNOWN": 0,
"ACCUSATIVE": 1,
"ADVERBIAL": 2,
"COMPLEMENTIVE": 3,
"DATIVE": 4,
"GENITIVE": 5,
"INSTRUMENTAL": 6,
"LOCATIVE": 7,
"NOMINATIVE": 8,
"OBLIQUE": 9,
"PARTITIVE": 10,
"PREPOSITIONAL": 11,
"REFLEXIVE_CASE": 12,
"RELATIVE_CASE": 13,
"VOCATIVE": 14
}
},
"Form": {
"values": {
"FORM_UNKNOWN": 0,
"ADNOMIAL": 1,
"AUXILIARY": 2,
"COMPLEMENTIZER": 3,
"FINAL_ENDING": 4,
"GERUND": 5,
"REALIS": 6,
"IRREALIS": 7,
"SHORT": 8,
"LONG": 9,
"ORDER": 10,
"SPECIFIC": 11
}
},
"Gender": {
"values": {
"GENDER_UNKNOWN": 0,
"FEMININE": 1,
"MASCULINE": 2,
"NEUTER": 3
}
},
"Mood": {
"values": {
"MOOD_UNKNOWN": 0,
"CONDITIONAL_MOOD": 1,
"IMPERATIVE": 2,
"INDICATIVE": 3,
"INTERROGATIVE": 4,
"JUSSIVE": 5,
"SUBJUNCTIVE": 6
}
},
"Number": {
"values": {
"NUMBER_UNKNOWN": 0,
"SINGULAR": 1,
"PLURAL": 2,
"DUAL": 3
}
},
"Person": {
"values": {
"PERSON_UNKNOWN": 0,
"FIRST": 1,
"SECOND": 2,
"THIRD": 3,
"REFLEXIVE_PERSON": 4
}
},
"Proper": {
"values": {
"PROPER_UNKNOWN": 0,
"PROPER": 1,
"NOT_PROPER": 2
}
},
"Reciprocity": {
"values": {
"RECIPROCITY_UNKNOWN": 0,
"RECIPROCAL": 1,
"NON_RECIPROCAL": 2
}
},
"Tense": {
"values": {
"TENSE_UNKNOWN": 0,
"CONDITIONAL_TENSE": 1,
"FUTURE": 2,
"PAST": 3,
"PRESENT": 4,
"IMPERFECT": 5,
"PLUPERFECT": 6
}
},
"Voice": {
"values": {
"VOICE_UNKNOWN": 0,
"ACTIVE": 1,
"CAUSATIVE": 2,
"PASSIVE": 3
}
}
}
},
"DependencyEdge": {
"fields": {
"headTokenIndex": {
"type": "int32",
"id": 1
},
"label": {
"type": "Label",
"id": 2
}
},
"nested": {
"Label": {
"values": {
"UNKNOWN": 0,
"ABBREV": 1,
"ACOMP": 2,
"ADVCL": 3,
"ADVMOD": 4,
"AMOD": 5,
"APPOS": 6,
"ATTR": 7,
"AUX": 8,
"AUXPASS": 9,
"CC": 10,
"CCOMP": 11,
"CONJ": 12,
"CSUBJ": 13,
"CSUBJPASS": 14,
"DEP": 15,
"DET": 16,
"DISCOURSE": 17,
"DOBJ": 18,
"EXPL": 19,
"GOESWITH": 20,
"IOBJ": 21,
"MARK": 22,
"MWE": 23,
"MWV": 24,
"NEG": 25,
"NN": 26,
"NPADVMOD": 27,
"NSUBJ": 28,
"NSUBJPASS": 29,
"NUM": 30,
"NUMBER": 31,
"P": 32,
"PARATAXIS": 33,
"PARTMOD": 34,
"PCOMP": 35,
"POBJ": 36,
"POSS": 37,
"POSTNEG": 38,
"PRECOMP": 39,
"PRECONJ": 40,
"PREDET": 41,
"PREF": 42,
"PREP": 43,
"PRONL": 44,
"PRT": 45,
"PS": 46,
"QUANTMOD": 47,
"RCMOD": 48,
"RCMODREL": 49,
"RDROP": 50,
"REF": 51,
"REMNANT": 52,
"REPARANDUM": 53,
"ROOT": 54,
"SNUM": 55,
"SUFF": 56,
"TMOD": 57,
"TOPIC": 58,
"VMOD": 59,
"VOCATIVE": 60,
"XCOMP": 61,
"SUFFIX": 62,
"TITLE": 63,
"ADVPHMOD": 64,
"AUXCAUS": 65,
"AUXVV": 66,
"DTMOD": 67,
"FOREIGN": 68,
"KW": 69,
"LIST": 70,
"NOMC": 71,
"NOMCSUBJ": 72,
"NOMCSUBJPASS": 73,
"NUMC": 74,
"COP": 75,
"DISLOCATED": 76,
"ASP": 77,
"GMOD": 78,
"GOBJ": 79,
"INFMOD": 80,
"MES": 81,
"NCOMP": 82
}
}
}
},
"EntityMention": {
"fields": {
"text": {
"type": "TextSpan",
"id": 1
},
"type": {
"type": "Type",
"id": 2
},
"sentiment": {
"type": "Sentiment",
"id": 3
}
},
"nested": {
"Type": {
"values": {
"TYPE_UNKNOWN": 0,
"PROPER": 1,
"COMMON": 2
}
}
}
},
"TextSpan": {
"fields": {
"content": {
"type": "string",
"id": 1
},
"beginOffset": {
"type": "int32",
"id": 2
}
}
},
"ClassificationCategory": {
"fields": {
"name": {
"type": "string",
"id": 1
},
"confidence": {
"type": "float",
"id": 2
}
}
},
"ClassificationModelOptions": {
"oneofs": {
"modelType": {
"oneof": [
"v1Model",
"v2Model"
]
}
},
"fields": {
"v1Model": {
"type": "V1Model",
"id": 1
},
"v2Model": {
"type": "V2Model",
"id": 2
}
},
"nested": {
"V1Model": {
"fields": {}
},
"V2Model": {
"fields": {
"contentCategoriesVersion": {
"type": "ContentCategoriesVersion",
"id": 1
}
},
"nested": {
"ContentCategoriesVersion": {
"values": {
"CONTENT_CATEGORIES_VERSION_UNSPECIFIED": 0,
"V1": 1,
"V2": 2
}
}
}
}
}
},
"AnalyzeSentimentRequest": {
"fields": {
"document": {
"type": "Document",
"id": 1,
"options": {
"(google.api.field_behavior)": "REQUIRED"
}
},
"encodingType": {
"type": "EncodingType",
"id": 2
}
}
},
"AnalyzeSentimentResponse": {
"fields": {
"documentSentiment": {
"type": "Sentiment",
"id": 1
},
"language": {
"type": "string",
"id": 2
},
"sentences": {
"rule": "repeated",
"type": "Sentence",
"id": 3
}
}
},
"AnalyzeEntitySentimentRequest": {
"fields": {
"document": {
"type": "Document",
"id": 1,
"options": {
"(google.api.field_behavior)": "REQUIRED"
}
},
"encodingType": {
"type": "EncodingType",
"id": 2
}
}
},
"AnalyzeEntitySentimentResponse": {
"fields": {
"entities": {
"rule": "repeated",
"type": "Entity",
"id": 1
},
"language": {
"type": "string",
"id": 2
}
}
},
"AnalyzeEntitiesRequest": {
"fields": {
"document": {
"type": "Document",
"id": 1,
"options": {
"(google.api.field_behavior)": "REQUIRED"
}
},
"encodingType": {
"type": "EncodingType",
"id": 2
}
}
},
"AnalyzeEntitiesResponse": {
"fields": {
"entities": {
"rule": "repeated",
"type": "Entity",
"id": 1
},
"language": {
"type": "string",
"id": 2
}
}
},
"AnalyzeSyntaxRequest": {
"fields": {
"document": {
"type": "Document",
"id": 1,
"options": {
"(google.api.field_behavior)": "REQUIRED"
}
},
"encodingType": {
"type": "EncodingType",
"id": 2
}
}
},
"AnalyzeSyntaxResponse": {
"fields": {
"sentences": {
"rule": "repeated",
"type": "Sentence",
"id": 1
},
"tokens": {
"rule": "repeated",
"type": "Token",
"id": 2
},
"language": {
"type": "string",
"id": 3
}
}
},
"ClassifyTextRequest": {
"fields": {
"document": {
"type": "Document",
"id": 1,
"options": {
"(google.api.field_behavior)": "REQUIRED"
}
},
"classificationModelOptions": {
"type": "ClassificationModelOptions",
"id": 3
}
}
},
"ClassifyTextResponse": {
"fields": {
"categories": {
"rule": "repeated",
"type": "ClassificationCategory",
"id": 1
}
}
},
"ModerateTextRequest": {
"fields": {
"document": {
"type": "Document",
"id": 1,
"options": {
"(google.api.field_behavior)": "REQUIRED"
}
}
}
},
"ModerateTextResponse": {
"fields": {
"moderationCategories": {
"rule": "repeated",
"type": "ClassificationCategory",
"id": 1
}
}
},
"AnnotateTextRequest": {
"fields": {
"document": {
"type": "Document",
"id": 1,
"options": {
"(google.api.field_behavior)": "REQUIRED"
}
},
"features": {
"type": "Features",
"id": 2,
"options": {
"(google.api.field_behavior)": "REQUIRED"
}
},
"encodingType": {
"type": "EncodingType",
"id": 3
}
},
"nested": {
"Features": {
"fields": {
"extractSyntax": {
"type": "bool",
"id": 1
},
"extractEntities": {
"type": "bool",
"id": 2
},
"extractDocumentSentiment": {
"type": "bool",
"id": 3
},
"extractEntitySentiment": {
"type": "bool",
"id": 4
},
"classifyText": {
"type": "bool",
"id": 6
},
"moderateText": {
"type": "bool",
"id": 11
},
"classificationModelOptions": {
"type": "ClassificationModelOptions",
"id": 10
}
}
}
}
},
"AnnotateTextResponse": {
"fields": {
"sentences": {
"rule": "repeated",
"type": "Sentence",
"id": 1
},
"tokens": {
"rule": "repeated",
"type": "Token",
"id": 2
},
"entities": {
"rule": "repeated",
"type": "Entity",
"id": 3
},
"documentSentiment": {
"type": "Sentiment",
"id": 4
},
"language": {
"type": "string",
"id": 5
},
"categories": {
"rule": "repeated",
"type": "ClassificationCategory",
"id": 6
},
"moderationCategories": {
"rule": "repeated",
"type": "ClassificationCategory",
"id": 7
}
}
}
}
},
"v1beta2": {
"options": {
"go_package": "cloud.google.com/go/language/apiv1beta2/languagepb;languagepb",
"java_multiple_files": true,
"java_outer_classname": "LanguageServiceProto",
"java_package": "com.google.cloud.language.v1beta2"
},
"nested": {
"LanguageService": {
"options": {
"(google.api.default_host)": "language.googleapis.com",
"(google.api.oauth_scopes)": "https://www.googleapis.com/auth/cloud-language,https://www.googleapis.com/auth/cloud-platform"
},
"methods": {
"AnalyzeSentiment": {
"requestType": "AnalyzeSentimentRequest",
"responseType": "AnalyzeSentimentResponse",
"options": {
"(google.api.http).post": "/v1beta2/documents:analyzeSentiment",
"(google.api.http).body": "*",
"(google.api.method_signature)": "document"
},
"parsedOptions": [
{
"(google.api.http)": {
"post": "/v1beta2/documents:analyzeSentiment",
"body": "*"
}
},
{
"(google.api.method_signature)": "document,encoding_type"
},
{
"(google.api.method_signature)": "document"
}
]
},
"AnalyzeEntities": {
"requestType": "AnalyzeEntitiesRequest",
"responseType": "AnalyzeEntitiesResponse",
"options": {
"(google.api.http).post": "/v1beta2/documents:analyzeEntities",
"(google.api.http).body": "*",
"(google.api.method_signature)": "document"
},
"parsedOptions": [
{
"(google.api.http)": {
"post": "/v1beta2/documents:analyzeEntities",
"body": "*"
}
},
{
"(google.api.method_signature)": "document,encoding_type"
},
{
"(google.api.method_signature)": "document"
}
]
},
"AnalyzeEntitySentiment": {
"requestType": "AnalyzeEntitySentimentRequest",
"responseType": "AnalyzeEntitySentimentResponse",
"options": {
"(google.api.http).post": "/v1beta2/documents:analyzeEntitySentiment",
"(google.api.http).body": "*",
"(google.api.method_signature)": "document"
},
"parsedOptions": [
{
"(google.api.http)": {
"post": "/v1beta2/documents:analyzeEntitySentiment",
"body": "*"
}
},
{
"(google.api.method_signature)": "document,encoding_type"
},
{
"(google.api.method_signature)": "document"
}
]
},
"AnalyzeSyntax": {
"requestType": "AnalyzeSyntaxRequest",
"responseType": "AnalyzeSyntaxResponse",
"options": {
"(google.api.http).post": "/v1beta2/documents:analyzeSyntax",
"(google.api.http).body": "*",
"(google.api.method_signature)": "document"
},
"parsedOptions": [
{
"(google.api.http)": {
"post": "/v1beta2/documents:analyzeSyntax",
"body": "*"
}
},
{
"(google.api.method_signature)": "document,encoding_type"
},
{
"(google.api.method_signature)": "document"
}
]
},
"ClassifyText": {
"requestType": "ClassifyTextRequest",
"responseType": "ClassifyTextResponse",
"options": {
"(google.api.http).post": "/v1beta2/documents:classifyText",
"(google.api.http).body": "*",
"(google.api.method_signature)": "document"
},
"parsedOptions": [
{
"(google.api.http)": {
"post": "/v1beta2/documents:classifyText",
"body": "*"
}
},
{
"(google.api.method_signature)": "document"
}
]
},
"ModerateText": {
"requestType": "ModerateTextRequest",
"responseType": "ModerateTextResponse",
"options": {
"(google.api.http).post": "/v1beta2/documents:moderateText",
"(google.api.http).body": "*",
"(google.api.method_signature)": "document"
},
"parsedOptions": [
{
"(google.api.http)": {
"post": "/v1beta2/documents:moderateText",
"body": "*"
}
},
{
"(google.api.method_signature)": "document"
}
]
},
"AnnotateText": {
"requestType": "AnnotateTextRequest",
"responseType": "AnnotateTextResponse",
"options": {
"(google.api.http).post": "/v1beta2/documents:annotateText",
"(google.api.http).body": "*",
"(google.api.method_signature)": "document,features"
},
"parsedOptions": [
{
"(google.api.http)": {
"post": "/v1beta2/documents:annotateText",
"body": "*"
}
},
{
"(google.api.method_signature)": "document,features,encoding_type"
},
{
"(google.api.method_signature)": "document,features"
}
]
}
}
},
"Document": {
"oneofs": {
"source": {
"oneof": [
"content",
"gcsContentUri"
]
}
},
"fields": {
"type": {
"type": "Type",
"id": 1
},
"content": {
"type": "string",
"id": 2
},
"gcsContentUri": {
"type": "string",
"id": 3
},
"language": {
"type": "string",
"id": 4
},
"referenceWebUri": {
"type": "string",
"id": 5
},
"boilerplateHandling": {
"type": "BoilerplateHandling",
"id": 6
}
},
"nested": {
"Type": {
"values": {
"TYPE_UNSPECIFIED": 0,
"PLAIN_TEXT": 1,
"HTML": 2
}
},
"BoilerplateHandling": {
"values": {
"BOILERPLATE_HANDLING_UNSPECIFIED": 0,
"SKIP_BOILERPLATE": 1,
"KEEP_BOILERPLATE": 2
}
}
}
},
"Sentence": {
"fields": {
"text": {
"type": "TextSpan",
"id": 1
},
"sentiment": {
"type": "Sentiment",
"id": 2
}
}
},
"EncodingType": {
"values": {
"NONE": 0,
"UTF8": 1,
"UTF16": 2,
"UTF32": 3
}
},
"Entity": {
"fields": {
"name": {
"type": "string",
"id": 1
},
"type": {
"type": "Type",
"id": 2
},
"metadata": {
"keyType": "string",
"type": "string",
"id": 3
},
"salience": {
"type": "float",
"id": 4
},
"mentions": {
"rule": "repeated",
"type": "EntityMention",
"id": 5
},
"sentiment": {
"type": "Sentiment",
"id": 6
}
},
"nested": {
"Type": {
"values": {
"UNKNOWN": 0,
"PERSON": 1,
"LOCATION": 2,
"ORGANIZATION": 3,
"EVENT": 4,
"WORK_OF_ART": 5,
"CONSUMER_GOOD": 6,
"OTHER": 7,
"PHONE_NUMBER": 9,
"ADDRESS": 10,
"DATE": 11,
"NUMBER": 12,
"PRICE": 13
}