Game Theory on the Blockchain: A Model for Games with Smart Contracts

·

Introduction

The rise of permissionless blockchains like Ethereum has introduced a revolutionary capability: smart contracts. These self-executing pieces of code, capable of maintaining state and interacting with other contracts, enable players in a game to deploy autonomous agents that act on their behalf. This fundamentally alters traditional game-theoretic assumptions about rationality. A player can now rationally choose to deploy a contract that commits them to act irrationally in specific situations, thereby making credible threats that were previously non-credible.

This paper introduces a formal model for analyzing these new types of games. We explore how the ability to deploy smart contracts changes the strategic landscape, generalizing established concepts like Stackelberg equilibria and providing new insights into the computational complexity of finding optimal strategies in these environments.

How Smart Contracts Change Game Theory

In conventional game theory, players are assumed to be rational actors who always choose actions to maximize their utility. The concept of a Subgame Perfect Equilibrium (SPE) is found through backward induction, where players reason backwards from the end of the game to determine optimal moves at each step.

Smart contracts disrupt this model. When a player deploys a smart contract:

This capability to commit transforms the game. Choosing which contract to deploy becomes a strategic move in itself, often taken before the conventional game begins. The interaction between multiple contracts, each reasoning about the others' potential actions, creates a complex, layered game of commitments and counter-commitments.

👉 Explore advanced strategic models

The Formal Model: Games with Smart Contract Moves

Our model builds upon extensive-form games, which represent sequential decision-making as a finite tree. We introduce a new type of node: a smart contract move.

Key Components of the Model

This model elegantly captures the strategic power of smart contracts. Deploying a contract is not just an action within the game; it is a meta-action that redefines the game itself for all players involved.

Recovering Classic Equilibria

A significant strength of our model is its ability to generalize well-known game-theoretic concepts as special cases.

Single Contract as Stackelberg Equilibrium

A Stackelberg equilibrium describes a scenario with a leader and a follower. The leader commits to a strategy first, and the follower optimizes their response based on this commitment.

Proposition: In our model, a game where one player has a single smart contract move is equivalent to a Stackelberg game with that player as the leader. The contract they deploy corresponds to the strategy they commit to, and the resulting SPE in the expanded tree yields the Stackelberg equilibrium outcome.

Two Contracts as Reverse Stackelberg Equilibrium

A reverse Stackelberg equilibrium further empowers the leader. Instead of committing to a single strategy, the leader commits to a response function—a mapping from the follower's possible actions to the leader's best responses. This allows the leader to punish the follower for undesirable choices.

Proposition: A game with two smart contract moves—one for the leader and one for the follower, in that order—is equivalent to a reverse Stackelberg game. The first player's contract can be designed to condition its actions on the contract subsequently deployed by the follower.

These equivalences show that our model provides a unified framework for understanding commitment in games, from classical concepts to the new possibilities enabled by blockchains.

Computational Complexity: The Challenge of Finding equilibria

While modeling these games is powerful, computing optimal strategies is computationally difficult. The expanded game tree, which includes all possible contract deployments, is exponentially larger than the original game.

Our research establishes several important complexity bounds:

We conjecture that the problem for three contracts is NP-complete, lying between the efficiency of the two-contract algorithm and the hardness of the unbounded case.

Table: Overview of Complexity Results for Computing SPE

ContractsPlayersInformationStrategiesLower BoundUpper Bound
02PerfectPureP-hardP
12PerfectMixedNP-completeNP-complete
12Imperfect-NP-completeNP-complete
22PerfectPureP-hardO(T* \L\^2)
33PerfectPureConjectured NP-hardNP
Unbounded-PerfectPurePSPACE-hardPSPACE

Applications and Implications

This model is not merely theoretical; it has practical implications for the design and analysis of decentralized systems.

The ability to pre-commit via smart contracts is a double-edged sword. It can be used to create more stable and efficient equilibria, but it can also be used to coordinate attacks or exploit systems in unforeseen ways.

👉 Learn more about strategic commitment

Frequently Asked Questions

What is a smart contract in game theory?

In game theory, a smart contract is a formalization of a player's ability to irreversibly commit to a strategy or a set of rules before a game is played. It is a programmable agent that acts on the player's behalf, making their threats or promises credible because deviation is impossible.

How does a smart contract create a credible threat?

A threat is credible if it is rational to carry out. A smart contract makes a threat credible by removing the player's autonomy. The contract is programmed to execute the threatening action regardless of whether it seems irrational in the moment, which forces other players to take the threat seriously when forming their strategies.

What is the difference between a Stackelberg equilibrium and a Nash equilibrium?

A Nash equilibrium is a set of strategies where no player can benefit by unilaterally changing their strategy. A Stackelberg equilibrium is a sequential concept where a leader commits to a strategy first, and a follower then responds optimally. The Stackelberg outcome is often better for the leader than any Nash equilibrium because the commitment power allows them to influence the follower's choice.

Why is computing equilibria with smart contracts so complex?

The complexity arises because deploying a contract is a meta-action that creates a new, larger game. Each possible contract a player could deploy leads to a different subgame. Reasoning about all possible contracts and their interactions causes an exponential explosion in the number of scenarios that must be analyzed, pushing the problem into higher complexity classes.

Are these results only relevant for blockchain-based games?

While motivated by blockchain technology, the model is abstract and general. It applies to any strategic setting where players have the ability to make binding, automated commitments before engaging in an interaction. This could include certain automated trading scenarios or long-term business contracts.

What is the significance of the reverse Stackelberg equilibrium?

The reverse Stackelberg equilibrium represents a significant increase in strategic power for the leader. Instead of just committing to a single action, the leader commits to a full strategy that punishes the follower for making undesirable choices. This allows the leader to extract more value from the interaction and achieve a more favorable outcome.