Automation scripts for testing Deepgram services running on Amazon SageMaker as an "Endpoint" resource.
See js-stt/README.md for setup and usage. Built on the AWS SDK HTTP/2 bidirectional streaming client (@aws-sdk/client-sagemaker-runtime-http2); configuration (region, endpoint name, input file, query string) is edited inline at the top of each script.
Scripts:
stt.file.ts— streams a WAV file to a bidirectional streaming endpoint, chunking the file with keepalivesstt.microphone.ts— captures live microphone input and streams it to a bidirectional streaming endpointstress-stt.ts— fires N parallelstt.file.tsinvocations and reports success/failure counts and timing
See python-stt/README.md for full setup and usage.
Scripts:
stt_microphone_stress.py— streams live microphone audio; supports multiple simultaneous connectionsstt_wav_stress.pystream— streams a WAV file at real-time pace; repeatable load testing without a microphonestt_wav_stress.pybatch— posts WAV files via HTTP with configurable concurrency; reports latency and throughputstt_wav_async.py— transcribes a WAV file (up to 1 GiB) via the SageMakerInvokeEndpointAsyncAPI with S3 input/output; suits long-form audio beyond the synchronous invoke limit, with configurable concurrency and a latency/throughput summary
End-to-end correctness gates (python-stt/e2e/) — wrap the stress scripts and score each connection's transcript against a known reference (spacewalk.wav) via Word Error Rate; intended as the promotion gate before an endpoint goes live:
e2e/e2e_test_streaming.py— drivesstt_wav_stress.py streamthrough ~10 scenarios (basic short/long-form, sustained + ramped concurrency, the major feature flags, an adversarial WebSocket-close path) and checks each connection's combined final transcript by WERe2e/e2e_test_batch.py—--mode sync(25 s sample viainvoke_endpoint, ≤ 25 MB) or--mode async(~15 min / ~76 MB viainvoke_endpoint_async+ S3, incl. summarize); validates every returned transcript by WER
See java/README.md for an index of Java projects.
java/stt/aws-sdk— WAV streaming load test built directly on AWS SDK v2 HTTP/2 bidi streamingjava/stt/deepgram-sdk— same load test, via the Deepgram Java SDK + SageMaker transport
TBD
See python-tts/README.md for full setup and usage.
Scripts:
tts_stress.py— streams text phrases to multiple simultaneous bidirectional connections; plays audio from one selectable connection
End-to-end correctness gates (python-tts/e2e/) — validate the synthesized audio itself (non-empty, correct container/codec, non-silent, requested sample rate, speed→duration), so no second transcription endpoint is required:
e2e/e2e_test_batch.py— synchronousinvoke_endpointagainst/v1/speak; carries the full parameter matrix (model/encoding/sample_rate/bit_rate/container/speed, inline IPA override, 2000-char limit)e2e/e2e_test_streaming.py— websocket/v1/speak; the streaming-only behaviors (Speak→audio,Flush→Flushed, sustained concurrency, streaming encodings, voice/speed)
See python-flux/README.md for full setup and usage.
Scripts:
flux_stress.pyfile— streams a WAV file to multiple Flux connections at real-time paceflux_stress.pymicrophone— streams live microphone audio to multiple Flux connectionsflux_stress.pylist-endpoints— lists available SageMaker endpoints in the target region
End-to-end correctness gate (python-flux/e2e/) — Flux is streaming-only (/v2/listen), so a single driver covers it:
e2e/e2e_test_streaming.py— drivesflux_stress.py filethrough basic / concurrency / connection-param / multilingual / in-band-control / negative scenarios, scoring each connection's combinedEndOfTurntranscript against the reference by WER