Extensions/ComfyUI-ZMongo
ComfyUI Extension

ComfyUI-ZMongo

Professional ZMongo Legal Operations suite for ComfyUI

By CentralFloridaAttorney·Created 5 months ago·Updated 3 months ago· 1
CentralFloridaAttorney/ComfyUI-ZMongo
Nodes95
On cloudLocal install
CategoryZMongo/06 Gemini, ZMongo/04 Images
Stars1
Updated3 months ago

Nodes (95)

05 Gemini Key Status

The read-only check before you trust the Gemini nodes

ZMongo/06 Gemini
05 Gemini Chat and Save to ZMongo

One node, generate and persist in a single run

ZMongo/06 Gemini
05 Gemini Chat

The multimodal Swiss army knife of this pack

ZMongo/06 Gemini
05 Gemini Count Tokens

Checking prompt size before it bites

ZMongo/06 Gemini
05 Delete Gemini API Key

Revoking server-side access you can't see

ZMongo/06 Gemini
05 Gemini Image + Text

A multimodal vision call from your own render

ZMongo/06 Gemini
05 Gemini JSON

Getting structured output instead of prose

ZMongo/06 Gemini
05 Gemini List Models

Finding out what your Gemini key can actually reach

ZMongo/06 Gemini
05 Gemini Prompt from ZMongo Doc

Pulling a stored document into a Gemini call

ZMongo/06 Gemini
05 Save Gemini API Key

Where your Gemini key actually lives in ZMongo

ZMongo/06 Gemini
05 Test Gemini API Key

Proving the key works before the real calls start

ZMongo/06 Gemini
04 Browse Collection Images

Your ZMongo store as a contact sheet

ZMongo/04 Images
00 Close Session

The polite way to end a ZMongo workflow

ZMongo/00 Auth
03 Count Docs

Knowing how much is in your store before you build around it

ZMongo/02 Docs
02 Create Collection

Making the table before you fill it

ZMongo/01 Collections
03 Create Doc

Parking structured data in your ZMongo store

ZMongo/02 Docs
02 Delete Collection

The one with the safety word

ZMongo/01 Collections
03 Delete Doc

Removing a record without nuking the whole collection

ZMongo/02 Docs
04 Debug Image Document

The tool for when saved images won't come back out

ZMongo/04 Images
04 Easy Save Image

Getting renders out of the graph and into storage

ZMongo/04 Images
03 Get Doc

Pull a whole document out of the database — ZMongo 03 Get Doc

ZMongo/02 Docs
03 Get Value

Pull one field out by dot-path — ZMongo 03 Get Value

ZMongo/02 Docs
00 Health

The 'did the database still wake up' node — ZMongo 00 Health

ZMongo/00 Auth
04 Image Field Candidates

What field name is my image data hiding in? — ZMongo 04 Image Field Candidates

ZMongo/04 Images
99 JSON Pick

Grab a value out of any JSON blob — ZMongo 99 JSON Pick

ZMongo/99 Helpers
00 API Key Session

Every ZMongo workflow starts here — and it's not calling your database

ZMongo/00 Auth
02 List Collections

Show me my tables — ZMongo 02 List Collections

ZMongo/01 Collections
03 List Docs

Find documents without dragging the whole database out — ZMongo 03 List Docs

ZMongo/02 Docs
04 Metadata Flattened Paths

See every key a document actually has — ZMongo 04 Metadata Flattened Paths

ZMongo/04 Images
03 Query Docs

Filter, sort, project — ZMongo 03 Query Docs

ZMongo/02 Docs
03 Save Value

Store one value by dot-path — ZMongo 03 Save Value

ZMongo/02 Docs
99 Select Nth Item

Pick items out of any list with one expression — ZMongo 99 Select Nth Item

ZMongo/99 Helpers
03 Update Doc

Change what's stored — ZMongo 03 Update Doc, and its two confusing modes

ZMongo/02 Docs
00 Who Am I

Who are we in this database, anyway? — ZMongo 00 Who Am I

