Spaces:
Running
Download README.md from clem/good-morning: direct link, hf CLI and curl.
- Browser
- Download file 3.25 kB
-
https://huggingface.co/spaces/clem/good-morning/resolve/main/README.md
- Command line
-
hf download hf://spaces/clem/good-morning/README.md
-
curl -L -o README.md https://huggingface.co/spaces/clem/good-morning/resolve/main/README.md
title: Good Morning
emoji: βοΈ
colorFrom: yellow
colorTo: red
sdk: static
pinned: false
short_description: First app for the new Reachy Mini, by Clem Delangue
tags:
- reachy_mini
- reachy_mini_python_app
Good Morning β a Reachy Mini app
First! The first Reachy Mini app built for the new version of Reachy Mini, by Clem Delangue, co-founder & CEO of Hugging Face.
Press a button β Reachy Mini says:
"Good morning. Today is a good day to help more people become AI builders, not just AI users thanks to open-source!"
The button lives at http://localhost:7860/ whenever the app is running on
your robot. The app also auto-opens that page in your default browser when
it starts.
Install
From the project root:
# Same Python env you use for the reachy-mini SDK (3.10β3.12).
pip install -e .
This installs the reachy_mini_apps entry point good_morning, so the app
shows up in the Reachy Mini dashboard's app list.
Run
Two options:
1) Through the Reachy Mini app system (preferred β this is what makes it
"an app"). Install from the Reachy Mini dashboard's Discover Apps panel,
hit Start on the good_morning tile, and the app will pop your default
browser open at http://localhost:7860/. Click the orange button.
2) Standalone, for quick testing:
python -m good_morning_app.main
Then open http://localhost:7860/ and click the button.
How it works
The first time the app starts, pyttsx3 synthesises the phrase once and
caches it as good_morning.<hash>.wav next to the code (the hash is derived
from the phrase, so changing PHRASE auto-invalidates the cache). On every
press we:
- Load the cached WAV β mono float32, resampled to 16 kHz, shape
(N, 1). - Push it to the speaker with
reachy_mini.media.push_audio_sample(samples)(the canonical TTS path per the SDK docs β there is no.speak()helper). - Sleep for the audio's duration since
push_audio_sampleis non-blocking.
A small thread polls the local FastAPI's /healthz endpoint until it
answers 200, then opens http://localhost:7860/ in your default browser.
Tweaking
Open src/good_morning_app/main.py:
PHRASEβ change what it says (audio cache is regenerated automatically).WEB_PORTβ where the button page lives.
To swap the TTS engine (e.g. for Piper or an online voice), replace
_synthesize_phrase() β anything that produces a WAV will work; the loader
handles mono/stereo and resampling.
Project layout
reachy-mini-good-morning/
βββ pyproject.toml # registers the reachy_mini_apps entry point
βββ README.md # this file (HF Space frontmatter at the top)
βββ src/
βββ good_morning_app/
βββ __init__.py
βββ main.py # GoodMorningApp(ReachyMiniApp)
References
- Reachy Mini SDK: https://github.com/pollen-robotics/reachy_mini
- Audio API (
push_audio_sample): https://github.com/pollen-robotics/reachy_mini/blob/main/docs/source/SDK/python-sdk.md - Reference app (entry-point shape,
ReachyMiniAppsubclass): https://github.com/pollen-robotics/reachy_mini_conversation_app