Copyright | (c) 2013-2021 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 |
Creates a new document classification request to analyze a single document in real-time, using a previously created and trained custom model and an endpoint.
Synopsis
- data ClassifyDocument = ClassifyDocument' {
- text :: Sensitive Text
- endpointArn :: Text
- newClassifyDocument :: Text -> Text -> ClassifyDocument
- classifyDocument_text :: Lens' ClassifyDocument Text
- classifyDocument_endpointArn :: Lens' ClassifyDocument Text
- data ClassifyDocumentResponse = ClassifyDocumentResponse' {
- labels :: Maybe [DocumentLabel]
- classes :: Maybe [DocumentClass]
- httpStatus :: Int
- newClassifyDocumentResponse :: Int -> ClassifyDocumentResponse
- classifyDocumentResponse_labels :: Lens' ClassifyDocumentResponse (Maybe [DocumentLabel])
- classifyDocumentResponse_classes :: Lens' ClassifyDocumentResponse (Maybe [DocumentClass])
- classifyDocumentResponse_httpStatus :: Lens' ClassifyDocumentResponse Int
Creating a Request
data ClassifyDocument Source #
See: newClassifyDocument
smart constructor.
ClassifyDocument' | |
|
Instances
Create a value of ClassifyDocument
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:text:ClassifyDocument'
, classifyDocument_text
- The document text to be analyzed.
$sel:endpointArn:ClassifyDocument'
, classifyDocument_endpointArn
- The Amazon Resource Number (ARN) of the endpoint.
Request Lenses
classifyDocument_text :: Lens' ClassifyDocument Text Source #
The document text to be analyzed.
classifyDocument_endpointArn :: Lens' ClassifyDocument Text Source #
The Amazon Resource Number (ARN) of the endpoint.
Destructuring the Response
data ClassifyDocumentResponse Source #
See: newClassifyDocumentResponse
smart constructor.
ClassifyDocumentResponse' | |
|
Instances
newClassifyDocumentResponse Source #
Create a value of ClassifyDocumentResponse
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:labels:ClassifyDocumentResponse'
, classifyDocumentResponse_labels
- The labels used the document being analyzed. These are used for
multi-label trained models. Individual labels represent different
categories that are related in some manner and are not mutually
exclusive. For example, a movie can be just an action movie, or it can
be an action movie, a science fiction movie, and a comedy, all at the
same time.
$sel:classes:ClassifyDocumentResponse'
, classifyDocumentResponse_classes
- The classes used by the document being analyzed. These are used for
multi-class trained models. Individual classes are mutually exclusive
and each document is expected to have only a single class assigned to
it. For example, an animal can be a dog or a cat, but not both at the
same time.
$sel:httpStatus:ClassifyDocumentResponse'
, classifyDocumentResponse_httpStatus
- The response's http status code.
Response Lenses
classifyDocumentResponse_labels :: Lens' ClassifyDocumentResponse (Maybe [DocumentLabel]) Source #
The labels used the document being analyzed. These are used for multi-label trained models. Individual labels represent different categories that are related in some manner and are not mutually exclusive. For example, a movie can be just an action movie, or it can be an action movie, a science fiction movie, and a comedy, all at the same time.
classifyDocumentResponse_classes :: Lens' ClassifyDocumentResponse (Maybe [DocumentClass]) Source #
The classes used by the document being analyzed. These are used for multi-class trained models. Individual classes are mutually exclusive and each document is expected to have only a single class assigned to it. For example, an animal can be a dog or a cat, but not both at the same time.
classifyDocumentResponse_httpStatus :: Lens' ClassifyDocumentResponse Int Source #
The response's http status code.