A roleplay system for improving sales skills using generative AI. Users can develop practical sales skills through voice-based conversations with emotionally expressive AI. This system is designed for junior sales representatives, helping them improve their sales skills through interactive simulations with AI.
- Voice Conversation with AI: Natural conversations powered by Amazon Bedrock
- Real-time Emotional Feedback: Visualization of anger meter, trust level, and progress
- Diverse Scenarios: Customizable sales scenes
- Detailed Analysis Reports: Improvement suggestions and feedback after each session
- Video Analysis During Conversation: Analyzes video during sessions to verify effective eye contact and gestures
- Compliance Violation Check: Identifies statements that violate compliance rules
- Reference Check: Verifies whether user statements are based on reference materials
Frontend
- React 19 + TypeScript
- Material UI 7
- Vite 6 (Build tool)
- AWS Amplify v6 (Authentication)
- React Context API (State management)
Backend
- AWS CDK (Infrastructure as Code)
- AWS Lambda (Python 3.13) + API Gateway
- Amazon Bedrock (Claude 3.5 Haiku, Claude Sonnet 4.5)
- Amazon Polly (Text-to-speech)
- Amazon Bedrock Guardrails (Compliance check)
- DynamoDB + RDS PostgreSQL
- Amazon S3 (PDF materials, audio files)
- Amazon Cognito (Authentication)
- Docker
- Node.js 22.x or higher
- Python 3.12 or higher
- Latest AWS CLI
- Latest AWS CDK
You can easily deploy without any prerequisites using AWS CloudShell:
-
Log in to AWS Console and click the CloudShell icon (terminal mark) at the top of the screen
-
Run the following commands
# Clone the repository
git clone https://github.com/aws-samples/sample-ai-sales-roleplay.git
cd sample-ai-sales-roleplay
# Run deployment script
chmod +x bin.sh
./bin.sh- Deployment Options (optional)
# Disable self-registration feature
./bin.sh --disable-self-register
# Use a different region
export AWS_DEFAULT_REGION=ap-northeast-1
./bin.sh
# Specify individual models
./bin.sh --conversation-model "global.anthropic.claude-sonnet-4-5-20250929-v1:0"
# Detailed customization
./bin.sh --cdk-json-override '{"context":{"default":{"allowedSignUpEmailDomains":["example.com"]}}}'- After deployment completes, you can access the application from the displayed URL
- Clone the repository
git clone https://github.com/aws-samples/sample-ai-sales-roleplay.git
cd sample-ai-sales-roleplay- Install dependencies
# Frontend
cd frontend
npm install
# Backend
cd ../cdk
npm install- Environment Setup Refer to AI Sales Roleplay Environment Setup (Japanese)
- bin.sh Deployment Script Reference (Japanese)
- Scenario Creation Guide (Japanese)
- Video Analysis Feature (Japanese)
- Polly Lexicon Guide (Japanese)
- Cost Estimation (Japanese)
Note: Most documentation is currently in Japanese. English translations are planned for future updates.
├── frontend/ # React application
│ ├── src/
│ │ ├── components/ # UI components
│ │ ├── pages/ # Application pages
│ │ ├── services/ # API services, authentication, etc.
│ │ ├── hooks/ # Custom React hooks
│ │ ├── types/ # TypeScript type definitions
│ │ ├── utils/ # Utility functions
│ │ ├── i18n/ # Internationalization settings
│ │ └── config/ # Configuration files
│ └── docs/ # Frontend-specific documentation
├── cdk/ # AWS CDK infrastructure code
│ ├── lib/
│ │ ├── constructs/ # Reusable CDK constructs
│ │ │ ├── api/ # API Gateway related
│ │ │ ├── storage/ # S3, DynamoDB related
│ │ │ └── compute/ # Lambda related
│ │ └── stacks/ # Deployable stacks
│ ├── lambda/ # Lambda function implementations
│ │ ├── bedrock/ # Amazon Bedrock integration
│ │ ├── scoring/ # Scoring engine
│ │ ├── textToSpeech/ # Text-to-speech synthesis
│ │ ├── scenarios/ # Scenario management
│ │ ├── sessions/ # Session management
│ │ ├── guardrails/ # Guardrails management
│ │ ├── rankings/ # Ranking features
│ │ └── videos/ # Video processing
│ └── data/ # Initial data (scenarios, Guardrails config)
├── docs/ # Project documentation
│ ├── api/ # API specifications
│ ├── cost/ # Cost estimation
│ ├── custom-resources/ # Custom resource guides
│ └── features/ # Feature specifications
└── .kiro/ # Kiro AI configuration files
See CONTRIBUTING for more information.
This library is licensed under the MIT-0 License. See the LICENSE file.



