speaker
speaker.py
Overview
speaker.py is the last-mile speech relay that takes high-level sentences from the cognitive layer and immediately forwards them to the TTS backend.
Interfaces (strongly-typed, stateless)
Direction |
Topic |
Semantics |
---|---|---|
Required |
|
High-level sentences from cognition |
Provided |
|
Identical text for TTS backends (latched) |
Contract
Pre-conditions
Upstream publishes valid UTF-8 strings on the speaker channel.
Post-conditions
Each incoming message is republished exactly once on the output topic.
Late subscribers to the latched output still get the last sentence.
Implementation notes
Publisher uses latch=True and queue_size=10 to absorb bursts.
Callback logs every relayed sentence at INFO level.
No additional state is stored.
Classes
|
Thin ROS node that immediately forwards sentences to the output topic. |