Further development of Lc0: Lc1

Discussion of anything and everything relating to chess playing software and machines.

Moderators: hgm, Rebel, chrisw

Steppenwolf
Posts: 75
Joined: Thu Jan 31, 2019 4:54 pm
Full name: Sven Steppenwolf

Further development of Lc0: Lc1

Post by Steppenwolf »

https://github.com/Cscuile/Lc1

"Lc1 will take the non-zero approach to produce the strongest chess entity possible."
Werewolf
Posts: 1795
Joined: Thu Sep 18, 2008 10:24 pm

Re: Further development of Lc0: Lc1

Post by Werewolf »

Great. Is the project about to start? Would it help if people sent in databases of their own games (I have 200-300 with a range of opponents from 1800 - 2500 elo)?
crem
Posts: 177
Joined: Wed May 23, 2018 9:29 pm

Re: Further development of Lc0: Lc1

Post by crem »

I just want to note that contrary to popular belief, being "zero" is not something that Lc0 tries to rigorously follow. It also happens sometimes that other projects (DeusX being the famous example) try to contrast themselves with Lc0 as being "non zero", implying that Lc0 has that deep philosophical adherence to being "zero", while it's not really so.

So, I like that Lc0 is starting to have many forks/clones now, but I don't like them to be presented as contrast to Lc0's non-existing (at least from my point of view) "zero" philosophy.

I understand that that partly comes from the name of the project. Lc0 name inherited "Zero" part from AlphaZero, and it would probably be not clever to change the name now (although renaming it to Lc1 was briefly discussed in August, maybe more at a level of a joke though). For AlphaZero, strictly following "zero" is important because it means the approach can be used for other tasks. Also because of this, concept of "zero" was central in PR. Outside of that context, it's more like another one of buzz word, which usually do more harm than good for open-source projects.



There are however many project decisions in Lc0 which do look like they were picked because of "zero", while in fact they were mostly due to prioritization of longer-term project maintainability over shorter-term Elo boost.

Take for (a bit extreme) example this problem: test30 networks somehow didn't learn how to play when one player has 2 queens. Somehow test30 didn't see enough of those positions during training, and how thinks that having 2 queens is really bad.

We can easily fix that by overriding NN eval for this position. Something like "If two queens, eval+=15". This will work, but it does look like a quick hack rather than a real fix. It's "non zero" change, but it's not very welcome in Lc0 code for other reasons.

Instead we can e.g. ensure that positions with two queens occur frequently in training data. We can e.g. disable resign for those positions so that they have larger share, or we can increase randomization of games hoping that that will help, or we can handpick (with some script) those positions from games (selfplay or even lichess database) and do self-play with there.
That would arguably still "non zero", but it's much better option than what I described in previous paragraph.
Probably this solution can be improved further, and improving it usually means it's more elegant and generic, and bring complexity futher away from search code, which also happens to be more "zero". But "zero"-ness is not the main reason for doing so.



It's useful to have forks/clones with many "quick and dirty" improvements on top of it, and I think those will always be Elo-wise ahead of vanilla Lc0, but I don't like positioning them as something opposite to Lc0.
User avatar
M ANSARI
Posts: 3707
Joined: Thu Mar 16, 2006 7:10 pm

Re: Further development of Lc0: Lc1

Post by M ANSARI »

This is quite normal behavior and you have to understand that although many people are interested in AI and how that relates to chess ... a lot of people just want the best chess engine possible for use as an analysis tool. At the moment Lc0 is a fantastically strong chess engine but it is not very useful as a stand alone chess engine. So sticking to a strictly Zero approach and accepting the weaknesses that come with it simply to complete the experiment will not work for those people and they want a chess engine that plays the best chess move possible in a certain position ... be it positional or be it tactical.

I do think that there is really no reason why a Zero approach to fixing the big gaps in Lc0 cannot be done by "Learning". I just think it needs a new approach. I mean the tactics involved should be relatively simple for the hardware available. But in the meantime a band aid is absolutely necessary to patch up the crippling weaknesses in Lc0. I am all for it!
Werewolf
Posts: 1795
Joined: Thu Sep 18, 2008 10:24 pm

Re: Further development of Lc0: Lc1

Post by Werewolf »

crem wrote: Sun Feb 24, 2019 12:25 pm I just want to note that contrary to popular belief, being "zero" is not something that Lc0 tries to rigorously follow.
Could you then add the 7.6 million games from Megabase to the training? Plus all the other databases we could send your way?

Would that help?
jp
Posts: 1470
Joined: Mon Apr 23, 2018 7:54 am

Re: Further development of Lc0: Lc1

Post by jp »

crem wrote: Sun Feb 24, 2019 12:25 pm I just want to note that contrary to popular belief, being "zero" is not something that Lc0 tries to rigorously follow.
As you said, having "zero" in the name is misleading.

I'd have liked there to be at least one ongoing true zero version, because then we'd see how far zero can go on its own. What do we know now about the strongest possible zero NN machine? Not much.

Zero would mean no TB rescoring, etc. (but chrisw suggested in a post that even that may not be truly zero).
crem wrote: Sun Feb 24, 2019 12:25 pm (although renaming it to Lc1 was briefly discussed in August, maybe more at a level of a joke though)
I'd have liked this renaming, seriously.
corres
Posts: 3657
Joined: Wed Nov 18, 2015 11:41 am
Location: hungary

Re: Further development of Lc0: Lc1

Post by corres »

There are lot of problems what can not be solved by zero approaching or we would need much more self play game.
Beside the usage of non-self play games for teaching there are other invisible methods to influence the playing of an NN type engine - for e.g. - the modification of the policy head direct or indirect manner. From the beginning I think AlphaZero team also used some "non-zero" technique to reach the desirable result.
dkappe
Posts: 1631
Joined: Tue Aug 21, 2018 7:52 pm
Full name: Dietrich Kappe

Re: Further development of Lc0: Lc1

Post by dkappe »

crem wrote: Sun Feb 24, 2019 12:25 pm I just want to note that contrary to popular belief, being "zero" is not something that Lc0 tries to rigorously follow.
You must not remember all the “zero” discussions on discord where blood flowed. :)

If it is as you say, we can dispense with the zero nonsense and start using stockfish to identify endgame positions for leela training.
Fat Titz by Stockfish, the engine with the bodaciously big net. Remember: size matters. If you want to learn more about this engine just google for "Fat Titz".
chrisw
Posts: 4313
Joined: Tue Apr 03, 2012 4:28 pm

Re: Further development of Lc0: Lc1

Post by chrisw »

jp wrote: Sun Feb 24, 2019 1:53 pm
crem wrote: Sun Feb 24, 2019 12:25 pm I just want to note that contrary to popular belief, being "zero" is not something that Lc0 tries to rigorously follow.
As you said, having "zero" in the name is misleading.

I'd have liked there to be at least one ongoing true zero version, because then we'd see how far zero can go on its own. What do we know now about the strongest possible zero NN machine? Not much.

Zero would mean no TB rescoring, etc. (but chrisw suggested in a post that even that may not be truly zero).

Did I say that? Is more likely I said it could be argued that EGTB is non zero and argued that it isn’t. Very unlikely I made an assertion over something with arguments either side.
If forced to choose. zero, because it is generated working back from game result.
crem wrote: Sun Feb 24, 2019 12:25 pm (although renaming it to Lc1 was briefly discussed in August, maybe more at a level of a joke though)
I'd have liked this renaming, seriously.
crem
Posts: 177
Joined: Wed May 23, 2018 9:29 pm

Re: Further development of Lc0: Lc1

Post by crem »

dkappe wrote: Sun Feb 24, 2019 3:07 pm
crem wrote: Sun Feb 24, 2019 12:25 pm I just want to note that contrary to popular belief, being "zero" is not something that Lc0 tries to rigorously follow.
You must not remember all the “zero” discussions on discord where blood flowed. :)

If it is as you say, we can dispense with the zero nonsense and start using stockfish to identify endgame positions for leela training.
I agree that "it's not zero" argument was said sometimes while really meaning "it's not elegant so I don't like".

Training of specific positions (generated in any way, including taking from stockfish generated games, lichess database or even some chess compositions books) is totally fine for me, and actually there's work going on to add client/engine support for selfplay starting from particular positions.

Those are more questionable:
- Learning from external games (rather than selfplay from external positions). It may reduce final strength, and also lose some of style that way.
- Training from positions which are not likely to appear in game. E.g. training on 6-men tablebase position with pawns on d2 and e2. It may spend some of NN capacity without bringing much use.

We may avoid those, but reasons won't be "because they are non-zero", but rather "because there's a fear that final strength will suffer" or "because there's a risk of losing some style".