Sample implementations using AWS Cloud Development Kit (CDK) and Python for building WhatsApp AI assistants powered by Amazon Bedrock.
| Project | Description | Stack |
|---|---|---|
| private-assistant | WhatsApp assistant with multi-language conversations, voice transcription, and image understanding via Claude 3.5 and LangChain | |
| private-assistant-v2 | Advanced multimodal assistant (images, video, audio, documents) using Amazon Nova Pro and Amazon Bedrock Agents, integrated via AWS End User Messaging — no extra API layer needed |
Classic serverless architecture using API Gateway as a WhatsApp webhook. Supports text, voice, and image messages. Conversation memory is managed via Amazon DynamoDB sessions.
Models: anthropic.claude-3-5-sonnet-20241022-v2:0 · anthropic.claude-3-5-haiku-20241022-v1:0
AWS Services: Amazon Bedrock · AWS Lambda · Amazon DynamoDB · Amazon API Gateway · Amazon Transcribe · Amazon S3
Key features:
- Multi-language conversations (Claude replies in the user's language)
- Voice note transcription with Amazon Transcribe (
IdentifyLanguage=True) - Image analysis via Claude 3.5 Sonnet using the Bedrock
invoke_modelAPI - Session-based conversation history stored in DynamoDB
- Two text agent options: LangChain-based (
langchain_agent_text) or direct Bedrock API (agent_text_v3)
Next-generation architecture using AWS End User Messaging for native WhatsApp integration (no API Gateway required). Messages arrive via SNS, are routed to Lambda, and processed by an Amazon Bedrock Agent that maintains full conversation context.
Models: amazon.nova-pro-v1:0 (agent) · us.amazon.nova-pro-v1:0 (multimodal via Converse API)
AWS Services: Amazon Bedrock (Agents + Converse API) · AWS Lambda · Amazon DynamoDB · Amazon S3 · Amazon Transcribe · AWS End User Messaging · Amazon SNS
Key features:
- Processes images, video, audio, and documents in a single conversation thread
- Amazon Bedrock Agent maintains context across message types
- Video processed via S3 URI; images and documents via bytes
- Audio transcribed with Amazon Transcribe then forwarded to the agent
- Conversation history stored as
ConversationHistoryin DynamoDB for the Bedrock Agent session state
Contributions are welcome! See CONTRIBUTING for more information.
If you discover a potential security issue in this project, notify AWS/Amazon Security via the vulnerability reporting page. Please do not create a public GitHub issue.
This library is licensed under the MIT-0 License. See the LICENSE file for details.