Commit Graph
129 Commits
Author SHA1 Message Date
diodiogod 11951d35dd Version 4.26.0
Add MOSS-TTS engine family and finalize native TTSD behavior

Release details:
- Integrate Local/Delay/TTSD MOSS models into unified nodes
- Finalize strict native TTSD incompatibility handling
- Improve native SRT behavior and user-facing error propagation
2026-05-18 16:46:50 -03:00
diodiogod 2b69130a42 Add MOSS-TTS engine family with native TTSD support (#295)
* docs: add new engine integration guide flow

* docs: link new engine guide navigation

* docs: clarify SRT is required for TTS engines

* docs: document SRT reuse of TTS processor

* docs: move new engine guide link below timeline

* Add MOSS-TTS engine integration

* docs: add reference input mode to engine research

* Add MOSS-TTS engine checkpoint

* Refine MOSS prompt fields and parameter switching

* Refine MOSS prompt field warnings and caching

* Improve MOSS inline edit handling and VRAM handoff

* Improve MOSS native dialogue mapping and UI

* docs: add long-form model analysis and VibeVoice reference

* Improve MOSS TTSD chunking, interrupts, and SRT mapping

* Refine MOSS mapping, device checks, and metadata

* Make MOSS native incompatibilities hard-fail

* Document MOSS native hard-fail compatibility rules
2026-05-18 16:42:53 -03:00
diodiogod f6ca9525a2 Refine generated training docs tables 2026-04-05 13:12:14 -03:00
diodiogod f1f05ae290 Document RVC training workflow and capabilities 2026-04-05 13:08:45 -03:00
diodiogod 1df7df8b77 Version 4.24.18
Improve VibeVoice and KugelAudio model support

Technical details:
- Add kugel-2 support as a VibeVoice KugelAudio variant
- Normalize KugelAudio v2 config fields for transformers 4.x compatibility
- Fix UnifiedDownloader alt_repo handling for VibeVoice Hindi tokenizer downloads
- Improve VibeVoice pause-tag tracing in custom character switching
- Update VibeVoice model registry and generated docs
2026-04-03 22:12:25 -03:00
diodiogod 86992ff44e Fix Multiline TTS Tag Editor guide links
Implementation details:
- convert related documentation paths to real Markdown links
- keep the guide content unchanged aside from link formatting
2026-03-31 23:47:17 -03:00
diodiogod 362d4959e0 Add Multiline TTS Tag Editor SRT cue merge and split tools
Implementation details:
- add cue-number merge actions for combining neighboring SRT subtitles
- add caret-based cue splitting with proportional timing estimation
- document SRT editing workflows in the new guide, library tab, and README
2026-03-31 23:42:37 -03:00
diodiogod 1653c689e5 Add standalone ASR punctuation and auxiliary model registry
Implementation details:
- add a standalone punctuation/truecase text node for raw ASR transcripts
- create a separate auxiliary-model YAML source of truth and docs generator
- register punctuation helper models outside the engine registry
- add lazy local download/runtime support for punctuators-backed ONNX models
- document auxiliary model sources and layouts for future helper-model expansion
2026-03-17 10:17:47 -03:00
diodiogod 6346122036 Generate README model auto-download table from YAML
- add README model download summary rows to the YAML source of truth
- generate and inject the README auto-download table via generate_engine_tables.py
- include Granite ASR in the generated model download summary
2026-03-17 00:19:02 -03:00
diodiogod c709f129fc Version 4.23.0
Add Granite ASR engine and expand unified ASR support

Implementation details:
- Add Granite ASR engine node, adapter, runtime, and unified downloader integration
- Reuse the Qwen forced aligner for optional custom Granite timestamps and SRT output
- Expose engine-side ASR translation target and prompt templates for Granite and Qwen
- Fix SRT overflow splitting so subtitle text is no longer silently dropped
- Update README and engine metadata for the expanded ASR lineup
2026-03-16 23:58:56 -03:00
diodiogod 70e8e1c356 Document Official 23-Lang Russian stress dictionary assets 2026-03-10 23:19:41 -03:00
diodiogod c834879563 docs: improve license table formatting for plain text rendering in LICENSE file 2026-03-01 02:06:04 -03:00
diodiogod 8849bcacfc docs: add model licenses to YAML source of truth, auto-generate license table in LICENSE file and full ENGINE_COMPARISON table 2026-03-01 02:02:30 -03:00
diodiogod c9b80e2340 docs: reorganize docs folder structure 2026-03-01 01:46:34 -03:00
diodiogod 104e3a72b4 docs: add Echo-TTS model sources and folder layout to YAML source of truth 2026-03-01 00:59:49 -03:00
diodiogod ba7823d571 docs: add Echo-TTS to README, update timeline, regenerate engine tables 2026-03-01 00:54:57 -03:00
diodiogod f4d032f4ef Regenerate engine comparison tables (Echo-TTS added via YAML) 2026-03-01 00:45:56 -03:00
diodiogod 4955436280 Fix Echo-TTS speed rating in engines YAML (Fast, not Slow) 2026-03-01 00:45:33 -03:00
diodiogod 597301fed9 fix(echo-tts): scope edit tags per pause fragment, fix VRAM reload, add to engine registry
- Fix inline edit tags (e.g. <Laughter>) incorrectly applying to entire
  combined audio when pause tags are present. Now parse pause tags first,
  extract edit tags per text fragment, apply edit post-processing per
  fragment before combining with silence.

- Fix force_speaker_kv + short fragments: replace hard error with smart
  auto-disable for fragments under 20 chars. Long fragments still benefit
  from force_speaker_kv; short ones generate cleanly without noisy tails.

- Fix VRAM unload/reload crash ("Inference tensors do not track version
  counter"): clone pca_state dict tensors before .to() to escape
  inference-mode version tracking after ComfyUI "Unload Models".

- Add Echo-TTS to tts_audio_suite_engines.yaml source of truth
  (English-only, ~7GB total, diffusion-based, CC-BY-NC-SA).
2026-03-01 00:45:33 -03:00
diodiogod 246f0d2bc0 Version 4.21.13
Integrate Egyptian Arabic (oddadmix) model and fix vocab mismatch

Technical details:
- Added 'oddadmix/chatterbox-egyptian-v0' to chatterbox-23l engine
- Implemented automatic download of 'resemble-ai/chatterbox' config.json to resolve vocabulary mismatch
- Updated engine documentation source of truth (YAML) with consistent Arabic flags
2026-02-21 11:21:00 -03:00
diodiogod 99e72ae3aa docs: fix viterbox source and refine rvc pack links 2026-02-20 14:00:49 -03:00
diodiogod 8f0c112da6 docs: split model sources and layouts from README 2026-02-20 13:46:00 -03:00
diodiogod 4e4c50045a docs: fix emoji encoding and update IndexTTS-2 size
- Fix: Insert Zero Width Non-Joiner between flag emojis in tables to prevent ligatures
- Update: Set IndexTTS-2 model size to ~4.7GB in YAML and Tables
2026-02-11 23:45:02 -03:00
diodiogod 4bd70b6aa2 docs: refactor KugelAudio as VibeVoice variant
- Remove standalone KugelAudio engine entry
- Merge KugelAudio details into VibeVoice engine documentation
- Regenerate comparison tables (ENGINE, FEATURE, LANGUAGE)
- Update README.md to reflect KugelAudio as a model variant
2026-02-11 23:29:12 -03:00
diodiogod 83bfeffab5 feat(engines): transpant KugelAudio to main branch
- Add dedicated KugelAudio implementation with relative imports
- Update engine/downloader/processor to support KugelAudio with fallback
- Regenerate engine comparison tables and update README
- Fix: Use relative imports for robustness
- Fix: Prevent 'Speaker 1:' prefix regression in processor
2026-02-11 22:33:08 -03:00
diodiogod 97d6f68b44 Add comprehensive code review for Echo-TTS PR #250
Documents architectural issues, missing features, and recommendations for
improving the Echo-TTS integration to follow project standards.
2026-02-06 01:51:30 -03:00
diodiogod 2830dfc15f Update ASR docs and comparison tables
- add Qwen3 ASR feature info to README
- add ASR capability/feature to engine tables source
- add ASR column to engine comparison table
2026-02-05 00:26:08 -03:00
diodiogod d74eef703d Version 4.20.2
Restrict Transformers to Qwen3-TTS-compatible range

Implementation details:
- Cap transformers<=4.57.3 in requirements and installer
- Add startup warning when Transformers 5.x is detected
- Add investigation report for Qwen3-TTS + Transformers 5.x
2026-02-02 22:24:27 -03:00
diodiogod 7bf270cae9 Version 4.19.12
Add Qwen3-TTS torch.compile optimizations (based on dffdeeq/Qwen3-TTS-streaming)

Implementation:
- Integrate streaming optimizations from dffdeeq/Qwen3-TTS-streaming fork
- Add torch.compile support with mode selection (default/reduce-overhead/max-autotune)
- Add manual CUDA graph capture option for additional optimization
- Update to support PyTorch 2.10+ and triton-windows 3.6+
- Remove obsolete inductor patches (not needed for PyTorch 2.10+)
- Add comprehensive optimization documentation with benchmark results
- Enable TensorFloat32 for Ampere+ GPUs automatically

Credit: Streaming implementation based on work by dffdeeq
https://github.com/dffdeeq/Qwen3-TTS-streaming
2026-01-30 17:30:22 -03:00
diodiogod 28a738662e Clean up README condensed engine table
- Remove Speed column (unnecessary for overview)
- Remove 🎯 emoji from title (too many emojis)
- Add ChatterBox to featured engines (now shows 7 engines)
2026-01-28 11:10:29 -03:00
diodiogod 6c87d67ed7 Add YAML-driven engine documentation table generator
- Created comprehensive YAML source of truth for all TTS engines
- Implemented Python generator for 3 documentation tables:
  * ENGINE_COMPARISON.md - Main engine overview with capabilities
  * LANGUAGE_SUPPORT.md - Detailed language support matrix
  * FEATURE_COMPARISON.md - Feature capabilities comparison
- YAML captures all engine metadata without information loss
- Tables auto-generated via scripts/generate_engine_tables.py
- Added flag emojis to language support table for easy scanning
- Speed performance fixes: F5-TTS marked as "Very Fast"
2026-01-28 10:50:10 -03:00
diodiogod fa74973ad5 Fix Qwen3-TTS audio hash error with nested dict structure
Fixed 'dict' object has no attribute 'cpu' error when using Voice Designer
voices with TTS Text node.

## Root Cause

Voice Designer and Character Voices nodes output unified NARRATOR_VOICE format:
{
    "audio": {"waveform": tensor, "sample_rate": 24000},
    "audio_path": "...",
    "reference_text": "...",
    ...
}

But TTS Text node was wrapping this AGAIN when creating voice_mapping:
{
    "waveform": audio_tensor,  # audio_tensor was already a dict!
    "sample_rate": 24000,
    "text": "..."
}

This created triple-nested structure that broke audio hashing.

## Fixes Applied

**TTS Text Node** (nodes/unified/tts_text_node.py):
- Extract actual waveform tensor from audio dict before creating voice_mapping
- Applied to all 6 places where audio_tensor is used:
  - Narrator voice mapping (line 1151)
  - Character ICL fallback (line 1183)
  - Character x_vector fallback (line 1217)
  - Character no-text fallback (line 1220)
  - Character no-audio fallback (line 1237)
- Pattern: Check if audio_tensor is dict, extract waveform/sample_rate if so

**Qwen3-TTS Adapter** (engines/adapters/qwen3_tts_adapter.py):
- Extract inner audio dict before passing to hash function
- Changed from passing full voice_ref to passing voice_ref['audio']

**Audio Hash Utility** (utils/audio/audio_hash.py):
- Added nested structure handling with fallback
- Detects Character Voices format {"audio": {...}} vs direct format
- Enhanced debug logging to diagnose structure issues

## Testing

- Voice Designer → TTS Text: Works without hash error
- Character Voices → TTS Text: Works without hash error
- Audio hashing generates stable keys for caching
- Both VoiceDesign and traditional voices function correctly
2026-01-28 00:15:21 -03:00
diodiogod 41b1bda1e5 Add CosyVoice3 model variant support and documentation
- Add Fun-CosyVoice3-0.5B-RL (default, better quality) and Fun-CosyVoice3-0.5B variants
- Use ChatterBox 23-Lang pattern: shared folder, both llm.pt/llm.rl.pt files, symlink switching
- Saves ~3.4GB by sharing common files (flow.pt, hift.pt, campplus.onnx, CosyVoice-BlankEN/)
- Switching variants invalidates cache (different model_identifier)
- Add COSYVOICE3_TAGS_GUIDE.md: concise guide for native paralinguistic tags
- Update README: What's New section, model download links, shared folder structure
2025-12-29 20:54:46 -03:00
tazztone a2cac49587 implemented a comprehensive pytest testing infrastructure for the TTS-Audio-Suite custom node. The infrastructure supports both **unit tests** (fast, no ComfyUI needed) and **integration tests** (requires running ComfyUI server).
## Key Files Created/Modified

### Configuration
- [pytest.ini](file:///C:/_stability_matrix/Data/Packages/Comfy-new/custom_nodes/TTS-Audio-Suite/pytest.ini) - Pytest configuration with markers
- [tests/conftest.py](file:///C:/_stability_matrix/Data/Packages/Comfy-new/custom_nodes/TTS-Audio-Suite/tests/conftest.py) - Session fixtures and ComfyUI API client

### Unit Tests
- [tests/unit/test_srt_parser.py](file:///C:/_stability_matrix/Data/Packages/Comfy-new/custom_nodes/TTS-Audio-Suite/tests/unit/test_srt_parser.py) - 23 tests ✅
- [tests/unit/test_pause_processor.py](file:///C:/_stability_matrix/Data/Packages/Comfy-new/custom_nodes/TTS-Audio-Suite/tests/unit/test_pause_processor.py) - 19 tests ✅
- [tests/unit/test_audio_processing.py](file:///C:/_stability_matrix/Data/Packages/Comfy-new/custom_nodes/TTS-Audio-Suite/tests/unit/test_audio_processing.py) - 18/22 tests ✅

### Integration Tests
- [tests/integration/test_workflows.py](file:///C:/_stability_matrix/Data/Packages/Comfy-new/custom_nodes/TTS-Audio-Suite/tests/integration/test_workflows.py) - Node registration & CosyVoice3 tests
- [tests/fixtures/workflows/](file:///C:/_stability_matrix/Data/Packages/Comfy-new/custom_nodes/TTS-Audio-Suite/tests/fixtures/workflows/) - Test workflow JSON files

### Bug Fix
- [nodes.py](file:///C:/_stability_matrix/Data/Packages/Comfy-new/custom_nodes/TTS-Audio-Suite/nodes.py) - Moved [os](file:///C:/_stability_matrix/Data/Packages/Comfy-new/custom_nodes/TTS-Audio-Suite/tests/unit/test_audio_processing.py#174-206)/[sys](file:///C:/_stability_matrix/Data/Packages/Comfy-new/custom_nodes/TTS-Audio-Suite/tests/conftest.py#60-65) imports to top level (was causing NameError during testing)

---

## Test Isolation Strategy

The key challenge was preventing pytest from importing the full ComfyUI node infrastructure during unit tests. We solved this using:

1. **Module-level mocking** in [conftest.py](file:///C:/_stability_matrix/Data/Packages/Comfy-new/custom_nodes/TTS-Audio-Suite/conftest.py) - Mocks ComfyUI modules (`folder_paths`, [comfy](file:///C:/_stability_matrix/Data/Packages/Comfy-new/custom_nodes/TTS-Audio-Suite/tests/conftest.py#135-216), [server](file:///C:/_stability_matrix/Data/Packages/Comfy-new/custom_nodes/TTS-Audio-Suite/tests/conftest.py#135-216), etc.) before pytest imports test modules
2. **Environment variables** - Sets `COMFYUI_TESTING=1` and `PYTEST_CURRENT_TEST=true`
3. **Direct imports via importlib** - Unit tests load utility modules directly, bypassing package [__init__.py](file:///C:/_stability_matrix/Data/Packages/Comfy-new/custom_nodes/TTS-Audio-Suite/__init__.py)

```python
# conftest.py - Mocks ComfyUI at module level
_MOCK_MODULES = ['comfy', 'folder_paths', 'server', 'execution', ...]
for _module_name in _MOCK_MODULES:
    if _module_name not in sys.modules:
        sys.modules[_module_name] = MagicMock()
```

---

## Running Tests

### Unit Tests (Fast, No Server)
```bash
cd C:\_stability_matrix\Data\Packages\Comfy-new\custom_nodes\TTS-Audio-Suite
..\..\venv\Scripts\python -m pytest tests/unit/ -m unit -v
```

### Integration Tests (Requires ComfyUI)
```bash
# Start ComfyUI first, OR the fixture will start it automatically
..\..\venv\Scripts\python -m pytest tests/integration/ -m integration -v
```

### Specific Test Markers
```bash
# Run only CosyVoice3 tests
..\..\venv\Scripts\python -m pytest -m cosyvoice -v

# Run slow tests
..\..\venv\Scripts\python -m pytest -m slow -v
```

---

## Test Results

| Test Suite | Passed | Failed | Notes |
|------------|--------|--------|-------|
| SRT Parser | 23 | 0 | ✅ All timestamp, validation, and parsing tests |
| Pause Processor | 19 | 0 | ✅ Tag detection, parsing, silence generation |
| Audio Processing | 18 | 4 | ⚠️ Minor tensor dimension mismatches |
| **Total** | **60** | **4** | 94% pass rate |

---

## Known Issues

1. **4 failing audio tests** - Due to tensor dimension return type differences in [pad_audio_to_duration](file:///C:/_stability_matrix/Data/Packages/Comfy-new/custom_nodes/TTS-Audio-Suite/utils/audio/processing.py#136-178) and [crossfade_audio](file:///C:/_stability_matrix/Data/Packages/Comfy-new/custom_nodes/TTS-Audio-Suite/utils/audio/processing.py#179-228). The actual implementations work correctly; tests need minor adjustments.

2. **Integration tests** - Require ComfyUI server. The [comfyui_server](file:///C:/_stability_matrix/Data/Packages/Comfy-new/custom_nodes/TTS-Audio-Suite/tests/conftest.py#135-216) fixture will auto-start ComfyUI if not running, but this adds startup time.

---

## Future Enhancements

- [ ] Add `pytest-watcher` configuration for auto-rerun on file changes
- [ ] Fix remaining 4 audio processing test assertions
- [ ] Add more CosyVoice3 integration test workflows
- [ ] GPU-specific test markers for model inference tests
2025-12-18 21:51:42 +01:00
diodiogod 7d3b171ab3 Add voice restoration with iteration reference support
New Feature: <restore:N@M> Syntax
- <restore> - Restore using original pre-edit audio (1 VC pass)
- <restore:N> - N VC passes using original audio as reference
- <restore:N@M> - N VC passes using audio from iteration M as reference

Implementation:
- Store audio snapshots after each edit iteration
- Parse iteration reference from @ syntax in restore tags
- Use specified iteration audio as VC reference instead of original
- Allows preserving partial effects (e.g., keep whisper, remove laughter)

Use Case Example:
<style:whisper:2> <Laughter:3> <restore:1@2>
- Applies whisper (iterations 1-2)
- Applies laughter (iterations 3-5)
- Restores using iteration 2 (whispered audio) with 1 VC pass
- Result: Keeps whisper effect but removes laughter voice degradation

Documentation:
- Updated INLINE_EDIT_TAGS_USER_GUIDE.md with restore tag section
- Added examples for basic and iteration-reference restoration
- Explained use cases and when to use each syntax
- Updated processing order and reference sections
2025-12-08 20:04:39 -03:00
diodiogod e01f3515ef Add comprehensive inline edit tags user guide
- Complete guide for Step Audio EditX inline tag system
- Covers all tag types: paralinguistic, emotion, style, speed
- ChatterBox 23-Lang v2 native vs post-processing tag distinction
- Language support warnings (Chinese, English, Japanese, Korean only)
- Voice resemblance degradation warnings for 3+ iterations
- Performance tips and best practices
- Inline vs manual node workflow comparison
- Pro tips for stronger effects with contextual text
- Planned voice restoration feature note
- FAQ and troubleshooting sections
2025-12-08 15:21:07 -03:00
diodiogod 08b52f63c3 Add inline edit tag support for Higgs Audio and fix CUDA graph unloading crash
Added edit tag extraction and batch processing for Higgs Audio TTS and SRT processors following the established pattern from VibeVoice and Step Audio EditX.

Key changes:
- Extract edit tags at top level before pause processing to keep nested functions returning tensors
- Apply edit post-processing after all audio generation completes
- For SRT: batch process all subtitle edits at end instead of per-subtitle
- Fix CUDA graph crash: detect original engine for stateless wrappers and refuse unloading when CUDA graphs enabled
- Store original_engine in ModelInfo to track Higgs even when masked as stateless_tts
- Update Higgs handler to check correct attribute paths for _cuda_graphs_enabled flag

Files modified:
- nodes/higgs_audio/higgs_audio_tts_processor.py: Add edit tag extraction and post-processing
- nodes/higgs_audio/higgs_audio_srt_processor.py: Batch edit processing for all subtitles
- utils/models/comfyui_model_wrapper/base_wrapper.py: Track original_engine for masked engines
- utils/models/comfyui_model_wrapper/model_manager.py: Store original engine when masking
- utils/models/comfyui_model_wrapper/engine_handlers/higgs_audio_handler.py: Refuse unload when CUDA graphs enabled
- docs/Dev reports/SRT_Edit_Tag_Batch_Processing_Pattern.md: Mark Higgs as implemented
2025-12-06 19:04:27 -03:00
diodiogod 96877fec99 Refactor SRT processors to batch edit post-processing at the end
Fixed inefficient per-subtitle edit processing that caused multiple engine loads.
Now all edit processing happens in a single batch after all subtitles are generated.

Changes:
- VibeVoice SRT: Collects all segments with edit_tags, applies edits once at end
- Step Audio EditX SRT: Same batching pattern, skips edits in _process_character_switching when in SRT mode
- Step processor: Added check to only apply edits when NOT in SRT mode
- Subtitle processing functions: Return segment dicts instead of applying edits directly

Benefits:
- Edit engine loads ONCE instead of once per subtitle
- Significantly faster SRT generation with edit tags
- Less VRAM thrashing from repeated model loading/unloading
- Maintains same quality output

Added dev report documenting the pattern for future engine implementations.
2025-12-06 17:12:33 -03:00
diodiogod d1b093d273 Refactor inline edit tags to use Audio Editor node + fix unified interface
Major changes:
1. Post-processor now uses Audio Editor node instead of calling engine directly
   - Inherits progress bars, caching, tested code
   - Much simpler and more maintainable

2. Fixed unified model interface usage across Step Audio EditX
   - Adapter now loads via unified_model_interface.load_model()
   - Audio Editor node now loads via unified_model_interface.load_model()
   - Both use model_type="tts" for consistent cache keys
   - Prevents duplicate model loading (was loading twice before)

3. Fixed pause tag + edit tag interaction
   - Pause tags split FIRST, then edit tags extracted per segment
   - Allows: "Hello <Laughter> [pause:1] World <Sigh>"
   - Laughter applies to "Hello", Sigh applies to "World"

4. Added lesson to fails document
   - All engines must use unified interface in ALL code paths
   - Cache key must match across adapters/nodes/processors

Bug fixes:
- Missing Dict import in post-processor
- Import path for Audio Editor node (use importlib)
- Progress bars now work during editing

Files modified:
- utils/audio/edit_post_processor.py - refactored to use Audio Editor node
- nodes/step_audio_editx/step_audio_editx_processor.py - pause handling
- engines/adapters/step_audio_editx_adapter.py - unified interface
- nodes/step_audio_editx_special/step_audio_editx_audio_editor_node.py - unified interface
- docs/Dev reports/fails_to_avoid_TTS_Engine_Implementation.md - added lesson
2025-12-05 21:43:05 -03:00
diodiogod 1f629737d2 Implement inline edit tags for Step Audio EditX post-processing
Added support for inline edit tags in TTS text that automatically apply
Step Audio EditX edits to generated audio from ANY engine.

Syntax examples:
- <Laughter:2> - paralinguistic with iterations
- <emotion:happy:1> - emotion edit
- <style:whisper:3> - style edit
- <speed:faster> - speed adjustment
- <Laughter:2|style:whisper> - multiple effects

Key changes:
- Extended step_audio_editx_special_tags.py with EditTag dataclass and iteration parsing
- Created edit_post_processor.py for centralized post-TTS edit application
- Integrated into Step Audio EditX processor with proper pause tag handling
- Pause tags split FIRST, then edit tags extracted per pause-segment
- Reuses already-loaded engine to avoid duplicate loading

Flow:
1. Parse text, split by pause tags first
2. Extract edit tags from each pause-delimited segment
3. Generate TTS with clean text (tags stripped)
4. Post-processor applies edits to segments with tags
5. Assemble final audio

Currently working for Step Audio EditX TTS and SRT nodes.
2025-12-05 21:20:21 -03:00
diodiogod 353c87de55 Fix Step Audio EditX transformers 4.54+ compatibility with simple config fix
Replace complex weight restoration workaround with a simple one-line config fix.

The root cause: Step-Audio-EditX model config was missing 'tie_word_embeddings'
setting, so transformers 4.54+ defaulted to True and tied lm_head to embed_tokens
even though the checkpoint has different weights for each.

Solution: Add 'tie_word_embeddings': false to config.json to prevent tying.

This is much simpler and cleaner than the previous safetensors weight restoration
approach. One line in config.json fixes the issue for all transformers versions.
2025-12-05 12:52:22 -03:00
diodiogod da30410099 Add Step Audio EditX SRT processor with full character switching support
- Create step_audio_editx_srt_processor.py following IndexTTS-2 pattern
- Register Step Audio EditX in unified SRT node (wrapper + processing)
- Add SRT-level progress tracking (job management at subtitle level)
- Build complete voice mapping with alias resolution for character switching
- Handle ComfyUI audio dict format extraction for temp file saving
- Skip internal job tracking in processor when SRT manages it
2025-12-04 16:02:36 -03:00
diodiogod f9c88d7e89 Add Step Audio EditX segment parameter support and fix tooltips
- Add step_audio_editx to PARAMETER_ENGINES for seed and temperature
- Fix engine node tooltips: parameters ARE used in clone mode (not hardcoded)
- Add reference implementation paths to implementation plan
- Update fails doc with latest lessons learned
2025-12-04 13:59:49 -03:00
diodiogod b550b5b3f8 Fix generation_info consistency across IndexTTS and Step Audio EditX
Make both engines follow ChatterBox 23-Lang modular pattern:

**Step Audio EditX:**
- Update combine_audio_segments() to use ChunkCombiner with return_info=True
- Return (audio, chunk_info) tuple when requested
- Fix single segment shape handling (ensure 2D [channels, samples])

**IndexTTS:**
- Add combine_audio_segments() method using ChunkCombiner
- Update process_text() to accept return_info parameter
- Build chunk_info from text segments and return timing data

**Unified Node:**
- Call both engines with return_info=True
- Use ChunkTimingHelper.enhance_generation_info() for detailed reports
- Clean text without tags before calculating length

**Documentation:**
- Add generation_info consistency requirement to fails document
- Document correct pattern: ChunkCombiner + ChunkTimingHelper
- Note wrong pattern: inline torch.cat without timing

Now both engines provide detailed timing reports like F5-TTS and ChatterBox.
2025-12-04 09:51:10 -03:00
diodiogod 701f98ca8a Remove automatic __del__ unload from IndexTTS and Step Audio EditX engines
Models should only unload when explicitly requested (Clear VRAM button) or when
switching engines - NOT automatically after generation completes.

__del__ was causing models to unload immediately after wrapper instance goes
out of scope, preventing model reuse between generations.

Pattern: F5-TTS and ChatterBox don't have __del__, only Index2 and StepAudio had it.
Removed to match correct behavior.
2025-12-04 09:18:25 -03:00
diodiogod b0b41e464f Fix 8-bit quantization device movement error
- Wrap .to() calls in try-except for quantized models
- Show warning only once per engine instance
- Add quantization notes to fails document
2025-12-04 01:37:48 -03:00
diodiogod 9128899a15 Fix Step Audio EditX character switching bug
- Configure character parser with available characters and language defaults like IndexTTS
- Add characters from text tags to available_characters to prevent fallback to "narrator"
- Add fallback voice mapping entries for characters without voice files
- Update fails document with character switching implementation lessons
2025-12-04 01:17:44 -03:00
diodiogod 89d12285b5 Add Step Audio EditX TTS engine implementation
Implemented Step Audio EditX integration with the following components:

Engine Implementation:
- Bundled Step Audio EditX reference code in step_audio_editx_impl/
- Created engine wrapper (step_audio_editx.py) with clone/edit methods
- Created adapter (step_audio_editx_adapter.py) for unified interface
- Created processor (step_audio_editx_processor.py) for TTS Suite integration

Model Management:
- Created downloader (step_audio_editx_downloader.py) for:
  - Main Step-Audio-EditX model (3B LLM + CosyVoice vocoder)
  - Step-Audio-Tokenizer files (linguistic_tokenizer.npy, speech_tokenizer_v1.onnx)
  - FunASR-Paraformer model with correct config for bundled funasr_detach
- Fixed FunASR config to use bundled class names (ParaformerStreaming, WavFrontendOnline, SpecAugLFR)
- Added auto-download for all required models on first use
- Updated unified_model_interface.py to auto-download Step-Audio-EditX components

Node Configuration:
- Created Step Audio EditX engine config node
- Registered in nodes.py and unified TTS text node

Known Issues:
- LLM generation hangs during inference despite:
  - torch.no_grad() wrapper
  - torch.cuda.synchronize()
  - Eager attention mode (Step1ForCausalLM doesn't support SDPA)
  - Reduced max_new_tokens
  - Removed logits processor
- Model loads successfully, all components initialized correctly
- Issue appears to be with transformers.generate() call itself
- Requires further investigation of Step1ForCausalLM compatibility

Files Modified:
- nodes.py: Added Step Audio EditX registration
- requirements.txt: Added FunASR dependencies
- utils/models/unified_model_interface.py: Added Step Audio EditX factory
- Various Step Audio EditX implementation files

Model Downloads:
- Step-Audio-EditX: 7GB (3B LLM + vocoder)
- FunASR-Paraformer: 881MB (from custom HF repo with fixed config)
- Step-Audio-Tokenizer: Bundled with main model download
2025-12-03 13:27:02 -03:00
diodiogod 5c5a1393ca Version 4.14.28
Fix Italian ChatterBox case-sensitive language prefix detection

- Make [it] prefix detection case-insensitive to prevent double-prefixing
- Users can now use [it], [IT], [It] or any capitalization without issues
- Avoids duplication that caused 'IT' to be spoken in output
2025-11-19 23:18:19 -03:00
diodiogod 43d1342b4b Fix: Move TIER2-3_REFACTOR_PLAN.md to correct directory
Remove incorrectly escaped 'Dev\ reports' directory
2025-11-14 23:02:11 -03:00