@@ -69,7 +69,7 @@ service LanguageService {
6969 }
7070
7171 // Analyzes the syntax of the text and provides sentence boundaries and
72- // tokenization along with part of speech tags, dependency trees, and other
72+ // tokenization along with part-of- speech tags, dependency trees, and other
7373 // properties.
7474 rpc AnalyzeSyntax (AnalyzeSyntaxRequest ) returns (AnalyzeSyntaxResponse ) {
7575 option (google.api.http ) = {
@@ -272,6 +272,21 @@ message Entity {
272272 Sentiment sentiment = 6 ;
273273}
274274
275+ // Represents the smallest syntactic building block of the text.
276+ message Token {
277+ // The token text.
278+ TextSpan text = 1 ;
279+
280+ // Parts of speech tag for this token.
281+ PartOfSpeech part_of_speech = 2 ;
282+
283+ // Dependency tree parse for this token.
284+ DependencyEdge dependency_edge = 3 ;
285+
286+ // [Lemma](https://en.wikipedia.org/wiki/Lemma_%28morphology%29) of the token.
287+ string lemma = 4 ;
288+ }
289+
275290// Represents the text encoding that the caller uses to process the output.
276291// Providing an `EncodingType` is recommended because the API provides the
277292// beginning offsets for various outputs, such as tokens and mentions, and
@@ -298,21 +313,6 @@ enum EncodingType {
298313 UTF32 = 3 ;
299314}
300315
301- // Represents the smallest syntactic building block of the text.
302- message Token {
303- // The token text.
304- TextSpan text = 1 ;
305-
306- // Parts of speech tag for this token.
307- PartOfSpeech part_of_speech = 2 ;
308-
309- // Dependency tree parse for this token.
310- DependencyEdge dependency_edge = 3 ;
311-
312- // [Lemma](https://en.wikipedia.org/wiki/Lemma_%28morphology%29) of the token.
313- string lemma = 4 ;
314- }
315-
316316// Represents the feeling associated with the entire text or entities in
317317// the text.
318318// Next ID: 6
0 commit comments