Real-time 3D hair color preview, texture configurator, and AR try-on for beauty ecommerce
The 3D Hair & Beauty Commerce framework is the definitive AI prompt system for beauty brands, hair care retailers, and salon platforms building the next generation of online shopping experiences. Hair color is the single highest-return-rate product category in beauty ecommerce — because customers cannot visualize the result before buying. This framework solves that with a complete technical stack: a real-time HSL-shift hair color shader that previews any shade instantly on a 3D head model, morph-target blending between hair texture styles, WebXR AR try-on that anchors the preview to the customer's own face, and a shade-matching system that reads the customer's current hair color from their camera and recommends the closest product. Every prompt is engineered for beauty ecommerce conversion — not just visual novelty.
Full Access Unlocked
All 52 prompts · All 6 modules
"The HSL hair color shader prompt produced a result that our in-house team had been trying to build f..."
Head of Digital · Top-5 global hair care brand
Need expert implementation?
Hire an OrchestratorConnect with a certified Prompt.Doctor Orchestrator to deploy this framework for you.
No coding required. You will use ChatGPT or Claude as your AI tool. Follow these steps in order — do not skip ahead.
Purchase & download the framework
Click the buy button on this page. After checkout, go to the and hit Download .zip. Unzip it — you'll get a .md file (the full framework) and a .pdf (easy to read reference). Keep both open.
Open your project — new or existing
This dashboard is designed to integrate into any existing project or be built as a standalone app. If you already have a site in Airo (or Cursor, Bolt, etc.), open that project. If you're starting fresh, create a new project. The Orchestrator Prompt handles both cases — it scans what's already there and adds only what's missing.
Paste the Orchestrator Prompt into your builder's chat
Open the on this page. Copy the Orchestrator Prompt and paste it into your AI builder's chat. It will scaffold the full admin system — secure login, email marketing module, booking engine, and CMS — on top of your existing codebase. This takes 2–5 minutes.
Add your API keys as secrets
Critical — Novice UsersIn your builder, go to Settings → Secrets and add the keys your app needs. For this framework: STRIPE_SECRET_KEY (for booking payments — get it from your Stripe dashboard), ANTHROPIC_API_KEY (for AI-assisted content — get it from console.anthropic.com), and DATABASE_URL (your MySQL connection string). No key is needed for the admin login, CMS, or email modules — those run on your existing infrastructure.
Don't have a MySQL server?
You can purchase a shared hosting plan with cPanel and MySQL at host.esgwon.dev. Once your account is set up, follow the step-by-step guide to create your database and connect it to your AI website builder.
How to set up cPanel MySQL & connect to your AI website →Need help with Stripe?
Get your STRIPE_SECRET_KEY and STRIPE_PUBLISHABLE_KEY from your Stripe dashboard. The guide covers test keys, webhook setup, and going live.
Need help with Anthropic?
Get your ANTHROPIC_API_KEY from console.anthropic.com. The guide covers model selection, cost management, and troubleshooting.
Prompting Airo after setup — always name the file
When asking Airo to add tables, columns, or features to the admin dashboard, always include src/server/lib/admin-db.ts in your prompt. Without it, Airo may target the wrong database. Example: "Add a bookings table in the admin database (src/server/lib/admin-db.ts) — do not touch any other database connection in this project."
Run the framework prompts inside your live app
Your app is now running in the builder's preview panel. Open the on this page, copy each prompt one at a time, and paste it into your builder's chat. Replace every [BRACKET] with your real data before sending. Work through the stages in order — each stage output feeds the next.
Test end-to-end, then publish or hand off to your client
Walk through the admin as a real user: log in, create a booking, send a test email campaign, update a CMS image, and run the Safe-to-Publish gate. Once everything passes, click Publish in your builder. Because this is a white-label dashboard, your client accesses it at /admin on their own domain — no Prompt.Doctor branding, no third-party login required.
6 modules · 52 prompts · 6 workflow stages
Head Model & Hair Mesh
GLTF head model loading with separate hair mesh, UV mapping for color shader, LOD for mobile, and hair mesh morph targets for style variants
9 promptsReal-Time Color Shader
Custom GLSL HSL-shift ShaderMaterial for hair color preview, 200+ shade swatch system, highlight and lowlight layer blending, and root-to-tip gradient mapping
10 promptsTexture & Style Configurator
Morph target blending between straight/wavy/curly/coily hair geometries, length slider via vertex shader Y-scale, and volume/density parameter
9 promptsAR Try-On System
WebXR Face Tracking session setup, face mesh landmark anchoring, MediaPipe FaceMesh fallback for non-WebXR browsers, and head model alignment to face pose
10 promptsShade Matching AI
getUserMedia camera stream, canvas pixel sampling for dominant hair color, LAB color space distance to product shade library, and top-3 recommendation display
8 promptsProduct Viewer & Commerce
3D product packaging viewer with label texture swap, 360° auto-rotate, shade-to-SKU mapping table, dynamic pricing, and add-to-cart with configuration payload
6 promptsWrite a React Three Fiber component that applies a real-time hair color preview shader to a 3D hair mesh using a custom GLSL ShaderMaterial. Requirements: (1) The hair mesh is a GLTF model with a UV-mapped texture (the base hair texture provides strand detail and specularity). (2) ShaderMaterial uniforms: u_baseTexture (sampler2D — the original hair texture), u_targetHue (float, 0.0–1.0), u_targetSaturation (float, 0.0–1.0), u_targetLightness (float, 0.0–1.0), u_colorIntensity (float, 0.0–1.0 — blend between original and target color), u_highlightHue (float), u_highlightMask (sampler2D — grayscale texture defining highlight placement), u_rootDarkness (float, 0.0–1.0 — how dark the roots are relative to lengths). (3) Fragment shader: (a) Provide complete RGB↔HSL conversion functions in GLSL. (b) Sample u_baseTexture — extract its luminance to preserve strand detail. (c) Convert u_targetHue/Saturation/Lightness to RGB. (d) Apply u_rootDarkness: darken the color based on UV.y (roots at top, tips at bottom — adjust lightness by mix(targetL * (1.0 - u_rootDarkness), targetL, uv.y)). (e) Blend highlight color at u_highlightMask regions. (f) Multiply final color by original luminance to preserve strand shading. (g) mix() between original texture color and computed color by u_colorIntensity. (4) React component: HairColorPreview with props shadeHex: string (convert to HSL for uniforms), highlightHex: string, rootDarkness: number, colorIntensity: number. Update uniforms reactively on prop change. (5) Outside Canvas: a shade swatch grid component showing 24 color options, clicking one updates shadeHex. Full TypeScript.
Write a TypeScript module that analyzes a user's hair color from their webcam and recommends the closest products from a shade library. Requirements: (1) captureHairSample(): request getUserMedia({ video: { facingMode: "user" } }), draw a single frame to a hidden canvas, sample a 40x40 pixel region in the upper-center of the frame (where hair typically appears), compute the average RGB of all pixels. (2) rgbToLab(r, g, b): implement the full sRGB → XYZ → CIELAB conversion in TypeScript (provide the complete math — D65 illuminant, gamma correction, XYZ matrix). (3) deltaE(lab1, lab2): implement CIE76 color difference formula: sqrt((L1-L2)^2 + (a1-a2)^2 + (b1-b2)^2). (4) Shade library: define a ShadeLibrary type: Array<{ id: string, name: string, hex: string, skuId: string, level: 1|2|3|4|5|6|7|8|9|10 }>. Convert each shade hex to LAB on initialization. (5) findClosestShades(sampledRgb, library, topN = 3): convert sampled RGB to LAB, compute deltaE against all library shades, return top N sorted by ascending deltaE with their deltaE scores. (6) React component: ShadeMatcher — shows a "Scan My Hair Color" button, activates camera, captures sample, displays top 3 recommended shades with product names, swatch colors, and "Add to Cart" buttons. Handle camera permission denial gracefully. Full TypeScript.
system
19 prompts
templates
10 prompts
workflow
15 prompts
prompts
8 prompts
"The HSL hair color shader prompt produced a result that our in-house team had been trying to build for 6 months. The root-to-tip gradient, the highlight mask layer, the luminance preservation for strand detail — it's the complete system, not a toy demo."
Head of Digital
Top-5 global hair care brand
"The CIELAB shade matching system is the feature that reduced our hair color return rate by 34%. The deltaE color distance math — converting camera pixels to LAB space and finding the closest product shade — is exactly the right algorithm for this problem."
CTO
Beauty ecommerce platform, $28M ARR
All 52 prompts across 6 modules are unlocked for your account.
Lifetime access