← All notes

BUILD LOG THREE.JS · AI WORKFLOWS · UX

Building the portfolio I could picture, not just the one I could design

An illustrated 2.5D Three.js room, a 59-second anime short, and what directing AI agents looks like when you care about taste, performance, and knowing when to stop.

// Creative engineering · 0-to-1 build

Published Updated

My old site was tidy and safe: a clean bio, project cards, links. I could picture something far more expressive, I just didn't have the illustration and animation chops to draw it by hand. AI agents gave me a way to build it anyway.

The spark hit while scrolling X. People were using Fable, an AI animation model, to put together short clips, and three things I care about lined up at once: anime, 2.5D illustration, and years of working on 3D web viewers. What happens when all three share one corner of the web?

The result is live at officedoge.dev/portfolio. You land straight inside an illustrated 2.5D room you can turn, zoom, and poke around. When you want the story behind the projects, click "Watch the film" (or click Doge in the middle) and a 59-second short plays over the room. When it ends, the last frame parts like a paper curtain and drops you right back in.

I like to call that feeling standing in the future: suddenly being able to build the exact thing sitting in your head, even when you don't personally draw every frame or type every line of code.

Sixty-two green tests can still be a house tour

I started with a brief for an animated short showcasing my projects, followed by an interactive 3D studio in Three.js, told the agents to make it stunning, and stepped back.

They did what careful engineers do: modelled the room and Doge in Blender, exported to Three.js, wired up playback and camera controls, and wrote tests. Sixty-two green tests.

Then I watched it. The camera drifted slowly from desk to shelf inside one 3D room. The character didn't look like Doge, and the monitors had striped rendering artefacts. It felt like a real-estate agent showing a house. I didn't want to watch it, and nobody else would either.

Early 3D studio prototype with a small Doge on the rug and striped rendering artefacts across the desk monitors.
The first build running in the browser: the 3D studio, an early Doge model, and striped rendering artefacts on the desk screens.

The mistake was mine. I asked for a film and an explorable room in one breath, so the agent fused them into a single camera path through 3D geometry. A music video needs cuts, jokes, and rhythm. An interactive room needs clarity and restraint.

I threw that build away and changed how I ran the second attempt:

  1. Lock the music first. The agent's warm, gentle audio sketch felt far too sleepy for a cheeky product teaser. I love Japanese bubble-era city pop for its bright energy and warmth, so I generated a city-pop track in Suno. It came out at 59 seconds, giving every shot a real clock to answer to.
  2. Review pictures instead of text specs. A written shot list hides everything that matters visually. I compared two visual directions from actual keyframe drawings; cel illustration won in a second, and I reviewed all eight chapters one frame at a time.
  3. Match the check to the decision. Green tests prove controls work, not whether a film is fun to watch. Stills settled the look, short clips settled motion, and cutting against the music settled pacing.
Storyboard keyframes in the warm cel-illustrated Direction A style showing Doge at a desk with dual monitors and coffee.
Direction A: the cel-illustrated storyboard that replaced the 3D house tour.

Once I anchored each chapter in what each project actually does, the jokes wrote themselves: an #ASAP Slack card flies off the monitor and Doge uses it as a coaster; my dog Panda grows up across BowlNote feeding logs; one locked window cycles through four seasons for Stillhere, my pixel pet memorial app.

Change the method, not the prompt

With the art style and storyboard locked in with Astra, I let Astra take the first swing at motion and produce a five-second opening test.

Click to play, feel the AGI 😂

Round, unbothered Doge had turned into a fox sitting on the desk, with a hinged arm growing out of his belly like a third leg and a cuff of fur floating near his shoulder.

Prompt tweaking was never going to save that. I switched video production straight over to Fable in the same minute, handed it Astra's clip, and asked one question: "is this Doge acceptable?" That was the real turning point of the weekend. A 2D cutout rig can only rotate flat pieces; reaching toward the camera requires the arm to actually change shape.

