GenAI IDP Core Package
This package is provided on an "as-is" basis, and may include bugs, errors, or other issues. All classes are under active development and subject to non-backward compatible changes or removal in any future version. These are not subject to the Semantic Versioning model. This means that while you may use them, you may need to update your source code when upgrading to a newer version of this package.
Overview
The GenAI IDP Core Package provides the foundational AWS CDK constructs for building intelligent document processing solutions. This package serves as the backbone for the GenAI Intelligent Document Processing (IDP) Accelerator, enabling organizations to transform unstructured documents into structured data at scale using AWS's latest AI/ML services.
For a comprehensive reference of all available constructs and their properties, please explore our API documentation. This detailed guide will help you understand the full capabilities of this package and how to leverage them in your projects.
Features
- Modular Architecture: Composable CDK constructs that can be combined to create complete document processing solutions
- Document Processing Infrastructure: Core components for document ingestion, tracking, and management
- Processing Environment API: GraphQL API for monitoring document processing status and results
- Web Application Support: Optional secure web interface for document tracking and management
- Extensible Design: Designed to work with multiple document processing patterns and AI/ML services
- Security-First Approach: Built-in support for encryption, IAM permissions, and secure data handling
- Observability: Integrated CloudWatch metrics, logs, and alarms for monitoring and troubleshooting
Getting Started
Installation
The package is available through npm for JavaScript/TypeScript projects and PyPI for Python projects.
JavaScript/TypeScript (npm)
# Using npm
npm install @cdklabs/genai-idp
# Using yarn
yarn add @cdklabs/genai-idp
Python (PyPI)
# Using pip
pip install cdklabs.genai-idp
# Using poetry
poetry add cdklabs.genai-idp
Basic Usage
Here's a simple example of how to use the core IDP constructs:
import * as cdk from 'aws-cdk-lib';
import { Construct } from 'constructs';
import * as s3 from 'aws-cdk-lib/aws-s3';
import * as kms from 'aws-cdk-lib/aws-kms';
import { ProcessingEnvironment } from '@cdklabs/genai-idp';
export class MyIdpStack extends cdk.Stack {
constructor(scope: Construct, id: string, props?: cdk.StackProps) {
super(scope, id, props);
// Create encryption key
const key = new kms.Key(this, 'IdpKey', {
enableKeyRotation: true,
});
// Create S3 buckets for input and output
const inputBucket = new s3.Bucket(this, 'InputBucket', {
encryption: s3.BucketEncryption.KMS,
encryptionKey: key,
eventBridgeEnabled: true,
});
const outputBucket = new s3.Bucket(this, 'OutputBucket', {
encryption: s3.BucketEncryption.KMS,
encryptionKey: key,
});
const workingBucket = new s3.Bucket(this, 'WorkingBucket', {
encryption: s3.BucketEncryption.KMS,
encryptionKey: key,
});
// Create processing environment
const environment = new ProcessingEnvironment(this, 'Environment', {
key,
inputBucket,
outputBucket,
workingBucket,
metricNamespace: 'MyIdpSolution',
});
// Attach document processors to the environment
// (processors are provided by separate packages)
}
}
API Reference
Key Components
- ProcessingEnvironment: Main construct that orchestrates the document processing workflow
- ProcessingEnvironmentApi: GraphQL API for monitoring document processing status
- IDocumentProcessor: Interface for document processing implementations
- LogLevel: Enum for controlling logging verbosity
For detailed API documentation, please refer to the TypeScript type definitions and JSDoc comments in the source code.
Contributing
We welcome contributions to the GenAI IDP Core Package! Please follow these steps to contribute:
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
Please ensure your code adheres to our coding standards and includes appropriate tests.
Related Projects
- @cdklabs/genai-idp-bda-processor: BdaProcessor implementation using Amazon Bedrock Data Automation
- @cdklabs/genai-idp-bedrock-llm-processor: BedrockLlmProcessor implementation for custom extraction using Amazon Bedrock models
- @cdklabs/genai-idp-sagemaker-udop-processor: SagemakerUdopProcessor implementation for specialized document processing using SageMaker endpoints
License
This project is licensed under the Apache License 2.0 - see the LICENSE file for details.
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
Metadata
Release files for cdklabs.genai-idp 0.3.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| cdklabs_genai_idp-0.3.1.tar.gz | 6.5 MB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| cdklabs_genai_idp-0.3.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 13.0 MB
Release files / cdklabs_genai_idp-0.3.1.tar.gz
| Download URL | cdklabs_genai_idp-0.3.1.tar.gz |
|---|---|
| Size | 6.5 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b8bc9ff125ec8093f0e966e9b9306355eeaaf94d345c0d3c4707826a92bc3f7a
|
|
BLAKE2b-256 checksum How to use checksums |
b656264374ccf1c197d347bab7381dbea03d1e489fc32257b007aa4262b0f06d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.14.5
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on May 18, 2026.
Transparency logRelease files / cdklabs_genai_idp-0.3.1-py3-none-any.whl
| Download URL | cdklabs_genai_idp-0.3.1-py3-none-any.whl |
|---|---|
| Size | 6.5 MB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f7d202635b0ee189c9f80366ba928b8ba502e7b92ac68a832e9c7aefed4797a6
|
|
BLAKE2b-256 checksum How to use checksums |
d5a026383aac2821a9ffa3b65b1ffdf405bc4f8eaedb9a3f6d1b4c718159ecfd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.14.5
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on May 18, 2026.
Transparency log