Skip to content

feat: support NovelAI Diffusion V5 image generation - #1606

Open
SameDesu123 wants to merge 3 commits into
kwaroran:mainfrom
SameDesu123:feat/novelai-v5-core
Open

feat: support NovelAI Diffusion V5 image generation#1606
SameDesu123 wants to merge 3 commits into
kwaroran:mainfrom
SameDesu123:feat/novelai-v5-core

Conversation

@SameDesu123

Copy link
Copy Markdown
Contributor

PR Checklist

  • Required Checks
    • Have you added type definitions?
    • Have you tested your changes?
    • Have you checked that it won't break any existing features?
  • If your PR uses models1, check the following:
    • Have you checked if it works normally in all models?
    • Have you checked if it works normally in all web, local, and node-hosted versions? If it doesn't, have you blocked it in those versions?
  • If your PR is highly AI generated2, check the following:
    • Have you understood what the code does?
    • Have you cleaned up any unnecessary or redundant code?
    • Is it not a huge change?
      • We currently do not accept highly AI generated PRs that are large changes.

Summary

Add the core request contracts required for NovelAI Diffusion V5 Full and Curated image generation while preserving the existing V4 and V4.5 paths.

Related Issues

None.

Changes

  • Add a dedicated NovelAI image request builder with V5 model capability detection.
  • Send V5 requests with the V5 parameter version, prompt hints, supported feature set, and PNG output contract.
  • Normalize V5 resolutions to 64-pixel steps and keep generation area within the 3 Mi-pixel limit.
  • Support the V5 text-to-image and image-to-image request fields.
  • Prevent unsupported legacy Vibe Transfer, Character Reference, Variety+, and noise-schedule behavior from leaking into V5 requests.
  • Add focused tests for V5 Full, V5 Curated, image-to-image, resolution fitting, prompt formatting, character coordinates, transparency, and the preserved V4.5 contract.

Impact

Users can use the existing NovelAI V5 Full and Curated model selections for image generation instead of sending those models the legacy request shape. Existing NovelAI V4, V4.5, V3, and V2 request behavior remains supported.

This PR provides the core request layer only. Dedicated UI controls for V5 quality presets, UC presets, transparent backgrounds, and multi-character positioning are not exposed yet.

Additional Notes

Validated with the focused NovelAI image test suite (11 tests), pnpm check, and git diff --check. Authenticated generation against the live NovelAI service and packaged desktop runtime validation have not been performed.

Footnotes

  1. Modifies the behavior of prompting, requesting, or handling responses from AI models.

  2. Over 80% of the code is AI generated.

@SameDesu123
SameDesu123 marked this pull request as ready for review August 28, 2026 11:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant