From 7ec2c5e3f3e5612d86c624cfbe4c449334fbe044 Mon Sep 17 00:00:00 2001 From: smthemex <138738845+smthemex@users.noreply.github.com> Date: Sun, 7 Apr 2024 20:11:21 +0800 Subject: [PATCH] Add files via upload --- __init__.py | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 __init__.py diff --git a/__init__.py b/__init__.py new file mode 100644 index 0000000..f3e6953 --- /dev/null +++ b/__init__.py @@ -0,0 +1,25 @@ +import os +import sys +import json + +python = sys.executable + +# create config +if not os.path.isfile(os.path.join(os.path.dirname(os.path.realpath(__file__)),"config.json")): + config = { + "Zpai_API_KEY": "your key" + } + with open(os.path.join(os.path.dirname(os.path.realpath(__file__)),"config.json"), "w") as f: + json.dump(config, f, indent=4) + +#load config +with open(os.path.join(os.path.dirname(os.path.realpath(__file__)),"config.json"), "r") as f: + config = json.load(f) + + +from .ChatGLM4_API_Node import NODE_CLASS_MAPPINGS, NODE_DISPLAY_NAME_MAPPINGS + +# Combine the dictionaries +#NODE_CLASS_MAPPINGS = {**NODE_CLASS_MAPPINGS_G} + +__all__ = ['NODE_CLASS_MAPPINGS', 'NODE_DISPLAY_NAME_MAPPINGS']