We ditched the rig for complete illustrated poses. The image model drew each pose whole, and Python handled the in-betweens: registering heads across poses to within 2 px to stop jitter, then warping the arm smoothly along the paw's path.

People ask if the short is "AI video". It isn't a video model hallucinating frames. All 3,540 frames (59 seconds at 60 fps, 1080p) were assembled offline by Python scripts across three layers:

  • Image model: character poses, props, clean backgrounds, and the flat-white latte art, locking in the illustrated look.
  • Python offline (NumPy, OpenCV, Pillow): chroma keying with spill removal, 2-pixel head alignment, displacement warps, and clean-plate patching. Heavy pixel math paid once on my laptop, never on a visitor's CPU.
  • Code (Skia): airflow lines, charts, typing bubbles, and the entire world outside Stillhere's window, where roughly 350 code-drawn leaves shift colour, fall in autumn, and grow back in spring from a single season variable moving 0 → 4.
Three numbered panels: pixel Doge latte art; the same Doge pose on green and transparent backgrounds; autumn and summer frames from Stillhere.
Three responsibilities across the film: (1) image-model artwork for the opening latte shot; (2) Python keying the green background out of a Doge pose; (3) Skia drawing the changing seasons outside Stillhere's window.

Exporting the finished sequence as MP4 (20.8 MB desktop, 9.4 MB mobile, down from a 103 MB master) kept the hand-drawn look while letting the world around Doge run at 60 fps. Even better for iteration: once a pose was approved, we could tweak timing and motion in Python without re-rolling Doge's face.

Why 2.5D beat modelled 3D

Once the film finished, the original 3D studio concept no longer belonged in the same universe. My biggest worry was style drift: a great styleframe turning into a plasticky, off-model Three.js render.

Early 3D-style studio concept showing a wooden desk, project shelves, a sunlit window nook and Doge in a warm miniature room.
The original studio concept: a warm miniature room with rounded forms and realistic lighting, before the shift to cel illustration.

So we stopped modelling the room altogether. Instead, we sliced the illustration into pieces, mounted each piece on a flat card with ten thin stacked paper layers behind the silhouette, and stood them at different depths in a limited-orbit Three.js scene. Bounding the camera orbit was what made the trick hold up: within a controlled viewing arc, parallax gives the room real depth without forcing the cards to survive a 360-degree spin, and Doge never loses his drawn silhouette.

Side-by-side comparison of the 2D studio styleframe and the live three.js 2.5D papercraft room render.
Styleframe on the left, live Three.js papercraft render on the right.

Each corner got a small animated callback to the film: a splitting jet engine, airflow over the F1 car, light tracing the red cord for my Chrome extension Knot, and the "In the works" box cracking open with golden light. Two stubborn bugs stood out:

  • The worm on Knot's cord: a hand-traced glow wobbled beside the line like a worm until we masked it directly with the cord's own pixels.
  • The frozen room: clicking into the desk froze the scene dead. A floating-point rounding error produced a canvas arc radius of -2e-16, throwing right before requestAnimationFrame ran at the end of the callback. Clamping the radius fixed the crash, and moving requestAnimationFrame into a finally block stopped a one-off exception from stalling the loop.

Then came the WebGL audit. I didn't write the Three.js optimisation code by hand, I demanded it. After years building 3D web viewers, you don't need to guess whether a fresh scene is leaking draw calls or hiding z-fighting between stacked layers. It always is. I asked the agents to audit the whole scene, which cleaned up a stack of z-fighting glitches and delivered four concrete cuts:

  • Draw calls (598 → 157): collapsed the ten stacked paper edges per card into InstancedMesh calls.
  • Artwork weight (35.2 MB → 2.7 MB): converted PNG layers to WebP.
  • Time-to-room (21.2 s → 10.9 s): split textures into two-wave loading, measured under emulated Slow 4G with 6× CPU throttling.
  • Idle power (60 fps → 30 fps): steps down after 1.5 seconds without input.

