npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@lowwattlabs/lfit

v1.0.3

Published

⚡ LFIT — Local Free Image Tool. Local HD image generation via stable-diffusion.cpp on Vulkan/iGPU. Free, private, on your hardware.

Downloads

62

Readme

⚡ LFIT — Local Free Image Tool

Local HD image generation. Free. Private. On your hardware.

LFIT runs stable-diffusion.cpp on your Vulkan-capable GPU. No cloud API keys, no per-image fees, no data leaving your machine. Three locked presets — pick by name, get consistent results.

Two tools, both free:

  • lfit-quick — Pollinations cloud FLUX, ~1.4s. Fast drafts and iteration. Lower fidelity, public service.
  • lfit — Local sd-server on your Vulkan GPU. HD, private, real assets. Pick a preset, get a PNG.

Install

npm install -g @lowwattlabs/lfit

Quick Start

# 1. Set up the server (first time only — downloads binary, verifies model/LoRA files)
lfit-server setup

# 2. Start the server
lfit-server start            # foreground
lfit-server start --daemon   # background

# 3. Generate
lfit --preset standard --prompt "a knight at a castle gate"
lfit --preset background --prompt "misty pine valley at dawn"
lfit --preset hero --prompt "ancient dragon, key art" --yes

# 4. Quick drafts (no server needed)
lfit-quick --prompt "neon cyberpunk alley, game key art"

The Three Presets

| Preset | Use for | Size | Steps | LoRA | Time | |--------|---------|------|-------|------|------| | standard (default) | Characters, items, single subjects | 1024×1024 | 8 | 8-step Lightning | ~2.5 min | | background | Scenes, environments, wallpapers, tiles | 1344×768 | 8 | 8-step Lightning | ~2.5 min | | hero | Final/max-quality key art | 1024×1024 | 32 | None (base SDXL) | ~13 MINUTES |

  • Default to standard. Use background for any scene/environment.
  • hero requires --yes flag — it takes ~13 minutes and blocks the server queue.
  • background auto-appends deep-focus phrasing unless you pass --shallow-dof.

How LoRA Actually Works (read this)

The sd-server intentionally ignores <lora:...> prompt tags. Writing <lora:sdxl_lightning_8step_lora:1.0> into the prompt does nothing — it passes through as literal text and you get base SDXL at 8 steps = blurry mush.

The LoRA is applied via a structured "lora" JSON field in the txt2img request. lfit does this automatically per preset. You do not hand-build payloads or call the server directly — just run lfit.

The server's LoRA path-cache is built only on GET /sdapi/v1/loras. lfit warms it automatically before each generation. Without this warm-up, a freshly-restarted server rejects the LoRA path with "invalid lora path."

hero sends no LoRA field → pristine base SDXL with no cumulative drift.


Self-Check: How to Tell It's Working

  • A correct standard/background image is SHARP. If output is soft/hazy/mushy, the LoRA did not apply — that is a failure, not "just how it looks."
  • lfit detects LoRA failure two ways:
    1. Small output warning — image data under 1000 bytes
    2. Fast completion warning — standard/background finishing under 30 seconds means LoRA didn't apply
  • Verify manually: curl -s http://127.0.0.1:7860/sdapi/v1/loras — should list sdxl_lightning_8step_lora

What Was Fixed (2026-05-31)

Before the fix, standard/background were silently running base SDXL at 8 steps because the server ignores prompt-tag LoRAs. The fix: lfit sends the structured "lora" field and warms the path-cache.

--lora-apply-mode at_runtime applies the LoRA non-destructively per request, so no-LoRA requests (hero) get pristine base SDXL with zero cumulative drift. The default immediately mode merges into the f16 weights; the apply/remove round-trip drifts ~0.55/255 and accumulates on a long-running server.


Server Management

lfit-server setup              # Download binary, verify model/LoRA files
lfit-server status             # Check if server is running
lfit-server start              # Start (foreground)
lfit-server start --daemon     # Start (background)
lfit-server stop               # Stop running server

API endpoint: http://127.0.0.1:7860 — A1111-compatible: POST /sdapi/v1/txt2img, GET /sdapi/v1/loras

Check LoRAs: curl -s http://127.0.0.1:7860/sdapi/v1/loras

Server flags (set by lfit-server start automatically):

sd-server \
    --listen-ip 127.0.0.1 --listen-port 7860 \
    --model /path/to/sd_xl_base_1.0.safetensors \
    --lora-model-dir /path/to/loras/ \
    --type f16 --vae-tiling --lora-apply-mode at_runtime

Key flags:

  • --lora-apply-mode at_runtime — Applies LoRA non-destructively per request. No-LoRA requests get pristine base SDXL with zero drift.
  • --vae-tiling — Avoids VAE OOM at 1024+ resolutions on smaller VRAM GPUs.
  • --type f16 — Keeps memory usage sane for UMA/integrated GPUs.

Telegram push (optional): Set TELEGRAM_BOT_TOKEN and TELEGRAM_CHAT_ID in your environment. Images auto-push on generation. Pass --no-telegram to skip.


Environment Variables

| Variable | Default | Description | |----------|---------|-------------| | LFIT_SERVER_URL | http://127.0.0.1:7860 | sd-server URL | | LFIT_MODEL_DIR | ~/.lfit/models/ | SDXL model directory | | LFIT_LORA_DIR | ~/.lfit/models/loras/ | LoRA directory | | LFIT_OUT_DIR | ~/.lfit/output/ | Output directory | | LFIT_SD_BIN | ~/.lfit/bin/sd-server | sd-server binary path | | LFIT_ENV_FILE | (none) | Env file for Telegram credentials |


Troubleshooting

Image is blurry/soft/mushy on standard or background → The LoRA did not apply. This is the #1 failure mode. Check:

  1. curl -s http://127.0.0.1:7860/sdapi/v1/loras — should list sdxl_lightning_8step_lora
  2. If the lora list is empty, restart the server with --lora-model-dir pointing to the correct directory
  3. Generation completed in under 30 seconds? That's base SDXL at 8 steps — way too fast for LoRA mode

"invalid lora path" error → The server's path-cache is stale. Restart the server, or trigger a cache refresh with GET /sdapi/v1/loras.

Vulkan OOM at 1024+ → Add --vae-tiling to the server flags. Without it, the VAE allocates a single ~4.8GB buffer at 1024+.

Server not found / connection refused → Is sd-server running? Check with curl -s http://127.0.0.1:7860/sdapi/v1/loras. Start it with lfit-server start or manually.

Very slow generation on hero → Expected. Hero runs 32 steps of full base SDXL with no LoRA. ~13 minutes on a mid-range iGPU.

Requirements

  • Python 3.8+
  • Vulkan-capable GPU with suitable drivers (minimum 4GB VRAM for standard/background, 8GB recommended for hero)
  • stable-diffusion.cpp server binary (sd-server) with Vulkan support compiled in
  • SDXL base 1.0 model file (sd_xl_base_1.0.safetensors) — download from HuggingFace
  • SDXL Lightning 8-step LoRA — download from HuggingFace

If LFIT saves you time or makes you money, buy us a coffee.

Also by Low Watt Labs

  • ⚡ Frisk — Catch leaked credentials and supply-chain threats in ClawHub skills before you install. GitHub · npm · ClawHub
  • 🪙 HOARD — Durable agent memory that survives session resets. GitHub · npm · ClawHub