Userscript · NovelAI Image Generation

A prompt studio,
injected into NovelAI.

Templates, placeholders, framing presets, and a batch queue — all overlaid on novelai.net/image. Save prompts you reuse, run permutations automatically, count T5 tokens and Anlas in real time.

Free & MIT No telemetry Requires Tampermonkey · Chrome / Firefox / Edge / Safari
Templates Save snippets, link a negative prompt, apply with ⌘↵
Live counters T5 tokens and Anlas cost, auto-detected from the live NovelAI DOM
What you get

Eight primitives, one panel

Every feature lives behind a single keyboard-driven surface. Nothing leaves your browser; everything persists across reloads.

Templates

Save and reuse prompt snippets. Organize by category, link a negative prompt, apply with one click or ⌘↵.

Placeholders

Define typed slots like {artist}, {character}, {style}. Multi-select to expand all combinations into the queue.

Batch Queue

Auto-generate every permutation of templates × placeholders. Configurable delay. Resumable across page reloads.

Randomizer

Inline syntax ||red|blue|green|| expands into separate queue entries — combinatorial without scripts.

Framing Presets

15 named composition bundles — close-up portrait, dutch angle, dynamic action — each appends 2–4 tags.

Negative Templates

A separate library of negatives. Link any positive template to one and use Pos+Neg to apply both at once.

Token & Anlas Counter

Live ~N/512 T5 estimate and per-image Anlas cost — Vibe Transfer, Precise Ref, and Opus plan auto-detected.

Quality Tag Presets

Pick a model preset (V4.5 Full, V4.5 Curated, V4, V3) and insert the right quality tags with one click.

⌘K Command Palette

Apply, queue, switch tabs, jump to a template — every action reachable from one fuzzy-search input.

How it works

Two minutes, end to end

Ekphrasis ships as a single userscript file with no build step. Tampermonkey loads it, the panel mounts on novelai.net/image, and that's it.

01 → Install
1

Add Tampermonkey

Install the Tampermonkey extension for your browser. It's the runtime that loads the userscript.

2

Click Install Ekphrasis

Tampermonkey intercepts .user.js and shows a confirm screen. Hit Install.

manual Tampermonkey dashboard → Create new script → paste contents of ekphrasis.user.js.
3

Open NovelAI

Visit novelai.net/image. The panel mounts on the right side. Press ? in the header for in-panel reference.

02 → Use
4

Save your first template

Click + new on the Templates tab. Paste a prompt you reuse — the prompt field accepts NovelAI weight syntax verbatim.

5

Add placeholders

On the Placeholders tab, define a type like artist and add a few values. Reference it in any template as {artist}.

tip Multi-select values to generate every combination via the queue.
6

Apply or queue

Hit ⌘↵ to apply now, or + Queue to append. The queue resumes after reload — close the tab without losing state.

7

Watch the counters

Footer strips show live T5 token count and Anlas cost. Green ≤ 400 tokens, yellow up to 480, red beyond.

Already installed?

Press ? in the panel header for the in-app weight, randomizer, and placeholder reference.

Install Ekphrasis Changelog
Syntax cheatsheet

Three small grammars

Everything Ekphrasis adds to NovelAI's prompt language. Plain text passes through untouched.

Weight

V4.5

Numerical multipliers on a single tag. Negative values suppress.

1.5::tag::
0.8::tag::
-0.5::tag::
Legacy still works: {tag} = ×1.05 per pair, [tag] = ÷1.05.

Randomizer

queue

Pipe-separated alternatives. Each combination becomes a queue entry.

||red|blue|green||
||red|blue|| hair, ||smiling|neutral|| 4 combinations queued
Combinatorial — multiple randomizers in one template multiply.

Placeholders

typed

Named slots resolved from the Placeholders tab at queue time.

1girl, {artist}, {eyes}
{artist} = ["wlop", "guweiz"] {eyes} = ["blue", "red"] 4 prompts queued
Multi-select on the Placeholders tab to generate every combination.
FAQ

Common questions

If something here doesn't answer it, open an issue with your browser, Tampermonkey version, and the Ekphrasis version from the panel footer.

01 Is this affiliated with NovelAI?

No. Ekphrasis is an independent open-source userscript. It runs entirely in your browser, modifies the page locally, and uses NovelAI's existing prompt field — no API, no key, no data leaves your machine.

02 Where is my data stored?

In Tampermonkey's extension storage, scoped to the script. Three documents:

ekphrasis.library.v4 holds your templates, placeholders, and categories. ekphrasis.settings.v4 holds preferences. ekphrasis.session.v4 holds the resumable queue and last-used template.

Export and import are plain JSON via the Settings tab.

03 Why does it sometimes break after a NovelAI update?

The script locates NovelAI's prompt textarea and generate button via DOM selectors. When NovelAI changes their HTML structure those selectors can drift. Open an issue with the broken element noted in DevTools and a fix usually ships the same week.

04 How does the queue handle rate limits?

It polls the page once per second and only fires the next generation after the previous one completes. A configurable inter-generation delay sits on top of that — bump it to 5–10s if you're hitting limits.

Known bug: queue processing can become slower when the NovelAI tab is in the background (for example while alt-tabbing away). Keeping NovelAI visible side-by-side (multi-window) or in the active window is typically faster; many runs average around ~10 seconds per generated image.

Network failures aren't auto-retried. Failed items stay in the queue marked failed so you can retry them manually.

05 What's the Anlas cost calculator actually counting?

Per-image cost based on your active model and modifiers: V4.5 Full base, +5 Anlas per Precise Reference image, +2 Anlas per Vibe Transfer beyond the first four (the first four are free). With Opus plan toggled on, V4.5 Full base drops to 0.

Vibe Transfer count, Precise Reference count, and Opus plan status are auto-detected from the live NovelAI DOM via polling and a MutationObserver.

06 Can I migrate my old nai_ext_* data?

Yes — automatically on first run. Legacy v3 keys are read, mapped to the v4 schema, and left in place for rollback safety. Import on the Settings tab also accepts full v4 libraries, partial bundles, and legacy v3 exports.

07 Does it work with Violentmonkey or Greasemonkey?

Tampermonkey is the primary target. Violentmonkey works in practice — both implement the GM_getValue / GM_setValue APIs Ekphrasis relies on. Greasemonkey 4 is unsupported (its API split makes the storage layer awkward).

08 Is there a keyboard-only flow?

Yes. ⌘K opens the command palette; every action in the panel — apply, queue, switch tab, jump to a template — is reachable from there. ⌘↵ applies the selected template. ? opens in-panel reference.