Communitygithub.com

Museum Diorama Prompt

A paradigm for writing, reviewing, or executing prompts for museum-grade, verifiable 3D dioramas, architectural cutaways, and single-file Three.js/WebGL scenes.

What is Museum Diorama Prompt?

This skill provides a rigorous, engineering-focused framework for crafting prompts that demand verifiable, deterministic results in 3D scene generation, particularly for museum-quality dioramas, architectural cutaways, and dense procedural builds. It is designed for use with AI agents like Claude Code, Cursor, or Codex, targeting stacks such as Three.js/TypeScript/Vite. The core principle is that every claim in the final build must be checkable via numbers, named objects, screenshots, or deterministic hooks, explicitly forbidding vague mood descriptions. The skill outlines a 7-part paradigm including locking deliverables, layering content, embedding anti-laziness clauses against common shortcuts (e.g., faking foliage with low-poly spheres), quantifying interactions with measurable metrics, listing known technical landmines for Three.js/WebGL, requiring deterministic QA hooks (like `window.__setDioramaState`), and mandating self-verification before delivery. It also provides a priority triage to prevent over-polishing detail at the expense of core structure and hooks, ensuring the output is testable and production-ready rather than demo-grade.

Works with~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/lcx040210-create/museum-diorama-prompt-skill/tree/HEAD

Ask in your favorite AI

Open a new chat with this agent skill pre-loaded.

Documentation

Museum Diorama Prompt — Verifiable 3D Scene Prompt Paradigm

Core Principle

A diorama prompt is an engineering contract, not a mood description. Every claim in the finished build must be checkable: by a number, a named object, a screenshot, or a deterministic hook. If a requirement cannot be verified, rewrite it until it can.

Provenance: distilled 2026-11-27 from the "CHONGQING 8D RAIN BOX" prompt (Chongqing 8D Rainy Night Miniature Diorama, 1:150, Three.js + TypeScript + Vite + vite-plugin-singlefile) at the user's request.

The 7-Part Paradigm (in this order)

  1. Lock the deliverable — stack, artifact path, offline/single-file, zero external requests, zero console errors/warnings, build commands. No "tutorial", no demo-grade output.
  2. Layer the content — split the scene into named tiers/zones, each with a height/depth range and a scale. Each tier lists its landmarks by name; each landmark is decomposed to prop level (the parts an inspector can tick off one by one).
  3. Embed anti-laziness clauses — predict how an executor will fake each hard element and forbid that specific fake (see clause library below).
  4. Quantify interaction — keys/buttons bound to named views, states and modes; layout requirements as measurable metrics (0 overlaps, 0 out-of-bounds, counts, margins), never "looks good".
  5. List the technical landmines — platform-specific failure modes already known for the stack (renderer, shaders, post-processing), stated as prohibitions with the safe alternative.
  6. Require deterministic QA hooks — window functions to set state, advance the simulation by a fixed dt, pose the camera, and read metrics. Screenshots and metrics, not vibes, close the task.
  7. Self-verify before delivery — build, capture the named views/states in headless Chrome at the named viewport, inspect, fix, rebuild, re-verify. Never claim a check that was not actually run; if the specified verification environment is unavailable, say so and state what was used instead.

Anti-Laziness Clause Library (adapt per scene)

ElementThe fake to forbidRequire instead
FoliageLow-poly spheres/icosahedrons as canopiesGPU-instanced alpha-cutout leaf clusters, stated minimum count (e.g. 2,000+), vertex sway
Shop interiorsFlat glowing rectangles / emissive planesReal recessed 3D interiors: furniture, props, signage text, lighting, visible through openings
VehiclesOne box with paintMulti-section sculpted body: glazing + pillars, wheels + rims, plates, lights, interior, mirrors/wipers
PeopleStatic capsulesProportioned articulated figures with clothing, carried props, umbrellas where weather fits
Moving transportSliding box, wall clippingArticulated segments, bellows, bogies, lit cabins; path clearance explicitly zero-clipping
Cutaway structureRibs/arches slicing across the subjectStructure hugs back wall/ceiling only, stops at the cutaway lip; sightline unobstructed
Ground/wetnessFlat color + roughness tweakShader: micro-grain bump, wet channels, neon puddle reflections, raindrop ripples, Fresnel halos; guard pow(max(x,1e-5),y) and divisions against NaN/Inf
Snow/weather modesGlobal white overlay / bloom whiteoutLocal blankets on named surfaces only, calibrated emissive, stated "zero whiteout"

Three.js / WebGL Landmines (carry into every such prompt)

  • NEVER combine MeshPhysicalMaterial with transmission > 0 and an MSAA EffectComposer (HalfFloatType) on Chrome Metal ANGLE — use transmission: 0 Fresnel acrylic for glass/panels.
  • Selective bloom threshold >= 0.90; calibrate emissive luminance per weather/state mode, not once globally.
  • Zero external textures/models/fonts/CDNs: everything procedural (geometry, Canvas2D textures, local system font stacks).
  • Deterministic hooks contract (exact names unless the task renames them):
    • window.__setDioramaState(opts) — {view, weather, exploded, convergence, time, autoOrbit}, snaps deterministically
    • window.__advanceSimulation(dt) — advances ALL animation by dt seconds and renders one frame
    • window.__setCameraPose(pos, target) — deterministic camera placement
    • window.__getDioramaMetrics() — {fps, triangles, drawCalls, weather, view, exploded, convergence, calloutCount, calloutOverlaps, calloutOutOfBounds}

HUD / Callout Rules Worth Copying

  • Persistent minimal header naming the piece, its scale, and a live status line per tier.
  • Mode/weather controls as labelled pills, each also bound to a key.
  • Explode/CAD view: numbered callout cards split left/right, projected from 3D anchors, with dynamic collision avoidance guaranteeing 0 card overlaps, 0 HUD overlaps, 0 out-of-bounds — and the metrics hook must report those three numbers so the guarantee is testable.

Audio (when the brief includes it)

Specify it like the visuals: WebAudio only, unlocked on user gesture/key, named layers (ambient bed, melody, mechanical hums, bells/chimes), a target loudness band (RMS ~0.12–0.15, Peak <= 0.85), and an explicit tone ban (no harsh hiss, no eerie sweeps) when the mood is warm.

Priority Triage (the paradigm's known weakness)

These prompts are deliberately over-dense and rarely state priorities. When executing one, impose this order and say so:

  1. Skeleton: tiers/zones, named landmarks, plinth/framing
  2. Deterministic hooks + metrics (so everything else is verifiable)
  3. Hero interactions: views, weather/state modes, explode, convergence event
  4. Signature moving elements (trains, cableway, vehicles)
  5. Prop density and micro-detail, tier by tier, until the budget runs out

Never sacrifice 1–3 to polish 5.

How to Use This Skill

  • Writing a new prompt: fill template.md in this directory — every {{slot}} must end up as a name, a number, or a checkable clause; delete any section that stays adjectival.
  • Reviewing a prompt: check it against the 7 parts; the usual gaps are missing anti-laziness clauses, unquantified layout claims, and no hooks.
  • Executing a prompt: follow Priority triage, verify with the hooks and named screenshots, and report unverified items as unverified.

Common Mistakes

  • Stacking adjectives ("stunning, immersive, rich") instead of naming parts
  • Forbidding a fake without requiring the real replacement
  • "Responsive / no overlap" with no metric and no hook to measure it
  • Claiming headless verification in an environment that was never checked (e.g. demanding macOS Metal while running on Linux) — verify what the actual environment is first

Related Skills