ZMongo/00 Auth
10 Best Variant Selector

You made 10 prompts with an LLM — now pick the winner — ZMongo 10 Best Variant Selector

ZMongo/07 Text Agents/Prompt Agents
10 Build Context Pack

Give the LLM its memory back — ZMongo 10 Build Context Pack

ZMongo/07 Text Agents/Memory
10 Caption Pack Generator

Turn a generation into a ready-to-post caption — ZMongo 10 Caption Pack Generator

ZMongo/07 Text Agents/Publishing
09 ZMongo Content Pack Add Image Sequence

Bundle an animation's frames as one sequence — ZMongo 09 Content Pack Add Image Sequence

ZMongo/09 Content Packs
09 ZMongo Content Pack Add Images

Splat a whole batch of images into a content pack — ZMongo 09 Content Pack Add Images

ZMongo/09 Content Packs
09 ZMongo Content Pack Add Image

Stash a hero image inside a content pack — ZMongo 09 Content Pack Add Image

ZMongo/09 Content Packs
09 ZMongo Content Pack Alias Editor

Rename, relabel, retype, or drop fields — ZMongo 09 Content Pack Alias Editor

ZMongo/09 Content Packs
09 ZMongo Content Pack Build

Turn any JSON blob into a typed, shareable content pack

ZMongo/09 Content Packs
09 ZMongo Content Pack Export JSON File

Export a content pack to a file you can drag back into ComfyUI

ZMongo/09 Content Packs/Portable
ZMongo Content Pack Export Static Workflow V3

Freeze a content pack into a self-contained workflow.json

ZMongo/Content Packs/V3/Static Workflow
ZMongo Content Pack Get Boolean

Pull a boolean out of a content pack for toggles and flags

ZMongo/09 Content Packs/Get
09 ZMongo Content Pack Get Float

Pull a float out of a content pack for CFG and denoise values

ZMongo/09 Content Packs/Get
09 ZMongo Content Pack Get Image

Rehydrate a stored image back into a real IMAGE tensor

ZMongo/09 Content Packs/Get
09 ZMongo Content Pack Get Int

Pull an int out of a content pack for seeds, steps, and sizes

ZMongo/09 Content Packs/Get
09 ZMongo Content Pack Get JSON

Pull a JSON field out of a content pack as text

ZMongo/09 Content Packs/Get
09 ZMongo Content Pack Get Selected

One node that pulls any field out of a content pack, whatever its type

ZMongo/09 Content Packs/Get
09 ZMongo Content Pack Get String

Pull a string out of a content pack, without digging through JSON

ZMongo/09 Content Packs/Get
09 ZMongo Content Pack JSON Text Loader

Load a content pack straight from pasted JSON text

ZMongo/09 Content Packs/Portable
09 ZMongo Content Pack Load JSON File

Load a content pack back from a file on disk

ZMongo/09 Content Packs/Portable
09 ZMongo Content Pack Load

Pull a saved content pack back out of the database

ZMongo/09 Content Packs
09 ZMongo Content Pack Manifest Preview

Preview what's inside a content pack before you wire it up

ZMongo/09 Content Packs
09 ZMongo Content Pack Save

Save a content pack into your ZMongo database

ZMongo/09 Content Packs
ZMongo Content Pack Static Outputs V3

The 64-output workhorse at the end of an exported static workflow

ZMongo/Content Packs/V3/Static Workflow
04 Display Image from ZMongo

Pull an image out of a ZMongo database document and preview it

ZMongo/04 Images
06 Create Text Document

Create a text document in ZMongo straight from a string input

ZMongo/03 Documents
06 Delete Document

Delete a document from ZMongo (with a safety switch)

ZMongo/03 Documents
06 Extract Document Text

Extract text from a stored document and feed it into your workflow

ZMongo/03 Documents
06 Document Field Paths

The X-ray that shows you every field hiding inside a document

ZMongo/03 Documents
06 Document File Browser

Browse your disk from inside ComfyUI and hand files to your workflow

