explaingit

hammonda100/sd-webui-token-weight-sliders

Analysis updated 2026-05-18

0JavaScriptAudience · vibe coder

TLDR

A Stable Diffusion WebUI extension that adds sliders for weighting individual prompt phrases, with optional MIDI hardware control.

Mindmap

mindmap
  root((repo))
    What it does
      Per phrase weight sliders
      Auto rewrites prompt
      Reset to plain text
    Tech stack
      JavaScript
      Web MIDI API
    Use cases
      Prompt fine tuning
      Physical MIDI control
      Faster iteration
    Audience
      Image generation users
      Vibe coders
    Requirements
      Chrome or Edge
      AUTOMATIC1111 or ReForge

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Fine-tune how strongly each phrase in an image prompt influences the output.

USE CASE 2

Drag sliders instead of manually typing weight syntax into prompts.

USE CASE 3

Map a Korg nanoKONTROL2 MIDI controller to control prompt weights physically.

What is it built with?

JavaScript

How does it compare?

hammonda100/sd-webui-token-weight-slidersabhishek-akkal/finovaadan-shahid/ecommerce_website
Stars000
LanguageJavaScriptJavaScriptJavaScript
Setup difficultyeasymoderate
Complexity1/53/5
Audiencevibe coderdeveloperdeveloper

Figures from each repo's GitHub metadata at analysis time.

In plain English

This is an extension for AUTOMATIC1111 and ReForge, two popular web-based interfaces used to run AI image generation models locally. The extension adds per-token weight controls, a more hands-on way to fine-tune how specific words in your image prompt influence the generated picture. Normally, when you write a prompt like "a sunny beach, calm waves, golden sand," every phrase has equal influence on the output. By adding weights using a special syntax like (sunny beach:1.3), you can tell the model to pay more or less attention to that particular phrase. This extension automates that process: as soon as you type a comma-separated prompt, a panel of sliders appears beneath it, one slider per phrase. Dragging a slider automatically rewrites the prompt with the appropriate weight syntax. There's also a reset button to strip all weights back to plain text. The distinctive extra feature is MIDI hardware integration. If you own a Korg nanoKONTROL2, a small USB MIDI controller with physical sliders and knobs, you can map its controls directly to the token weight sliders. The physical sliders control the first eight prompt phrases, the knobs control the next eight, and you can switch between banks of 16 tokens at a time using the controller's Solo buttons. A pickup mode prevents sudden jumps when switching banks. The extension is written in JavaScript and requires a browser that supports the Web MIDI API, which in practice means Chrome or Edge. It installs by copying a folder into the WebUI extensions directory.

Copy-paste prompts

Prompt 1
Show me how to install this extension into my AUTOMATIC1111 or ReForge setup.
Prompt 2
Explain how the token weight slider syntax maps to prompt phrases.
Prompt 3
Help me set up MIDI mapping for a Korg nanoKONTROL2 with this extension.
Prompt 4
Write a guide for using pickup mode when switching between token banks.

Frequently asked questions

What is sd-webui-token-weight-sliders?

A Stable Diffusion WebUI extension that adds sliders for weighting individual prompt phrases, with optional MIDI hardware control.

What language is sd-webui-token-weight-sliders written in?

Mainly JavaScript. The stack also includes JavaScript.

Who is sd-webui-token-weight-sliders for?

Mainly vibe coder.

Open on GitHub → Explain another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.