The SMS sequence is SMS → Twilio → Twilio Gateway → MQTT → sms_bear_gateway → MQTT → tts_worker. Any of these could be a hot spot. (Or, there could be several warm spots, and the chain is just too long.) The first step is to inspect where the latency is introduced.
The sequence is more complicated than it needs to be for particular applications. (It was designed to simplify in-class portion of the day one activity.) Now that we have some applications, we can optimize at the application level too.
Some of the work may apply to the Twilio Gateway project, rather than the code in the bear-as-a-service repo.
Bear's event → speech latency is high. (How high?) Improve this.
The SMS sequence is SMS → Twilio → Twilio Gateway → MQTT →
sms_bear_gateway
→ MQTT →tts_worker
. Any of these could be a hot spot. (Or, there could be several warm spots, and the chain is just too long.) The first step is to inspect where the latency is introduced.The sequence is more complicated than it needs to be for particular applications. (It was designed to simplify in-class portion of the day one activity.) Now that we have some applications, we can optimize at the application level too.
Some of the work may apply to the Twilio Gateway project, rather than the code in the bear-as-a-service repo.