ZMongo/03 Documents
06 Get Document

Pull one whole document out of the database, without touching JSON

ZMongo/03 Documents
06 Get Document Text

The node that turns a document ID into an actual string you can use

ZMongo/03 Documents
06 Get Document Value

Pluck one field out of a document with dot notation

ZMongo/03 Documents
06 Document API Health

The 2-second sanity check before you blame your database node

ZMongo/03 Documents
06 Document Index Selector

Slice and dice a document list with one string of index math

ZMongo/03 Documents
06 Ingest Text PDF / DOCX

Turn a PDF or DOCX into a searchable database record

ZMongo/03 Documents
06 List Documents

Browse your document collection like it's a folder you can query

ZMongo/03 Documents
06 Document OCR Status

Check whether the server's OCR actually finished

ZMongo/03 Documents
06 Queue Document OCR

The fire-and-forget way to get text out of a scanned PDF

ZMongo/03 Documents
06 Save Document Text

Persist any string to the database with one wire

ZMongo/03 Documents
06 Save Document Value

Write to any field in a document, dot-path included

ZMongo/03 Documents
06 Select Nth Document Item

The safest way to grab one item out of a list

ZMongo/03 Documents
06 Update Document Metadata

Tag and triage your documents without touching the record body

ZMongo/03 Documents
06 Upload Document File

Ship the raw file itself to the backend, not just its text

ZMongo/03 Documents
06 Document WhoAmI

Find out which database silo you're actually writing to

ZMongo/03 Documents
08 Dynamic Preset Outputs

Turn a saved preset back into 64 live wires, automatically

ZMongo/08 Presets
10 Find Similar Successful Prompts

What worked the last time I generated something like this?

ZMongo/07 Text Agents/Provenance
07 Load Image Sequence from ZMongo

Reassemble a saved image sequence straight back into a batch tensor

ZMongo/05 Image Sequences
10 Load Memory Capsule

Pull your saved prompts back into the graph

ZMongo/07 Text Agents/Memory
08 Load Preset

Put that saved KSampler config back on the canvas

ZMongo/08 Presets
00 Local File Store Session

Local File Store Session

ZMongo/00 Auth
ZMongo: Message of the Day

The pack's little news ticker

ZMongo
08 Preset Debug Info

Read that preset JSON without squinting

ZMongo/08 Presets
10 Prompt Critic

A Gemini-powered second opinion on your prompt

ZMongo/07 Text Agents/Prompt Agents
10 Prompt Evolver

Generate N variants, keep the best one

ZMongo/07 Text Agents/Prompt Agents
10 Save Prompt Provenance Ledger

The audit trail for your prompts

ZMongo/07 Text Agents/Provenance
99 Record Loop Manager

A self-advancing loop for batch processing

ZMongo/99 Helpers
07 Save Image Sequence to ZMongo

Park every frame as a document

ZMongo/05 Image Sequences
08 Save Preset By Node ID

ZMongo Save Preset By Node ID

ZMongo/08 Presets
10 Save Prompt Memory

Your prompt ideas, tagged and searchable

ZMongo/07 Text Agents/Memory
10 Text Agent Session

The config card every ZMongo LLM node needs

ZMongo/07 Text Agents
10 Workflow Documentation Agent

Auto-write the README for your graph

ZMongo/07 Text Agents/Publishing
Readme

🚀 ComfyUI-ZMongo

Welcome to ComfyUI-ZMongo, an advanced framework that transforms ComfyUI into an integrated production ecosystem. By decoupling hardcoded values from your workflow graph and offloading them into a centralized database layer, ZMongo allows you to utilize your database as a reusable parameter library, prompt hub, and structured asset store.

Whether you want to synchronize complex generation parameters across multiple local worker rigs, store structured prompt configurations, or build automated document ingestion pipelines driven by Large Language Models (LLMs), ComfyUI-ZMongo seamlessly bridges your visual graphs with database state management.


📌 Table of Contents


🔑 00 Session / Auth

