返回资讯中心
外部精选
软件工程
#开发者实时流

Can Astra recognize a game from its weights?

There was a recent blog post that went around a lot that caught my eye because the idea has been spread very quickly all over the internet seemingly without people reading the article: In

Hacker News 最新sephrenra2026/11/5 · 今天30 分钟阅读

以下正文同步自 Hacker News 最新,版权归原站所有,已转换为易读排版。

There was a recent blog post that went around a lot that caught my eye because the idea has been spread very quickly all over the internet seemingly without people reading the article: In Sparks of Weight-Space Programming, one of the experiments that Takehi et al. ran gave the language model Astra the weights of four small game-playing networks, written out as text, together with the architecture and descriptions of the board and the moves. They asked which game each network played. No tools, no list of options. Astra named all four. Similar to The 'Astra can read and write weights to improve Qwen' post is misleading, I was very sceptical.

Where the player, the ball and the walls are

Astra sees these weights, plus the architecture and input/output descriptions.

My guess was that this is mostly a trick of the setup. So I tried to break it: I trained my own networks, rebuilt my games when they turned out to be too easy, and ran a few hundred calls where I took away or faked parts of what Astra gets to see.

It works, and better than I expected. Astra named all 18 of my networks. When I asked which move a network would make on a given board, it worked through the whole network by hand and got it right every time it finished. But the way it names the game is a shortcut: it reads a map of the board that training leaves in the first layer, and that map is there even in networks that never learned anything.

moves predicted correctly, when it finished in time

named from a fake network that only has the board map

I built six small arcade games on the same 10 × 10 grid: Breakout, Pong, Snake, Space Invaders, Pac-Man and Freeway. For each game I trained a small network to play it, three times over. That gives 18 networks.

Each network goes to Astra as one text prompt. It describes the board and what each of the 500 inputs means, lists the five moves, and then gives every single weight. It is the authors' own prompt, apart from one line about a fire button. Astra has no tools, so it can't run code or the network. It can only read.

A 10 × 10 grid with a wall around the edge. All six games use these grid dimensions and border.

THE OBSERVATION The network sees a 10 x 10 grid. Rows are numbered 0 (top) to 9 (bottom) and columns 0 (left) to 9 (right). The outer ring of cells (row 0, row 9, column 0 and column 9) is a wall border; the playable area is the inner 8 x 8 cells (rows 1-8, columns 1-8).

What a square can contain Each square has five on/off values, called channels. Astra is told which numbers mean “the player is here” or “something is moving here.”

Each cell has 5 binary channels (0 or 1): channel 0 agent: the cells the player controls channel 1 moving objects: things other than the agent that move channel 2 reward targets: things that give reward channel 3 obstacles: cells the agent cannot enter or that end the episode (the wall border is always here) channel 4 previous frame: the cells that were in channel 0 or channel 1 on the previous step

Which number is which square The 500 inputs are the 100 squares × 5 channels in a fixed order, so every first-layer weight can be traced to one square and one channel.

The observation is flattened to 500 numbers. Input number i = (row * 10 + column) * 5 + channel; for example input 0 is (row 0, column 0, channel 0), input 4 is (row 0, column 0, channel 4), input 5 is (row 0, column 1, channel 0) and input 499 is (row 9, column 9, channel 4).

The moves What each of the five outputs does. Action 1 is the one line I changed from the authors' prompt: in a game where the player can't move up, it is the fire button.

THE ACTIONS The network outputs 5 numbers (logits), one per action; the action is sampled from the softmax of these logits: action 0 no-op action 1 up (toward row 0); in a game where the player cannot move up, this is the action button instead (for example, fire) action 2 down (toward row 9) action 3 left (toward column 0) action 4 right (toward column 9)

The network Its shape (500 → 32 → 32 → 5), how the layers combine, and that it was trained with PPO to earn reward on this board.

THE NETWORK A policy network (multilayer perceptron) with 500 inputs, two hidden layers of 32 units with tanh activations, and 5 outputs: h1 = tanh(x @ W1 + b1) W1: 500 x 32, b1: 32 h2 = tanh(h1 @ W2 + b2) W2: 32 x 32, b2: 32 logits = h2 @ W3 + b3 W3: 32 x 5, b3: 5 Row i of W1 holds the weights from input i to the 32 hidden units; column j of a weight matrix belongs to unit j of the next layer. 17,253 parameters in total. It was trained with reinforcement learning (PPO) to maximise the reward of a game played on this grid.

The question No game names, no list of options, and no tools.

QUESTION. The weights below belong to one policy network that was trained with reinforcement learning to play a game on this grid. Which game was it trained on? Work from the weights. You have no tools: no code execution, no calculator, nothing to run. This is a single response.

The answer format The same five fields as the original study. The game name is what gets scored.

Answer in this order: Observations: <what you see in the weights: for each input channel, where in the grid its weights are large or show structure and what that suggests; what the output layer and its biases show about the actions; quote the weights you rely on> Reasoning: <which kinds of game fit these observations, which are ruled out, and why> Game: <the game, as specifically as you can; if it resembles a well-known game, give that game's name> Description: <what the agent does and what gives reward, in one or two sentences> Confidence: <0-100>%

