1"""Generated message classes for language version v1beta2. 2 3Provides natural language understanding technologies to developers. Examples 4include sentiment analysis, entity recognition, entity sentiment analysis, and 5text annotations. 6""" 7# NOTE: This file is autogenerated and should not be edited by hand. 8 9from __future__ import absolute_import 10 11from apitools.base.protorpclite import messages as _messages 12from apitools.base.py import encoding 13from apitools.base.py import extra_types 14 15 16package = 'language' 17 18 19class AnalyzeEntitiesRequest(_messages.Message): 20 r"""The entity analysis request message. 21 22 Enums: 23 EncodingTypeValueValuesEnum: The encoding type used by the API to 24 calculate offsets. 25 26 Fields: 27 document: Input document. 28 encodingType: The encoding type used by the API to calculate offsets. 29 """ 30 31 class EncodingTypeValueValuesEnum(_messages.Enum): 32 r"""The encoding type used by the API to calculate offsets. 33 34 Values: 35 NONE: If `EncodingType` is not specified, encoding-dependent information 36 (such as `begin_offset`) will be set at `-1`. 37 UTF8: Encoding-dependent information (such as `begin_offset`) is 38 calculated based on the UTF-8 encoding of the input. C++ and Go are 39 examples of languages that use this encoding natively. 40 UTF16: Encoding-dependent information (such as `begin_offset`) is 41 calculated based on the UTF-16 encoding of the input. Java and 42 Javascript are examples of languages that use this encoding natively. 43 UTF32: Encoding-dependent information (such as `begin_offset`) is 44 calculated based on the UTF-32 encoding of the input. Python is an 45 example of a language that uses this encoding natively. 46 """ 47 NONE = 0 48 UTF8 = 1 49 UTF16 = 2 50 UTF32 = 3 51 52 document = _messages.MessageField('Document', 1) 53 encodingType = _messages.EnumField('EncodingTypeValueValuesEnum', 2) 54 55 56class AnalyzeEntitiesResponse(_messages.Message): 57 r"""The entity analysis response message. 58 59 Fields: 60 entities: The recognized entities in the input document. 61 language: The language of the text, which will be the same as the language 62 specified in the request or, if not specified, the automatically- 63 detected language. See Document.language field for more details. 64 """ 65 66 entities = _messages.MessageField('Entity', 1, repeated=True) 67 language = _messages.StringField(2) 68 69 70class AnalyzeEntitySentimentRequest(_messages.Message): 71 r"""The entity-level sentiment analysis request message. 72 73 Enums: 74 EncodingTypeValueValuesEnum: The encoding type used by the API to 75 calculate offsets. 76 77 Fields: 78 document: Input document. 79 encodingType: The encoding type used by the API to calculate offsets. 80 """ 81 82 class EncodingTypeValueValuesEnum(_messages.Enum): 83 r"""The encoding type used by the API to calculate offsets. 84 85 Values: 86 NONE: If `EncodingType` is not specified, encoding-dependent information 87 (such as `begin_offset`) will be set at `-1`. 88 UTF8: Encoding-dependent information (such as `begin_offset`) is 89 calculated based on the UTF-8 encoding of the input. C++ and Go are 90 examples of languages that use this encoding natively. 91 UTF16: Encoding-dependent information (such as `begin_offset`) is 92 calculated based on the UTF-16 encoding of the input. Java and 93 Javascript are examples of languages that use this encoding natively. 94 UTF32: Encoding-dependent information (such as `begin_offset`) is 95 calculated based on the UTF-32 encoding of the input. Python is an 96 example of a language that uses this encoding natively. 97 """ 98 NONE = 0 99 UTF8 = 1 100 UTF16 = 2 101 UTF32 = 3 102 103 document = _messages.MessageField('Document', 1) 104 encodingType = _messages.EnumField('EncodingTypeValueValuesEnum', 2) 105 106 107class AnalyzeEntitySentimentResponse(_messages.Message): 108 r"""The entity-level sentiment analysis response message. 109 110 Fields: 111 entities: The recognized entities in the input document with associated 112 sentiments. 113 language: The language of the text, which will be the same as the language 114 specified in the request or, if not specified, the automatically- 115 detected language. See Document.language field for more details. 116 """ 117 118 entities = _messages.MessageField('Entity', 1, repeated=True) 119 language = _messages.StringField(2) 120 121 122class AnalyzeSentimentRequest(_messages.Message): 123 r"""The sentiment analysis request message. 124 125 Enums: 126 EncodingTypeValueValuesEnum: The encoding type used by the API to 127 calculate sentence offsets for the sentence sentiment. 128 129 Fields: 130 document: Input document. 131 encodingType: The encoding type used by the API to calculate sentence 132 offsets for the sentence sentiment. 133 """ 134 135 class EncodingTypeValueValuesEnum(_messages.Enum): 136 r"""The encoding type used by the API to calculate sentence offsets for 137 the sentence sentiment. 138 139 Values: 140 NONE: If `EncodingType` is not specified, encoding-dependent information 141 (such as `begin_offset`) will be set at `-1`. 142 UTF8: Encoding-dependent information (such as `begin_offset`) is 143 calculated based on the UTF-8 encoding of the input. C++ and Go are 144 examples of languages that use this encoding natively. 145 UTF16: Encoding-dependent information (such as `begin_offset`) is 146 calculated based on the UTF-16 encoding of the input. Java and 147 Javascript are examples of languages that use this encoding natively. 148 UTF32: Encoding-dependent information (such as `begin_offset`) is 149 calculated based on the UTF-32 encoding of the input. Python is an 150 example of a language that uses this encoding natively. 151 """ 152 NONE = 0 153 UTF8 = 1 154 UTF16 = 2 155 UTF32 = 3 156 157 document = _messages.MessageField('Document', 1) 158 encodingType = _messages.EnumField('EncodingTypeValueValuesEnum', 2) 159 160 161class AnalyzeSentimentResponse(_messages.Message): 162 r"""The sentiment analysis response message. 163 164 Fields: 165 documentSentiment: The overall sentiment of the input document. 166 language: The language of the text, which will be the same as the language 167 specified in the request or, if not specified, the automatically- 168 detected language. See Document.language field for more details. 169 sentences: The sentiment for all the sentences in the document. 170 """ 171 172 documentSentiment = _messages.MessageField('Sentiment', 1) 173 language = _messages.StringField(2) 174 sentences = _messages.MessageField('Sentence', 3, repeated=True) 175 176 177class AnalyzeSyntaxRequest(_messages.Message): 178 r"""The syntax analysis request message. 179 180 Enums: 181 EncodingTypeValueValuesEnum: The encoding type used by the API to 182 calculate offsets. 183 184 Fields: 185 document: Input document. 186 encodingType: The encoding type used by the API to calculate offsets. 187 """ 188 189 class EncodingTypeValueValuesEnum(_messages.Enum): 190 r"""The encoding type used by the API to calculate offsets. 191 192 Values: 193 NONE: If `EncodingType` is not specified, encoding-dependent information 194 (such as `begin_offset`) will be set at `-1`. 195 UTF8: Encoding-dependent information (such as `begin_offset`) is 196 calculated based on the UTF-8 encoding of the input. C++ and Go are 197 examples of languages that use this encoding natively. 198 UTF16: Encoding-dependent information (such as `begin_offset`) is 199 calculated based on the UTF-16 encoding of the input. Java and 200 Javascript are examples of languages that use this encoding natively. 201 UTF32: Encoding-dependent information (such as `begin_offset`) is 202 calculated based on the UTF-32 encoding of the input. Python is an 203 example of a language that uses this encoding natively. 204 """ 205 NONE = 0 206 UTF8 = 1 207 UTF16 = 2 208 UTF32 = 3 209 210 document = _messages.MessageField('Document', 1) 211 encodingType = _messages.EnumField('EncodingTypeValueValuesEnum', 2) 212 213 214class AnalyzeSyntaxResponse(_messages.Message): 215 r"""The syntax analysis response message. 216 217 Fields: 218 language: The language of the text, which will be the same as the language 219 specified in the request or, if not specified, the automatically- 220 detected language. See Document.language field for more details. 221 sentences: Sentences in the input document. 222 tokens: Tokens, along with their syntactic information, in the input 223 document. 224 """ 225 226 language = _messages.StringField(1) 227 sentences = _messages.MessageField('Sentence', 2, repeated=True) 228 tokens = _messages.MessageField('Token', 3, repeated=True) 229 230 231class AnnotateTextRequest(_messages.Message): 232 r"""The request message for the text annotation API, which can perform 233 multiple analysis types (sentiment, entities, and syntax) in one call. 234 235 Enums: 236 EncodingTypeValueValuesEnum: The encoding type used by the API to 237 calculate offsets. 238 239 Fields: 240 document: Input document. 241 encodingType: The encoding type used by the API to calculate offsets. 242 features: The enabled features. 243 """ 244 245 class EncodingTypeValueValuesEnum(_messages.Enum): 246 r"""The encoding type used by the API to calculate offsets. 247 248 Values: 249 NONE: If `EncodingType` is not specified, encoding-dependent information 250 (such as `begin_offset`) will be set at `-1`. 251 UTF8: Encoding-dependent information (such as `begin_offset`) is 252 calculated based on the UTF-8 encoding of the input. C++ and Go are 253 examples of languages that use this encoding natively. 254 UTF16: Encoding-dependent information (such as `begin_offset`) is 255 calculated based on the UTF-16 encoding of the input. Java and 256 Javascript are examples of languages that use this encoding natively. 257 UTF32: Encoding-dependent information (such as `begin_offset`) is 258 calculated based on the UTF-32 encoding of the input. Python is an 259 example of a language that uses this encoding natively. 260 """ 261 NONE = 0 262 UTF8 = 1 263 UTF16 = 2 264 UTF32 = 3 265 266 document = _messages.MessageField('Document', 1) 267 encodingType = _messages.EnumField('EncodingTypeValueValuesEnum', 2) 268 features = _messages.MessageField('Features', 3) 269 270 271class AnnotateTextResponse(_messages.Message): 272 r"""The text annotations response message. 273 274 Fields: 275 categories: Categories identified in the input document. 276 documentSentiment: The overall sentiment for the document. Populated if 277 the user enables 278 AnnotateTextRequest.Features.extract_document_sentiment. 279 entities: Entities, along with their semantic information, in the input 280 document. Populated if the user enables 281 AnnotateTextRequest.Features.extract_entities. 282 language: The language of the text, which will be the same as the language 283 specified in the request or, if not specified, the automatically- 284 detected language. See Document.language field for more details. 285 sentences: Sentences in the input document. Populated if the user enables 286 AnnotateTextRequest.Features.extract_syntax. 287 tokens: Tokens, along with their syntactic information, in the input 288 document. Populated if the user enables 289 AnnotateTextRequest.Features.extract_syntax. 290 """ 291 292 categories = _messages.MessageField('ClassificationCategory', 1, repeated=True) 293 documentSentiment = _messages.MessageField('Sentiment', 2) 294 entities = _messages.MessageField('Entity', 3, repeated=True) 295 language = _messages.StringField(4) 296 sentences = _messages.MessageField('Sentence', 5, repeated=True) 297 tokens = _messages.MessageField('Token', 6, repeated=True) 298 299 300class ClassificationCategory(_messages.Message): 301 r"""Represents a category returned from the text classifier. 302 303 Fields: 304 confidence: The classifier's confidence of the category. Number represents 305 how certain the classifier is that this category represents the given 306 text. 307 name: The name of the category representing the document. 308 """ 309 310 confidence = _messages.FloatField(1, variant=_messages.Variant.FLOAT) 311 name = _messages.StringField(2) 312 313 314class ClassifyTextRequest(_messages.Message): 315 r"""The document classification request message. 316 317 Fields: 318 document: Input document. 319 """ 320 321 document = _messages.MessageField('Document', 1) 322 323 324class ClassifyTextResponse(_messages.Message): 325 r"""The document classification response message. 326 327 Fields: 328 categories: Categories representing the input document. 329 """ 330 331 categories = _messages.MessageField('ClassificationCategory', 1, repeated=True) 332 333 334class DependencyEdge(_messages.Message): 335 r"""Represents dependency parse tree information for a token. 336 337 Enums: 338 LabelValueValuesEnum: The parse label for the token. 339 340 Fields: 341 headTokenIndex: Represents the head of this token in the dependency tree. 342 This is the index of the token which has an arc going to this token. The 343 index is the position of the token in the array of tokens returned by 344 the API method. If this token is a root token, then the 345 `head_token_index` is its own index. 346 label: The parse label for the token. 347 """ 348 349 class LabelValueValuesEnum(_messages.Enum): 350 r"""The parse label for the token. 351 352 Values: 353 UNKNOWN: Unknown 354 ABBREV: Abbreviation modifier 355 ACOMP: Adjectival complement 356 ADVCL: Adverbial clause modifier 357 ADVMOD: Adverbial modifier 358 AMOD: Adjectival modifier of an NP 359 APPOS: Appositional modifier of an NP 360 ATTR: Attribute dependent of a copular verb 361 AUX: Auxiliary (non-main) verb 362 AUXPASS: Passive auxiliary 363 CC: Coordinating conjunction 364 CCOMP: Clausal complement of a verb or adjective 365 CONJ: Conjunct 366 CSUBJ: Clausal subject 367 CSUBJPASS: Clausal passive subject 368 DEP: Dependency (unable to determine) 369 DET: Determiner 370 DISCOURSE: Discourse 371 DOBJ: Direct object 372 EXPL: Expletive 373 GOESWITH: Goes with (part of a word in a text not well edited) 374 IOBJ: Indirect object 375 MARK: Marker (word introducing a subordinate clause) 376 MWE: Multi-word expression 377 MWV: Multi-word verbal expression 378 NEG: Negation modifier 379 NN: Noun compound modifier 380 NPADVMOD: Noun phrase used as an adverbial modifier 381 NSUBJ: Nominal subject 382 NSUBJPASS: Passive nominal subject 383 NUM: Numeric modifier of a noun 384 NUMBER: Element of compound number 385 P: Punctuation mark 386 PARATAXIS: Parataxis relation 387 PARTMOD: Participial modifier 388 PCOMP: The complement of a preposition is a clause 389 POBJ: Object of a preposition 390 POSS: Possession modifier 391 POSTNEG: Postverbal negative particle 392 PRECOMP: Predicate complement 393 PRECONJ: Preconjunt 394 PREDET: Predeterminer 395 PREF: Prefix 396 PREP: Prepositional modifier 397 PRONL: The relationship between a verb and verbal morpheme 398 PRT: Particle 399 PS: Associative or possessive marker 400 QUANTMOD: Quantifier phrase modifier 401 RCMOD: Relative clause modifier 402 RCMODREL: Complementizer in relative clause 403 RDROP: Ellipsis without a preceding predicate 404 REF: Referent 405 REMNANT: Remnant 406 REPARANDUM: Reparandum 407 ROOT: Root 408 SNUM: Suffix specifying a unit of number 409 SUFF: Suffix 410 TMOD: Temporal modifier 411 TOPIC: Topic marker 412 VMOD: Clause headed by an infinite form of the verb that modifies a noun 413 VOCATIVE: Vocative 414 XCOMP: Open clausal complement 415 SUFFIX: Name suffix 416 TITLE: Name title 417 ADVPHMOD: Adverbial phrase modifier 418 AUXCAUS: Causative auxiliary 419 AUXVV: Helper auxiliary 420 DTMOD: Rentaishi (Prenominal modifier) 421 FOREIGN: Foreign words 422 KW: Keyword 423 LIST: List for chains of comparable items 424 NOMC: Nominalized clause 425 NOMCSUBJ: Nominalized clausal subject 426 NOMCSUBJPASS: Nominalized clausal passive 427 NUMC: Compound of numeric modifier 428 COP: Copula 429 DISLOCATED: Dislocated relation (for fronted/topicalized elements) 430 """ 431 UNKNOWN = 0 432 ABBREV = 1 433 ACOMP = 2 434 ADVCL = 3 435 ADVMOD = 4 436 AMOD = 5 437 APPOS = 6 438 ATTR = 7 439 AUX = 8 440 AUXPASS = 9 441 CC = 10 442 CCOMP = 11 443 CONJ = 12 444 CSUBJ = 13 445 CSUBJPASS = 14 446 DEP = 15 447 DET = 16 448 DISCOURSE = 17 449 DOBJ = 18 450 EXPL = 19 451 GOESWITH = 20 452 IOBJ = 21 453 MARK = 22 454 MWE = 23 455 MWV = 24 456 NEG = 25 457 NN = 26 458 NPADVMOD = 27 459 NSUBJ = 28 460 NSUBJPASS = 29 461 NUM = 30 462 NUMBER = 31 463 P = 32 464 PARATAXIS = 33 465 PARTMOD = 34 466 PCOMP = 35 467 POBJ = 36 468 POSS = 37 469 POSTNEG = 38 470 PRECOMP = 39 471 PRECONJ = 40 472 PREDET = 41 473 PREF = 42 474 PREP = 43 475 PRONL = 44 476 PRT = 45 477 PS = 46 478 QUANTMOD = 47 479 RCMOD = 48 480 RCMODREL = 49 481 RDROP = 50 482 REF = 51 483 REMNANT = 52 484 REPARANDUM = 53 485 ROOT = 54 486 SNUM = 55 487 SUFF = 56 488 TMOD = 57 489 TOPIC = 58 490 VMOD = 59 491 VOCATIVE = 60 492 XCOMP = 61 493 SUFFIX = 62 494 TITLE = 63 495 ADVPHMOD = 64 496 AUXCAUS = 65 497 AUXVV = 66 498 DTMOD = 67 499 FOREIGN = 68 500 KW = 69 501 LIST = 70 502 NOMC = 71 503 NOMCSUBJ = 72 504 NOMCSUBJPASS = 73 505 NUMC = 74 506 COP = 75 507 DISLOCATED = 76 508 509 headTokenIndex = _messages.IntegerField(1, variant=_messages.Variant.INT32) 510 label = _messages.EnumField('LabelValueValuesEnum', 2) 511 512 513class Document(_messages.Message): 514 r"""################################################################ # 515 Represents the input to API methods. 516 517 Enums: 518 TypeValueValuesEnum: Required. If the type is not set or is 519 `TYPE_UNSPECIFIED`, returns an `INVALID_ARGUMENT` error. 520 521 Fields: 522 content: The content of the input in string format. 523 gcsContentUri: The Google Cloud Storage URI where the file content is 524 located. This URI must be of the form: gs://bucket_name/object_name. For 525 more details, see https://cloud.google.com/storage/docs/reference-uris. 526 NOTE: Cloud Storage object versioning is not supported. 527 language: The language of the document (if not specified, the language is 528 automatically detected). Both ISO and BCP-47 language codes are 529 accepted.<br> [Language Support](/natural-language/docs/languages) lists 530 currently supported languages for each API method. If the language 531 (either specified by the caller or automatically detected) is not 532 supported by the called API method, an `INVALID_ARGUMENT` error is 533 returned. 534 type: Required. If the type is not set or is `TYPE_UNSPECIFIED`, returns 535 an `INVALID_ARGUMENT` error. 536 """ 537 538 class TypeValueValuesEnum(_messages.Enum): 539 r"""Required. If the type is not set or is `TYPE_UNSPECIFIED`, returns an 540 `INVALID_ARGUMENT` error. 541 542 Values: 543 TYPE_UNSPECIFIED: The content type is not specified. 544 PLAIN_TEXT: Plain text 545 HTML: HTML 546 """ 547 TYPE_UNSPECIFIED = 0 548 PLAIN_TEXT = 1 549 HTML = 2 550 551 content = _messages.StringField(1) 552 gcsContentUri = _messages.StringField(2) 553 language = _messages.StringField(3) 554 type = _messages.EnumField('TypeValueValuesEnum', 4) 555 556 557class Entity(_messages.Message): 558 r"""Represents a phrase in the text that is a known entity, such as a 559 person, an organization, or location. The API associates information, such 560 as salience and mentions, with entities. 561 562 Enums: 563 TypeValueValuesEnum: The entity type. 564 565 Messages: 566 MetadataValue: Metadata associated with the entity. Currently, Wikipedia 567 URLs and Knowledge Graph MIDs are provided, if available. The associated 568 keys are "wikipedia_url" and "mid", respectively. 569 570 Fields: 571 mentions: The mentions of this entity in the input document. The API 572 currently supports proper noun mentions. 573 metadata: Metadata associated with the entity. Currently, Wikipedia URLs 574 and Knowledge Graph MIDs are provided, if available. The associated keys 575 are "wikipedia_url" and "mid", respectively. 576 name: The representative name for the entity. 577 salience: The salience score associated with the entity in the [0, 1.0] 578 range. The salience score for an entity provides information about the 579 importance or centrality of that entity to the entire document text. 580 Scores closer to 0 are less salient, while scores closer to 1.0 are 581 highly salient. 582 sentiment: For calls to AnalyzeEntitySentiment or if 583 AnnotateTextRequest.Features.extract_entity_sentiment is set to true, 584 this field will contain the aggregate sentiment expressed for this 585 entity in the provided document. 586 type: The entity type. 587 """ 588 589 class TypeValueValuesEnum(_messages.Enum): 590 r"""The entity type. 591 592 Values: 593 UNKNOWN: Unknown 594 PERSON: Person 595 LOCATION: Location 596 ORGANIZATION: Organization 597 EVENT: Event 598 WORK_OF_ART: Work of art 599 CONSUMER_GOOD: Consumer goods 600 OTHER: Other types 601 """ 602 UNKNOWN = 0 603 PERSON = 1 604 LOCATION = 2 605 ORGANIZATION = 3 606 EVENT = 4 607 WORK_OF_ART = 5 608 CONSUMER_GOOD = 6 609 OTHER = 7 610 611 @encoding.MapUnrecognizedFields('additionalProperties') 612 class MetadataValue(_messages.Message): 613 r"""Metadata associated with the entity. Currently, Wikipedia URLs and 614 Knowledge Graph MIDs are provided, if available. The associated keys are 615 "wikipedia_url" and "mid", respectively. 616 617 Messages: 618 AdditionalProperty: An additional property for a MetadataValue object. 619 620 Fields: 621 additionalProperties: Additional properties of type MetadataValue 622 """ 623 624 class AdditionalProperty(_messages.Message): 625 r"""An additional property for a MetadataValue object. 626 627 Fields: 628 key: Name of the additional property. 629 value: A string attribute. 630 """ 631 632 key = _messages.StringField(1) 633 value = _messages.StringField(2) 634 635 additionalProperties = _messages.MessageField('AdditionalProperty', 1, repeated=True) 636 637 mentions = _messages.MessageField('EntityMention', 1, repeated=True) 638 metadata = _messages.MessageField('MetadataValue', 2) 639 name = _messages.StringField(3) 640 salience = _messages.FloatField(4, variant=_messages.Variant.FLOAT) 641 sentiment = _messages.MessageField('Sentiment', 5) 642 type = _messages.EnumField('TypeValueValuesEnum', 6) 643 644 645class EntityMention(_messages.Message): 646 r"""Represents a mention for an entity in the text. Currently, proper noun 647 mentions are supported. 648 649 Enums: 650 TypeValueValuesEnum: The type of the entity mention. 651 652 Fields: 653 sentiment: For calls to AnalyzeEntitySentiment or if 654 AnnotateTextRequest.Features.extract_entity_sentiment is set to true, 655 this field will contain the sentiment expressed for this mention of the 656 entity in the provided document. 657 text: The mention text. 658 type: The type of the entity mention. 659 """ 660 661 class TypeValueValuesEnum(_messages.Enum): 662 r"""The type of the entity mention. 663 664 Values: 665 TYPE_UNKNOWN: Unknown 666 PROPER: Proper name 667 COMMON: Common noun (or noun compound) 668 """ 669 TYPE_UNKNOWN = 0 670 PROPER = 1 671 COMMON = 2 672 673 sentiment = _messages.MessageField('Sentiment', 1) 674 text = _messages.MessageField('TextSpan', 2) 675 type = _messages.EnumField('TypeValueValuesEnum', 3) 676 677 678class Features(_messages.Message): 679 r"""All available features for sentiment, syntax, and semantic analysis. 680 Setting each one to true will enable that specific analysis for the input. 681 682 Fields: 683 classifyText: Classify the full document into categories. 684 extractDocumentSentiment: Extract document-level sentiment. 685 extractEntities: Extract entities. 686 extractEntitySentiment: Extract entities and their associated sentiment. 687 extractSyntax: Extract syntax information. 688 """ 689 690 classifyText = _messages.BooleanField(1) 691 extractDocumentSentiment = _messages.BooleanField(2) 692 extractEntities = _messages.BooleanField(3) 693 extractEntitySentiment = _messages.BooleanField(4) 694 extractSyntax = _messages.BooleanField(5) 695 696 697class PartOfSpeech(_messages.Message): 698 r"""Represents part of speech information for a token. 699 700 Enums: 701 AspectValueValuesEnum: The grammatical aspect. 702 CaseValueValuesEnum: The grammatical case. 703 FormValueValuesEnum: The grammatical form. 704 GenderValueValuesEnum: The grammatical gender. 705 MoodValueValuesEnum: The grammatical mood. 706 NumberValueValuesEnum: The grammatical number. 707 PersonValueValuesEnum: The grammatical person. 708 ProperValueValuesEnum: The grammatical properness. 709 ReciprocityValueValuesEnum: The grammatical reciprocity. 710 TagValueValuesEnum: The part of speech tag. 711 TenseValueValuesEnum: The grammatical tense. 712 VoiceValueValuesEnum: The grammatical voice. 713 714 Fields: 715 aspect: The grammatical aspect. 716 case: The grammatical case. 717 form: The grammatical form. 718 gender: The grammatical gender. 719 mood: The grammatical mood. 720 number: The grammatical number. 721 person: The grammatical person. 722 proper: The grammatical properness. 723 reciprocity: The grammatical reciprocity. 724 tag: The part of speech tag. 725 tense: The grammatical tense. 726 voice: The grammatical voice. 727 """ 728 729 class AspectValueValuesEnum(_messages.Enum): 730 r"""The grammatical aspect. 731 732 Values: 733 ASPECT_UNKNOWN: Aspect is not applicable in the analyzed language or is 734 not predicted. 735 PERFECTIVE: Perfective 736 IMPERFECTIVE: Imperfective 737 PROGRESSIVE: Progressive 738 """ 739 ASPECT_UNKNOWN = 0 740 PERFECTIVE = 1 741 IMPERFECTIVE = 2 742 PROGRESSIVE = 3 743 744 class CaseValueValuesEnum(_messages.Enum): 745 r"""The grammatical case. 746 747 Values: 748 CASE_UNKNOWN: Case is not applicable in the analyzed language or is not 749 predicted. 750 ACCUSATIVE: Accusative 751 ADVERBIAL: Adverbial 752 COMPLEMENTIVE: Complementive 753 DATIVE: Dative 754 GENITIVE: Genitive 755 INSTRUMENTAL: Instrumental 756 LOCATIVE: Locative 757 NOMINATIVE: Nominative 758 OBLIQUE: Oblique 759 PARTITIVE: Partitive 760 PREPOSITIONAL: Prepositional 761 REFLEXIVE_CASE: Reflexive 762 RELATIVE_CASE: Relative 763 VOCATIVE: Vocative 764 """ 765 CASE_UNKNOWN = 0 766 ACCUSATIVE = 1 767 ADVERBIAL = 2 768 COMPLEMENTIVE = 3 769 DATIVE = 4 770 GENITIVE = 5 771 INSTRUMENTAL = 6 772 LOCATIVE = 7 773 NOMINATIVE = 8 774 OBLIQUE = 9 775 PARTITIVE = 10 776 PREPOSITIONAL = 11 777 REFLEXIVE_CASE = 12 778 RELATIVE_CASE = 13 779 VOCATIVE = 14 780 781 class FormValueValuesEnum(_messages.Enum): 782 r"""The grammatical form. 783 784 Values: 785 FORM_UNKNOWN: Form is not applicable in the analyzed language or is not 786 predicted. 787 ADNOMIAL: Adnomial 788 AUXILIARY: Auxiliary 789 COMPLEMENTIZER: Complementizer 790 FINAL_ENDING: Final ending 791 GERUND: Gerund 792 REALIS: Realis 793 IRREALIS: Irrealis 794 SHORT: Short form 795 LONG: Long form 796 ORDER: Order form 797 SPECIFIC: Specific form 798 """ 799 FORM_UNKNOWN = 0 800 ADNOMIAL = 1 801 AUXILIARY = 2 802 COMPLEMENTIZER = 3 803 FINAL_ENDING = 4 804 GERUND = 5 805 REALIS = 6 806 IRREALIS = 7 807 SHORT = 8 808 LONG = 9 809 ORDER = 10 810 SPECIFIC = 11 811 812 class GenderValueValuesEnum(_messages.Enum): 813 r"""The grammatical gender. 814 815 Values: 816 GENDER_UNKNOWN: Gender is not applicable in the analyzed language or is 817 not predicted. 818 FEMININE: Feminine 819 MASCULINE: Masculine 820 NEUTER: Neuter 821 """ 822 GENDER_UNKNOWN = 0 823 FEMININE = 1 824 MASCULINE = 2 825 NEUTER = 3 826 827 class MoodValueValuesEnum(_messages.Enum): 828 r"""The grammatical mood. 829 830 Values: 831 MOOD_UNKNOWN: Mood is not applicable in the analyzed language or is not 832 predicted. 833 CONDITIONAL_MOOD: Conditional 834 IMPERATIVE: Imperative 835 INDICATIVE: Indicative 836 INTERROGATIVE: Interrogative 837 JUSSIVE: Jussive 838 SUBJUNCTIVE: Subjunctive 839 """ 840 MOOD_UNKNOWN = 0 841 CONDITIONAL_MOOD = 1 842 IMPERATIVE = 2 843 INDICATIVE = 3 844 INTERROGATIVE = 4 845 JUSSIVE = 5 846 SUBJUNCTIVE = 6 847 848 class NumberValueValuesEnum(_messages.Enum): 849 r"""The grammatical number. 850 851 Values: 852 NUMBER_UNKNOWN: Number is not applicable in the analyzed language or is 853 not predicted. 854 SINGULAR: Singular 855 PLURAL: Plural 856 DUAL: Dual 857 """ 858 NUMBER_UNKNOWN = 0 859 SINGULAR = 1 860 PLURAL = 2 861 DUAL = 3 862 863 class PersonValueValuesEnum(_messages.Enum): 864 r"""The grammatical person. 865 866 Values: 867 PERSON_UNKNOWN: Person is not applicable in the analyzed language or is 868 not predicted. 869 FIRST: First 870 SECOND: Second 871 THIRD: Third 872 REFLEXIVE_PERSON: Reflexive 873 """ 874 PERSON_UNKNOWN = 0 875 FIRST = 1 876 SECOND = 2 877 THIRD = 3 878 REFLEXIVE_PERSON = 4 879 880 class ProperValueValuesEnum(_messages.Enum): 881 r"""The grammatical properness. 882 883 Values: 884 PROPER_UNKNOWN: Proper is not applicable in the analyzed language or is 885 not predicted. 886 PROPER: Proper 887 NOT_PROPER: Not proper 888 """ 889 PROPER_UNKNOWN = 0 890 PROPER = 1 891 NOT_PROPER = 2 892 893 class ReciprocityValueValuesEnum(_messages.Enum): 894 r"""The grammatical reciprocity. 895 896 Values: 897 RECIPROCITY_UNKNOWN: Reciprocity is not applicable in the analyzed 898 language or is not predicted. 899 RECIPROCAL: Reciprocal 900 NON_RECIPROCAL: Non-reciprocal 901 """ 902 RECIPROCITY_UNKNOWN = 0 903 RECIPROCAL = 1 904 NON_RECIPROCAL = 2 905 906 class TagValueValuesEnum(_messages.Enum): 907 r"""The part of speech tag. 908 909 Values: 910 UNKNOWN: Unknown 911 ADJ: Adjective 912 ADP: Adposition (preposition and postposition) 913 ADV: Adverb 914 CONJ: Conjunction 915 DET: Determiner 916 NOUN: Noun (common and proper) 917 NUM: Cardinal number 918 PRON: Pronoun 919 PRT: Particle or other function word 920 PUNCT: Punctuation 921 VERB: Verb (all tenses and modes) 922 X: Other: foreign words, typos, abbreviations 923 AFFIX: Affix 924 """ 925 UNKNOWN = 0 926 ADJ = 1 927 ADP = 2 928 ADV = 3 929 CONJ = 4 930 DET = 5 931 NOUN = 6 932 NUM = 7 933 PRON = 8 934 PRT = 9 935 PUNCT = 10 936 VERB = 11 937 X = 12 938 AFFIX = 13 939 940 class TenseValueValuesEnum(_messages.Enum): 941 r"""The grammatical tense. 942 943 Values: 944 TENSE_UNKNOWN: Tense is not applicable in the analyzed language or is 945 not predicted. 946 CONDITIONAL_TENSE: Conditional 947 FUTURE: Future 948 PAST: Past 949 PRESENT: Present 950 IMPERFECT: Imperfect 951 PLUPERFECT: Pluperfect 952 """ 953 TENSE_UNKNOWN = 0 954 CONDITIONAL_TENSE = 1 955 FUTURE = 2 956 PAST = 3 957 PRESENT = 4 958 IMPERFECT = 5 959 PLUPERFECT = 6 960 961 class VoiceValueValuesEnum(_messages.Enum): 962 r"""The grammatical voice. 963 964 Values: 965 VOICE_UNKNOWN: Voice is not applicable in the analyzed language or is 966 not predicted. 967 ACTIVE: Active 968 CAUSATIVE: Causative 969 PASSIVE: Passive 970 """ 971 VOICE_UNKNOWN = 0 972 ACTIVE = 1 973 CAUSATIVE = 2 974 PASSIVE = 3 975 976 aspect = _messages.EnumField('AspectValueValuesEnum', 1) 977 case = _messages.EnumField('CaseValueValuesEnum', 2) 978 form = _messages.EnumField('FormValueValuesEnum', 3) 979 gender = _messages.EnumField('GenderValueValuesEnum', 4) 980 mood = _messages.EnumField('MoodValueValuesEnum', 5) 981 number = _messages.EnumField('NumberValueValuesEnum', 6) 982 person = _messages.EnumField('PersonValueValuesEnum', 7) 983 proper = _messages.EnumField('ProperValueValuesEnum', 8) 984 reciprocity = _messages.EnumField('ReciprocityValueValuesEnum', 9) 985 tag = _messages.EnumField('TagValueValuesEnum', 10) 986 tense = _messages.EnumField('TenseValueValuesEnum', 11) 987 voice = _messages.EnumField('VoiceValueValuesEnum', 12) 988 989 990class Sentence(_messages.Message): 991 r"""Represents a sentence in the input document. 992 993 Fields: 994 sentiment: For calls to AnalyzeSentiment or if 995 AnnotateTextRequest.Features.extract_document_sentiment is set to true, 996 this field will contain the sentiment for the sentence. 997 text: The sentence text. 998 """ 999 1000 sentiment = _messages.MessageField('Sentiment', 1) 1001 text = _messages.MessageField('TextSpan', 2) 1002 1003 1004class Sentiment(_messages.Message): 1005 r"""Represents the feeling associated with the entire text or entities in 1006 the text. 1007 1008 Fields: 1009 magnitude: A non-negative number in the [0, +inf) range, which represents 1010 the absolute magnitude of sentiment regardless of score (positive or 1011 negative). 1012 score: Sentiment score between -1.0 (negative sentiment) and 1.0 (positive 1013 sentiment). 1014 """ 1015 1016 magnitude = _messages.FloatField(1, variant=_messages.Variant.FLOAT) 1017 score = _messages.FloatField(2, variant=_messages.Variant.FLOAT) 1018 1019 1020class StandardQueryParameters(_messages.Message): 1021 r"""Query parameters accepted by all methods. 1022 1023 Enums: 1024 FXgafvValueValuesEnum: V1 error format. 1025 AltValueValuesEnum: Data format for response. 1026 1027 Fields: 1028 f__xgafv: V1 error format. 1029 access_token: OAuth access token. 1030 alt: Data format for response. 1031 bearer_token: OAuth bearer token. 1032 callback: JSONP 1033 fields: Selector specifying which fields to include in a partial response. 1034 key: API key. Your API key identifies your project and provides you with 1035 API access, quota, and reports. Required unless you provide an OAuth 2.0 1036 token. 1037 oauth_token: OAuth 2.0 token for the current user. 1038 pp: Pretty-print response. 1039 prettyPrint: Returns response with indentations and line breaks. 1040 quotaUser: Available to use for quota purposes for server-side 1041 applications. Can be any arbitrary string assigned to a user, but should 1042 not exceed 40 characters. 1043 trace: A tracing token of the form "token:<tokenid>" to include in api 1044 requests. 1045 uploadType: Legacy upload protocol for media (e.g. "media", "multipart"). 1046 upload_protocol: Upload protocol for media (e.g. "raw", "multipart"). 1047 """ 1048 1049 class AltValueValuesEnum(_messages.Enum): 1050 r"""Data format for response. 1051 1052 Values: 1053 json: Responses with Content-Type of application/json 1054 media: Media download with context-dependent Content-Type 1055 proto: Responses with Content-Type of application/x-protobuf 1056 """ 1057 json = 0 1058 media = 1 1059 proto = 2 1060 1061 class FXgafvValueValuesEnum(_messages.Enum): 1062 r"""V1 error format. 1063 1064 Values: 1065 _1: v1 error format 1066 _2: v2 error format 1067 """ 1068 _1 = 0 1069 _2 = 1 1070 1071 f__xgafv = _messages.EnumField('FXgafvValueValuesEnum', 1) 1072 access_token = _messages.StringField(2) 1073 alt = _messages.EnumField('AltValueValuesEnum', 3, default='json') 1074 bearer_token = _messages.StringField(4) 1075 callback = _messages.StringField(5) 1076 fields = _messages.StringField(6) 1077 key = _messages.StringField(7) 1078 oauth_token = _messages.StringField(8) 1079 pp = _messages.BooleanField(9, default=True) 1080 prettyPrint = _messages.BooleanField(10, default=True) 1081 quotaUser = _messages.StringField(11) 1082 trace = _messages.StringField(12) 1083 uploadType = _messages.StringField(13) 1084 upload_protocol = _messages.StringField(14) 1085 1086 1087class Status(_messages.Message): 1088 r"""The `Status` type defines a logical error model that is suitable for 1089 different programming environments, including REST APIs and RPC APIs. It is 1090 used by [gRPC](https://github.com/grpc). The error model is designed to be: 1091 - Simple to use and understand for most users - Flexible enough to meet 1092 unexpected needs # Overview The `Status` message contains three pieces of 1093 data: error code, error message, and error details. The error code should be 1094 an enum value of google.rpc.Code, but it may accept additional error codes 1095 if needed. The error message should be a developer-facing English message 1096 that helps developers *understand* and *resolve* the error. If a localized 1097 user-facing error message is needed, put the localized message in the error 1098 details or localize it in the client. The optional error details may contain 1099 arbitrary information about the error. There is a predefined set of error 1100 detail types in the package `google.rpc` that can be used for common error 1101 conditions. # Language mapping The `Status` message is the logical 1102 representation of the error model, but it is not necessarily the actual wire 1103 format. When the `Status` message is exposed in different client libraries 1104 and different wire protocols, it can be mapped differently. For example, it 1105 will likely be mapped to some exceptions in Java, but more likely mapped to 1106 some error codes in C. # Other uses The error model and the `Status` 1107 message can be used in a variety of environments, either with or without 1108 APIs, to provide a consistent developer experience across different 1109 environments. Example uses of this error model include: - Partial errors. 1110 If a service needs to return partial errors to the client, it may embed 1111 the `Status` in the normal response to indicate the partial errors. - 1112 Workflow errors. A typical workflow has multiple steps. Each step may 1113 have a `Status` message for error reporting. - Batch operations. If a 1114 client uses batch request and batch response, the `Status` message 1115 should be used directly inside batch response, one for each error sub- 1116 response. - Asynchronous operations. If an API call embeds asynchronous 1117 operation results in its response, the status of those operations should 1118 be represented directly using the `Status` message. - Logging. If some 1119 API errors are stored in logs, the message `Status` could be used 1120 directly after any stripping needed for security/privacy reasons. 1121 1122 Messages: 1123 DetailsValueListEntry: A DetailsValueListEntry object. 1124 1125 Fields: 1126 code: The status code, which should be an enum value of google.rpc.Code. 1127 details: A list of messages that carry the error details. There is a 1128 common set of message types for APIs to use. 1129 message: A developer-facing error message, which should be in English. Any 1130 user-facing error message should be localized and sent in the 1131 google.rpc.Status.details field, or localized by the client. 1132 """ 1133 1134 @encoding.MapUnrecognizedFields('additionalProperties') 1135 class DetailsValueListEntry(_messages.Message): 1136 r"""A DetailsValueListEntry object. 1137 1138 Messages: 1139 AdditionalProperty: An additional property for a DetailsValueListEntry 1140 object. 1141 1142 Fields: 1143 additionalProperties: Properties of the object. Contains field @type 1144 with type URL. 1145 """ 1146 1147 class AdditionalProperty(_messages.Message): 1148 r"""An additional property for a DetailsValueListEntry object. 1149 1150 Fields: 1151 key: Name of the additional property. 1152 value: A extra_types.JsonValue attribute. 1153 """ 1154 1155 key = _messages.StringField(1) 1156 value = _messages.MessageField('extra_types.JsonValue', 2) 1157 1158 additionalProperties = _messages.MessageField('AdditionalProperty', 1, repeated=True) 1159 1160 code = _messages.IntegerField(1, variant=_messages.Variant.INT32) 1161 details = _messages.MessageField('DetailsValueListEntry', 2, repeated=True) 1162 message = _messages.StringField(3) 1163 1164 1165class TextSpan(_messages.Message): 1166 r"""Represents an output piece of text. 1167 1168 Fields: 1169 beginOffset: The API calculates the beginning offset of the content in the 1170 original document according to the EncodingType specified in the API 1171 request. 1172 content: The content of the output text. 1173 """ 1174 1175 beginOffset = _messages.IntegerField(1, variant=_messages.Variant.INT32) 1176 content = _messages.StringField(2) 1177 1178 1179class Token(_messages.Message): 1180 r"""Represents the smallest syntactic building block of the text. 1181 1182 Fields: 1183 dependencyEdge: Dependency tree parse for this token. 1184 lemma: [Lemma](https://en.wikipedia.org/wiki/Lemma_%28morphology%29) of 1185 the token. 1186 partOfSpeech: Parts of speech tag for this token. 1187 text: The token text. 1188 """ 1189 1190 dependencyEdge = _messages.MessageField('DependencyEdge', 1) 1191 lemma = _messages.StringField(2) 1192 partOfSpeech = _messages.MessageField('PartOfSpeech', 3) 1193 text = _messages.MessageField('TextSpan', 4) 1194 1195 1196encoding.AddCustomJsonFieldMapping( 1197 StandardQueryParameters, 'f__xgafv', '$.xgafv') 1198encoding.AddCustomJsonEnumMapping( 1199 StandardQueryParameters.FXgafvValueValuesEnum, '_1', '1') 1200encoding.AddCustomJsonEnumMapping( 1201 StandardQueryParameters.FXgafvValueValuesEnum, '_2', '2') 1202