Is agent based modelling the best tool for tokenomics?

What is agent based modelling?

Agent based modelling is a very useful and flexible modelling technique. It is especially useful when modelling complex systems, such as societies or economies. This makes it particularly useful when modelling token economies. Agent based modelling can be a powerful tool for any ICO.

My name is Stylianos Kampakis from the Tesseract Academy and in this article I’m going to be talking about this great tool.

 

What is agent based modeling about?

Agent based modeling is a type of modeling where we simulate each individual in a system which could be an economy, or a system related to ecology for example, let’s say a forest or some other physical environment. We simulate each individual separately, and we make the assumption that each individual is autonomous and agents can be heterogeneous. So this means that we create simplified versions of real entities inside a computer.

Agent based modeling has existed since the 1940s but started to become popular during the 90s.

So why is this a useful concept because at first glance it might sound quite complicated?  Why would you want to take a system, let’s say an economy, and model each individual separately?

In most cases modeling takes place through mathematical equations. In order to do that succesfully we need to make a lot of abstractions, and in mathematical modeling sometimes we have to make way too many assumptions which means that in systems  where we can make the right assumptions, or where our assumptions are not correct, then we either can’t build a model or our models are useless.

The beauty of agent based modeling is that we don’t really have to think too much or too hard about how to set an abstract model. We just start with a common intuition about the system, and we start encoding the rules in a piece of software, and then we just simulate the environment. And after many simulations we receive the results and then we start analyzing the behavior of the system.

 

And why is this relevant for blockchain and ICOs?

WeII, through the advent of blockchain and the rise of ICOs, we saw many start-ups creating artificial economies, tokenized economies. And in these economies there are many questions such as how do I reduce the volatility of my economy? How do I control inflation? How do you fight against speculation? And each token economy is a bit special in the sense that they have their own artificial rules, they’re not like the real economy. So it’s not easier to just inherently take models from the real economy and transfer them as they are to a token economy.

So, agent based modeling can be a very useful tool to model these kinds of economies without really having to overthink about how to create a mathematical abstraction around them.

So we’re gonna go through some successful models, some famous models in agent based modeling. One of the most prominent ones is:

 

Schelling’s segregation model

Schelling was a social scientist. He was interested in studying segregation in urban environments, that is in cities. This is a very, very beautiful model that demonstrates the power of agent based modeling. Schelling set up this model of an artificial city where the city is represented by square grids, and each grid is populated either by one of the people in the red tribe, or one of the people in the blue tribe.

 

 

And finally, some grids are not populated. So, the individuals in the two tribes have their own preferences as to where they want to live. These preferences mainly relate to who is around them. So, this, it’s called in the simulation, similarity threshold. But in the real world it’s a bit like a racism threshold in a sense, right?

So, people want to be around other people around them, or they may dislike to be around people that are different to them. And, effectively Schelling studied the different behaviors of the system and the different thresholds of similarity. And what he observed is that, even in situations where the individuals in the tribes really don’t mind if many of their neighbors are of a different tribe, we still see segregation occurring. So, segregation in urban environments does not mean that the people segregated or gathered in an area just according to Schelling’s model, they have a strong dislike from people which they consider to be different, but rather, even if they have a small preference for their own tribe, in a sense, then we can still see these kind of ghettos and communities emerging. So, let’s go and see the simulation in action.

This is Schelling’s segregation model, it’s a simulation created by Stanford. Here we see the different parameters around the simulation. The main parameter is this one, the similar.

We can just reset and then start the simulation.And we see that even when one individual requires that only 30% of their neighbors are similar to them, we still start seeing these kinds of segregated communities form.

Let’s try to increase the threshold and see what happens. So, we see that when we increase the similarity threshold these communities form stronger and stronger clusters.

Another very famous model is:

 

Axelrod’s iterated prisoners dilemma simulation

Axelrod is another social scientist who was interested to study how cooperation is generated, how it’s created in social networks. In order to study these, he devised some sort of game where the individuals, they’re playing an iterated prisoner’s dilemma.

The prisoner’s dilemma for those of you who don’t  know, it’s a very simple game where there are two choices: Cooperate or defect. An individual maximizes their own game if they defect. However, if both individuals defect then they get a low payout. If they cooperate, then they get a medium one. As you can see, if one individual defects and the other cooperates, then the evil individual gets a reward of five. If both of them defect, they get the reward of one. And if both of them cooperate, they get the reward of three.

 

 