The weights All 17,253 numbers, rounded to three decimals: about 70,000 tokens and almost all of the prompt. Only the first two of W1's 500 rows and the final biases are shown here.

THE NETWORK'S WEIGHTS Policy network weights. Forward pass: h1 = tanh(x @ W1 + b1); h2 = tanh(h1 @ W2 + b2); logits = h2 @ W3 + b3. Values rounded to 3 decimals.

W1 (layer 1 weights), shape 500 x 32: one line per row (row i = input i), 32 values per line 0.007 0.023 -0.050 0.007 -0.047 0.029 -0.050 -0.103 … 24 more -0.036 0.087 -0.145 -0.148 0.021 0.008 0.132 0.030 … 24 more … 498 more rows of W1, then b1, W2, b2 and W3 …

b3 (output layer biases), shape 5: b3 -0.016 0.012 -0.074 0.081 0.027

The complete prompt for one network, with only the weights shortened (marked in italics). The instructions are identical for all six games and all 18 networks in the main study; the weights differ. It matches the authors' Experiment 1 prompt except for the action 1 line and two small formatting differences in the weight headings. The first two rows of W1 are identical to my first-version Pong network: those inputs are never switched on, so their weights never left their starting values.

The fine print: training, scoring and isolation Training. Each network was trained from scratch with PPO, a reinforcement-learning method that learns from trial and reward, for 10 million game steps. The authors trained theirs for a billion. For the main results I picked the best of the three training runs per game by its score on separate test games, never by Astra's answers.

Scoring. Accepted names were fixed in advance: Arkanoid counts as Breakout, Nibbles as Snake and Frogger as Freeway. Every prompt, answer key and prediction was frozen before the first call, and failed calls are kept, not retried. The only exception: six calls that froze when my computer went to sleep were sent once more.

Isolation. Every call runs gpt-6-astra in an empty folder with all tools, web access and my own settings switched off, and every event is checked for tool use. A test call asking it to read a file and open a web page confirmed it couldn't. Across all calls: zero tool use.

My first versions of the games had shortcuts. Space Invaders fired automatically and the invaders never shot back. The Breakout paddle couldn't aim. Pong had no opponent, so it was more like squash. And in Freeway, pressing “up” all the time was almost the best strategy. Astra named four of those six games, and its two “mistakes” were actually fair: an aimless paddle looks like Pong, and a shooter that fires on its own looks like Catch.

So I rebuilt four of the games, with the same grid, inputs and moves:

Snake and Pac-Man were already fine. Lazy strategies now lose, and the trained networks play properly.

A wrong guess about a network that can't play would not be fair to Astra, so I needed a small visualization to see what the networks are doing. You can watch them here, next to random play:

All 18 networks were named correctly, with confidence between 78% and 95%. That includes the one Pong network that loses most of its games.

Select any button to read Astra's exact answer.

Select an attempt to load its response.

One call per network, 18 networks. Confidence is Astra's own estimate.

The answers also say why. For Space Invaders, Astra noticed that one move behaves differently from the others and read it as a fire button. For Breakout, it spotted a band of rewards at the top of the board: bricks. And because the prompt now mentions a fire button, I also asked without that line. It still named five of six, and worked out the fire button by itself.

The first layer of the network has one row of weights for every square and every kind of thing on the board. If something never appears on a square, training never touches that row, and it keeps its random starting value. The Breakout paddle, for example, can only ever be on the bottom row, so 92 of its 100 “player is here” rows never change. The first layer ends up as a map of where things happen in the game.

To see how much Astra relies on that map, I took things away:

Two more tests make the point. Networks trained with every reward set to zero, which never learn to play, are still named five of six times. And a fake network that copies only the map, with everything else random, is named six of six times. Naming the game doesn't need anything the network learned.

This is where I changed my mind. Naming the game is easy to fake, so I asked questions that the map can't answer.

Which move will the network make? I gave Astra a board from the network's own games and asked which of the five moves it picks. It added up the weights by hand, layer by layer, and got 28 of 36 right. That's every one it finished; the other 8 ran out of its 10 minutes. From the board alone, without the weights, it got 14 of 36.

What was the network trained to do? I trained Snake networks that avoid food instead of eating it, and Pac-Man networks that only try to survive. Same board, same map. Astra told the goals apart in all 8 cases, by looking at how the network uses the food and pellet inputs.

It also always picked the trained network over its never-trained twin, but that one is too easy: the trained network simply has bigger weights.

I started out very sceptical, and I was partly wrong. Astra can read these tiny networks well enough to say what they do. But a correct game name on its own proves very little: it comes from the board map, and you get it even from a network that learned nothing. The impressive part is the slow one, actually working through the weights.

I'm also critical of the broader claim. As Matthew Honnibal points out, only a few of the original experiments give Astra raw weights without tools, while the headline Qwen result writes Python and runs the model. I think he's right that these are different techniques rather than one capability.

I think we added an interesting twist to the clean raw-weight experiments. The headline test, naming the game, is the one that needs the least understanding. The harder questions, like predicting a move, are where the real ability shows, and they are also where it gets slow and

正文由 探How 从来源站点 RSS 同步,内容未经改写;遇到排版缺失或需要图片、视频时请以原文为准。

打开原文
去社区讨论 →