[KongchangAI]
· 2 min read· 1,417 words

Real Data-Driven Toy Town: Claude Builds a 3D Miniature City

Real Data-Driven Toy Town: Claude Builds a 3D Miniature City

Creator writes an engine from scratch in Swift and Metal, driven by real timetables and sensor data for 3D toy-town animation, with Claude Code coding and scoring.

Modeled on Fürth, Germany and the railway to Munich, the project builds a 3D world resembling an N-scale model railway. All moving objects strictly follow real timetable and sensor data from Saturday, October 10, 2026, including train speeds, river levels, wind speeds, parking, and star positions. The creator wrote the rendering engine from scratch in Swift and Metal, with Claude Code writing code and humans directing, testing, and quality control. The film is one continuous long take of 22,680 frames rendered on two Macs. The project took about a week, debugging is now the main work, and the creator plans to open-source it.

Recently, the Reddit community shared an amazing project: a 3D animated world modeled on the German city of Fürth and the railway line to Munich, looking much like an N-scale model railway. What makes this project most striking is that every moving object in the film—every train, S-Bahn, U-Bahn, tram, and bus—strictly follows the timetable and sensor data from a real-world day. According to the creator, the project took only about a week, and the main workload has already shifted from development to debugging.

reddit source: Opus 5.5 / Fable 5.2: An animated toy town you can fall into: every train, bus and tram in this film

Engine from Scratch: The Pursuit of Excellence with Swift and Metal

