跳到正文
TwoPeanuts· 来源· @PeanutPair · X·· 5 天前同新闻AI 评分70

同一新闻,精选展示《Karpathy 用 Claude Code 和 Opus 5.5 基于真实数据构建游戏地图》

正文

卡帕西让Claude把美国真实数据画成《文明》地图,我点开收入那层看了一会儿,原来查数据也能这么像逛游戏啊。

卡帕西11月26日在X分享了这个作品usaciv。他说,自己让Claude Code里的Opus 5.5把美国公开数据装进《文明》风格的地图,做了约7小时,生成4.5万行代码,接了31种真实数据来源。GDP变成“金币产出”,城市的产业特点也有了游戏里的名字。我喜欢这种做法,原来只想扫一眼的统计表,换成地图后就想多点几个地方。

我实际打开了网页,切到Income。地图下方直接写清,这里比的是家庭收入中位数,来自美国人口普查局ACS 2024年的五年调查数据。Almanac说明页还提醒,城市名下的数字覆盖整个都市圈,不能直接当成市区的数据。看着像游戏,读数时仍得知道自己在比什么,这些说明留着,我才愿意继续看。

来源页也能翻到人口、GDP等数据的出处和年份。我没有逐项审计原始数据,但很喜欢它把这些留给读者检查。AI能把表格做得漂亮以后,少掉来源和统计范围也会更难察觉;这次换了呈现方式,仍能回头查数是从哪里来的,这比单看“写了多少行代码”更能打动我。

卡帕西也说,Claude漏了几个州和地区;当前网页的说明写的是美国本土48州。这是一份可以打开探索的AI作品,还不能当成完整的《文明》游戏或已全部核准的数据工具。我这次看的,是收入视图和说明、来源页,没有重跑他的开发过程。原帖里有网站链接,也有Claude做的预告片。
https://x.com/karpathy/status/2125779541952246039

引用Andrej Karpathy@karpathy
I asked Claude to populate a Civilization-style game map with real data from the US. Opus 5.5 downloaded and parse a ton of public data and 7 hours and 45K lines of code later... it works :) - 31 real data sources including Census, BEA, BLS, EIA, NOAA, USGS, DoD, NPS, FAA, FEMA, CDC... - Real elevation, land cover, GDP, jobs, power plants, mines, ports, airports, bases, parks, universities, freight flows, disasters; all reconciled onto one 25 km hex grid. - The data is converted into Civilization language, e.g. Gold yield is GDP. A city's districts are its real industry specializations: San Jose gets a Campus, Detroit is "Motor city". Its citizens are its real workforce: 1 in 4 San Jose workers are engineers, coders or scientists, against 1 in 14 nationally. Wonders are chosen by published rules, such as national parks by visitor numbers and universities by R&D spending, etc etc. - 19 lenses (income, degrees, faith, disasters…), a City View for 524 metros, and nine advisors plus an Explorer. The Explorer turns any column for any of 3,100+ counties into a table and scatter plot, linked to the map. - Claude decided to skip a few states and territories sry - Built using Claude Code desktop app, Opus 5.5 on medium and turning on ultracode. It's deployed here: https://karpathy.ai/usaciv/ and the "?" has the source link too. I don't exactly know where I was going with this but it's really fun to browse and play with. Possibly it can be expanded or built into a game. I only have half of my weekly Claude quote left though so someone else will have to take over :D. Claude also made a trailer:
在 X 查看被引用的帖子

来源:TwoPeanuts · x.com