

# StartOntologyInduction

Starts an ontology induction, which induces a draft ontology from the documents that you provide. The induction runs asynchronously. To get its status, call GetOntologyInduction. When the induction's status is `DRAFT`, AWS Context has created the ontology as a `DRAFT`: GetOntologyInduction returns the ontology's ID, and GetOntology returns the draft. To publish the draft, use the AWS Context console. Because AWS Context creates the ontology on your behalf, you need `context:CreateOntology` permission in addition to `context:StartOntologyInduction`. If you specify tags, you also need `context:TagResource` permission.

## Request Parameters
<a name="API_StartOntologyInduction_RequestParameters"></a>

 ** clientToken **   
A unique, case-sensitive identifier that you provide to make the request idempotent. A retry of the same request with the same token returns the induction that the first request created, and the same token used with a different request returns a `ValidationException`. If that induction, or the ontology it created, was deleted since, a retry with the token fails with `ConflictException`.  
Type: String  
Length Constraints: Minimum length of 1. Maximum length of 64.  
Pattern: `[\x21-\x7E]+`   
Required: No

 ** inputConfig **   
The input to induce the ontology from. Set exactly one member.  
Type: [OntologyInductionInputConfig](API_OntologyInductionInputConfig.md) object  
 **Note: **This object is a Union. Only one member of this object can be specified or returned.  
Required: Yes

 ** ontologyDescription **   
Optional. The new ontology's description. An empty string is the same as none.  
Type: String  
Length Constraints: Minimum length of 0. Maximum length of 1024.  
Pattern: `\P{Cc}*`   
Required: No

 ** ontologyName **   
The new ontology's display name.  
Type: String  
Length Constraints: Minimum length of 1. Maximum length of 128.  
Pattern: `[^\s\p{Cc}\p{Z}\p{Cf}](\P{Cc}*[^\s\p{Cc}\p{Z}\p{Cf}])?`   
Required: Yes

 ** ontologyTags **   
Tags to add to the ontology the induction creates at DRAFT, with the same limits and rules as `tags`. They are checked here, and supplying them also requires `context:TagResource` on the new ontology. These tags go on the ontology only. `tags` go on the induction.  
Type: String to string map  
Map Entries: Minimum number of 0 items. Maximum number of 200 items.  
Key Length Constraints: Minimum length of 1. Maximum length of 128.  
Value Length Constraints: Minimum length of 0. Maximum length of 256.  
Required: No

 ** prompt **   
Optional. Instructions for the induction.  
Type: String  
Length Constraints: Minimum length of 1. Maximum length of 8000.  
Required: No

 ** seedOntologyId **   
Optional. An existing ontology to start from, by ID or ARN. If you omit it, AWS Context induces the ontology from the documents alone. The seed must be an ontology that you own, it must be `PUBLISHED`, and its current version must be derived from a Turtle source document. You also need `context:GetOntology` permission on the seed. If the seed doesn't exist, the request fails with `ResourceNotFoundException`. If it can't be used, the request fails with `ValidationException`. If the seed's source document is deleted while the induction runs, is larger than 400,000 bytes, or doesn't parse, the induction fails with `SEED_INVALID`.  
Type: String  
Length Constraints: Minimum length of 1. Maximum length of 180.  
Pattern: `(arn:(aws|aws-cn|aws-us-gov):context:[a-z0-9\-]{1,32}:(\d{12})?:ontology/)?[a-z0-9]+(-[a-z0-9]+)*`   
Required: No

 ** tags **   
Tags to add to the induction when you create it: up to 200 in the request, of which at most 50 can be user tags. Keys can't start with `aws:`. To add tags, you also need `context:TagResource` permission on the new induction. If you specify more than 50 user tags, the request fails with `ServiceQuotaExceededException`, as on TagResource. If an AWS Organizations tag policy refuses a tag, the request fails with `ValidationException`. These tags go on the induction only. `ontologyTags` go on the ontology.  
Type: String to string map  
Map Entries: Minimum number of 0 items. Maximum number of 200 items.  
Key Length Constraints: Minimum length of 1. Maximum length of 128.  
Value Length Constraints: Minimum length of 0. Maximum length of 256.  
Required: No

## Response Elements
<a name="API_StartOntologyInduction_ResponseElements"></a>

The following elements are returned by the service.

 ** arn **   
The Amazon Resource Name (ARN) of the ontology induction.  
Type: String  
Length Constraints: Minimum length of 1. Maximum length of 1011.  
Pattern: `arn:(aws|aws-cn|aws-us-gov):context:[a-z0-9\-]{1,32}:\d{12}:ontology-induction/oi-[a-z0-9]+(-[a-z0-9]+)*` 

 ** id **   
The ID of the induction, assigned by AWS Context.  
Type: String  
Length Constraints: Minimum length of 1. Maximum length of 180.  
Pattern: `(arn:(aws|aws-cn|aws-us-gov):context:[a-z0-9\-]{1,32}:\d{12}:ontology-induction/)?oi-[a-z0-9]+(-[a-z0-9]+)*` 

 ** status **   
Always INDUCING on a fresh start. The stored status on an idempotent replay. The ontology is created at DRAFT: GetOntologyInduction returns its ID from then on. It stays a draft until you publish it in the AWS Context console.  
Type: String  
Valid Values: `INDUCING | DRAFT | FAILED | CANCELLED` 