The technical foundation of this project is quite unusual. The creator did not use any off-the-shelf game engine, but instead wrote the rendering engine from scratch using Swift and Metal (Apple's graphics API). This approach is uncommon in similar projects—developers typically choose Unity or Unreal to quickly build scenes—but this creator clearly pursued deeper, lower-level control.

During development, Claude Code took on the role of writing code, while the creator himself handled directing, testing, and "complaining"—suggesting that in complex projects, AI is more of an executor while humans focus on creative direction and quality control. This collaborative model is quite representative in today's era of increasingly prevalent AI-assisted development.

Real Data Drives Everything

The core appeal of the project lies in its data-driven nature. None of the animations are hand-crafted; instead, they are driven by real recorded data from Saturday, October 10, 2026:

  • Every train, S-Bahn, U-Bahn, tram, and bus appears at real times and locations
  • ICE 501 passes through the 7.6 km Euerwang Tunnel at 250 km/h
  • River levels (Regnitz River at 181 cm) are displayed in real time with source and timestamp
  • Wind turbines rotate at wind speeds measured by the German Meteorological Service
  • City parking lots show available spaces
  • Real sun position, and a sky containing 2.55 million catalog stars

In addition, building footprints and heights are based on real data, and the terrain and tracks are also real. The visual style deliberately maintains a "toy-like" feel: marzipan-like walls and model trees create a unique miniature-world atmosphere.

Swift is a programming language launched by Apple in 2014, emphasizing safety, speed, and modern syntax, and has become the mainstream choice for app development on iOS, macOS, and other platforms. Metal is Apple's own low-level graphics and compute API, released in 2014 with iOS 8, replacing OpenGL ES in the Apple ecosystem. Compared with traditional graphics APIs like OpenGL, Metal allows developers to control the GPU more directly and reduce driver overhead, thereby achieving higher rendering efficiency in high-load scenarios. Because Metal is deeply integrated with Swift and can fully leverage the graphics performance of Apple chips (such as the M series), choosing this technology stack means the creator can finely control the rendering pipeline of every frame, but must also handle scene graph management, resource loading, shader writing, and other tasks typically done by a game engine. This is exactly the challenge of "writing the engine from scratch" in this project, and explains why debugging took up most of the time.

N gauge is one of the common scale standards in model railways, with a track gauge of 9 mm, corresponding to a real gauge ratio of approximately 1:148 to 1:160 (slightly varying by regional standards). This scale is popular because it allows long routes and complex scenes in limited space, and is especially suitable for representing railway networks interwoven with city and suburbs. The article describes the 3D animated world as "looking much like an N-scale model railway," precisely emphasizing its miniature, exquisite, and toy-like visual style. Unlike true-scale simulation, N-scale models often create interest through exaggerated details and compact layouts, which is consistent with the deliberate toy feel of "marzipan-like walls and model trees" in the project. Understanding this background helps grasp the creator's balance between real data and artistic style.

Production Process: Rendered on Two Macs as a Single Continuous Shot

The film is a continuous long-take flight, totaling 22,680 frames, rendered directly from the application on two Macs. The creator not only used Claude Code to write code but also had Claude compose the film's "music." This level of AI involvement throughout the entire process demonstrates the potential boundaries of current AI tools in creative projects.

The creator says the project has been completed for about a week and is now working on open-sourcing it, welcoming community help. For those who want to dive deeper into the data, the engine, or using Claude Code on large-scale projects, this is a rare case study.

A long take refers to a single shot in film and television works that is continuously filmed without editing; in 3D animation, it means the entire scene must be continuously loaded and updated in real time, without relying on shot changes to hide gaps in rendering or data loading. For this project, a continuous-shot flight of 22,680 frames (about 12.6 minutes, estimated at 30 frames per second) requires the engine to stably maintain synchronized updates of all moving objects, environmental effects, and astronomical data throughout the entire flight; any stutter or missing data in any frame would break continuity. This explains why rendering required two Macs working in tandem, and also highlights the stability challenges faced by writing an engine from scratch under long continuous rendering. Long takes are often used in animation to create immersion and spatial continuity, which aligns closely with the concept of an "enterable toy town."

Significance and Insights: Exploring the Boundaries of AI-Assisted Development

What drew attention to this project is not only its visual appeal but also the several key trends it demonstrates. AI programming tools are evolving from simple code completion into collaborative partners capable of supporting complete project development. In this project, Claude Code handled engine writing and music generation, while humans handled creative decisions and quality control.

At the same time, the project reveals new possibilities for data visualization: integrating real-world timetables, sensor readings, and astronomical data into a unified 3D environment to create an experience that is both real and dreamlike. This "enterable toy town" may foreshadow new directions for future urban data display, educational simulation, and even game design.

Of course, the project's limitations are also obvious—disk space is a real constraint, meaning expanding to more areas will require more efficient storage solutions. But the creator's willingness to open-source and open attitude give this project value beyond itself in the technical community.

Claude Code is a command-line-based AI programming assistant launched by Anthropic. Unlike traditional code completion tools, it can understand the context of the entire codebase and execute multi-step coding tasks, including creating files, running tests, and debugging. In complex projects, Claude Code can handle module-level code writing but requires humans to provide clear goals and continuous feedback. The article mentions that the creator was responsible for "directing, testing, and complaining," which precisely reflects the typical division of labor in current AI-assisted development: AI as a highly capable coder, humans as requirement definers and quality gatekeepers. This model has obvious advantages in shortening development cycles, but it also places higher demands on human architectural judgment and debugging skills, because AI-generated code still requires humans to understand its behavior and locate problems. The project's open-source plan will also provide the community with a sample for observing the actual effects of AI participation in large projects.

One-line Summary

The creator wrote an engine from scratch using Swift and Metal, driving 3D toy-town animations with real timetables and sensor data, with Claude Code contributing to coding and music.

Paragraph Summary

The project is modeled on the German city of Fürth and the railway line to Munich, building a 3D animated world that looks much like an N-scale model railway. All moving objects—trains, S-Bahn, U-Bahn, trams, and buses—strictly follow the real timetable and sensor data from Saturday, October 10, 2026, including train speeds, river levels, wind speeds, parking spaces, and star positions. The creator did not use an off-the-shelf game engine but wrote the rendering engine from scratch in Swift and Metal, with Claude Code writing the code and humans handling directing, testing, and quality control. The film is a single continuous long take totaling 22,680 frames, rendered on two Macs. The project took about a week, with debugging now the main work, and the creator plans to open-source it.

#Claude Code#Swift Metal engine#3D animation project#real data driven#toy town miniature world
Share:

Related articles