Code4City: can a coding agent build a real city block?
Code4City hands an AI coding agent one square kilometre of
Manhattan around Madison Square Park — maps, terrain, aerial photos and
street-level photos — and asks it to build that place as a 3D world a game
engine can run.
We ran it with three models — gemini-3.8-flash, GPT-6 Astra and
Fable 5.1 — each given exactly the same data, the same brief, the same
machine and maximum reasoning effort, so this compares the models like for
like.
The task
Code4City A game engine and a modelling tool
Given
The source data and the brief.
Tools
Unreal Engine and Blender, with a graphics card, so the
agent could render and look at its own work.
Hands back
An Unreal project and level that opens and runs, the
Blender source files, and the code that produced them.
Effort
Maximum reasoning effort, for all three models.
The source data
Maps, terrain, aerial imagery and street-level photographs of the square
kilometre.
Everything was frozen before the runs, so all three runs
saw exactly the same bytes.
What came out
Each clip is a delivered world, recorded without changing anything the agent
built. Within a row the camera path is identical.
gemini-3.8-flashLow orbit around the park, 45 m up.GPT-6 AstraLow orbit around the park, 45 m up.Fable 5.1Low orbit around the park, 45 m up.
gemini-3.8-flashDown Fifth Avenue at street height.GPT-6 AstraDown Fifth Avenue at street height.Fable 5.1Down Fifth Avenue at street height.
With the same data, brief and tools, the two
larger models produced buildings with windowed facades, streets with lane
markings and parked cars, and recognisable landmarks. gemini-3.8-flash produced
blocky untextured buildings with oversized roofs.
The same four cameras in each world
Stills from the same camera position, lens and resolution in each world. Click
any image for full size.
gemini-3.8-flash
GPT-6 Astra
Fable 5.1
straight down over the park
the park from the south-west
Fifth Avenue
the Flatiron corner
How the agents worked
Every session was logged in full.
run
actions taken
shell commands
looked at its own images
looked at the source photos
gemini-3.8-flash
327
180
9
11
GPT-6 Astra
604
536
56
1
Fable 5.1
448
298
177
12
What the shell commands were for
Each shell command is sorted by what it touches: the game engine, the
modelling tool, the agent's own scripts, image files, or reading and moving files
and logs — mostly the agent checking the output of something it just
ran.
own codegame engine3D modellinglooking at an imagereading files and logssomething else
How often it looked at its own images
Renders, previews and plots the agent produced itself. Looking at the aerial
and street photographs it was given is counted separately in the table above.
The run that looked at its own output most often delivered
the most finished world. That is Fable 5.1, which looked at its own images
177 times, against 56 for GPT-6 Astra and only 9 for gemini-3.8-flash —
which spent more of its looking on the source photographs (11 times) than on what
it had built.
An action counts as looking at an image when it opens an image
file or names one in a command. Images are sorted by where they live: the source
data the run was given, or anything else, which is the agent's own output.
Time and cost
run
active time
actions
cost
gemini-3.8-flash
90 min
327
$5.84
GPT-6 Astra
255 min
604
$60.46
Fable 5.1
170 min
448
$106.73
Cost, US dollars
Active time
gemini-3.8-flash was by far the cheapest run —
$5.84, against $60.46 for GPT-6 Astra and $106.73 for Fable 5.1, which ran at
maximum effort for hours and cost 10 and 18 times as much. Time does not follow
cost: GPT-6 Astra took the longest at 255 minutes but cost less than Fable 5.1,
which finished in 170.
Costs are API-equivalent: the tokens each run actually used,
priced at the provider's published list price. Active time excludes pauses.
Appendix
A. Following a pedestrian and a vehicle
In each world the camera follows whichever pedestrian and whichever vehicle
moved furthest during the recording, from the same distance and height.
gemini-3.8-flashfollowing one pedestrianGPT-6 Astrafollowing one pedestrianFable 5.1following one pedestrian
gemini-3.8-flashfollowing one vehicleGPT-6 Astrafollowing one vehicleFable 5.1following one vehicle
B. How much moves in each world
Moving parts counted from each world's own running simulation (a car with four
separately turning wheels counts as five).
run
moving parts
vehicle parts
pedestrian parts
gemini-3.8-flash
24
16
8
GPT-6 Astra
2,561
1,940
621
Fable 5.1
1,580
700
880
gemini-3.8-flash populated its world with a handful of moving things; the
larger models with over a thousand. In gemini-3.8-flash's world the traffic finds
the ground by casting a ray straight down from a fixed 20 m and standing on the
first solid thing it meets — a roof, a tree canopy or the collision shell of
a merged block of buildings — so most of its cars ride at exactly 20.2 m,
above the street, at a perfectly constant speed.