La nena se confundía con la pantalla overlay de canciones/cuentos y
terminaba cerrando la app para salir. Ahora Sofía reproduce la canción
o el cuento directo en su pantalla apenas termina de hablar, y el botón
de micrófono se transforma en un control de "terminar" (mood "playing":
ícono de stop, halo dorado pulsante) — un solo toque corta el audio y
vuelve a la charla.
- Elimina overlay-canciones/overlay-cuentos y songs.js/stories.js (la
grilla de exploración queda para una sección de padres más adelante)
- sofia.js: nuevas playSong()/playStory()/stopMedia() y mood "playing"
- engine.py: Sofía anuncia la canción/cuento sin pedir que toquen nada
- app.py: LUMI_SHARE=1 habilita link público temporal (*.gradio.live)
Add real song playback, precache stories, improve LLM fallback
- content/songs/: 6 curated mp3s (tracked via Git LFS), content/songs.json
now points to them and is loaded by ContentLibrary (loader.py).
- activities.json: drop the old text-only song_* placeholders, now that
"song" intent plays real audio (mirrors the "story" pattern: the LLM
only announces, never sings/invents lyrics).
- engine.py: dedicated <nota> + no-LLM fallback for the "song" intent;
FALLBACK_REPLY now points users at the real cause (ZeroGPU limit)
instead of a vague "se me trabó la lengua"; log each failed
_generate attempt for easier diagnosis without burning extra quota.
- frontend: songs.js plays/pauses the suggested song (auto-play on
overlay open, tap to pause), wired up in app.js.
- voice/tts.py + app.py: precache all content/stories.json audio at
startup, so "Escuchar cuento" never hits a cold ~25s synthesis wait.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Add panel parental, fix app.py docstring, model card, and open trace
- content/colors.json + content/loader.py: paleta curada para "Sofía,
cambiate a <color>"; llm/engine.py detecta la intención sofia_color y
presenta el <contenido> curado, frontend/static/sofia.js aplica la
paleta a las variables CSS de Sofía.
- frontend: nueva sección "Cuentos" (frontend/static/stories.js,
content/stories.json, index.html, style.css) junto con ajustes en
activities.js, app.js, songs.js.
- llm/engine.py: bloques <nota> para saludo y presentación de cuentos,
backend alternativo vía Ollama (LUMI_LLM_BACKEND=ollama) para correr
local sin GPU grande, documentado en CLAUDE.md/requirements.txt.
- voice/tts.py: silencio inicial en el audio para que parlantes
Bluetooth no se coman las primeras sílabas.
- parental/store.py: quita líneas de fase/nombre de memory_block.
Rework frontend UI, add Actividades and Canciones sections
- Rebuild frontend (Sofia design): 3-tab app (Hablar/Actividades/Canciones)
with mood-based character animation, served via new /static and /content
static mounts.
- Actividades: "¿Qué forma es esta?" shape-recognition game, answerable by
touch or voice, content sourced from content/shapes.json.
- Canciones: song grid driven by content/songs.json, gracefully marks
tracks "Próximamente" until their mp3s are added to content/songs/.
- Tighten safety/guard.py to use word-boundary matching against
safety/blocklist.txt (avoids false positives like "arma" in "farmacia"),
and expand blocklist with plural/feminine variants.
Simplify startup flow: drop scripted greeting, start from child's first turn
The session_start/awaiting_mood choreography always opened with a canned
"Hoy podemos hacer X, Y o Z" line (awkward Spanish for most activity
titles), and the child's first reply was discarded in favor of repeating
that same menu, which felt like the conversation restarting.
Remove the whole pre-scripted flow: the app now stays idle until the
child presses the mic, and the first utterance goes straight through
engine.respond() like any other turn.
Rename persona Lumi -> Sofía, prep for HF Space deploy
- llm/engine.py, frontend/index.html: user-facing persona rename to Sofía
(with grammatical gender agreement in the system prompt)
- app.py: auto-download the GGUF from bartowski/Qwen2.5-7B-Instruct-GGUF
if models/model.gguf isn't present (Space doesn't version the 4.6GB file)
- requirements.txt: add huggingface_hub (used by the download fallback)
- README.md: add HF Space YAML frontmatter (Gradio SDK, app_file, license,
short description) and finish the Sofía rename in the landing page text
- LICENSE: add MIT license
Initial commit: Lumi pipeline migrated to llama.cpp, local-first TTS
- llm/engine.py: migrate from Ollama to llama-cpp-python (GGUF, chatml),
add real conversation history from ParentalStore, fix system prompt to
neutral Latin American Spanish
- voice/tts.py: remove edge-tts fallback, reuse a single Kokoro pipeline
instance, add warmup() to pay cold-load cost at startup not on first reply
- safety/blocklist.txt: expand from 3 to 44 terms
- requirements.txt, README.md: sync with actual stack