It’s called a dilemma because it doesn’t have a clear solution. Axelrod was very interested to see how cooperation or defection will work in this system. He ran this tournament where people tried different strategies.  In the end, the winning strategy was proven to be tit-for-tat, which means that an individual simply mirrors the other opponent’s or the other prisoner’s last response. So cooperate if the other person cooperates, defect if the other person defects. 

 

 

Another very interesting and famous model. Not too complicated. We’re still in the 80s, but still very powerful in the sense that before that no one would have guessed that tit-for-tat would have been the most successful strategy. Actually Axelrod’s case somehow had assumed that people would automatically cooperate. It was proven this is not the scenario. It was a surprise to himself as well that the tit-for-tat strategy was the most successful.

And finally another model, which is more complicated and I personally particularly like, is:

 

Sugarscape

The reason for this model is that it’s essentially the first model in computational economics. Where computational economics mainly deal with a use of agent-based modeling to simulate economies. Sugarscape is an artificial economy where you have individuals whose whole lives revolve around the resource called sugar, as we can see in this animation, it’s gathered into large clusters. It’s like two hills where most of the sugar is clustered. Then these individuals can do other stuff. They can metabolize the sugar if they need it for energy and they can reproduce, and they carry resources, and all that stuff. I mean there are many different versions of Sugarscape. It’s really a simulation that is on one hand simple since within individuals, they can take some basic action, so they have only one resource. However, it’s very powerful. There‘s not enough time to explain Sugarscape in detail, but I would urge you to try and read more about it if you’re interested in the subject.

 

 

Now let’s move on to agent-based modeling and blockchain. This is the topic of this article. That is why agent-based modeling is a very good tool for token economies. The main reason I particularly like agent-based modeling for the analysis of token economies for tokenomics is because we dont really need an explicit theory or an explicit mathematical model in order to create and use an agent-based model. This is something very, very useful because as we stand right now, there are not really many proper models around token economies. In my practice I’ve seen many start ups, many businesses coming up with new concepts around the token economies, which can further complicate any models that might exist in the future. With agent-based modeling, we don’t have to worry about this that much.

Once you understand the main business model around an ICO, then you can start immediately encoding these into a simulation.

 

What’s a general framework for agent-based modeling and ICOs?

Well, the first thing you need to do is define the core entities in your system. This could be the users, or it could be the nodes that validates transactions or it could be investors or speculators.It’s up to you as to how deep you want to go and how important you consider these entities to be.

Secondly, we need to define behaviors. We need to think about what the users can do. Obviously they can buy the token, they can use it, maybe they can sell it. It’s the same for investors. And then after that, we need to run multiple simulations. So you never run a single simulation in an agent-based model. There are always some statistical components which could be a total number of users, maybe some nodes of the price. You need to think about how to insert the statistical components. These are there because it can create different scenarios because the world is uncertain. We need to simulate this stochasticity.

What we care about when we analyze the results, we care mainly about the marginal cases. We care about crashes or we care about rapid valuations. We care about scenarios where the system might do something unpredictable when things might go very, very well or very, very bad. Once we tackle these best and worst case scenarios, then we can be more certain that the system is going to be stable when it’s rolled out in the real world.

 

And how do we ensure this?

We ensure this by determining some ranges of parameters, some optimal ranges of parameters with the burn rate or the total number of coins issued, et cetera.

 

How can you create an agent based model?

If you ask me personally, I like to use Python and R because I’m a data scientist and these are the languages I prefer to use in my day to day practice.

However, there are many kinds of software if you want to create your own agent based models. Starlogo is a very good piece of software if you’re not very experienced in programming. Repast is a Java framework if you’re interested in doing something a bit more advanced. But in reality, there are many choices and you can always just build an agent based model from the ground up in any programming language you prefer. I just find Python and R to be very useful and very convenient for that sort of purpose.

 

 

I hope you enjoyed this article about agent based modeling and I hope that I’ve convinced you at least a little bit as to why this is a great tool for studying ICOs, for building token economies.

Original

Spread the love

Related posts

Leave a Comment