# Gynoid Creation Core

Creation Core is a Windows-first, downloadable local artwork workspace. It runs independently of the
Drakima website and uses the creator PC's existing ComfyUI/Qwen Image 2.1 installation. Its projects,
prompts, generation receipts, candidates and approved PNGs stay on that PC. It has no website account,
database, credit or publication dependency. Importing, reviewing, Drakima cleanup and exporting remain
available without ComfyUI; AI generation needs the local provider and suitable hardware.

## Creator workflow

Download the portable Windows x64 ZIP from `/CreationCore`, extract it and launch
`Drakima.GynoidCreationCore.exe`. The app opens its local browser interface at `http://127.0.0.1:5288`.
The package includes the .NET runtime, Drakima's approved Akari backdrop, Orbitron and an OFL-licensed
VT323 pixel font. Fonts and imagery do not depend on a website/CDN connection. Model weights and
ComfyUI are separate prerequisites; use Stability Matrix or the existing ComfyUI launcher.

1. **Projects:** record a concept, identity, lore and art direction without creating a website Gynoid.
2. **Local setup:** choose a local workspace and verify ComfyUI nodes and selected Qwen Image 2.1 model files.
3. **Create artwork:** generate characters, rooms, seats and props; use reference edits for expressions,
   rear views, reactions and lift poses. Optional batches append up to 20 separate variation instructions.
4. **Review and refine:** compare source/results, inspect transparency on light/dark/checkered previews,
   mark candidates approved/rejected, and reuse references. Drakima cleanup and Qwen removal both create
   new candidates. Neither silently overwrites the source.
5. **Export:** choose approved PNGs and optionally include prompts/seeds/model names in a portable ZIP.

The export includes a versioned `creation-core.json` manifest with names, roles, dimensions and hashes.
Sources, rejected candidates and physical paths are excluded. PNGs can be used in personal projects.
For Drakima, extract the ZIP and upload selected PNGs through the Gynoid Wizard or VN Maker's existing
asset forms; assign them and complete the normal review/publication workflow. Automated ZIP ingestion
and VN Maker generation-tool replacement are not part of this initial release. Model/reference licenses
still apply. The initial Windows preview is unsigned.

## Local boundaries and recovery

The executable binds IPv4 loopback only. Host/Origin validation and a per-launch write nonce prevent
remote browser origins from changing local projects. The provider address is restricted to
`http://127.0.0.1:PORT`; outbound HTTP disables redirects and proxies. No cloud-generation fallback exists.
The Qwen adapter builds a versioned current-model graph; the retired VN generation adapter is not used.

Settings live in the creator's local application-data folder. The default workspace is
`GynoidCreationCore` under their user profile. Each project contains its own assets, jobs and exports.
An exclusive filesystem lease prevents two instances writing one workspace. Atomic `.pending` files
are transient writes, not backup sets. Network/reparse-point workspace roots are rejected. Authors
should choose an unsynced local folder and close the app before moving/deleting project directories.

The app submits one job at a time and bounds the local queue to 24 active jobs. It stores provider IDs
and polls existing execution history after restart. If the provider never acknowledged submission,
manual review is required; the app does not regenerate implicitly. ComfyUI history and its normal
input/output files must remain available until collection. Queued cancellation targets only that job;
running renders are interrupted through ComfyUI. Removing/resetting ComfyUI history can require manual
output recovery. The app never clears ComfyUI's shared queue or deletes another tool's media.

## Packaging and website delivery

Build with `DrakimaCore.Full.slnx`; the everyday website solution does not launch this desktop tool.
Run `scripts/Publish-GynoidCreationCore.ps1 -OutputDirectory <external-release-directory>` to produce a
self-contained Windows x64 ZIP and SHA-256 release manifest. The script refuses an existing version,
uses bounded OS-temp staging, and excludes website Runtime/database dependencies. It does not publish
to a remote service. Install the ZIP and `release.json` together under the configured media root's
`downloads/gynoid-creation-core` folder to enable the website download. The public route shows an
unavailable state if that release is absent or incomplete. The interface displays its compiled release version.

Source owners: `Libraries/Drakima.CreationCore.Application` for neutral recipes/contracts;
`Libraries/Drakima.CreationCore.Infrastructure` for provider, files, queue and processing;
`Tools/Drakima.GynoidCreationCore` for the local UI/HTTP host; `CreationCoreDownloadService` and the
Public Web controller for website distribution. Tests live in `Tests/Drakima.CreationCore.Tests` and
`Tests/JavaScript/creation-core-recipes.test.mjs`. These projects have no dependency on Runtime.

See [verification](verification.md) and the [tool README](../../Tools/Drakima.GynoidCreationCore/README.md).
Provider references: [Qwen Image 2.1](https://docs.comfy.org/tutorials/image/qwen/qwen-image-2-1) and
[ComfyUI API](https://docs.comfy.org/development/comfyui-server/comms_routes).

## Initial preview acceptance

The 0.1.0 Windows preview was exercised on 2026-09-27 with local Qwen Image 2.1 int8 models and an
RTX 5090. A 3:4 chair image completed text-to-image, reference editing and both background-removal
paths. Browser approval and ZIP export succeeded, and project/job receipts survived an application
restart without another submission. The extracted self-contained executable also imported, cleaned,
reviewed and exported a PNG with its ComfyUI endpoint unavailable. These checks validate the local
pipeline, not the artistic consistency of every possible character batch.

Desktop and 390-pixel layouts were checked with the bundled Akari backdrop and local fonts. The PNG
bundle was inspected for excluded source images, prompts and machine paths with provenance disabled.
The website download controller has regression coverage for unavailable, incomplete and invalid release
pointers. Website import remains the existing manual PNG upload workflow; this preview adds no automatic
importer or publication path.
