AWS SDK for Go (PILOT)
API Reference

PREVIEW DOCUMENTATION - This is a preview of a new format for the AWS SDK for Go API Reference documentation. For the current AWS SDK for Go API Reference, see https://docs.aws.amazon.com/sdk-for-go/api/.

We welcome your feedback on this new version of the documentation. Send your comments to aws-sdkdocs-feedback@amazon.com.

SyntaxToken

import "github.com/aws/aws-sdk-go/service/comprehend"

type SyntaxToken struct { BeginOffset *int64 `type:"integer"` EndOffset *int64 `type:"integer"` PartOfSpeech *PartOfSpeechTag `type:"structure"` Text *string `min:"1" type:"string"` TokenId *int64 `type:"integer"` }

Represents a work in the input text that was recognized and assigned a part of speech. There is one syntax token record for each word in the source text.

BeginOffset

Type: *int64

The zero-based offset from the beginning of the source text to the first character in the word.

EndOffset

Type: *int64

The zero-based offset from the beginning of the source text to the last character in the word.

PartOfSpeech

Identifies the part of speech represented by the token and gives the confidence that Amazon Comprehend has that the part of speech was correctly identified. For more information about the parts of speech that Amazon Comprehend can identify, see how-syntax.

Text

Type: *string

The word that was recognized in the source text.

TokenId

Type: *int64

A unique identifier for a token.

Method

GoString

func (s SyntaxToken) GoString() string

GoString returns the string representation

SetBeginOffset

func (s *SyntaxToken) SetBeginOffset(v int64) *SyntaxToken

SetBeginOffset sets the BeginOffset field's value.

SetEndOffset

func (s *SyntaxToken) SetEndOffset(v int64) *SyntaxToken

SetEndOffset sets the EndOffset field's value.

SetPartOfSpeech

func (s *SyntaxToken) SetPartOfSpeech(v *PartOfSpeechTag) *SyntaxToken

SetPartOfSpeech sets the PartOfSpeech field's value.

SetText

func (s *SyntaxToken) SetText(v string) *SyntaxToken

SetText sets the Text field's value.

SetTokenId

func (s *SyntaxToken) SetTokenId(v int64) *SyntaxToken

SetTokenId sets the TokenId field's value.

String

func (s SyntaxToken) String() string

String returns the string representation

On this page: