lichess.org
Donate

Can we beat Lc0 With stockfish power?

Chess botChess PersonalitiesChess engineSoftware DevelopmentStrategy
Lets research about it

I believe that Stockfish and Leela Chess Zero are both headed into the wrong direction.

Although Leela uses same strategy as AlphaZero (the learning by playing against itself, using neural network), it does not have the same goal as AlphaZero, which was to do an experiment and be a proof of concept. Yes, Stockfish and Lc0 have a much stronger rating than AlphaZero had, but they are being used as tools, not as experiments. Those who know programming can check their code and notice how much their code mobility has been compromised for sake of performance. But code experimentation asks for code mobility. In other words, the code is too complex. And that's because they are focused in optimizing the code's performance and the use of hardware, to maximize their chess ratings.

That's exactly why they will both be superseded by some other project. By focusing too much on present perspectives, they get no future perspective. So they will be defeated by a new project that has NOT been specifically designed for chess. Like AlphaZero, which was designed to learn different games and solve different puzzles. But this new project will use a different strategy.

There is one thing which is odd about AlphaZero. They call it Zero because it only knew the chess rules and leaned by itself how to play the game well. So it wasn't Zero after all, it was born with chess knowledge. In my understanding, it had been hardcoded with the chess rules. It already knew the the board, the pieces, how they move, how does the game end, and how are the pieces distributed through the board when it starts. So, all AlphaZero did learn was how to create a good "position evaluation function". It learns a value and policy function to guide the exploration in a Monte-Carlo Tree Search.

Are babies born with useful knowledge? No, just survival knowledge. They know how to breathe, cry and suck. But they don't know how fundamental things such as how to understand the visual world, how to walk, how to talk, etc.

Thus, in new experiment, the system will be born with zero knowledge of chess. All it will know from birth is a basic knowledge of graphs, just enough so that the end user can teach it any given game through an interactive API (supervised learning), and only then ask it to learn by itself how to play well that game. The new project will have to use a graph neural network. And, by the way, that's what best resembles the nature's biological intelligence.

Based on the idea that a graph node can represent a chess square, it can learn how to play chess by receiving a series of instructions structured in json format defining the game rules. It will learn:
1 - How that square connects to the 8 adjacent squares, forming the 8 possible moves (actually, the king moves).
2 - How those squares interconnect, forming a board.
3 - How those single-square connections group together, forming the other longer moves (which can be played by bishops, rooks and knights).
4 - How do the chess pieces move (and which are them), including the two-piece castling move.
5 - How the game ends (checkmates and draw conditions such as 3-fold repetition, 50 move rule and stalemates).
6 - How does the game start (which is the chess starting position, and who moves).

7 - How to evaluate a position (like AlphaZero learned)

And step 7 won't necessarily have to start from the chess starting position. It can start backwards (as if it was trying o build chess endgame tablebases). In any case, forward or backward, I believe it should start from an empty board and add pieces one by one. That's because the process of adding pieces changes the graph, just like the removal of pieces. And the empty board allows it to start from the raw knowledge it learned in step 2 above. Actually, it can start from step 1 and build the board.

Please share your thoughts ! :-)
+1-117laugh1thinking5hearthorsey1
polylogarithmique11 months ago
#2
I think that starting from absolutely zero means your engine will be able to learn different games, not only chess, but as a counterpart it will take more time to learn chess than if it already knew the rules.
And it is not clear to me what advantage it would get in terms of quality of play from starting from zero.
Finally, as long as it hasn't been actually done, saying "Stockfish and Leela Chess Zero will be defeated by this" is just empty words, isn't it? Having a big idea is very good, but what really matters at the end of the day is what you actually do with it.
+111-1laughthinking1hearthorsey
EvilChessedited 11 months ago
#3
@polylogarithmique said in #2:

>I think that starting from absolutely zero means your engine will be able to learn different games, not only chess, but as a counterpart it will take more time to learn chess than if it already knew the rules. And it is not clear to me what advantage it would get in terms of quality of play from starting from zero.

The learning of chess rules will be supervised, and immediate, as it does not require any searching. Yes, it will be able to learn different games, such as chess variants, checkers, and etc. Having to learn chess rules is not an advantage. It is just the best and the natural of fulfilling a requirement for pure GNN learning to be possible. The requirement is that chess rules must be stored in the graph itself. GNN is what will actually give it the advantage over AlphaZero.

>Finally, as long as it hasn't been actually done, saying "Stockfish and Leela Chess Zero will be defeated by this" is just empty words, isn't it?

Nickolas Tesla spent days and nights studying, without sleeping or eating appropriately, because he could see AC electricity would change the world we know. His friends came out to talk to his family and say they thought he was getting crazy. He had empty words, at first, but he was lucky enough to be able to spend that time on developing his idea, which soon was proven to be right by a team of engineers. But most good ideas just die as empty words, then they are reinvented again and again by other individuals, until someone finally gets the change to develop and use them for a big purpose. Only then the idea gets known by everyone else. This has happened with the navigation tools, which have been reinvented many times.

Many of the fundamental ideas of major science areas, such as quantum physics and biochemistry, could only be proven decades later, when experiments became finally possible. Example: geneticsunzipped.com/news/2021/8/26/where-did-dna-come-from

Today, internet makes it much easier to make na idea famous, and to spread it through peoples collective intelligence, even subconsciously. For instance, I have been inspired by the way stockfish is analyzing games on lichess, forward and backward at the same time.

>Having a big idea is very good, but what really matters at the end of the day is what you actually do with it.

You're right on that. Indeed, I never said I will actually do anything with it. Since I'm not retired nor a "pensioner", I can only work in things that are profitable (that pay my bills).

So it's just a prediction of an idea that someone else would already have too, anyway. Because ideas come mostly from a context, an era, not from an individual or a team of individuals. Thus, at some point in time, I predict that this idea will be executed by software developers who are being paid for that (thus making profit from it). All it needs is an investor. Though I don't expect to get a chance of being part of this. Unfortunately, I don't work for Google. :-)

+1-1laughthinkinghearthorsey
kalafiorczyk11 months ago
#4
Are you thinking of reinventing en.wikipedia.org/wiki/Genetic_programming from scratch?
+1-1laugh1thinkinghearthorsey
Toscani11 months ago
#5
Chess engines need blinkers like a horse race. The engine needs to remain focused on what is in front. The engine needs to stop looking at what is behind and see what it can do infront or in a particular sector of a chessboard. If it can only solve chess with 3 pieces then disregard the passive pieces or non mobile pieces while trying to find an advantage. First it must calculate to prun pieces out of the analysis. Then it should analyze whith the applicable piece left over. It's like a pawn race, yo just count the squares to see who reaches fisrt, then you analyse the what if's....

The engine does not have to use all 64 squares to solve. It can be 4 sectors of 16 squares. If it finds a solution within a cluster of 4, 9, 16 squares , then it does not need to solve for 64.

Solve like playing crazy house on a chessboard with only 16 squares. The sectors need to talk to each other to request a piece that's needed to mate.

Now you know my thought, have fun programming the idea like crazy house. Then like in genetic programming, crossover the pieces from one sector to the other until that sector is solved.

One of the sectors will have more advantage to be played that the other, so that will be the short term horizon plan.
The long term plan is to solve chess in clusters. Clusters of squares can be sectors. (64/4 = 16 squares)

When the problem is too large, cut it down in size! There are 4 sectors on a chessboard. S1=Bottom left, S2=Top left, S3=Top Right, S4=Bottom Right. So the math guarantees 4 chess pieces in any of the 4 sectors, if 12 pieces exist on the chessboard.

Solving chess with 12 pieces ? (One Black King and it's 5 pieces of chose and 1 white king and it's 5 pieces of choice.)
Place the pieces in each sector and keep doing it until you reach the 12th piece. Solve the sector that has the king in it.

4 sectors, each letter will represent any piece up to 12 letters distributed over 4 sectors. It does not matter where you place the 12 pieces, you will have a sector that has at least 4 chess pieces. You then combine two sectors and solve for advantage or mate.
S1 - a, e, I
S2 - b, f, j
S3 - c, g, k
S4 - d, h, L
Solving by cluster sectors when there is only 12 pieces on the chessboard.
S1 + S2 = a, e, I + b, f, j (6 piece end game table)
S1 + S3 = a, e, I + c, g, k (6 piece end game table)
S1 + S4 = a, e, I + d, h, L (6 piece end game table)
S2 + S3 = b, f, j + c, g, k (6 piece end game table)
S2 + S4 = b, f, j + d, h, L (6 piece end game table)
S3 + S4 = c, g, k + d, h, L (6 piece end game table)

Nothing wrong with this system, it only needs to be some peer review and then coding to an open source engine. Then the benchmark test to see what the gain is.

Solve chess on a smaller scale is the solution to seeing the endgame horizon.

Once the engine engines see's a calculated end, without analysis, it can then start heading in that direction until it sees a quicker calculated end. Seeing the horizon makes all the difference to knowing where your heading and what you will neeed to get there.

Sometimes it helps to see a problem when we hide or remove a piece. It simplifies things. Chess engines need to do that too. Then then would assign a value to the position with one less piece. Engines will need to hide pieces to solve chess. Not all chess pieces are active, so they don't need to be in the analysis until they can become active. So the engine needs to calculate first and analyze second.

Like when we solve mates in one. The engine needs to think the same way.This is a podcast called Genetics Unzipped, so unsurprisingly, we spend a lot of time talking about genes. These are stretches of DNA or RNA that encode the instructions that tell cells to make specific proteins. Just to be pedantic, there are also genes that make functional non-coding RNAs, which don’t encode a protein but instead have their own job to do in cells.
As far as we can tell, all of life on earth evolved from one common ancestor, LUCA, which must have had one set of genes, whatever they looked like. But that leaves the question of how this simple set of genes diversified to encompass the incredible diversity of genes that now exist in trillions of extant and extinct species on earth. In other words: where do genes come from?
Some new genes form when nature tinkers with existing ones by accidentally changing, duplicating, blending or breaking them up. Small changes in some powerful genes can make them a major source of evolutionary change. For example, changes in HOX genes that help lay out complex organisms’ body shape, telling your body ‘make a head here’, ‘make feet here’ can have enormous consequences for the resulting organism.
HOX genes are often arranged in clusters thought to have formed when a single original HOX gene was duplicated. For example, humans have 39 HOX genes in 4 clusters. That’s a lot of accidental copying and pasting. We talked about this more back in episode 3 of our previous series, Fish, Facts and Fiction.
Other genes have even weirder origins, with the latest science showing that some of our genes come from our mortal enemies - viruses.
Throughout evolution, our ancestors have been locked in a war against invading viruses. These tiny molecular machines consist of little more than a string of genetic material in a protein coat, invading our cells and hijacking their machinery to create millions of copies of themselves, sometimes at the expense of our lives.
Some viruses, such as HIV, are retroviruses, meaning that they can insert themselves into our DNA, where they get copied and pasted into multiple parts of the genome. During the course of evolution, these inserted viral genes can jump around, mutate and change, eventually becoming embedded in their host's genome. As a result, scientists think that around half of our genome contains DNA sequences that have been abandoned by ancient viruses, adding up to a whole lotta genetic junk.
But sometimes, as it turns out, organisms have harnessed these viral invaders and put them to work for their advantage.
For example, syncytin genes, which make proteins that help form the placenta during pregnancy and stops the mother’s immune system from attacking her baby in the womb look suspiciously like genes from a retrovirus – which are often masters at evading attack from the immune system.
Curiously, the syncytin gene is only found in humans and large primates, suggesting that somewhere in our evolutionary timeline, before humans and primates split, we stole these viral genes and turned them to our own ends. Interestingly, some mammals - including mice, cats and dogs- have syncytin genes that do the same jobs but look like different viruses, suggesting that other sections of the evolutionary tree employed the same tactic but using different viruses.
Other stolen viral genes help us defeat viruses themselves. For example, a gene in the human genome that switches on immune defence mechanisms when it detects a viral infection, forcing infected cells to self-destruct, has been traced back to a retrovirus from 45 to 60 million years ago
The viruses trapped in our genomes have bought us enormous benefits, but unfortunately, it isn’t all good news. The ability of viral genes to jump around our genome can deactivate essential genes and cause disease. Experts suggest that a new jump occurs in around 1 in 20 babies, which can be harmless or - just as easily - disease-causingor even deadly, depending on the genetic changes resulting from the jump.
Jumping genes have also been linked to the genetic chaos inside cancer cells and other conditions like schizophrenia, epilepsy, and intellectual disabilities. What’s more, it turns out that stealing genes is a two-way street, with recent analyses showing that pathogens like influenza can snatch genetic sequences from their hosts and use them for their own sneaky devices. Unfortunately, it seems to be hard to keep our genes to ourselves!

References

The early evolution of the genetic code- Cell
Driving change: the evolution of alternative genetic codes- Trends in Genetics
How evolution builds genes from scratch - Nature
On the origin of degeneracy in the genetic code - Proceedings of the Royal Society
On Nature’s Strategy for Assigning Genetic Code Multiplicity - PLoS ONE
Evolution of the genetic code through progressive symmetry breaking- Journal of theoretical biology
RNA Relics and Origin of Life - Int J Mol Biol
Which came first, the virus or the host? - Promega Connections
The Origin of the Genetic Code - Francis Crick (1968) JMB
Origin and evolution of the genetic code - The universal enigma - IUBMB Life

Kat Arney
evolution, origins of life, viruses

More information

Genetics Unzipped is the podcast from the Genetics Society - one of the oldest learned societies dedicated to promoting research, training, teaching and public engagement in all areas of genetics. Find out more and apply to join at genetics.org.uk
Blog Archive Contact Twitter