skill: capture scene-note discipline and fix Arrival/passport packaging
BetterLeaks / scan (push) Failing after 46s
BetterLeaks / scan (push) Failing after 46s
Document explicit write-down requirement for Undressed room + antechamber scene descriptors. Fix Arrival overview packaging to emit All/Men/Ladies (including stairs inference from legacy A4-C6 numbering) and remove stale generic outputs. Switch passport output to Name.jpg (drop nn- prefix) while cleaning legacy numbered files for future reruns.
This commit is contained in:
@@ -22,8 +22,8 @@ Use this skill to run the **NPC Nudity Workflow** for Grok-based NPC renders (co
|
||||
- **Prereq (Undressed):** before generating **Undressed**, define each courtesan's **name + extremely specific facial description** (face geometry, nose/brow/jaw/cheekbones/eye shape, unique marks) and **body description detailed enough to draw the same body twice**. Include this anchor in every Undressed prompt to keep identity consistent.
|
||||
- **Undressed recipe (aligns with old FullyNaked):** use **grok-imagine-image-pro** as primary, apply the **V4 → V1** fallback chain (**V4 twice, then V1 up to 8 times per scene**), and keep **narrative-appropriate nudity wording** (avoid hard explicit-genital phrasing; use short-trimmed pubic hair cues matching head hair **for all genders**).
|
||||
- **Scene selection rule (Undressed):** decide how many scenes you need, then **keep hammering until that count succeeds**. If a scene keeps failing moderation, **switch to a different scene**. **The successful Undressed scenes define the canonical locations** for all later stages.
|
||||
- **Scene-canon rule (2026-03-28):** maintain **scene/background canon separately from character canon**. Store a reusable scene descriptor per keeper scene (layout, props, lighting, camera angle, ambiance) and reuse that descriptor for rerenders/fill-gaps so later stages stay in the same location.
|
||||
- **Antechamber rule (2026-03-28):** where a dynamic adjacent room is used, define and store the **antechamber descriptor** in equal detail, derived from the Undressed room canon (layout, props, lighting, camera/sightline transition). Keep this descriptor separate from character canon for reliable gap-filling rerenders.
|
||||
- **Scene-canon rule (2026-03-28):** maintain **scene/background canon separately from character canon**. **Write down** a reusable scene descriptor per keeper Undressed room (layout, props, lighting, camera angle, ambiance) and reuse that descriptor for rerenders/fill-gaps so later stages stay in the same location.
|
||||
- **Antechamber rule (2026-03-28):** where a dynamic adjacent room is used, **write down and store** the **antechamber descriptor** in equal detail, derived from the Undressed room canon (layout, props, lighting, camera/sightline transition). Keep this descriptor separate from character canon for reliable gap-filling rerenders.
|
||||
- **QA rule (Undressed, human inspection):** visually inspect all outputs for **intent fails** - images that passed moderation but have anatomical absurdities (e.g., pubic hair extending to knees, impossible proportions). Treat as FAIL and rerender. Keep grinding until all keepers pass basic intent/plausibility checks. This is separate from **moderation fails** (API rejects); intent fails require human judgment.
|
||||
- **Undressed recipe (locked, validated 2026-03-24):** text-only identity anchors with **short semicolon format** (~25-35 words: hair; eyes; skin; distinctive facial geometry; height; build; cup size). Use **grok-imagine-image-pro**, **V4×2 → V1×2** (4 attempts max), old simple nudity clauses, and **"smiling warmly with inviting, direct eye contact"**. See `references/LOCKED_RECIPE.md` for full specification. Expected fidelity: **75-100%** with good identity design; generic identities fail catastrophically.
|
||||
- **Prereq (Dressed):** before generating **Dressed**, define the **tier-appropriate clothing description** in text, **detailed enough to render consistently across multiple runs**; use it in Dressed prompts while referencing the chosen Undressed keeper for face/body continuity.
|
||||
@@ -71,7 +71,7 @@ Prerequisite: The human user has selected favorites across all dress stages and
|
||||
|
||||
**ArrivalAll packaging (tier root):** place the selected **ArrivalAll** overview images **directly in the tier folder** (same level as passport photos, not inside Per Courtesan). When tier has both genders, generate three sets and name packaged finals: `Arrival (Men, Lobby type A/B/C).jpg`, `Arrival (Ladies, Lobby type A/B/C).jpg`, `Arrival (All, Lobby type A/B/C).jpg`. Add `with stairs` suffix if applicable. The raw composites are generated as `ArrivalAllMen_A1-C6`, `ArrivalAllLadies_A1-C6`, `ArrivalAllSingles_A1-C6` (18 images each); human selects the best per letter.
|
||||
|
||||
**Passport lineup thumbnails (tier root):** generate **`01-Name.jpg`** etc from each Single's **Dressed.jpg** so the lineup is visible at a glance (no counting in ArrivalAllSingles). Use **OpenCV face detection** on the **upper half** of the Dressed image and crop a square centered on the **largest face** with ~2× padding. **Human review required**: if any face is poorly framed, regenerate that individual using **Pillow fallback** (upper-half, center-X square crop). **Do not generate** `01-Name.txt` markers anymore; the images fully replace them. Dependencies: OpenCV in venv `~/.openclaw/workspace/.venv-opencv` (opencv-python + numpy). Pillow fallback in `~/.openclaw/workspace/.venv-pillow`.
|
||||
**Passport lineup thumbnails (tier root):** generate **`Name.jpg`** (no `nn-` prefix) from each Single's **Dressed.jpg** so the lineup is visible at a glance (no counting in ArrivalAllSingles). Use **OpenCV face detection** on the **upper half** of the Dressed image and crop a square centered on the **largest face** with ~2× padding. **Human review required**: if any face is poorly framed, regenerate that individual using **Pillow fallback** (upper-half, center-X square crop). **Do not generate** `01-Name.txt` markers anymore; the images fully replace them. Dependencies: OpenCV in venv `~/.openclaw/workspace/.venv-opencv` (opencv-python + numpy). Pillow fallback in `~/.openclaw/workspace/.venv-pillow`.
|
||||
|
||||
**Notes folder (during generation):** Keep a **Notes/** folder directly in tier root containing appearance/identity text files, clothing descriptions, and reference notes per courtesan. This folder remains in tier root after packaging (not moved to "Stages and Raw Files") for easy DM reference.
|
||||
|
||||
|
||||
@@ -167,8 +167,8 @@ python3 /home/rick/.openclaw/workspace/scripts/flush_courtesans_staging.py
|
||||
- **Exception:** do **not** apply this rule retroactively to the current Poor→Wealthy courtesan set.
|
||||
- **Production order (rendering):** **Undressed** (lock scenes) → **Dressed** (choose keeper outfit) → **regenerate Dressed A–E from the chosen keeper** to lock outfit continuity → **Arrival A–C** (uses the Dressed keeper) → **Teasing → Teasing More → Topless → Underwear**.
|
||||
- **Lock scenery** during Undressed; reuse those same settings for later stages to ensure continuity.
|
||||
- **Scene-canon separation rule (2026-03-28):** document scene/background canon independently of character canon (separate notes/fields). Keep a reusable scene descriptor per keeper scene: layout, props, lighting, camera angle, and ambiance. Use this scene descriptor for any gap-filling rerenders.
|
||||
- **Antechamber rule (2026-03-28):** when using a dynamic adjacent room, define a dedicated antechamber descriptor derived from the Undressed room canon (layout, props, lighting, and camera/sightline transition). Capture it with the same detail as the Undressed room and keep it in separate scene fields from character identity.
|
||||
- **Scene-canon separation rule (2026-03-28):** document scene/background canon independently of character canon (separate notes/fields). **Write down** a reusable descriptor for each keeper Undressed room: layout, props, lighting, camera angle, and ambiance. Use this descriptor for any gap-filling rerenders.
|
||||
- **Antechamber rule (2026-03-28):** when using a dynamic adjacent room, define and **write down** a dedicated antechamber descriptor derived from the Undressed room canon (layout, props, lighting, and camera/sightline transition). Capture it with the same detail as the Undressed room and keep it in separate scene fields from character identity.
|
||||
- **Stop at ≥2 scenes per pair** when returns diminish; use intent reviews to direct targeted rerenders.
|
||||
- **Round-robin rerenders** across pairs to avoid stalling on one stubborn slot.
|
||||
- Use **KEEP list** for "exceptional" outputs to avoid losing wins during cleanup.
|
||||
|
||||
@@ -8,7 +8,7 @@ Usage:
|
||||
Notes:
|
||||
- Uses "Stages and Raw Files" as stage root if present.
|
||||
- Enforces preflight: no stage-letter tokens in non-Arrival folders.
|
||||
- Generates passport lineup thumbnails (01-Name.jpg) via OpenCV on upper-half crop.
|
||||
- Generates passport lineup thumbnails (Name.jpg) via OpenCV on upper-half crop.
|
||||
"""
|
||||
|
||||
from pathlib import Path
|
||||
@@ -469,21 +469,64 @@ def copy_stages_double(base: str, dirs, dst_folder: Path, final_stage: str):
|
||||
|
||||
|
||||
def copy_arrival_overview(arrival_dir: Path, tier_dir: Path):
|
||||
# choose latest per (letter, stairs) key
|
||||
re_overview=re.compile(r'ArrivalAllSingles_([ABC])(\d)(_stairs)?__')
|
||||
buckets={}
|
||||
for f in arrival_dir.glob('ArrivalAllSingles_*__*.jpg'):
|
||||
m=re_overview.search(f.name)
|
||||
"""Copy ArrivalAll overview composites to tier root.
|
||||
|
||||
Supports ArrivalAllSingles, ArrivalAllMen, ArrivalAllLadies and maps them to:
|
||||
- Arrival (All, Lobby type X).jpg
|
||||
- Arrival (Men, Lobby type X).jpg
|
||||
- Arrival (Ladies, Lobby type X).jpg
|
||||
|
||||
Stair variants are detected either by explicit `_stairs` token or by legacy
|
||||
variant numbering (A4-C6 => with stairs).
|
||||
"""
|
||||
re_overview = re.compile(
|
||||
r'ArrivalAll(?P<group>Singles|Men|Ladies)_(?P<letter>[ABC])(?P<variant>\d+)(?P<stairs>_stairs)?__',
|
||||
re.IGNORECASE,
|
||||
)
|
||||
|
||||
buckets = {}
|
||||
seen_groups = set()
|
||||
|
||||
for f in arrival_dir.glob('ArrivalAll*__*.jpg'):
|
||||
m = re_overview.search(f.name)
|
||||
if not m:
|
||||
continue
|
||||
L=m.group(1)
|
||||
stairs=bool(m.group(3))
|
||||
key=(L, stairs)
|
||||
group = m.group('group').title()
|
||||
letter = m.group('letter').upper()
|
||||
variant = int(m.group('variant'))
|
||||
stairs = bool(m.group('stairs')) or variant >= 4
|
||||
key = (group, letter, stairs)
|
||||
buckets.setdefault(key, []).append(f)
|
||||
for (L, stairs), files in buckets.items():
|
||||
f=pick_latest(files)
|
||||
label = f"Arrival (Lobby type {L}, with stairs).jpg" if stairs else f"Arrival (Lobby type {L}).jpg"
|
||||
copy_to(f, tier_dir/label)
|
||||
seen_groups.add(group)
|
||||
|
||||
if not buckets:
|
||||
return
|
||||
|
||||
has_gender_sets = ('Men' in seen_groups) or ('Ladies' in seen_groups)
|
||||
|
||||
# If gendered sets exist, remove old generic Arrival (Lobby type X) files to avoid duplicate naming.
|
||||
if has_gender_sets:
|
||||
for old in tier_dir.glob('Arrival (Lobby type *.jpg'):
|
||||
try:
|
||||
old.unlink()
|
||||
except Exception:
|
||||
pass
|
||||
|
||||
for (group, letter, stairs), files in sorted(buckets.items()):
|
||||
f = pick_latest(files)
|
||||
|
||||
if group == 'Singles':
|
||||
if has_gender_sets:
|
||||
base = f"Arrival (All, Lobby type {letter}"
|
||||
else:
|
||||
base = f"Arrival (Lobby type {letter}"
|
||||
elif group == 'Men':
|
||||
base = f"Arrival (Men, Lobby type {letter}"
|
||||
else: # Ladies
|
||||
base = f"Arrival (Ladies, Lobby type {letter}"
|
||||
|
||||
label = f"{base}, with stairs).jpg" if stairs else f"{base}).jpg"
|
||||
copy_to(f, tier_dir / label)
|
||||
|
||||
|
||||
def generate_passports(tier_dir: Path, per_dir: Path, singles_bases):
|
||||
@@ -496,11 +539,18 @@ def generate_passports(tier_dir: Path, per_dir: Path, singles_bases):
|
||||
except Exception:
|
||||
Image=None
|
||||
|
||||
# Cleanup legacy numbered passport names from older runs (01-Name.jpg)
|
||||
for old in tier_dir.glob('[0-9][0-9]-*.jpg'):
|
||||
try:
|
||||
old.unlink()
|
||||
except Exception:
|
||||
pass
|
||||
|
||||
cascade = cv2.CascadeClassifier(cv2.data.haarcascades + 'haarcascade_frontalface_default.xml')
|
||||
fallback_used=[]
|
||||
missing=[]
|
||||
|
||||
for idx, base in enumerate(sorted(singles_bases), start=1):
|
||||
for base in sorted(singles_bases):
|
||||
name_only = extract_single_name(base)
|
||||
name = name_only.replace('_',' ')
|
||||
dressed=per_dir/'Singles'/name/'Dressed.jpg'
|
||||
@@ -539,10 +589,10 @@ def generate_passports(tier_dir: Path, per_dir: Path, singles_bases):
|
||||
if Image is not None:
|
||||
# re-encode via Pillow to keep consistent quality
|
||||
pil=Image.fromarray(cv2.cvtColor(crop, cv2.COLOR_BGR2RGB))
|
||||
out=tier_dir/f"{idx:02d}-{name}.jpg"
|
||||
out=tier_dir/f"{name}.jpg"
|
||||
pil.save(out, format="JPEG", quality=95)
|
||||
continue
|
||||
out=tier_dir/f"{idx:02d}-{name}.jpg"
|
||||
out=tier_dir/f"{name}.jpg"
|
||||
cv2.imwrite(str(out), crop, [int(cv2.IMWRITE_JPEG_QUALITY), 95])
|
||||
|
||||
return fallback_used, missing
|
||||
|
||||
Reference in New Issue
Block a user