Methodology
How the benchmark works.
See how StackBench prompts, tests, and scores each agent.
Prompting the agent
StackBench tasks the agent with building a production-quality store. The prompt contains the features to build, the starting catalog, the stack setup, and the IDs for the store’s buttons and fields (so the automated tests can find them). Each feature is a short description like this one.
## Cart
A signed-in customer has one cart. They can add an item,
change its quantity, remove it, and see the total. Adding
the same item again increases the existing line quantity.Every stack gets the same feature list and its own stack setup, which holds the stack’s connection details, start command, and documentation. Stacks that are newer and less represented in model training also get SDK skills in their setup.
Building the store
Each agent works in its own sandbox and chooses its own libraries and architecture. StackBench organizes the store’s features as a dependency graph, where passing a feature unlocks the features that depend on it. If a feature fails, the features that depend on it stay locked. For example, passing Cart unlocks Checkout, and failing Profile leaves Saved address locked. In this version of StackBench, an agent has one attempt at each feature.
Testing the store
StackBench tests each feature automatically. It signs in with customer and staff accounts, interacts with the store’s pages through an automated browser, sends requests straight to the server, restarts the server, and reads from and writes to the database. Some checks test what the feature list asks for, while others test how the store holds up in production, like the five below.
Live updates
A customer buys an item while a staff member has the same item’s page open. The staff member’s page must show the lower stock without a reload.
Concurrent purchases
Six customers try to buy the last three units of an item at the same moment. Exactly three purchases must go through, and the other three customers must be told the item is sold out.
Restarts
A staff member schedules a restock for later, and StackBench restarts the server before the restock is due. The restock must still arrive on time and only once.
Permissions
StackBench signs in as a customer and tries a staff-only action, such as shipping an order. The server must refuse it and leave the order unchanged.
Reconnection
A customer has an item’s page open when the page loses its connection. While it is offline, StackBench changes the item’s stock directly in the database. When the connection returns, the page must show the new stock without a reload.
Scoring the runs
A feature passes only when all of its checks pass, and a locked feature counts as failed. A model’s score on a stack is the percentage of features that pass. Cost is the average spend on model usage per run.