Skip to main content

lending_analysis

Creates, updates, deletes, gets or lists a lending_analysis resource.

Overview

Namelending_analysis
TypeResource
Idaws.textract.lending_analysis

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
analyze_lending_model_versionstringThe current model version of the Analyze Lending API.
document_metadataobjectInformation about the input document.
job_statusstringThe current status of the lending analysis job. (IN_PROGRESS, SUCCEEDED, FAILED, PARTIAL_SUCCESS)
next_tokenstringIf the response is truncated, Amazon Textract returns this token. You can use this token in the subsequent request to retrieve the next set of lending results. (pattern: <code>.\S.</code>)
resultsarrayHolds the information returned by one of AmazonTextract's document analysis operations for the pinstripe.
status_messagestringReturns if the lending analysis job could not be completed. Contains explanation for what error occurred.
warningsarrayA list of warnings that occurred during the lending analysis operation.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_lending_analysisselectregionGets the results for an Amazon Textract asynchronous operation that analyzes text in a lending document. You start asynchronous text analysis by calling StartLendingAnalysis, which returns a job identifier (JobId). When the text analysis operation finishes, Amazon Textract publishes a completion status to the Amazon Simple Notification Service (Amazon SNS) topic that's registered in the initial call to StartLendingAnalysis. To get the results of the text analysis operation, first check that the status value published to the Amazon SNS topic is SUCCEEDED. If so, call GetLendingAnalysis, and pass the job identifier (JobId) from the initial call to StartLendingAnalysis.
start_lending_analysisexecregion, DocumentLocationStarts the classification and analysis of an input document. StartLendingAnalysis initiates the classification and analysis of a packet of lending documents. StartLendingAnalysis operates on a document file located in an Amazon S3 bucket. StartLendingAnalysis can analyze text in documents that are in one of the following formats: JPEG, PNG, TIFF, PDF. Use DocumentLocation to specify the bucket name and the file name of the document. StartLendingAnalysis returns a job identifier (JobId) that you use to get the results of the operation. When the text analysis is finished, Amazon Textract publishes a completion status to the Amazon Simple Notification Service (Amazon SNS) topic that you specify in NotificationChannel. To get the results of the text analysis operation, first check that the status value published to the Amazon SNS topic is SUCCEEDED. If the status is SUCCEEDED you can call either GetLendingAnalysis or GetLendingAnalysisSummary and provide the JobId to obtain the results of the analysis. If using OutputConfig to specify an Amazon S3 bucket, the output will be contained within the specified prefix in a directory labeled with the job-id. In the directory there are 3 sub-directories: detailedResponse (contains the GetLendingAnalysis response) summaryResponse (for the GetLendingAnalysisSummary response) splitDocuments (documents split across logical boundaries)

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
regionstringAWS region (default: us-east-1)

SELECT examples

Gets the results for an Amazon Textract asynchronous operation that analyzes text in a lending document. You start asynchronous text analysis by calling StartLendingAnalysis, which returns a job identifier (JobId). When the text analysis operation finishes, Amazon Textract publishes a completion status to the Amazon Simple Notification Service (Amazon SNS) topic that's registered in the initial call to StartLendingAnalysis. To get the results of the text analysis operation, first check that the status value published to the Amazon SNS topic is SUCCEEDED. If so, call GetLendingAnalysis, and pass the job identifier (JobId) from the initial call to StartLendingAnalysis.

SELECT
analyze_lending_model_version,
document_metadata,
job_status,
next_token,
results,
status_message,
warnings
FROM aws.textract.lending_analysis
WHERE region = '{{ region }}' -- required
;

Lifecycle Methods

Starts the classification and analysis of an input document. StartLendingAnalysis initiates the classification and analysis of a packet of lending documents. StartLendingAnalysis operates on a document file located in an Amazon S3 bucket. StartLendingAnalysis can analyze text in documents that are in one of the following formats: JPEG, PNG, TIFF, PDF. Use DocumentLocation to specify the bucket name and the file name of the document. StartLendingAnalysis returns a job identifier (JobId) that you use to get the results of the operation. When the text analysis is finished, Amazon Textract publishes a completion status to the Amazon Simple Notification Service (Amazon SNS) topic that you specify in NotificationChannel. To get the results of the text analysis operation, first check that the status value published to the Amazon SNS topic is SUCCEEDED. If the status is SUCCEEDED you can call either GetLendingAnalysis or GetLendingAnalysisSummary and provide the JobId to obtain the results of the analysis. If using OutputConfig to specify an Amazon S3 bucket, the output will be contained within the specified prefix in a directory labeled with the job-id. In the directory there are 3 sub-directories: detailedResponse (contains the GetLendingAnalysis response) summaryResponse (for the GetLendingAnalysisSummary response) splitDocuments (documents split across logical boundaries)

EXEC aws.textract.lending_analysis.start_lending_analysis
@region='{{ region }}' --required
@@json=
'{
"DocumentLocation": "{{ DocumentLocation }}",
"ClientRequestToken": "{{ ClientRequestToken }}",
"JobTag": "{{ JobTag }}",
"NotificationChannel": "{{ NotificationChannel }}",
"OutputConfig": "{{ OutputConfig }}",
"KMSKeyId": "{{ KMSKeyId }}"
}'
;