May 8, 2026

Voice, Memory, and Massive Code Cleanup Ahead of v0.6.0

Hundreds of lines of dead code were removed across services: EventBusService (384 LOC) and its test suite, three orphan public methods on InterfaceRegistryServi

Hundreds of lines of dead code were removed across services: EventBusService (384 LOC) and its test suite, three orphan public methods on InterfaceRegistryService and DocumentService, eight unused DataGraphService methods, the session-reentry subsystem, unused transcript helpers, and DocumentService.search_by_metadata. All unit tests pass, and no production callers existed for any removed path.

Voice synthesis received a multi-pronged fix. Chunk silence is now trimmed (up to 100 ms trailing kept) so concatenated replies no longer accumulate 2-3 seconds of dead air. Each chunk gets one retry on phonemizer errors or silent output, and the phonemize step is serialized behind a lock to prevent a parallel race that crashed multi-chunk replies. A pool of three Kokoro instances runs ONNX inference in parallel, cutting synthesis latency. Markdown stripping was added so bold/italic stars, code fences, links, and headers are no longer pronounced verbatim. Plaintext extraction now inserts spaces at block-tag boundaries, fixing run-together tokens that were silently dropped by espeak.

Memory and discovery flows were tightened. The pre_act auto-recall no longer injects a spurious document.search that the LLM never requested. The find_tools summary was rewritten to explicitly cover user-named skills, so the model now discovers a skill the user mentions by name instead of claiming it lacks the ability. Data-graph concept aliases were embedded directly into the LUT (365 rows) to make birthday vs. birth_date canonicalization reliable where cosine similarity alone failed.

Other fixes and polish: read skill extraction now preserves dates and inline URLs; find_tools was hoisted to always-available index 0; timer cards lost their box shadow and border; security annotations were added for CSRF and tmp log path hotspots; lint cleanups replaced isNaN with Number.isNaN, charCodeAt with codePointAt, and tightened ReDoS regexes in voice, message processor, and og-image service; test fixtures switched to https, and Sonar nullable-dereference guards were added.

  • Trimmed per-chunk silence to eliminate 2-3 s gaps in long spoken replies

  • Added markdown stripping so * asterisks *, links, and code fences are not pronounced

  • Retry individual TTS chunks on phonemizer errors instead of failing the whole synthesis

  • Purged 384 LOC of dead EventBusService and over 500 LOC total across DataGraphService, session-reentry, and other dead paths

  • Reframed find_tools summary so the model discovers user-named skills instead of refusing them

  • Built 365-row concept alias LUT to make birthday/job_title canonicalization reliable