JSON-Structured Image Decomposition: Generate Precise Before/After Visuals for Client Proposals
What This Builds
Most remodeling proposals contain a price list and a scope document. The homeowners who sign faster are the ones who can picture the finished result. This technique gives you a repeatable workflow to take a photo you already shot during the site visit and produce a realistic before/after visualization — correct cabinet color, new countertop material, updated flooring — in about 15 minutes, without design software or a rendering service.
The output is a pair of images you drop directly into your proposal PDF. Clients stop second-guessing finishes. They sign.
Prerequisites
- Advanced subscription ($20/month) at gemini.google.com — the image editing features require the paid tier
- A smartphone or tablet with decent photos from your site visits (standard phone camera quality is fine)
- Your existing proposal template — a Word doc, Google Doc, or Canva layout you already use
- AI Studio (aistudio.google.com) bookmarked as a free backup when Gemini quota runs out
The Concept
Free-text image prompts are unpredictable. Tell an AI "change the cabinets to white shaker and update the countertop to quartz," and it may swap the cabinets, shift the backsplash, add pendant lights that weren't there, and change the floor — all in one edit. You asked for two changes. You got six. Starting over is frustrating.
JSON prompting solves this by giving the AI a written contract for every element in the image before you ask it to change anything. You first ask Gemini to read the photo and output a structured list of everything it sees — each item named, with its color, material, and position recorded. That list is your blueprint. You edit exactly the fields you want changed, leave everything else untouched, and hand the modified blueprint back to Gemini along with the original photo. Because every surface is explicitly accounted for, the model makes only the changes you specified.
Think of it like a change order. You wouldn't let a sub swap flooring without a written scope. The JSON blueprint is the written scope for the AI.
Build It Step by Step
Part 1: Capture a Usable Site Photo
The quality of the output depends more on the photo than on the prompt.
- During your site visit, photograph the room or surface you're proposing to change. Stand back far enough to capture the full space, not just one wall.
- Get even, natural light if you can. Avoid harsh flash shots — shadows make material edits look fake.
- Shoot at eye level, roughly centered on the primary surface (cabinets, floor, wall). Dramatic angles make the AI's perspective math harder.
- Take 2-3 shots. Pick the clearest one. You don't need to do anything else with the photo before you start.
One photo is all you need for this workflow. You'll use it twice: once for the extraction step, once for the edit step.
Part 2: Extract the JSON Blueprint
- Open gemini.google.com and start a new conversation.
- Upload your site photo.
- Paste this extraction prompt exactly:
Analyze this room photo and output a structured JSON object describing every visible surface, material, and object. For each item, include these fields:
- name (descriptive label, e.g. "upper_cabinets", "kitchen_floor", "countertop")
- color (specific color description, e.g. "medium oak", "off-white", "dark gray")
- material (e.g. "painted wood", "ceramic tile", "laminate", "granite")
- finish (e.g. "matte", "gloss", "brushed", "flat")
- position (where in the frame, e.g. "upper left", "full floor", "center island")
Output clean JSON only. No explanation before or after the JSON block.
- Gemini will return a JSON object. Copy the entire response — from the opening
{to the closing}. - Paste it into a plain text file or Google Doc and save it. Label it with the client name and room (e.g.,
henderson-kitchen-blueprint.json).
Read through the JSON before proceeding. Find the items you're proposing to change. For a kitchen, that's typically upper_cabinets, lower_cabinets, countertop, backsplash, and kitchen_floor.
Part 3: Make Surgical Edits to the Blueprint
Open your saved JSON. Find each field you want to change and update only that field.
Examples for a kitchen proposal:
Changing cabinets from stained oak to white shaker:
"upper_cabinets": {
"color": "bright white",
"material": "painted wood",
"finish": "semi-gloss",
...
}
Changing laminate countertops to quartz:
"countertop": {
"color": "white with subtle gray veining",
"material": "quartz",
"finish": "polished",
...
}
Changing vinyl floor to luxury vinyl plank in warm oak:
"kitchen_floor": {
"color": "warm medium oak",
"material": "luxury vinyl plank",
"finish": "low-sheen",
...
}
Leave every other field exactly as Gemini returned it. Walls, ceiling, appliances, windows, fixtures — untouched. You are making a surgical change to the contract, not rewriting it.
Part 4: Generate the After Visual
- Start a fresh Gemini conversation. Do not continue the extraction conversation.
- Upload the original site photo again.
- Paste this prompt, with your modified JSON replacing the placeholder:
Modify this image based on the following JSON. Apply only the changes shown in the JSON fields. Preserve all other elements exactly as they appear in the photo — walls, ceiling height, appliances, windows, lighting, and overall composition must remain unchanged.
[PASTE YOUR MODIFIED JSON HERE]
- Gemini will generate the modified image. Download it.
You now have a before photo (your original) and an after photo (the AI edit). Drop both into your proposal.
Part 5: Test and Refine
The first attempt usually gets 80-90% there. Common things to fix:
The cabinets look painted but the texture is wrong. Add "texture": "smooth flat panel" or "texture": "recessed shaker panel" to the cabinet object and regenerate.
The floor changed but so did the wall color. Find the wall object in your JSON and confirm its color and material fields are still set to what Gemini originally returned. An empty or ambiguous wall field can cause drift. Add explicit values and try again.
Gemini changed the backsplash even though you didn't ask. The backsplash field probably wasn't in the original JSON output — Gemini missed it during extraction. Add it manually with the current color and material, then regenerate.
If a specific object keeps changing, look for keys in the JSON that might be implicitly linked to it (e.g., a wall_tile field that Gemini is interpreting as backsplash). Remove or rename the ambiguous key.
Real Example: Henderson Kitchen Proposal
The job. A kitchen remodel quoted at $38,400. Existing cabinets are stained medium oak. The homeowner wants white shaker cabinets, quartz countertops in white/gray, and new LVP flooring. She's not sure about the LVP color and keeps asking to see options before committing.
Setup. During the walkthrough, you took 4 photos. The best shot is a wide-angle from the doorway showing all three walls of cabinets, the island, and the full floor.
Step 1: Extract. Upload the photo with the extraction prompt. Gemini returns JSON with 14 named elements including upper_cabinets, lower_cabinets, island_cabinets, countertop, backsplash, kitchen_floor, ceiling, walls, refrigerator, range, dishwasher, window_over_sink, pendant_lights, sink.
Step 2: Edit for Option A (warm oak LVP). You update upper_cabinets, lower_cabinets, and island_cabinets to white shaker. You update countertop to white quartz with gray veining. You update kitchen_floor to warm medium oak LVP. Everything else stays exactly as returned.
Step 3: Generate Option A. Upload the original photo. Paste the modified JSON. Download the result.
Step 4: Edit for Option B (cool gray LVP). Open your saved JSON file again. Change only kitchen_floor from warm oak to "cool light gray" / "luxury vinyl plank". Generate Option B.
Step 5: Build the proposal section. You now have three images: the current kitchen, Option A, Option B. Your proposal includes a half-page visual comparison with a note that the flooring selection affects the final price by approximately $400 either way.
What the homeowner said. She chose Option A within 24 hours and signed the contract the same day. No more "can I see what it would look like" emails.
Time saved. Comparable rendering services charge $150-300 per image with 48-72 hour turnaround. This workflow costs nothing beyond your Gemini subscription and takes 15-20 minutes from photo to finished visuals.
What to Do When It Breaks
- Gemini refuses to edit the photo or says it can't modify uploaded images. You may be in a session where image generation is disabled. Sign out and back in, or switch to AI Studio (aistudio.google.com) which uses the same model and is free.
- The AI changes too many things at once, not just the fields you edited. Your JSON has ambiguous or conflicting fields. Find the item that changed unexpectedly and add an explicit
"unchanged": truenote to its entry, or add more specific values to fields that were vague in the original extraction. - The output looks cartoonish or over-processed. Add
"realism": "photorealistic, match original photo lighting and camera perspective"as a top-level field in your JSON. This often pulls the edit back toward the natural look of the original. - Gemini didn't include a key surface in the JSON extraction. Some surfaces (especially backsplashes behind appliances, or trim details) get missed on the first pass. Add them manually with your best description of the current state before making any edits.
- You hit your quota mid-project. Switch to AI Studio. The interface is slightly more technical but uses the same underlying model and has a generous free quota. Everything in this workflow runs identically there.
Variations
- Simpler version. Skip the JSON extraction and test a plain-text edit first: upload your photo and write "Change only the cabinet color to white. Keep everything else exactly the same." If the result is good enough, stop there. Use JSON when you need more precision or you're editing multiple surfaces.
- Extended version. Collect JSON blueprints from all your before photos and build a small library. When a client asks "what would this look like with gray shaker cabinets?" you already have the blueprint ready — just edit two fields and generate. Over time, you'll have a reusable file for each project that you can revisit for change order discussions or upsell conversations.
- Two-room comparison. Extract JSON from two different rooms in the same house, then standardize the flooring and cabinet fields to the same values in both. Generate both "after" images with matching finishes. Clients love seeing the whole-home consistency story in a proposal.
What to Do Next
- This week. Pull a photo from your last 3 site visits and run through the full workflow once. The first extraction will take 20 minutes while you get familiar with the JSON output. The second will take 10. By the third, it's a fast, repeatable step.
- This month. Add a "Proposed Finishes" visual page to your standard proposal template. Drop your before/after pair into that page for every bid where finishes are part of the scope. Track whether those proposals close faster.
- Advanced. Combine this with your Claude Project estimating assistant. After you generate the after visual, drop it into Claude with your scope of work and ask it to write a one-paragraph "Transformation Summary" for the proposal cover page. You'll have a polished visual and a polished narrative in under 30 minutes total.
Advanced guide for Residential Remodeling Estimator professionals. These techniques use more sophisticated AI features that may require paid subscriptions.