## Errors
<a name="API_StartOntologyInduction_Errors"></a>

For information about the errors that are common to all actions, see [Common Error Types](CommonErrors.md).

 ** AccessDeniedException **   
You don't have sufficient access to perform this operation. Verify that you have permission to perform the operation on the resource.    
 ** message **   
A message that describes the error.
HTTP Status Code: 403

 ** ConflictException **   
The request conflicts with the current state of the resource. Check the resource's current state before you retry the request.    
 ** message **   
A message that describes the error.  
 ** resourceId **   
The ID of the resource that caused the conflict. When several resources caused it, a comma-separated list of their IDs.  
 ** resourceType **   
The type of the resource that caused the conflict.  
Valid values:  
+  `agent-context` - An agent context.
+  `connection` - A connection.
+  `curation-policy` - A curation policy.
+  `evaluation` - Reserved for future use.
+  `ontology` - An ontology.
+  `ontology-induction` - An ontology induction.
+  `resource-policy` - A resource-based policy.
HTTP Status Code: 409

 ** InternalServerException **   
The request failed because of an internal error. Retry the request.    
 ** message **   
A message that describes the error.
HTTP Status Code: 500

 ** ResourceNotFoundException **   
The specified resource was not found. Check that the ID is correct and that the resource exists in your account and Region.    
 ** message **   
A message that describes the error.  
 ** resourceId **   
The ID of the resource that was not found.  
 ** resourceType **   
The type of the resource that wasn't found.  
Valid values:  
+  `agent-context` - An agent context.
+  `connection` - A connection.
+  `curation-policy` - A curation policy.
+  `evaluation` - Reserved for future use.
+  `ontology` - An ontology.
+  `ontology-induction` - An ontology induction.
+  `resource-policy` - A resource-based policy.
HTTP Status Code: 404

 ** ServiceQuotaExceededException **   
The request would exceed a service quota. Check the quota that `quotaCode` names, reduce your usage, and then retry the request.    
 ** message **   
A message that describes the error.  
 ** quotaCode **   
The code of the quota that the request would exceed.  
 ** resourceId **   
The ID of the resource that the quota applies to.  
 ** resourceType **   
The type of the resource that the quota applies to.  
Valid values:  
+  `agent-context` - An agent context.
+  `connection` - A connection.
+  `curation-policy` - A curation policy.
+  `evaluation` - Reserved for future use.
+  `ontology` - An ontology.
+  `ontology-induction` - An ontology induction.
+  `resource-policy` - A resource-based policy.  
 ** serviceCode **   
The code of the service that owns the quota.
HTTP Status Code: 402

 ** ThrottlingException **   
The request was denied because it exceeded a request rate quota. Wait, then retry the request.    
 ** message **   
A message that describes the error.  
 ** quotaCode **   
The code of the quota that throttled the request.  
 ** retryAfterSeconds **   
The number of seconds to wait before you retry the request, if AWS Context provides one.  
 ** serviceCode **   
The code of the service whose quota throttled the request.
HTTP Status Code: 429

 ** ValidationException **   
The input fails to satisfy the constraints of the operation. Correct the input before you retry the request.    
 ** fieldList **   
The fields that failed validation, each with a message that describes why.  
 ** message **   
A message that describes the error.  
 ** reason **   
The reason that the input failed validation. Valid values:  
+  `unknownOperation` - The operation isn't recognized.
+  `cannotParse` - The request couldn't be parsed.
+  `fieldValidationFailed` - One or more fields failed validation. `fieldList` describes them.
+  `other` - Another reason. `message` describes it.
HTTP Status Code: 400

## See Also
<a name="API_StartOntologyInduction_SeeAlso"></a>

For more information about using this API in one of the language-specific AWS SDKs, see the following:
+  [AWS Command Line Interface V2](https://docs.aws.amazon.com/goto/cli2/context-2022-07-26/StartOntologyInduction) 
+  [AWS SDK for .NET V4](https://docs.aws.amazon.com/goto/DotNetSDKV4/context-2022-07-26/StartOntologyInduction) 
+  [AWS SDK for C\+\+](https://docs.aws.amazon.com/goto/SdkForCpp/context-2022-07-26/StartOntologyInduction) 
+  [AWS SDK for Go v2](https://docs.aws.amazon.com/goto/SdkForGoV2/context-2022-07-26/StartOntologyInduction) 
+  [AWS SDK for Java V2](https://docs.aws.amazon.com/goto/SdkForJavaV2/context-2022-07-26/StartOntologyInduction) 
+  [AWS SDK for JavaScript V3](https://docs.aws.amazon.com/goto/SdkForJavaScriptV3/context-2022-07-26/StartOntologyInduction) 
+  [AWS SDK for Kotlin](https://docs.aws.amazon.com/goto/SdkForKotlin/context-2022-07-26/StartOntologyInduction) 
+  [AWS SDK for PHP V3](https://docs.aws.amazon.com/goto/SdkForPHPV3/context-2022-07-26/StartOntologyInduction) 
+  [AWS SDK for Python (Boto3)](https://docs.aws.amazon.com/goto/boto3/context-2022-07-26/StartOntologyInduction) 
+  [AWS SDK for Ruby V3](https://docs.aws.amazon.com/goto/SdkForRubyV3/context-2022-07-26/StartOntologyInduction) 