🚀 ComfyUI Tysigu Utility Nodes
ComfyUI 用の高機能なカスタムノード群です。
テキストの行ごとの読み込み、進行状況の可視化、入力の切り替えを、スパゲッティのような複雑な配線なしでエレガントに管理するために設計されました。
[EN] A collection of highly functional custom nodes for ComfyUI. Designed to elegantly manage line-by-line text reading, visual progression display, and dynamic inputs without the mess of spaghetti wiring!
✨ Features / 機能紹介
配線が絡まるストレスや、既存ノードの「強制的すぎる仕様」に対するジレンマを一気に解決する便利ツール群です。
複数行のテキスト(プロンプト)をバッチ処理する際、以下のような柔軟で思い通りのコントロールを可能にします。
- 指定の行番号から読み込みを始めて連続実行する
- 行を意図的に進めたり戻したりする
- 特定の行で固定する(同じプロンプトでガチャを回す)
これらのノードを使えば、現在の処理の進行状況を画面上で直感的に可視化し、テキスト入力の切り替えもノードの繋ぎ変えなしで一瞬で行えます!
[EN] Tools designed to instantly resolve the stress of tangled wires and the dilemma of "forced sequential reading" in existing nodes.
When processing multi-line texts (prompts) in batches, it enables flexible and precise control such as:
- Start reading from a specific line number and execute sequentially.
- Intentionally advance or return to previous lines.
- Fix at a specific line (useful for 'gacha' rerolling with the same prompt).
With these nodes, you can visually track your current processing progress directly on the screen and switch text inputs instantly without reconnecting nodes!
📖 1. TysiguReadLines
複数行のプロンプトリストから、テキストを順番(または指定箇所で固定)に読み込む次世代のリーダーノードです。
既存のリーダーノードにありがちな「次は絶対に次の行しか読まない」という不便さを解消しました。
- 🎯 行の固定(ガチャ用): 特定の行(キャラや構図)に固定して生成結果を厳選(ガチャ)するのに最適です。
- ⚙️ 柔軟な自動進行: はじめの行を指定すれば、あとは自動で順番に次の行へと進んでくれます。
- 🔁 自動ループ: 最後の行まで到達したら、エラーで止まることなく自動で最初の行へ戻ってループします。
- 🔄 ワンクリック・リセット: ノード上の専用ボタン(
Reset line to 1)を押すだけで、いつでも瞬時に「1行目」から処理をリスタートできます!
[EN] Reads a multi-line prompt list sequentially or holds on a fixed line. Solves the inconvenience of existing reader nodes.
- 🎯 Fixed Line for 'Gacha': Perfect for locking onto a specific line (character/composition) and rerolling generations.
- ⚙️ Flexible Progressive Batch: Set a starting line and let it automatically proceed sequentially through the queue.
- 🔁 Auto-Loop: Automatically returns to the first line upon reaching the end of the list without triggering errors.
- 🔄 One-Click Reset: Features a dedicated
Reset line to 1button on the node, allowing you to instantly restart your process from the very first line at any time!
🖥️ 2. TysiguTextDisplay
処理の進行状況がブラックボックスになるのを防ぐ、可視化特化のディスプレイノードです。
以下のような情報が、ノード上のUIに直接、美しく一覧表示されます。
- 📊 総行数が何行あるか
- 🚨 今は何行目の処理を行っているか
- 📝 どんなテキスト(プロンプト)内容が送信されているか
💡 【便利ポイント】
現在の行番号や内容がハッキリと分かるため、「何行目から何行目だけを重点的に繰り返したい」「狙ったキャラを出すためにこの行に固定しよう」といった用途において、非常に直感的で調整しやすくなります!
🔗 【接続方法】
TysiguReadLines ノードから出力される display_info ピンのケーブルを引っ張り、このディスプレイノードに入力(接続)することで機能します。
[EN] A visually-focused display node that prevents your progress from becoming a black box. The following information is beautifully listed directly on the node UI:
- 📊 Total number of lines
- 🚨 Which line is currently being processed
- 📝 What exact text (prompt) is currently being sent
💡 [Pro Tip] By clearly seeing the current line number and content, it becomes highly intuitive to make adjustments like "I want to focus on repeating lines X to Y" or "Let's lock onto this line to nail this specific character!".
🔗 [How to connect] Simply connect the
display_infooutput pin from theTysiguReadLinesnode into the input of this display node, and it will start visualizing everything.
🔀 3. TysiguDynamicSwitch
複数の入力(別々のキャラリストなど)を切り替える際、毎回わずらわしいケーブルの繋ぎ変えをする必要が完全にゼロになります!
- 👉 直感的な操作: ノード上の
switch_indexの数値を変更するだけで、複数ある入力の中から使いたいものを一つ選択(切り替え)できます。 - 🏷️ 動的ラベル表示【New!】: 接続したテキスト入力の「タイトル」や「行数」などの情報がピンの横に自動で並ぶため、どこに何が繋がっているかが一目でわかります!
- 🔄 接続を整理(Pack機能)【New!】: ノード下部の専用ボタンを1クリックするだけで、接続を外して虫食い状態になってしまった空きピンを自動で上に詰め、一瞬で綺麗に再整理します。
- ♾️ 高い拡張性: ノードに繋ぐピン(入力ソケット)はご自身の使用数に合わせてどんどん増やせます。プログラム内部の処理上は最大999個の枠を探せるよう安全マージンを取って設計されているため、大量のリストを接続してもエラーで落ちるリスクがなく安心です。
[EN] Eliminates the need for annoying cable rewiring when switching between multiple inputs!
- 👉 Intuitive Operation: Select and switch between multiple inputs simply by changing the
switch_indexvalue on the node.- 🏷️ Dynamic Pin Labels [New!]: The connected text nodes' titles and line counts are automatically displayed on the pins, so you instantly know what is connected where!
- 🔄 Pack Connections Button [New!]: A single click automatically cleans up empty unassigned pins and reorganizes your connections to instantly neaten your workflow.
- ♾️ High Scalability: You can keep adding input sockets (pins) as needed. The internal program is safely designed with a margin to search up to 999 slots, completely eliminating the risk of crashing even when connecting a massive number of lists.
📥 4. TysiguTextInput
複数行のプロンプトやテキストデータを一つのノード内でシンプルに管理・入力するためのテキストノードです。
💡 【最大の強み: キュー(Batch)数の即座な把握】
テキストを入力するだけで、ノード上に「このリストの総行数が何行あるか」が自動表示されます。これにより、以下の判断が一目でつくようになります。
- 「バッチカウント(Queueの数)をいくつに設定すればリストを一回り(全生成)できるか」
わざわざプロンプトの行数を手動で数える必要がなくなり、計算ミスや確認のストレスが一切なくなります!
[EN] A convenient text node designed for cleanly managing and inputting multi-line prompts all within a single location.
💡 [Biggest Strength: Instant Batch Queue Assessment] When you input text, it automatically displays "the total number of lines in this list". This allows you to judge at a glance exactly how many ComfyUI Batch Counts (Queue instances) you need to set to complete one full cycle of all prompts. It completely eliminates the stress of miscalculation and manual checking!
🇯🇵 5. Japanese to Hiragana (TysiguJapaneseToHiragana)
漢字やカタカナを含む日本語の文章を解析し、自動的に「ひらがな」および「ローマ字」へと高精度に変換・出力するノードです。音声合成(TTS)ノードへの読み仮名渡しや、ファイル名・プロンプトのローマ字変換に最適です。
- 🗣️ ひらがな・ローマ字の同時出力: 入力された文章から、読み仮名(ひらがな)と指定形式のローマ字を同時に生成・出力します。
- 🔤 選べる3種類のローマ字変換方式 (
romaji_mode):- ヘボン式 (
hepburn): 英語圏の発音に最も近く、一般的な表記方式(例: 「し」→shi、「ち」→chi、「つ」→tsu、「ふ」→fu、「じ」→ji)。英語圏向けモデルや一般的な英字表記に最適です。 - 訓令式 (
kunrei): 日本の小学校教育で習う50音表の規則に忠実な表記(例: 「し」→si、「ち」→ti、「つ」→tu、「ふ」→hu、「じ」→zi)。 - パスポート式 (
passport): 外務省の旅券表記規定に基づいたヘボン式の変種表記(長音の扱いや特定の例外規則に対応)。
- ヘボン式 (
- 🔡 文字ケースと区切りの柔軟な調整: ローマ字のケース(小文字
lowercase/ 大文字uppercase/ 先頭大文字titlecase)や単語間の区切り文字(romaji_spacer)を自由に設定可能。 - 🖥️ リアルタイムUIプレビュー: ノード上に「【入力テキスト】」「【ひらがなプレビュー】」「【ローマ字プレビュー】」が自動表示され、変換結果を一目で確認できます。
- 🔗 外部テキスト入力ピン: Whisperなどの音声認識(STT)ノードやテキスト生成ノードから
text_inputピンへ直接配線可能(外部入力が優先されます)。
⚠️ 【重要: 依存ライブラリのインストール】
本ノードは形態素解析にpykakasiを使用します。動作には外部ライブラリの導入が必須となるため、必ず後述のrequirements.txtからの依存関係インストールを実行してください(ComfyUI-Manager 経由の場合は自動解決されます)。
[EN] Analyzes Japanese text (including Kanji/Katakana) and accurately converts it to Hiragana and Romaji. Perfect for passing reading pronunciations to TTS models or converting Japanese prompts/filenames to alphabet.
- 🗣️ Dual Output: Outputs both Hiragana and formatted Romaji simultaneously.
- 🔤 3 Romaji Conversion Modes:
- Hepburn (
hepburn): Matches English phonetics closely (e.g.,shi,chi,tsu,fu,ji). Best for general English models.- Kunrei (
kunrei): Standard Japanese pedagogical system (e.g.,si,ti,tu,hu,zi).- Passport (
passport): Japanese passport official Hepburn variant.- 🔡 Case & Spacing Customization: Choose lowercase, uppercase, or titlecase, and customize word spacers.
- 🖥️ Real-time UI Preview: Displays original text, hiragana, and romaji previews directly on the node.
- ⚠️ Dependency Note: Requires
pykakasi. Please install viarequirements.txt.
🎙️ 6. Load Audio With File Name (TysiguLoadAudioAdvanced)
ComfyUIの input フォルダ内の音声ファイルを読み込み、波形データだけでなく「拡張子なしファイル名」や「物理フルパス」を後続ノードへ受け渡せる高機能オーディオリーダーです。
- ✂️ ノード内トリミング機能:
start_time(開始秒)とend_time(終了秒)を指定するだけで、ComfyUI上で音声を瞬時に切り出して読み込み可能。 - 🏷️ ファイル名とフルパスの出力:
file_name: 拡張子を除いたファイル名を出力(後続の保存・書き出しノードの命名に便利)。filepath: 音声ファイルの物理フルパスを出力(Whisper等のファイルパス入力を要求するノードとダイレクトに連携可能)。
- 🎵 幅広い音声フォーマット対応:
.wav,.mp3,.flac,.ogg,.m4a,.aiffを自動認識。
[EN] Advanced audio loader that reads files from the ComfyUI
inputfolder and provides not only AUDIO data but also duration, clean filename (without extension), and absolute file path.
- ✂️ Built-in Trimming: Set
start_timeandend_timein seconds to trim audio on the fly.- 🏷️ Filename & Path Outputs: Seamlessly feeds file paths to Whisper STT nodes or uses file names for downstream save nodes.
- 🎵 Wide Format Support: Supports
.wav,.mp3,.flac,.ogg,.m4a, and.aiff.
✂️ 7. Audio Silence Trimmer (TysiguAudioSilenceTrimmer)
TTS(音声合成)で生成された音声や録音データの「無音区間(空白)」を自動検出し、自然な余白(パディング)を残したまま綺麗にカットするトリミングノードです。
- 🎯 選べる3箇所のトリミング:
trim_start: 音声冒頭の無音をカット。trim_middle: 発話間の長すぎる沈黙区間をカット(発話間のテンポ改善に最適)。trim_end: 音声末尾の不要な無音余白をカット。
- 🎛️ しきい値調整 (
threshold_db): 無音と判定する音量レベル(dB)を細かく調整可能(初期推奨値:-45.0dB)。 - ⏱️ 自然な余白を保持(マージン機能): 無音を完全にゼロにするのではなく、開始・中間・終了に指定秒数(
margin_*_seconds、デフォルト1.0秒)の自然な無音を残すため、息継ぎや発話の頭欠け・尻切れを防ぎます。
[EN] Automatically detects silence in generated TTS or recorded audio and trims it while preserving natural padding margins.
- 🎯 Selective Trimming: Independently toggle start, middle (pause between speech), and end trimming.
- 🎛️ Adjustable Threshold (
threshold_db): Fine-tune silence detection sensitivity (default:-45.0dB).- ⏱️ Natural Padding Margins: Retains customizable margin padding seconds (
margin_*_seconds) so audio never sounds abrupt or clipped.
🛠️ Installation / インストール方法
Method 1: Via ComfyUI-Manager (Recommended / 推奨)
Search for ComfyUI-TysiguUtilityNodes in ComfyUI-Manager and click Install.
Dependencies (pykakasi) will be installed automatically.
Method 2: Manual Install (手動インストール)
- Navigate to your ComfyUI
custom_nodesdirectory:cd ComfyUI/custom_nodes - Clone this repository:
git clone https://github.com/tysigu-project/ComfyUI-TysiguUtilityNodes.git - Install dependencies / 依存関係のインストール:
⚠️Japanese to Hiraganaノードを使用するために外部ライブラリpykakasiが必要です。必ず以下のコマンドを実行してください。(ポータブル版 ComfyUI の場合 / For portable ComfyUI):cd ComfyUI-TysiguUtilityNodes pip install -r requirements.txt..\..\python_embeded\python.exe -m pip install -r requirements.txt - Restart ComfyUI. The nodes will be available under the
TysiguUtilityNodesand🧪AILab/🎙️Tysigucategories.
💡 Usage / 使い方
ComfyUIのキャンバス上で 右クリック > Add Node から以下のカテゴリーを選択して各ノードを追加してください。
TysiguUtilityNodes: テキスト制御ノード群(ReadLines, TextDisplay, DynamicSwitch, TextInput, Audio Silence Trimmer)🧪AILab/🎙️Tysigu: 音声・言語処理ノード群(Japanese to Hiragana, Load Audio With File Name)
⚡ Pro Tip: ノードの検索窓(Search)で
tysiguと入力すると、これらのノードを最速で呼び出すことができます!
