Memory 019eae58
Memory ID (Session ID): 019eae58-f724-7000-9d8d-5653aab48d87
Last Updated: 2026-06-10 00:40:44
Fact Summary
- ElevenLabsAdapter DI Constraint: In
/home/dev/active/[[projects/storymatrix|StoryMatrix]]/src/[[projects/storymatrix|StoryMatrix]]/infrastructure/container.py,ElevenLabsAdapter(andelevenlabs_tts_adapter) MUST be passed the rootconfig=configobject, not theconfig.providers.elevenlabssub-config. The adapter handles sub-config extraction internally to access root-level flags likedev_local_only. - Async Stream Handling: In
elevenlabs.py(synthesize_with_stitching), always useasync withfor asynchronous context managers and ensureawait self._collect_stream(response.data)is used when processing streaming responses. - Float Zero Falsiness Bug: In
audio_discovery_service.py, when handling timestamps or durations, NEVER use truthyorchains (e.g.,val or default) because0.0is a valid duration. Always use explicitis not Nonechecks. - DRY Config Access: Use the
extract_tts_provider()helper inconfig_accessor.pyfor reading TTS configuration. Do not duplicate provider extraction logic in components likecharacter_mapping_stage.pyorgenerate_story.py. - Python Versioning: StoryMatrix strictly targets Python 3.11+. Ensure
/home/dev/active/[[projects/storymatrix|StoryMatrix]]/pyproject.tomlhastarget-version="py311"for Ruff andpython_version="3.11"for mypy. - SFX Observability: When classifying SFX, ensure fallback logic handles ties properly (defaults to
impact_sfx) and emit warnings for unrecognized subtypes.
Reference Session
- Associated Chat Session: 019eae58-f724-7000-9d8d-5653aab48d87