
Generative AI-powered American Sign Language Avatars
A generative AI-powered solution that translates speech or text into expressive ASL avatar animations
- Polling: API Gateway supports a maximum timeout of 30 seconds. So, if you give a longer audio file that takes more than 30 seconds, we want to avoid the timeout issue. Also, It's a best practice not to build a synchronous APIs for long running processes. . We built an asynchronous API consisting of two-stages. First stage is assigned with an API endpoint that accepts the S3 key, and bucket name. This API endpoint delegates the request to a step function workflow and sends a response back with the execution ARN. The second stage is assigned to an API that checks the status of the step function execution based on the execution ARN provided as an input to this API endpoint. If the ASL avatar creation is completed, this API returns the pre-signed URL back.. Otherwise it sends a RUNNING status and the front-end waits for a couple of seconds, and then call the second API endpoint again. This step is repeated until the pre-signed URL is returned by the API.
- Step function supports direct optimized integration with Bedrock: We don't need to have the Lambda in the middle to create ASL gloss. We can call the Bedrock API directly from step function to save the Lambda compute cost.
We provided a prompt to convert English Text to ASL gloss along with the input text message to Bedrock API to invoke Claude. We use few shot prompting technique by providing few examples to produce accurate ASL gloss.
amazon-bedrock-samples
git repository here.git clone https://github.com/aws-samples/genai-asl-avatar-generator.git
1
2
3
4
5
[DEFAULT]
s3_bucket= <your S3 bucket>
s3_prefix= <files will be generated in this prefix within your S3 bucket>
table_name=<dynamodb table name>
region=<your preferred AWS region>
1
2
cd genai-asl-avatar-generator/dataprep
./env_setup.cmd
1
python prep_metadata.py
1
python create_sign_videos.py
1
python create_pose_videos.py
1
2
cd genai-asl-avatar-generator/backend
sam deploy --guided
1
amplify init
- Open `frontend/amplify/backend/function/Audio2Sign/index.py`
- Modify the `stateMachineArn` variable to have the state machine ARN shown in the output generated from backend deployment
1
amplify add hosting
1
npm install --force
1
amplify publish
1
amplify delete
1
sam delete
1
rm -rf genai-asl-avatar-generator
- If you reused an existing EC2 instance, you can delete the project folder recursively to clean up all the resources:
Replace <bucket-name> with the name of your S3 bucket.
1
2
aws s3 rm s3://<bucket-name> --recursive
aws s3 rb s3://<bucket-name> --force
Any opinions in this post are those of the individual author and may not reflect the opinions of AWS.