Every enterprise data pipeline requires a flexible, authenticated entry point. The initialization section provides nodes that bridge local canvas variables to backend configurations using modern token infrastructure.

💡 Added Benefit — Dual Operational Backends: ZMongo custom nodes include a robust Local File Store system. If you don't supply a hosted base URL or authentication credentials, the database nodes can be operated using a Local Storage Node for saving and loading your data cleanly on your local hard drive. This provides immediate, zero-config persistence out of the box, with an effortless upgrade path to a hosted production cluster later on. Below is a recommended graph structure for a dual-operational setup:

[ ComfyUI Graph Grid ] ──► (00 API Key Session) ──► Secure Bearer Socket ──► Hosted Silo DB │ └─► [ No Credentials Supplied ] ──► Built-In Local File Store ──► Local Disk Cache

00 API Key Session (ZMongoApiKeySessionNode)

The primary cryptographic gateway for your database sessions. It manages persistence, tracks transaction logging, handles fallback switches for local-only storage, and securely flows your authenticated session downstream to all other operational nodes.

  • Inputs:
    • base_url: The address of your backend operational cluster (e.g., https://businessprocessapplications.com). Leave blank or default to engage local-only mode.
    • zai_api_key: Your private security key fetched from your user management panel.
    • username: Your explicit account identity for logging and telemetry data isolating your personal silo storage.

00 Who Am I (ZMongoApiWhoAmINode)

A network sanity-check block used to verify connection integrity. It pings the database server, validating active tokens, user access levels, and infrastructure connectivity statuses.


📁 01 Collections & 02 Docs

ZMongo groups data sets cleanly into distinct structural boundaries. These management tools provide full control over creating and managing collections (tables) and records directly within the node workspace.

01 Create Collection / 01 Delete Collection

Administrative schema nodes that allow you to stand up or drop custom dataset tables dynamically based on programmatic milestones or pipeline logic.

02 Create Document / 02 Delete Document

Saves or completely wipes out structured dictionary documents into target collections. Perfect for saving raw prompt structures, negative weights, and runtime configurations without typing a single line of raw code.


📄 03 Documents

The 03 Documents suite provides local file scanning, document text parsing across various extensions, sequence selection, and asynchronous server-side OCR processing.

🔍 03 Document File Browser (ZMongoDocumentFilePathBrowser)

Scans a target machine folder with customized folder depth and extension filters. It formats discovered paths into array lists designed for batch streaming.

  • Supported Formats: .pdf, .docx, .txt, .md, .csv, .json, .log, and .rtf.

📥 03 Ingest Text PDF / DOCX (ZMongoDocumentIngestTextFile)

Extracts text components from complex document files directly at the local system level. It maps extracted strings, line counts, and metadata configurations cleanly into document payloads.

  • Layout Engines: Employs PyMuPDF for advanced PDF element mapping and python-docx for parsing tabular text configurations.

🔀 03 Document Index Selector (ZMongoDocumentIndexSelector)

A versatile index-expression compiler that slices and filters multi-document list records with precision.

  • Selection Syntax Examples:
    • 3 — Extracts index number 3.
    • 2-7 — Grabs an inclusive series of rows from index 2 to 7.
    • 0,2,5 — Filters out a specified custom set.
    • * or all — Passes the entire sequence uninterrupted.

👁️ 03 Queue Document OCR / 06 Document OCR Status

Schedules automated optical character recognition on the server backend for image-heavy documents or scanned media layers, outputting extraction tracking states and raw parsed text.

📑 Extended Document Node Registry:

  • 03 Upload Document File: Packages and uploads local asset payloads directly to server storage folders.
  • 03 Create Text Document: Instantiates a fresh document entry populated directly with string variables.
  • 03 List Documents: Returns structured collection metadata matching query arguments.
  • 03 Get Document Text: Retrieves target strings using intelligent structure fallbacks.
  • 03 Document Field Paths: Flattens deeply nested object trees into readable dot-notated list configurations.
  • 03 Get Document Value / 06 Save Document Value: Targets deep properties directly to mutate or extract specific fields.

🖼️ 04 Image & 05 Images

These nodes turn your database into a centralized visual asset management layer, eliminating cluttered storage folders and preventing data loss when scaling across multiple machines.

  • 04 Save Image to Field: Intercepts active pixel grids directly from rendering nodes, packages them into optimized binary array objects, and saves them within targeted records.
  • 04 Load Image from Field: Resolves remote image pointers or binary fields and converts them into standard image tensors ready for immediate VAE decoding.
  • 05 Images Batch Upload: Collects multiple workflow output frames simultaneously and streams them directly into web platform asset galleries.

🧠 06 Gemini / AI API

Integrate advanced intelligence directly into your node graph to dynamically build prompt layouts, translate styles, and analyze imagery using state-of-the-art multimodal LLMs.

  • 06 Gemini Chat: Establishes conversational prompt logic paths, feeding text fields into deep models to dynamically create high-fidelity generation instructions.
  • 06 Gemini Flash: A lightweight inference option built for fast, low-latency processing tasks like parsing text or cleaning messy clip conditioning parameters.

📦 07 Text Agents (In-Development)

Turn your text strings into active logic directors. The text agents layer extracts context from your documents to dynamically branch your execution pipeline.

  • 07 Text Agent Router: Evaluates incoming text elements against complex logical conditions to automatically direct the active execution flow down different path branches based on string data.

🎛️ 08 Presets

The 08 Presets architecture frees your workspace from rigid, tangled parameter connections. Instead of routing endless wires for seeds, steps, samplers, and CFG scales across a massive grid, you can group an entire node's state into a named database preset.

[ Target Node (e.g. KSampler ID: 14) ] ──► [ 08 Save Preset By Node ID ] ──► Unified DB Storage │ [ Downstream Graph Mapping ] ◄── [ 08 Dynamic Preset Outputs ] ◄── [ 08 Load Preset ] ┘

💾 08 Save Preset By Node ID (ZMongoSavePresetByNodeID)

Inspects active node states at runtime using their unique canvas numeric ID. It captures every active input value, widget choice, slider property, and connection coordinate, saving them as a clean, standardized preset object.

  • Dynamic Connection Flattening: If the targeted node gets its values from an upstream link, the save node automatically traces the connection chain back to its source, resolving and saving the actual literal values.

📂 08 Load Preset (ZMongoLoadPreset)

Retrieves stored configuration configurations. It can read parameters from local JSON files, hosted cloud databases, or direct text block values, formatting them into an active preset payload.

🔌 08 Dynamic Preset Outputs (ZMongoDynamicPresetOutputs)

An automated output pin factory that parses structural preset entries and exposes them through sequential wildcard sockets (out_00, out_01, etc.) to map properties directly to downstream inputs.


🎒 09 Content Packs

Content Packs expand on the preset system by bundling entire multi-node generation environments into single, highly transportable database collections. This allows you to store mixed production data—including images, structural strings, meta flags, and numeric generation configs—into Content Packs that can be easily shared across multiple projects.

  • 09 Export Content Pack: Packages active generation parameters, text items, and images into Downloadable Content Packs, which can be dropped into a canvas to rehydrate the saved content.
  • 09 Dynamic Content Pack Outputs: Automatically expands content pack array records back into sequential canvas links, providing a clean solution for building template-driven production pipelines.

🛠️ Message of the Day (MOTD)

  • Message Of The Day (MOTD): Connects to infrastructure alerts, updating your canvas with package change logs and cluster status announcements.

⚙️ Installation & Setup

To install the extension along with all advanced document extraction tools, clone the repository into your custom nodes directory and install dependencies inside your ComfyUI Python environment:

cd custom_nodes
git clone [https://github.com/CentralFloridaAttorney/ComfyUI-ZMongo.git](https://github.com/CentralFloridaAttorney/ComfyUI-ZMongo.git)
cd ComfyUI-ZMongo

# Install required processing libraries
pip install pymupdf python-docx requests python-dotenv