Compare commits

...
44 Commits
Author SHA1 Message Date
Rhys Yang a88722ce8f Merge pull request #107 from Comfy-Org/main
Checkout submodules before publishing
2025-02-01 23:51:39 +08:00
Robin Huang c0b66c4e07 Checkout submodules before publishing 2024-12-31 14:37:36 -08:00
Rhys Yang d191668607 Update pyproject.toml 2024-09-06 19:40:28 +08:00
Rhys Yang a70cbb0c8d Bump version to 1.3.4 2024-09-06 19:30:16 +08:00
Rhys Yang b95499617e Update CHANGELOG.md 2024-09-06 19:29:57 +08:00
Rhys Yang 77095ee38b Fix the input validation of the Parameter Generator node #89
Fix the input validation of the `Parameter Extractor` node #90
2024-09-06 18:24:13 +08:00
Rhys Yang 1e59445091 Merge pull request #87 from spagatticode/ExtractorFix
Update the `Parameter Extractor` node to support parsing quoted parameters
2024-09-06 18:22:55 +08:00
Spag@tti_code b3e66eb21c Merge branch 'ExtractorFix' of https://github.com/spagatticode/comfyui-prompt-reader-node into ExtractorFix
# Conflicts:
#	nodes.py
2024-08-13 13:31:06 +02:00
Spag@tti_code 145fbbb158 Parse parameters in quotes 2024-08-13 13:25:05 +02:00
Spag@tti_code 7c215dde00 Parse parameters in quotes 2024-08-13 12:59:20 +02:00
Rhys Yang 07a1a5314d Merge pull request #85 from ComfyNodePRs/licence-update
Update PyProject Toml - License
2024-08-04 21:43:17 +08:00
snomiao ed6533422e chore(licence-update): Update PyProject Toml - License 2024-08-02 23:03:26 +00:00
Rhys Yang 278e32450f Fix the Parameter Generator unable to choose standard resolutions #82 2024-07-15 23:51:33 +08:00
Rhys Yang b248fcf346 Fix the Prompt Saver unable to correctly handle filenames containing . #80 2024-06-28 15:20:16 +08:00
Rhys Yang 4b35b41d08 Add Any Converter node #76 #78 2024-06-07 07:39:14 +08:00
Rhys Yang af96defbe0 Revert "Change the Type Converter node to a node that converts any type to a * type"
This reverts commit e8ca90fe35.
2024-06-07 07:04:14 +08:00
Rhys Yang e8ca90fe35 Change the Type Converter node to a node that converts any type to a * type 2024-06-07 01:32:18 +08:00
receyuki 659d35b9b8 Bump version to 1.3.3 2024-05-28 02:04:13 +08:00
receyuki ee54281e45 Update CHANGELOG.md 2024-05-28 02:03:38 +08:00
receyuki f94e130bef Update pyproject.toml
Update icon
2024-05-28 01:46:48 +08:00
Rhys Yang 6ab1534e85 Update pyproject.toml 2024-05-28 01:02:12 +08:00
Rhys Yang d960b6dbf1 Create publish_registry.yml 2024-05-28 00:56:44 +08:00
receyuki 0d0afd7f45 Update pyproject.toml
Add icon
2024-05-28 00:43:26 +08:00
Rhys Yang 2069d0c4fc Merge pull request #75 from haohaocreates/pyproject
Add pyproject.toml for Custom Node Registry
2024-05-28 00:33:31 +08:00
haohaocreates 55a57a3b2e chore(pyproject): Add pyproject.toml for Custom Node Registry 2024-05-22 16:57:15 -04:00
receyuki a2e6aff81c Bump version to 1.3.2 2024-05-22 00:30:23 +08:00
receyuki 2af4a879b5 Update core to 1.3.5 2024-05-22 00:28:49 +08:00
receyuki 12b5178915 Update CHANGELOG.md 2024-05-22 00:28:30 +08:00
receyuki a4f5891079 Update node description 2024-05-15 23:24:56 +08:00
receyuki 9042867e97 Update README.md 2024-05-15 23:16:49 +08:00
receyuki 5527096b53 Update README.md 2024-05-15 23:14:19 +08:00
receyuki 9a84eb186b Update core to 1.3.5b2 2024-05-15 23:12:29 +08:00
Rhys Yang faeea1f73c Merge pull request #66 from COvert96/patch-1
Add filename placeholders %width and %height to the`Prompt Saver` node
2024-04-09 02:19:54 +08:00
Chris Overtveld e6cca92351 Update nodes.py save_images to have %width and %height
There's probably a reason this is not in the main branch, I assume because of certain node conflicts but it works for me!
2024-04-07 14:26:51 +02:00
Rhys Yang 05c3553688 Update core to a7eaf3d 2024-03-22 00:06:30 +08:00
Rhys Yang 23b5afbc4f Update the Prompt Reader node to the new exception handling method 2024-03-22 00:05:10 +08:00
Rhys Yang c2ac789c44 Add support for pasted images to the Prompt Reader node #64 2024-03-07 22:32:40 +08:00
Rhys Yang bc62d2be03 Bump version to 1.3.1 2024-02-28 02:15:52 +08:00
Rhys Yang 74beb22df4 Update README.md
Update CHANGELOG.md
2024-02-28 02:15:26 +08:00
Rhys Yang 0d43174e14 Add JPEG to the image extension list 2024-02-28 02:11:00 +08:00
Rhys Yang 91336e987d Add user-friendly warnings and remove the exception raised during the reading of metadata #58 #63 2024-02-28 01:41:18 +08:00
Rhys Yang cbf771ff03 Fix the issue where the Prompt Saver node cannot consume filename from another Prompt Saver node #62 2024-02-27 03:10:02 +08:00
Rhys Yang 867f5eb6f1 Fix the Prompt Saver node freezes workflow when name includes %model #61 2024-02-27 02:38:47 +08:00
Rhys Yang 88ed9fa966 Remove ckpt validation of the Prompt Reader node #59 2024-02-27 00:58:09 +08:00
8 changed files with 248 additions and 50 deletions
+22
View File
@@ -0,0 +1,22 @@
name: Publish to Comfy registry
on:
workflow_dispatch:
push:
branches:
- main
paths:
- "pyproject.toml"
jobs:
publish-node:
name: Publish Custom Node to registry
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v4
with:
submodules: true
- name: Publish Custom Node
uses: Comfy-Org/publish-node-action@main
with:
personal_access_token: ${{ secrets.REGISTRY_ACCESS_TOKEN }}
+53
View File
@@ -1,4 +1,57 @@
# Change Log
## v1.3.4
> [!TIP]
> Starting from v1.3, to support auto-detection on Civitai, `calculate_model_hash` will be renamed as
> `calculate_hash` and it will be enabled by default. Due to the addition of temporary storage of the model hash values,
> the first image generated after switching to the new model will take more time to calculate the hash value,
> but it will not affect the generation speed afterwards until the server is restarted.
> [!NOTE]
> comfyui-prompt-reader-node is now published on the [Comfy Registry](https://www.comfyregistry.org/).
- Add `Any Converter` node #76 #78
- Fix the input validation of the `Parameter Generator` node #89
- Fix the input validation of the `Parameter Extractor` node #90
- Fix the `Parameter Generator` unable to choose standard resolutions #82
- Fix the `Prompt Saver` unable to correctly handle filenames containing `.` #80
- Update the `Parameter Extractor` node to support parsing quoted parameters #87 @spagatticode
- Update PyProject Toml - License #85 @haohaocreates
## v1.3.3
> [!TIP]
> Starting from v1.3, to support auto-detection on Civitai, `calculate_model_hash` will be renamed as
> `calculate_hash` and it will be enabled by default. Due to the addition of temporary storage of the model hash values,
> the first image generated after switching to the new model will take more time to calculate the hash value,
> but it will not affect the generation speed afterwards until the server is restarted.
> [!NOTE]
> comfyui-prompt-reader-node is now published on the [Comfy Registry](https://www.comfyregistry.org/).
- Add pyproject.toml for Custom Node Registry #75 @haohaocreates
## v1.3.2
> Starting from v1.3, to support auto-detection on Civitai, `calculate_model_hash` will be renamed as
> `calculate_hash` and it will be enabled by default. Due to the addition of temporary storage of the model hash values,
> the first image generated after switching to the new model will take more time to calculate the hash value,
> but it will not affect the generation speed afterwards until the server is restarted.
- Add support for pasted images to the `Prompt Reader` node #64
- Update core to [1.3.5](https://github.com/receyuki/stable-diffusion-prompt-reader/releases/tag/v1.3.5)
- Update nodes.py save_images to have %width and %height #66 @COvert96
- Update the `Prompt Reader` node to the new exception handling method
## v1.3.1
> Starting from v1.3, to support auto-detection on Civitai, `calculate_model_hash` will be renamed as
> `calculate_hash` and it will be enabled by default. Due to the addition of temporary storage of the model hash values,
> the first image generated after switching to the new model will take more time to calculate the hash value,
> but it will not affect the generation speed afterwards until the server is restarted.
- Add user-friendly warnings and remove the exception raised during the reading of metadata #58 #63
- Add JPEG to the image extension list
- Fix the issue where the `Prompt Saver` node cannot consume filename from another `Prompt Saver` node #62
- Fix the `Prompt Saver` node freezes workflow when name includes `%model` #61
- Remove ckpt validation of the `Prompt Reader` node #59
## v1.3.0
> Starting from this version, to support auto-detection on Civitai, `calculate_model_hash` will be renamed as
> `calculate_hash` and it will be enabled by default. Due to the addition of temporary storage of the model hash values,
+34 -22
View File
@@ -1,5 +1,5 @@
<div align="center">
<img alt="icon" src="https://github.com/receyuki/stable-diffusion-prompt-reader/raw/master/sd_prompt_reader/resources/icon.png" width=20% height=20%>
<img alt="icon" src="https://github.com/receyuki/stable-diffusion-prompt-reader/raw/master/sd_prompt_reader/resources/icon-cube.png" width=20% height=20%>
<h1>SD Prompt Reader Node</h1>
<a href="https://github.com/receyuki/comfyui-prompt-reader-node/blob/master/LICENSE">
<img alt="GitHub" src="https://img.shields.io/github/license/receyuki/comfyui-prompt-reader-node"></a>
@@ -28,22 +28,27 @@ additional metadata to ensure compatibility with metadata detection on websites
## Supported Formats
| | PNG | JPEG | WEBP | TXT* |
|--------------------------------------------------------------------------|:---:|:----:|:----:|:----:|
| [A1111's webUI](https://github.com/AUTOMATIC1111/stable-diffusion-webui) | ✅ | ✅ | ✅ | ✅ |
| [Easy Diffusion](https://github.com/easydiffusion/easydiffusion) | ✅ | ✅ | ✅ | |
| [StableSwarmUI](https://github.com/Stability-AI/StableSwarmUI)* | ✅ | ✅ | | |
| [Fooocus-MRE](https://github.com/MoonRide303/Fooocus-MRE)* | ✅ | ✅ | | |
| [InvokeAI](https://github.com/invoke-ai/InvokeAI) | ✅ | | | |
| [ComfyUI](https://github.com/comfyanonymous/ComfyUI)* | ✅ | | | |
| [NovelAI](https://novelai.net/) | ✅ | | | |
| [Draw Things](https://drawthings.ai/) | ✅ | | | |
| Naifu(4chan) | ✅ | | | |
| | PNG | JPEG | WEBP | TXT* |
|----------------------------------------------------------------------------------------|:---:|:----:|:----:|:----:|
| [A1111's webUI](https://github.com/AUTOMATIC1111/stable-diffusion-webui) | ✅ | ✅ | ✅ | ✅ |
| [Easy Diffusion](https://github.com/easydiffusion/easydiffusion) | ✅ | ✅ | ✅ | |
| [StableSwarmUI](https://github.com/Stability-AI/StableSwarmUI)* | ✅ | ✅ | | |
| [StableSwarmUI (prior to 0.5.8-alpha)](https://github.com/Stability-AI/StableSwarmUI)* | ✅ | ✅ | | |
| [Fooocus-MRE](https://github.com/MoonRide303/Fooocus-MRE)* | ✅ | ✅ | | |
| [NovelAI (stealth pnginfo)](https://novelai.net/) | ✅ | | ✅ | |
| [NovelAI (legacy)](https://novelai.net/) | ✅ | | | |
| [InvokeAI](https://github.com/invoke-ai/InvokeAI) | ✅ | | | |
| [InvokeAI (prior to 2.3.5-post.2)](https://github.com/invoke-ai/InvokeAI) | ✅ | | | |
| [InvokeAI (prior to 1.15)](https://github.com/invoke-ai/InvokeAI) | ✅ | | | |
| [ComfyUI](https://github.com/comfyanonymous/ComfyUI)* | ✅ | | | |
| [Draw Things](https://drawthings.ai/) | ✅ | | | |
| Naifu(4chan) | ✅ | | | |
See [SD Prompt Reader](https://github.com/receyuki/stable-diffusion-prompt-reader#supported-formats) for details
## Installation
>While ZIP package is available, it is strongly recommended not to use it for installation.
> [!NOTE]
> While ZIP package is available, it is strongly recommended not to use it for installation.
### Install and update via [ComfyUI Manager](https://github.com/ltdrdata/ComfyUI-Manager) (Recommended)
Search for `SD Prompt Reader` in the ComfyUI Manager and install it.
### Install manually
@@ -76,9 +81,11 @@ It uses the Image Data Reader from the
[standalone SD Prompt Reader](https://github.com/receyuki/stable-diffusion-prompt-reader),
allowing it to support the same formats and receive updates along with the
[SD Prompt Reader](https://github.com/receyuki/stable-diffusion-prompt-reader).
- Due to custom nodes and complex workflows potentially causing issues with SD Prompt Reader's ability
to read image metadata correctly, it is recommended to embed the `Prompt Saver` Node within the workflow
to ensure maximum compatibility.
> [!IMPORTANT]
> Due to custom nodes and complex workflows potentially causing issues with SD Prompt Reader's ability
> to read image metadata correctly, it is recommended to embed the `Prompt Saver` Node within the workflow
> to ensure maximum compatibility.
<details>
<summary><b>More Information</b></summary>
@@ -122,16 +129,19 @@ e.g. `sd_xl_base` will be matched with `SDXL\sd_xl_base.safetensors`, and vice v
- The `Prompt Saver` Node will write additional metadata in the A1111 format to the output images
to be compatible with any tools that support the A1111 format,
including SD Prompt Reader and Civitai.
Due to custom nodes and complex workflows potentially causing issues with SD Prompt Reader's ability
- Due to custom nodes and complex workflows potentially causing issues with SD Prompt Reader's ability
to read image metadata correctly, it's recommended to embed this node within the workflow
to ensure maximum compatibility.
- Since it's not possible to directly extract metadata from `KSampler`, it's necessary to
use the `Parameter Generator` Node to generate parameters and simultaneously output them to
the `Prompt Saver` Node and `KSampler` Node.
to ensure maximum compatibility.
> [!TIP]
> Since it's not possible to directly extract metadata from `KSampler`, it's necessary to
> use the `Parameter Generator` Node to generate parameters and simultaneously output them to
> the `Prompt Saver` Node and `KSampler` Node.
<details>
<summary><b>More Information</b></summary>
#### Image Format
- Only PNG format supports embedding both metadata and workflow at the same time. Other formats can only embed metadata.
#### Duplicate Filename
- When the filename already exists, an index will be added at the end of the filename,
e.g. `file.png, file_1.png, file_2.png`.
@@ -175,7 +185,9 @@ from the `%counter` in the built-in `Saver` node, it will count all image files
- Since it's not possible to directly extract metadata from `KSampler`, it's necessary to
use the `Parameter Generator` Node to generate parameters and simultaneously output them to both
the `Prompt Saver` Node and `KSampler` Node.
- The `Parameter Generator` Node can also be used as a control panel for complex ComfyUI workflows, just like the [AP workflow](https://perilli.com/ai/comfyui/).
> [!TIP]
> The `Parameter Generator` Node can also be used as a control panel for complex ComfyUI workflows, just like the [AP workflow](https://perilli.com/ai/comfyui/).
<details>
<summary><b>More Information</b></summary>
+1 -1
View File
@@ -1 +1 @@
VERSION = "1.3.0"
VERSION = "1.3.4"
Binary file not shown.

After

Width:  |  Height:  |  Size: 156 KiB

+122 -26
View File
@@ -2,7 +2,7 @@
@author: receyuki
@title: SD Prompt Reader
@nickname: SD Prompt Reader
@description: ComfyUI node version of the SD Prompt Reader
@description: The ultimate solution for managing image metadata and multi-tool compatibility. ComfyUI node version of the SD Prompt Reader
"""
@@ -30,7 +30,6 @@ import folder_paths
from .stable_diffusion_prompt_reader.sd_prompt_reader.constants import (
SUPPORTED_FORMATS,
MESSAGE,
)
from .stable_diffusion_prompt_reader.sd_prompt_reader.image_data_reader import (
ImageDataReader,
@@ -45,6 +44,15 @@ BLUE = "\033[1;34m"
CYAN = "\033[36m"
RESET = "\033[0m"
ERROR_MESSAGE = {
"format_error": "No data detected or unsupported format. "
"Please see the README for more details.\n"
"https://github.com/receyuki/comfyui-prompt-reader-node#supported-formats",
"complex_workflow": "The workflow is overly complex, or unsupported custom nodes have been used. "
"Please see the README for more details.\n"
"https://github.com/receyuki/comfyui-prompt-reader-node#prompt-reader-node",
}
def output_to_terminal(text: str):
print(f"{RESET+BLUE}" f"[SD Prompt Reader] " f"{CYAN+text+RESET}")
@@ -133,6 +141,8 @@ class SDPromptReader:
def load_image(self, image, parameter_index):
if image in SDPromptReader.files:
image_path = folder_paths.get_annotated_filepath(image)
elif image.startswith("pasted/"):
image_path = folder_paths.get_annotated_filepath(image)
else:
image_path = image
i = Image.open(image_path)
@@ -148,15 +158,28 @@ class SDPromptReader:
file_path = Path(image_path)
if file_path.suffix not in SUPPORTED_FORMATS:
output_to_terminal(MESSAGE["suffix_error"][1])
raise ValueError(MESSAGE["suffix_error"][1])
with open(file_path, "rb") as f:
image_data = ImageDataReader(f)
if not image_data.tool:
output_to_terminal(MESSAGE["format_error"][1])
raise ValueError(MESSAGE["format_error"][1])
if image_data.status.name == "COMFYUI_ERROR":
output_to_terminal(ERROR_MESSAGE["complex_workflow"])
return self.error_output(
error_message=ERROR_MESSAGE["complex_workflow"],
image=image,
mask=mask,
width=i.width,
height=i.height,
filename=file_path.stem,
)
elif image_data.status.name in ["FORMAT_ERROR", "UNREAD"]:
output_to_terminal(ERROR_MESSAGE["format_error"])
return self.error_output(
error_message=ERROR_MESSAGE["format_error"],
image=image,
mask=mask,
width=i.width,
height=i.height,
filename=file_path.stem,
)
seed = int(
self.param_parser(image_data.parameter.get("seed", 0), parameter_index)
@@ -235,6 +258,28 @@ class SDPromptReader:
return model
@staticmethod
def error_output(
error_message, image=None, mask=None, width=0, height=0, filename=""
):
return {
"ui": {"text": ("", "", error_message)},
"result": (
image,
mask,
"",
"",
0,
0,
0.0,
width,
height,
"",
filename,
"",
),
}
@classmethod
def IS_CHANGED(s, image, parameter_index):
if image in SDPromptReader.files:
@@ -245,6 +290,10 @@ class SDPromptReader:
image_data = ImageDataReader(f)
return image_data.props
@classmethod
def VALIDATE_INPUTS(s, image):
return True
class SDPromptSaver:
model_hash_dict = {}
@@ -308,15 +357,15 @@ class SDPromptSaver:
"lora_name": any_type,
"width": (
"INT",
{"default": 1, "min": 1, "max": MAX_RESOLUTION, "step": 8},
{"default": 1, "min": 1, "max": MAX_RESOLUTION, "step": 1},
),
"height": (
"INT",
{"default": 1, "min": 1, "max": MAX_RESOLUTION, "step": 8},
{"default": 1, "min": 1, "max": MAX_RESOLUTION, "step": 1},
),
"positive": ("STRING", {"default": "", "multiline": True}),
"negative": ("STRING", {"default": "", "multiline": True}),
"extension": (["png", "jpg", "webp"],),
"extension": (["png", "jpg", "jpeg", "webp"],),
"calculate_hash": ("BOOLEAN", {"default": True}),
"resource_hash": ("BOOLEAN", {"default": True}),
"lossless_webp": ("BOOLEAN", {"default": True}),
@@ -407,8 +456,10 @@ class SDPromptSaver:
"%seed": seed,
"%steps": steps,
"%cfg": cfg,
"%width": width,
"%height": height,
"%extension": extension,
"%model": model_name_real,
"%model": Path(model_name_real).stem,
"%sampler": sampler_name_real,
"%scheduler": scheduler_real,
"%quality": jpg_webp_quality,
@@ -552,7 +603,14 @@ class SDPromptSaver:
output_to_terminal("Saved file: " + str(file))
comments.append(comment)
return {"ui": {"images": results}, "result": (files, file_paths, comments)}
return {
"ui": {"images": results},
"result": (
self.unpack_singleton(files),
self.unpack_singleton(file_paths),
self.unpack_singleton(comments),
),
}
@staticmethod
def calculate_hash(name, hash_type):
@@ -611,13 +669,13 @@ class SDPromptSaver:
@staticmethod
def get_unique_filename(stem: Path, extension: str, output_folder: Path):
file = stem.with_suffix(f".{extension}")
file = stem.with_suffix(f"{stem.suffix}.{extension}")
index = 0
while (output_folder / file).exists():
index += 1
new_stem = f"{stem}_{index}"
file = Path(new_stem).with_suffix(f".{extension}")
new_stem = Path(f"{stem}_{index}")
file = new_stem.with_suffix(f"{new_stem.suffix}.{extension}")
return file
@@ -634,6 +692,10 @@ class SDPromptSaver:
return ""
@staticmethod
def unpack_singleton(arr: list):
return arr[0] if len(arr) == 1 else arr
class SDParameterGenerator:
ASPECT_RATIO_MAP = {
@@ -726,11 +788,11 @@ class SDParameterGenerator:
),
"width": (
"INT",
{"default": 512, "min": 1, "max": MAX_RESOLUTION, "step": 8},
{"default": 512, "min": 16, "max": MAX_RESOLUTION, "step": 8},
),
"height": (
"INT",
{"default": 512, "min": 1, "max": MAX_RESOLUTION, "step": 8},
{"default": 512, "min": 16, "max": MAX_RESOLUTION, "step": 8},
),
"batch_size": (
"INT",
@@ -807,9 +869,6 @@ class SDParameterGenerator:
output_vae=True,
output_clip=True,
):
if ckpt_name not in SDParameterGenerator.ckpt_list:
raise FileNotFoundError(f"Invalid ckpt_name: {ckpt_name}")
ckpt_path = folder_paths.get_full_path("checkpoints", ckpt_name)
if config_name != "none":
config_path = folder_paths.get_full_path("configs", config_name)
@@ -912,6 +971,10 @@ class SDParameterGenerator:
),
}
@classmethod
def VALIDATE_INPUTS(s, aspect_ratio):
return True
class SDPromptMerger:
@classmethod
@@ -981,6 +1044,30 @@ class SDTypeConverter:
)
class SDAnyConverter:
@classmethod
def INPUT_TYPES(s):
return {
"required": {},
"optional": {
"any_type_input": (
any_type,
{"forceInput": True},
),
},
}
RETURN_TYPES = (any_type,)
RETURN_NAMES = ("ANY_TYPE_OUTPUT",)
FUNCTION = "convert_any"
CATEGORY = "SD Prompt Reader"
def convert_any(self, any_type_input: str = ""):
return (any_type_input,)
class SDBatchLoader:
@classmethod
def INPUT_TYPES(s):
@@ -1135,17 +1222,20 @@ class SDParameterExtractor:
@staticmethod
def parse_setting(settings):
pattern = re.compile(r"([^:,]+):\s*\(([^)]+)\)|([^:,]+):\s*([^,]+)")
pattern = re.compile(r"([^:,]+):\s*\(([^)]+)\)|([^:,]+):\s*\"([^\"]+)\"|([^:,]+):\s*([^,]+)")
matches = pattern.findall(settings)
result = {}
for match in matches:
key, value_paren, key_nonparen, value_nonparen = match
if key:
key = key.strip()
key_paren, value_paren, key_quotes, value_quotes, key_nonparen, value_nonparen = match
if key_paren:
key = key_paren.strip()
value = value_paren.strip()
value = tuple(v.strip() for v in value.split(","))
elif key_quotes:
key = key_quotes.strip()
value = value_quotes.strip()
else:
key = key_nonparen.strip()
value = value_nonparen.strip()
@@ -1153,6 +1243,10 @@ class SDParameterExtractor:
return result
@classmethod
def VALIDATE_INPUTS(s, parameter):
return True
class SDLoraLoader:
def __init__(self):
@@ -1243,6 +1337,7 @@ NODE_CLASS_MAPPINGS = {
"SDParameterGenerator": SDParameterGenerator,
"SDPromptMerger": SDPromptMerger,
"SDTypeConverter": SDTypeConverter,
"SDAnyConverter": SDAnyConverter,
"SDBatchLoader": SDBatchLoader,
"SDParameterExtractor": SDParameterExtractor,
"SDLoraLoader": SDLoraLoader,
@@ -1255,6 +1350,7 @@ NODE_DISPLAY_NAME_MAPPINGS = {
"SDParameterGenerator": "SD Parameter Generator",
"SDPromptMerger": "SD Prompt Merger",
"SDTypeConverter": "SD Type Converter",
"SDAnyConverter": "SD Any Converter",
"SDBatchLoader": "SD Batch Loader",
"SDParameterExtractor": "SD Parameter Extractor",
"SDLoraLoader": "SD Lora Loader",
+15
View File
@@ -0,0 +1,15 @@
[project]
name = "comfyui-prompt-reader-node"
description = "The ultimate solution for managing image metadata and multi-tool compatibility. ComfyUI node version of the SD Prompt Reader."
version = "1.3.4"
license = { text = "MIT License" }
dependencies = ["piexif"]
[project.urls]
Repository = "https://github.com/receyuki/comfyui-prompt-reader-node"
# Used by Comfy Registry https://comfyregistry.org
[tool.comfy]
PublisherId = "receyuki"
DisplayName = "comfyui-prompt-reader-node"
Icon = "https://raw.githubusercontent.com/receyuki/comfyui-prompt-reader-node/main/images/icon-400.png"