The handover from film to room took four tries: swinging boards (killed on sight), a rolling curtain with awkward letterbox edges, feathered and full-window experiments (both worse), and finally what shipped. The film's last frame splits into backdrop and Doge, mounted directly onto the Three.js camera. It waits two requestAnimationFrame ticks before hiding the <video> element so nothing flashes. Then the camera solves its starting position from the screen size and position of Doge's sunglasses, two subdivided backdrop sheets curl aside like real 3D paper rolls, and the film's Doge dissolves into the room's Doge as the camera pulls back.

AI wrote that projection math, and only because I refused to settle when the first builds didn't match the mockup it had pitched. If an agent promises an effect in a mockup, push it to build the real thing; if it genuinely can't, rethink the design together. Even now, Doge's alignment isn't pixel-perfect on every single viewport ratio, and I'm completely fine with that. Anyone who has matched a 2D video frame to a live 3D camera across arbitrary screen shapes knows chasing perfection there is a bottomless pit. Close enough ships. This is a portfolio, not a museum exhibition.

Sequence showing the green paper backdrop rolling aside like a curtain while the film's Doge dissolves into the 2.5D room.
The final paper-curtain handover aligning on Doge's sunglasses.

Let visitors reach the room first

Right up to launch, the flow assumed visitors would watch the film first and enter the room second, simply because that was the order I built them in. I spent hours polishing that front door: preloading the room during playback, silently buffering the first 8 seconds of video on other pages of the site, and turning frame 1 (a top-down flat white with my pixel avatar in the foam) into a custom play button with rising steam and a gold buffering ring.

Top-down flat white latte art featuring the pixel Doge, with play text and a gold buffering progress arc around the rim.
The flat-white frame: originally the entrance play screen, now the buffering screen on click.

An hour after launch, I sent the link to Adam Brock, founder of Hypermatic. Two notes came back:

I'd probably load straight to the room, and have the video player as a popup option when you click on the Doge or something. I think the room is the more impressive quick first impression.

I would also add a super subtle amount of rotation as you hover from left to right, just to make it more obvious it's in a 3D space, until they drag it manually.

He was right immediately. I had spent hours making the film faster to load before asking whether it needed to load first. I had mistaken my build order for the visitor's journey.

I flipped the entrance. The room now opens first, leaning gently toward the pointer until your first drag so the 2.5D depth reads right away. The film only fetches when someone clicks "Watch the film" or clicks Doge. The flat-white cup became the click-to-buffer screen, the paper curtain still drops you back into the room at the end, and deleting the cross-page video preloader stopped every other page from fetching bytes visitors might never watch.

Adam caught one more blind spot on his 2560×1440 monitor: he clicked through three corners before noticing the corner action bar sitting at the very bottom edge of the screen. In my smaller laptop window it looked obvious; on a large display it practically vanished. Testing across screen sizes and lifting the bar closer to the focal point fixed a discoverability bug I never would have seen alone.

Adam fixed how visitors enter the room; Elbert Alias, founder of Wappalyzer and Alias Lab, changed why they stick around. He suggested hiding Easter eggs inside the studio, which flipped a switch for me. A 3D showcase is easy to glance at and close; a room with secrets turns into a playground people actually want to poke around. I went a bit wild tucking surprises into different corners, and I'll leave them unspoiled for you to find.

What stuck with me

AI makes it dangerously easy to outrun your own design thinking. Both big detours (the 3D house tour and the gated video entrance) happened because excitement carried me straight into building before deciding what the experience should actually be. At the same time, every breakthrough came from engineering judgement that predated AI: throwing away 62 green tests when the experience felt dead, knowing to audit draw calls and z-fighting early, pushing agents to honour their own mockups, and knowing when "close enough" is ready to ship.

Define the experience, prove a small slice visually, put it in front of fresh eyes (thank you, Adam and Elbert), and stay willing to delete your own clever work when a simpler path wins.

Come walk around the room, and take a sip if you want the story.