Copyright | (c) 2013-2018 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay+amazonka@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Language | Haskell2010 |
Detects the key noun phrases found in the text.
- detectKeyPhrases :: Text -> LanguageCode -> DetectKeyPhrases
- data DetectKeyPhrases
- dkpText :: Lens' DetectKeyPhrases Text
- dkpLanguageCode :: Lens' DetectKeyPhrases LanguageCode
- detectKeyPhrasesResponse :: Int -> DetectKeyPhrasesResponse
- data DetectKeyPhrasesResponse
- dkprsKeyPhrases :: Lens' DetectKeyPhrasesResponse [KeyPhrase]
- dkprsResponseStatus :: Lens' DetectKeyPhrasesResponse Int
Creating a Request
Creates a value of DetectKeyPhrases
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
dkpText
- A UTF-8 text string. Each string must contain fewer that 5,000 bytes of UTF-8 encoded characters.dkpLanguageCode
- The RFC 5646 language code for the input text. If you don't specify a language code, Amazon Comprehend detects the dominant language. If you specify the code for a language that Amazon Comprehend does not support, it returns andUnsupportedLanguageException
. For more information about RFC 5646, see Tags for Identifying Languages on the IETF Tools web site.
data DetectKeyPhrases Source #
See: detectKeyPhrases
smart constructor.
Request Lenses
dkpText :: Lens' DetectKeyPhrases Text Source #
A UTF-8 text string. Each string must contain fewer that 5,000 bytes of UTF-8 encoded characters.
dkpLanguageCode :: Lens' DetectKeyPhrases LanguageCode Source #
The RFC 5646 language code for the input text. If you don't specify a language code, Amazon Comprehend detects the dominant language. If you specify the code for a language that Amazon Comprehend does not support, it returns and UnsupportedLanguageException
. For more information about RFC 5646, see Tags for Identifying Languages on the IETF Tools web site.
Destructuring the Response
detectKeyPhrasesResponse Source #
Creates a value of DetectKeyPhrasesResponse
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
dkprsKeyPhrases
- A collection of key phrases that Amazon Comprehend identified in the input text. For each key phrase, the response provides the text of the key phrase, where the key phrase begins and ends, and the level of confidence that Amazon Comprehend has in the accuracy of the detection.dkprsResponseStatus
- -- | The response status code.
data DetectKeyPhrasesResponse Source #
See: detectKeyPhrasesResponse
smart constructor.
Response Lenses
dkprsKeyPhrases :: Lens' DetectKeyPhrasesResponse [KeyPhrase] Source #
A collection of key phrases that Amazon Comprehend identified in the input text. For each key phrase, the response provides the text of the key phrase, where the key phrase begins and ends, and the level of confidence that Amazon Comprehend has in the accuracy of the detection.
dkprsResponseStatus :: Lens' DetectKeyPhrasesResponse Int Source #
- - | The response status code.