# Image-path reopening audit Date: 2026-08-27 ## Outcome The smallest defensible next experiment is a split-corrected **Z-Image normal-specialist LoRA**. Z-Image is the only currently eligible challenger that already has matched project evidence, a public ungated checkpoint, an explicit publisher licence trail, and an official maintained LoRA implementation. No GPU is authorised by this audit alone; the exact training runner and immutable remote input gate must pass first. ## Candidate audit | Candidate | Current primary-source state | Decision | | --- | --- | --- | | `Tongyi-MAI/Z-Image` | Public, ungated 6B BF16 checkpoint at immutable revision `04cc4abb7c5069926f75c9bfde9ef43d49423021`; Hugging Face metadata declares Apache-2.0. The publisher repository at `26f23eda626ffadda020b04ff79488e1d72004cd` carries Apache-2.0. The publisher describes the undistilled base as LoRA-capable, with CFG and negative prompting. Hugging Face Diffusers at `d57cecde92a6d396845ab35425aa27469dff8173` includes an official Z-Image DreamBooth/LoRA trainer with BF16, cached latents, gradient checkpointing, 8-bit Adam, and FP8 options. The project already measured 23.27 GB peak inference memory and the strongest zero-shot tissue-scale organisation of its M1 pair on A100 40 GB. | **Advance to one bounded normal-only challenger.** | | `DIDSR/HistoGen` | FDA/DIDSR code and checkpoint are CC0-1.0, but the released task is segmentation-mask-to-image synthesis of cell nuclei. It does not provide text-conditioned gastric gland/tissue generation or the required field-level category control. | Eligible rights, wrong task; do not use as the global generator. | | `xuanxu92/ctrPath` | Released 512×512 nuclei-mask-plus-text generator. Repository presentation is internally inconsistent between an MIT statement and an Apache-2.0 licence indicator, and the downloadable checkpoint also depends on Stable Diffusion 1.5 and CtrlLoRA components. Its advertised SuperDiff pathology super-resolution stage is explicitly not released. | Do not enter the submission path until the exact checkpoint/component licence chain and released SR implementation are resolved. | | `bhosalems/PathDiff` | Text/mask-conditioned pathology generator with a Google Drive checkpoint, but the repository presents no explicit licence and describes research/educational use. It also notes that randomly paired conditions may be pathologically implausible. | Exclude from direct submission. | | PixCell / CytoSyn | Pathology-native but previously verified as non-commercial or no-derivatives for the published checkpoints. | Continue to exclude absent written challenge-compatible permission. | Generic natural-image super-resolution is not selected. It can sharpen hallucinated nuclei, vacuoles, or oversized organisms without restoring correct gastric topology. The pathology-specific SuperDiff implementation is not released, and no other audited released SR checkpoint supplies both a clear submission-compatible chain and evidence for gastric H&E at this scale. ## Frozen challenger - **Question:** Can Z-Image's already stronger tissue prior learn corrected normal gastric topology from the exact 32-field slide-disjoint normal corpus where Qwen-Image-2512 failed? - **Model:** `Tongyi-MAI/Z-Image` at `04cc4abb7c5069926f75c9bfde9ef43d49423021`. - **Trainer:** official Hugging Face Diffusers Z-Image LoRA path pinned before deployment; no third-party community trainer. - **Data:** `qwen2512-normal-specialist-slide-disjoint-v2`, 32 exact 1024×1024 RGB images from nine non-held-out slides at 0.25 µm/pixel. The name is historical; the image/caption/provenance bytes are model-independent. - **Training:** BF16 LoRA rank 32, batch one, four epochs, one dataset repeat, learning rate `1e-4`, cached latents, gradient checkpointing, 8-bit Adam, fixed training seed, one whole checkpoint per epoch. - **Validation:** same fixed normal prompt, negative prompt, 1024×1024 geometry, 50 steps, CFG 4.0, and seed 41001 at every whole checkpoint. Compare against the immutable M1 Z-Image zero-shot normal cell, failed corrected Qwen normal checkpoints, and untouched M1 real normal reference. Never mix epochs or cells. - **Automatic gates:** exact revision/config/corpus hashes, four checkpoints and validation cells, 1024×1024 RGB, no NaN/empty outputs, privacy thresholds of DINO cosine below 0.995 and dHash distance above 4 against both corrected corpora, and Sydney-QA feature extraction with status remaining `CALIBRATION_REQUIRED`. - **Engineering gate:** at least one whole checkpoint must improve coherent normal gastric gland/foveolar architecture over the Z-Image zero-shot and Qwen controls without goblet-like/metaplastic clear-cell excess, implausible repetition, pasted structures, or loss of tissue coverage. Sharpness is descriptive, never sufficient. - **Stop rules:** first run is normal-only; do not run IM, gastritis, mixed, canvas generation, or candidate pooling unless a whole normal checkpoint passes. Runner EXIT shutdown, explicit signal failure markers, guest shutdown, GCE STOP, and cumulative S$700 control remain mandatory. ## Evidence boundary This audit establishes an engineering choice, not clinical validity or final legal advice. Sydney-QA, DINO, sharpness, and visual review cannot replace GI-pathologist sign-off. The Z-Image model repository uses Apache-2.0 metadata and its publisher code repository includes an Apache-2.0 licence; the exact frozen submission still requires a final rights review across model, trainer, dataset, and output manifests. ## Reproducible implementation gate The official trainer is wrapped by `scripts/run_zimage_lora_worker.sh`; fixed-checkpoint inference is isolated in `scripts/run_zimage_validation.py`; `scripts/verify_zimage_challenger.py` binds the exact model, trainer, corpus, split, training, and validation configuration; and `gcp-zimage` provides the short bounded control surface. The worker archives the exact model card, publisher licence, Diffusers licence, upstream commits, dependency lock, config, corpus gate, GPU identity, checkpoint hashes, validation manifests, terminal markers, and complete artifact hashes before shutting the guest down. Initial local CPU preflight passed 32 images, nine non-held-out source slides, all exact hashes, and the frozen training/validation contract. Its config SHA-256 was `b758f9dc098ce430f3d5a44a325f65af8b535a582af0e6bc498deb9133abeb74`; this is retained as the launch-time evidence for attempt 1. Attempt 1 (`20260826T231203Z-zimage-normal`) failed before model download or training because the pinned Diffusers commit contains the official Z-Image trainer but not the `requirements_z_image.txt` file referenced by its README. The recovered run has exit code 1 and `RUN_FAILED`; no checkpoint or validation image exists. The correction follows the exact trainer's embedded PEP 723 dependency declaration, excludes unused Prodigy, preserves the CUDA image's Torch/torchvision pair, and pins the direct requirement envelope in `requirements/zimage_trainer_d57cecde.txt` at SHA-256 `336da007b4dcb72d542b793e2888c32a97196c7e05df64ff2a496ec5c85d51d1`. The corrected immutable config SHA-256 is `6a3c66826c7d8cb937a6c1d0c66edf468d195cc16a57aa08ad9e0a8eadc43cf1`. Local preflight passes again. No scientific variable changed. Attempt 2 (`20260827T001927Z-zimage-normal`) also failed before model download or training. The corrected trainer envelope installed, but Diffusers import reached Transformers' audio utilities and loaded the image's ABI-incompatible `torchaudio 2.11.0+cu129` against `torch 2.9.1+cu129`; `_torchaudio.abi3.so` failed on undefined symbol `torch_library_impl`. The recovered run has exit code 1 and `RUN_FAILED`; no checkpoint or validation image exists. Its `worker.log` SHA-256 is `7ddf12c2116bf07f1448c31d637f14e5def61758ec1295f90e5713e4d8b6092b`. The second minimal correction pins the exact compatible CUDA 12.9 trio used by the successful project runners: `torch 2.9.1+cu129`, `torchvision 0.24.1+cu129`, and `torchaudio 2.9.1+cu129`. The lock at `requirements/zimage_torch_runtime_cu129.txt` has SHA-256 `e5359bf567d77ad8c502696cf8e3caf6605471d77ee398e913024ec9cf2bd082`; the worker installs it from the official PyTorch wheel index and asserts every version before any model download. Corrected config SHA-256 is `c443d7a646315c428ed3b000bd0c3922ac243eedda6cf97c0172dea89eab272f`. The model, data, training schedule, prompts, seed, validation, and gates remain frozen. Attempt 3 (`20260827T010003Z-zimage-normal`) successfully passed the corrected runtime/import/input gates and downloaded the exact model revision, but failed before training because Accelerate 1.14.0 rejects the literal `--report_to none` as an unsupported tracker. Its recovered exit code is 1 with `RUN_FAILED`; there is no checkpoint or validation image. `worker.log` SHA-256 is `2b654ab5c18fa528c55f74419003ed5a5d31df218fcf2a8b6eb072cb3f024960`. The smallest correction uses the already installed, local-only supported `tensorboard` tracker and freezes `report_to` in the immutable config. Corrected config SHA-256 is `ce6319bc8fc2e21dba72e63401bd48c21d6c892c648755e19871e62ea4a581d3`. No scientific variable changed. Attempt 4 (`20260827T013450Z-zimage-normal`) is the first valid scientific run: exit code 0, four whole LoRAs, four fixed validation cells, and all local integrity/privacy gates pass. Full-resolution review rejects every checkpoint. Step 32 mostly preserves the zero-shot composition, while steps 64-128 increase elongated-lumen repetition, stain drift, and simplified cellular topology rather than converging on the untouched local normal gastric reference. No category or pool advances. Full evidence is in `reports/ZIMAGE_NORMAL_CHALLENGER_V1_REPORT.md`. The only authorised follow-up is the inference-only exact-caption alignment in `config/zimage_normal_prompt_alignment_v1.json`: same model, four checkpoint hashes, negative prompt, seed, dimensions, sampler settings, and controls, with the positive prompt changed to the byte-identical caption used by every training record. If that single aligned prompt does not rescue one whole checkpoint, close the Z-Image LoRA path. That exact-caption run completed and failed. All four cells generated pseudo-label text containing the scale/caption language, violated the no-text mechanical gate, and showed stacked or mirrored papillary tissue with extreme repetition rather than local normal gastric topology. The Z-Image LoRA path is closed under its preregistered stop rule. Full evidence is in `reports/ZIMAGE_NORMAL_PROMPT_ALIGNMENT_REPORT.md`. The remaining measured eligible challenger is FLUX.2 Klein Base 4B at the immutable M1 model revision `a3b4f4849157f664bdbc776fd7453c2783562f4d`. Its zero-shot cells were weaker than Z-Image, so it is not presumed superior. It advances only to an implementation/licence audit because the 4B base is Apache-2.0, Black Forest Labs explicitly positions it for fine-tuning, and official Diffusers now includes `train_dreambooth_lora_flux2_klein.py`. A separate frozen normal-only preregistration is required before GPU start. The audit is now complete at the CPU/documentation level. The exact model card and license at the M1 revision are Apache-2.0. Publisher repository commit `50fe5162777813d869182b139e83b10743caef15` identifies the 4B Base as the limited-hardware fine-tuning model and carries an Apache-2.0 repository license. Official Diffusers commit `ec94eec6cabd536c44c77647038303e96ab9355b` contains the dedicated Klein DreamBooth LoRA trainer, documents local Qwen text encoding, CPU offload, latent caching, gradient checkpointing, 8-bit Adam, and NF4 quantization, and is itself Apache-2.0. Exact upstream artifact hashes are frozen in `manifests/flux2_klein_challenger_upstream.csv`. The official FP8 example is not eligible on the A100 40 GB because the documentation requires compute capability 8.9 or later; A100 is 8.0. The same official trainer explicitly supports bitsandbytes NF4 as the older-card alternative. `config/flux2_klein_normal_challenger_v1.json` therefore freezes one normal-only 1024px NF4 rank-32 run using the corrected 32-field corpus, the exact training caption, four whole epoch checkpoints, and the same seed and full-resolution/held-out/privacy gates. This is only a preregistration. GPU start remains prohibited until the exact runner, validation code, dependency import test, local gate, remote immutable gate, and three independent shutdown layers pass. The bounded FLUX.2 Klein run then completed successfully and produced four intact whole LoRAs and four fixed validation cells. Integrity, rights-evidence capture, split, dimensions, runtime, and both privacy screens pass. Full-resolution review rejects all four checkpoints: each preserves or rearranges the zero-shot model's repetitive micro-rosette/oval shortcut and lacks credible normal gastric nuclei, epithelium, lamina propria, and gland diversity. The preregistered stop rule closes FLUX.2 Klein category, canvas, and pool expansion. Full evidence is in `reports/FLUX2_KLEIN_NORMAL_CHALLENGER_V1_REPORT.md`. The corrected Qwen, Z-Image, and FLUX.2 general-image LoRA routes have therefore all failed the same frozen normal-only gate. Further GPU work is prohibited until a new CPU/source audit identifies a released pathology-native generator or pathology-specific super-resolution system with an explicit submission-compatible model, code, and component licence chain. Generic super-resolution is not an eligible fallback because it can sharpen incorrect topology without restoring it. That follow-on audit is now complete. No released route passes rights, exact-checkpoint, gastric whole-tissue, privacy-safe conditioning, and bounded A100 gates together, so no new GPU experiment is authorised. The exact candidate matrix and source ledger are in `reports/PATHOLOGY_NATIVE_ROUTE_AUDIT.md`. Primary sources: - https://huggingface.co/Tongyi-MAI/Z-Image - https://github.com/Tongyi-MAI/Z-Image - https://github.com/huggingface/diffusers/blob/main/examples/dreambooth/README_z_image.md - https://huggingface.co/didsr/HistoGen - https://github.com/DIDSR/HistoGen - https://github.com/xuanxu92/ctrPath - https://github.com/bhosalems/PathDiff