This Lambda is invoked by another Lambda.
Get the audio stream from KVS.
Get the real time transcription by Google Speech to Text.
Write the transcription to DynamoDB.
Save the audio data as wav file in s3.
https://drive.google.com/file/d/1OsolNuuSxA6zbFeaM-fIVdolntdGaLqo/view?usp=sharing
- openjdk version "1.8.0_265"
- Gradle 6.6.1
- credentials.json with Google Speech To Text enabled
Maybe it will work with other versions as well. Try it for yourself.
git clone https://github.com/yuga-t/kvsConsumerGoogleSTT.git
cd kvsConsumerGoogleSTT
Put credentials.json in kvsConsumerGoogleSTT/src/resources/
gradle build
Upload kvsConsumerGoogleSTT/build/ditributions/kvsConsumerGoogleSTT.zip to Lambda.
Set Handler of Runtime settings
com.amazonaws.kvstranscribestreaming.KVSTranscribeStreamingLambda::handleRequest
Set Environment Variable of Lambda.
- key:
GOOGLE_APPLICATION_CREDENTIALS
, value:credentials.json
- key:
LIMITDAY_OF_TTL
, value:1
- key:
RECORDINGS_BUCKET_NAME
, value:amazon-connect-audio-bucket
- key:
RECORDINGS_KEY_PREFIX
, value:recordings/
- key:
RECORDINGS_PUBLIC_READ_ACL
, value:TRUE
- key:
REGION
, value:ap-northeast-1
- key:
START_SELECTOR_TYPE
, value:NOW
- key:
TRANSCRIPT_TABLE_NAME
, value:transcriptTable
The demo will not work on this project alone.
Requires AmazonConnect ContactFlow and another Lambda, and so on.
Please refer to here.
- https://github.com/amazon-connect/amazon-connect-realtime-transcription
- https://github.com/googleapis/java-speech/blob/master/samples/snippets/src/main/java/com/example/speech/InfiniteStreamRecognize.java
"kvsConsumerGoogleSTT" is under MIT license.