Resource: aws_comprehend_entity_recognizer

Terraform resource for managing an AWS Comprehend Entity Recognizer.

Example Usage

Basic Usage

resource "aws_comprehend_entity_recognizer" "example" {
  name = "example"

  data_access_role_arn = aws_iam_role.example.arn

  language_code = "en"
  input_data_config {
    entity_types {
      type = "ENTITY_1"
    }
    entity_types {
      type = "ENTITY_2"
    }

    documents {
      s3_uri = "s3://${aws_s3_bucket.documents.bucket}/${aws_s3_object.documents.id}"
    }

    entity_list {
      s3_uri = "s3://${aws_s3_bucket.entities.bucket}/${aws_s3_object.entities.id}"
    }
  }

  depends_on = [
    aws_iam_role_policy.example
  ]
}

resource "aws_s3_object" "documents" {
  # ...
}

resource "aws_s3_object" "entities" {
  # ...
}

Argument Reference

The following arguments are required:

The following arguments are optional:

input_data_config Configuration Block

annotations Configuration Block

augmented_manifests Configuration Block

documents Configuration Block

entity_list Configuration Block

entity_types Configuration Block

vpc_config Configuration Block

Attribute Reference

This resource exports the following attributes in addition to the arguments above:

Timeouts

aws_comprehend_entity_recognizer provides the following Timeouts configuration options:

Import

In Terraform v1.5.0 and later, use an import block to import Comprehend Entity Recognizer using the ARN. For example:

import {
  to = aws_comprehend_entity_recognizer.example
  id = "arn:aws:comprehend:us-west-2:123456789012:entity-recognizer/example"
}

Using terraform import, import Comprehend Entity Recognizer using the ARN. For example:

% terraform import aws_comprehend_entity_recognizer.example arn:aws:comprehend:us-west-2:123456789012:entity-recognizer/example