ComfyUI Extension: Civitai Recipe Finder

Authored by BAIKEMARK

Created

Updated

66 stars

Instantly explore Civitai community hits for your local AI models and apply full recipes with one click โ€” or dive deep to uncover the best prompts, parameters, and LoRA combos.

Custom Nodes (0)

    README

    Civitai Toolkit

    ๐Ÿ‘‰ ็‚นๅ‡ป่ฟ™้‡ŒๆŸฅ็œ‹ไธญๆ–‡ๆ–‡ๆกฃ

    <details> <summary>๐Ÿ•’ <b>Changelog (click to expand)</b></summary>

    [4.0.2] - 2025-10-07

    Summary:
    Adds API Key support to improve reliability, authentication, and request limits for all Civitai API interactions.

    ๐Ÿš€ Added

    ๐Ÿ”‘ API Key Management

    • Introduced a brand-new โ€œAPI Key Managementโ€ section in the ComfyUI Settings Panel.
    • Users can now generate an API Key from their Civitai Account Page and enter it directly in the plugin settings.
    • Once saved, all plugin requests to Civitai will automatically include Authorization headers for authentication.

    ๐Ÿ’ก Why this matters:
    This feature helps users increase API rate limits and prepare for upcoming Civitai features that may require authentication.
    You can create and manage your API Key on the Civitai Account Settings page.


    [4.0.1] - 2025-10-06

    Fixes

    • Startup freeze issue:
      Some users reported that ComfyUI would hang indefinitely on startup when having a large number of LoRA models.
      This update fixes the issue by moving the scanning process to the background.

    Improvements

    • Background processing:
      Model hashing and Civitai info fetching now run asynchronously in the background, allowing ComfyUI to start instantly.
    • Resume support:
      Added progress persistence, resuming from the last saved state instead of starting over.

    [4.0.0] - 2025-10-05

    ๐Ÿ’ฅ Major Updates

    • Officially renamed to Civitai Toolkit to reflect its all-in-one suite positioning.
    • The original Recipe Finder remains as a core module.

    โœจ New & Improved

    • Dual Sidebar UI: introduces Local Model Manager and Civitai Online Browser.
    • Enhanced UX: smoother interaction and higher model management efficiency.
    </details>

    Overview

    Civitai Toolkit is an all-in-one Civitai integration hub built exclusively for ComfyUI. It seamlessly combines online browsing and discovery, local model management, and recipe reconstruction & data analysis โ€” enabling you to go from inspiration to realization without ever leaving ComfyUI.

    No more switching between your browser and file manager โ€” with two powerful sidebar panels and a suite of analysis nodes, youโ€™ll enjoy a complete Civitai experience directly inside ComfyUI.


    โœจ Key Features

    • ๐ŸŒ Civitai Online Browser Access Civitai directly within ComfyUI. Search, filter, and download models in one click.

    • ๐Ÿ—‚๏ธ Local Model Manager Browse, search, and categorize local models with automatic Civitai metadata linking.

    • ๐Ÿ” Visual Recipe Finder Instantly explore a modelโ€™s popular works and restore full generation recipes (prompts, params, LoRA combos, etc.).

    • ๐Ÿ“Š Community Trend Analysis Automatically collect common generation parameters and discover popular sampler, CFG, and prompt combinations.

    • ๐Ÿ”— Golden Combination Discovery Reveal high-frequency co-usage between models and discover new creative synergies.

    • โšก Instant Trigger Word Extraction Extract trigger words from both local metadata and Civitai API, then generate a clean Markdown comparison table.


    ๐Ÿงญ Core Interfaces: Sidebar System

    ๐ŸŒ Civitai Online Browser

    Highlights:

    • ๐Ÿ”Ž Advanced Search & Filtering โ€” by keywords, model type, base model, sorting (Hot / New / Top Rated), etc.
    • ๐Ÿ”„ Local Sync โ€” automatically marks models as โ€œDownloadedโ€ to prevent duplicates.
    • ๐Ÿ–ผ๏ธ Immersive Detail View โ€” model descriptions, version selector, sample gallery, file list, and direct download links.
    <div align="center" style="display: flex; flex-wrap: wrap; justify-content: center;"> <img src="./image/Civitai_Browser.png" alt="Civitai Browser" width="48%" /> <img src="./image/Civitai_Browser_pop.png" alt="Civitai Browser Pop" width="48%" /> </div>

    ๐Ÿ—‚๏ธ Local Model Manager

    Highlights:

    • ๐Ÿ” Auto Scan & Recognition โ€” indexes local models and matches them to Civitai database via Hash.
    • ๐Ÿ’ฌ Rich Info Display โ€” view version details, trigger words, ratings, downloads, and more.
    • โšก Streamlined Interaction โ€” filter by type, keyword search, and one-click copy for Hash or triggers.
    <div align="center" style="display: flex; flex-wrap: wrap; justify-content: center;"> <img src="./image/Local_Manager.png" alt="Local Manager" width="48%" /> <img src="./image/Local_Manager_pop.png" alt="Local Manager Pop" width="48%" /> </div>

    ๐Ÿงฉ Core Node Suite

    1๏ธโƒฃ Visual Recipe Finder

    Civitai Recipe Gallery

    • Browse top-rated works for a given model and load full recipes in one click.
    • ๐Ÿš€ Instant Workflow Restore โ€” safely and smartly reconstructs original workflows (ComfyUI-Manager compatible).
    • ๐Ÿ’พ Save Source Files โ€” download images with embedded metadata to the output directory.

    | Output Port | Type | Description | | --------------- | --------------- | ------------------------------------------------------------ | | image | IMAGE | Selected sample image | | info_md | STRING | Markdown recipe report (recommended for MarkdownPresenter) | | recipe_params | RECIPE_PARAMS | Parameter pipeline (use with Get Parameters from Recipe) |

    โš ๏ธ First Run Notice: The first run computes model hashes (may take some time). Results are cached in Civitai Toolkit/data or Civitai_Recipe_Finder/data for faster future runs.

    gallery example

    Get Parameters from Recipe

    Unpack the recipe_params pipeline and output generation-ready parameters for KSampler: ckpt_name, positive_prompt, negative_prompt, seed, steps, cfg, sampler_name, scheduler, width, height, denoise.


    2๏ธโƒฃ In-Depth Model Analysis

    Node: Model Analyzer (Checkpoint / LoRA)

    Features:

    • Unified process from data fetching โ†’ community statistics โ†’ parameter summary โ†’ Markdown report.
    • Replaces legacy multi-node setups with faster, cleaner analysis.

    Inputs: model_name, image_limit, sort, nsfw_level, filter_type, summary_top_n, force_refresh Outputs:

    • full_report_md: Full Markdown report
    • fetch_summary: Fetch summary (e.g., โ€œAnalyzed 100 entries successfullyโ€)
    • params_pipe: Extracted community parameter pipeline (use with Get Parameters from Analysis)

    Model_DeepResearch example

    Get Parameters from Analysis

    Unpack the params_pipe to extract community-common parameters โ€” works the same as Get Parameters from Recipe.


    3๏ธโƒฃ Lightweight Tools

    Lora Trigger Words

    Instantly extract LoRA trigger words:

    | Output Port | Type | Content | | ------------------- | -------- | ---------------------------------- | | metadata_triggers | STRING | Local metadata trigger words | | civitai_triggers | STRING | Official Civitai API trigger words | | triggers_md | STRING | Markdown comparison table |

    lora_trigger_words example


    โš™๏ธ Installation & Usage

    โœ… Manual Installation

    ComfyUI/custom_nodes/ComfyUI-Civitai-Toolkit/
    pip install -r requirements.txt
    

    โœ… Install via ComfyUI Manager

    Search Civitai Toolkit in ComfyUI Manager โ†’ click โ€œInstallโ€ โ†’ restart ComfyUI. Youโ€™ll find the toolkit in the sidebar and under the Civitai node category.

    ๐Ÿ’ก Tip: The Markdown Presenter node can be found under the Display category.


    ๐Ÿงช Workflow Examples

    • Built-in Template: Templates โ†’ Custom Nodes โ†’ ComfyUI-Civitai-Recipe
    • Repository Samples: example_workflows

    ๐Ÿ”ง Version Compatibility

    • Migration from โ‰ค3.1: Go to Settings โ†’ CivitaiUtils โ†’ Migration to transfer old JSON cache into the new database.

    ๐Ÿ™ Credits

    Heartfelt thanks to all the amazing open-source projects and their authors ๐Ÿ™Œ