Instructions to use saik0s/comfy_backup with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- llama-cpp-python
How to use saik0s/comfy_backup with llama-cpp-python:
# !pip install llama-cpp-python from llama_cpp import Llama llm = Llama.from_pretrained( repo_id="saik0s/comfy_backup", filename="ComfyUI/models/text_encoders/gemma-3-12b-it-q2_k.gguf", )
llm.create_chat_completion( messages = "No input example has been defined for this model task." )
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use saik0s/comfy_backup with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf saik0s/comfy_backup:Q4_K_S # Run inference directly in the terminal: llama cli -hf saik0s/comfy_backup:Q4_K_S
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf saik0s/comfy_backup:Q4_K_S # Run inference directly in the terminal: llama cli -hf saik0s/comfy_backup:Q4_K_S
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf saik0s/comfy_backup:Q4_K_S # Run inference directly in the terminal: ./llama-cli -hf saik0s/comfy_backup:Q4_K_S
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf saik0s/comfy_backup:Q4_K_S # Run inference directly in the terminal: ./build/bin/llama-cli -hf saik0s/comfy_backup:Q4_K_S
Use Docker
docker model run hf.co/saik0s/comfy_backup:Q4_K_S
- LM Studio
- Jan
- Ollama
How to use saik0s/comfy_backup with Ollama:
ollama run hf.co/saik0s/comfy_backup:Q4_K_S
- Unsloth Studio
How to use saik0s/comfy_backup with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for saik0s/comfy_backup to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for saik0s/comfy_backup to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for saik0s/comfy_backup to start chatting
- Pi
How to use saik0s/comfy_backup with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf saik0s/comfy_backup:Q4_K_S
Configure the model in Pi
# Install Pi: npm install -g @mariozechner/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "saik0s/comfy_backup:Q4_K_S" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Hermes Agent new
How to use saik0s/comfy_backup with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf saik0s/comfy_backup:Q4_K_S
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:8080/v1 hermes config set model.default saik0s/comfy_backup:Q4_K_S
Run Hermes
hermes
- Atomic Chat new
- OpenClaw new
How to use saik0s/comfy_backup with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf saik0s/comfy_backup:Q4_K_S
Configure OpenClaw
# Install OpenClaw: npm install -g openclaw@latest # Register the local server and set it as the default model: openclaw onboard --non-interactive --mode local \ --auth-choice custom-api-key \ --custom-base-url http://127.0.0.1:8080/v1 \ --custom-model-id "saik0s/comfy_backup:Q4_K_S" \ --custom-provider-id llama-cpp \ --custom-compatibility openai \ --custom-text-input \ --accept-risk \ --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
- Docker Model Runner
How to use saik0s/comfy_backup with Docker Model Runner:
docker model run hf.co/saik0s/comfy_backup:Q4_K_S
- Lemonade
How to use saik0s/comfy_backup with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull saik0s/comfy_backup:Q4_K_S
Run and chat with the model
lemonade run user.comfy_backup-Q4_K_S
List all available models
lemonade list
| import os | |
| import folder_paths | |
| import json | |
| from server import PromptServer | |
| import glob | |
| from aiohttp import web | |
| def get_allowed_dirs(): | |
| dir = os.path.abspath(os.path.join(__file__, "../../user")) | |
| file = os.path.join(dir, "text_file_dirs.json") | |
| with open(file, "r") as f: | |
| return json.loads(f.read()) | |
| def get_valid_dirs(): | |
| return get_allowed_dirs().keys() | |
| def get_dir_from_name(name): | |
| dirs = get_allowed_dirs() | |
| if name not in dirs: | |
| raise KeyError(name + " dir not found") | |
| path = dirs[name] | |
| path = path.replace("$input", folder_paths.get_input_directory()) | |
| path = path.replace("$output", folder_paths.get_output_directory()) | |
| path = path.replace("$temp", folder_paths.get_temp_directory()) | |
| return path | |
| def is_child_dir(parent_path, child_path): | |
| parent_path = os.path.abspath(parent_path) | |
| child_path = os.path.abspath(child_path) | |
| return os.path.commonpath([parent_path]) == os.path.commonpath([parent_path, child_path]) | |
| def get_real_path(dir): | |
| dir = dir.replace("/**/", "/") | |
| dir = os.path.abspath(dir) | |
| dir = os.path.split(dir)[0] | |
| return dir | |
| async def get_files(request): | |
| name = request.match_info["name"] | |
| dir = get_dir_from_name(name) | |
| recursive = "/**/" in dir | |
| # Ugh cant use root_path on glob... lazy hack.. | |
| pre = get_real_path(dir) | |
| files = list(map(lambda t: os.path.relpath(t, pre), | |
| glob.glob(dir, recursive=recursive))) | |
| if len(files) == 0: | |
| files = ["[none]"] | |
| return web.json_response(files) | |
| def get_file(root_dir, file): | |
| if file == "[none]" or not file or not file.strip(): | |
| raise ValueError("No file") | |
| root_dir = get_dir_from_name(root_dir) | |
| root_dir = get_real_path(root_dir) | |
| if not os.path.exists(root_dir): | |
| os.mkdir(root_dir) | |
| full_path = os.path.join(root_dir, file) | |
| if not is_child_dir(root_dir, full_path): | |
| raise ReferenceError() | |
| return full_path | |
| class TextFileNode: | |
| RETURN_TYPES = ("STRING",) | |
| CATEGORY = "utils" | |
| def VALIDATE_INPUTS(self, root_dir, file, **kwargs): | |
| if file == "[none]" or not file or not file.strip(): | |
| return True | |
| get_file(root_dir, file) | |
| return True | |
| def load_text(self, **kwargs): | |
| self.file = get_file(kwargs["root_dir"], kwargs["file"]) | |
| with open(self.file, "r") as f: | |
| return (f.read(), ) | |
| class LoadText(TextFileNode): | |
| def IS_CHANGED(self, **kwargs): | |
| return os.path.getmtime(self.file) | |
| def INPUT_TYPES(s): | |
| return { | |
| "required": { | |
| "root_dir": (list(get_valid_dirs()), {}), | |
| "file": (["[none]"], { | |
| "pysssss.binding": [{ | |
| "source": "root_dir", | |
| "callback": [{ | |
| "type": "set", | |
| "target": "$this.disabled", | |
| "value": True | |
| }, { | |
| "type": "fetch", | |
| "url": "/pysssss/text-file/{$source.value}", | |
| "then": [{ | |
| "type": "set", | |
| "target": "$this.options.values", | |
| "value": "$result" | |
| }, { | |
| "type": "validate-combo" | |
| }, { | |
| "type": "set", | |
| "target": "$this.disabled", | |
| "value": False | |
| }] | |
| }], | |
| }] | |
| }) | |
| }, | |
| } | |
| FUNCTION = "load_text" | |
| class SaveText(TextFileNode): | |
| OUTPUT_NODE = True | |
| def IS_CHANGED(self, **kwargs): | |
| return float("nan") | |
| def INPUT_TYPES(s): | |
| return { | |
| "required": { | |
| "root_dir": (list(get_valid_dirs()), {}), | |
| "file": ("STRING", {"default": "file.txt"}), | |
| "append": (["append", "overwrite", "new only"], {}), | |
| "insert": ("BOOLEAN", { | |
| "default": True, "label_on": "new line", "label_off": "none", | |
| "pysssss.binding": [{ | |
| "source": "append", | |
| "callback": [{ | |
| "type": "if", | |
| "condition": [{ | |
| "left": "$source.value", | |
| "op": "eq", | |
| "right": '"append"' | |
| }], | |
| "true": [{ | |
| "type": "set", | |
| "target": "$this.disabled", | |
| "value": False | |
| }], | |
| "false": [{ | |
| "type": "set", | |
| "target": "$this.disabled", | |
| "value": True | |
| }], | |
| }] | |
| }] | |
| }), | |
| "text": ("STRING", {"forceInput": True, "multiline": True}) | |
| }, | |
| } | |
| FUNCTION = "write_text" | |
| def write_text(self, **kwargs): | |
| self.file = get_file(kwargs["root_dir"], kwargs["file"]) | |
| if kwargs["append"] == "new only" and os.path.exists(self.file): | |
| raise FileExistsError( | |
| self.file + " already exists and 'new only' is selected.") | |
| with open(self.file, "a+" if kwargs["append"] == "append" else "w") as f: | |
| is_append = f.tell() != 0 | |
| if is_append and kwargs["insert"]: | |
| f.write("\n") | |
| f.write(kwargs["text"]) | |
| return super().load_text(**kwargs) | |
| NODE_CLASS_MAPPINGS = { | |
| "LoadText|pysssss": LoadText, | |
| "SaveText|pysssss": SaveText, | |
| } | |
| NODE_DISPLAY_NAME_MAPPINGS = { | |
| "LoadText|pysssss": "Load Text 🐍", | |
| "SaveText|pysssss": "Save Text 🐍", | |
| } | |