Commit Graph

4 Commits

Author SHA1 Message Date
Ethanfel e9c947b613 fix: strip title and heading tags from EPUB text output
Publish to ComfyUI Registry / publish (push) Has been cancelled
The chapter title was appearing multiple times in the text (from <title>,
<h1>, and body). Now <title> and <h1>/<h2>/<h3> are removed from the body
text since the title is already available via the chapter_title output.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-10 00:07:00 +02:00
Ethanfel 4eabac4c7e feat: add chapter_title output to EPUB Loader for file naming
Returns the title of the first selected chapter as a STRING so it can
be wired directly into a Save Audio node's filename field.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-09 17:40:38 +02:00
Ethanfel d779526225 Preserve paragraph breaks in EPUB text extraction
get_text(separator=' ') collapsed all paragraphs into one line.
Now inserts \n\n at block-level element boundaries (p, h1-h6, div,
li, br, tr) before extraction, then normalises whitespace.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-05 18:06:41 +02:00
Ethanfel 5dfaa0b300 Replace torchaudio.save with soundfile.write; add EPUB loader node
- nodes/generator.py: swap torchaudio.save for soundfile.write to avoid
  torchcodec/FFmpeg dependency crash in environments without FFmpeg shared libs
- nodes/epub_loader.py: new OmniVoiceEpubLoader node for loading EPUB chapters
- tests/test_epub_loader.py: 8 tests for the EPUB loader
- install.py: add beautifulsoup4 to runtime deps
- __init__.py, nodes/__init__.py: register OmniVoiceEpubLoader

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-05 17:24:18 +02:00