Skip to content

Bug in calculation of Puzzle Popularity? #12408

@goodspellr

Description

@goodspellr

I'm looking through the puzzle database (downloaded from https://database.lichess.org/#puzzles on 15 Feb. 2023) and I've come across 8 puzzles that have a "popularity" greater than 100. According to the documentation, this shouldn't happen.

Here is a list of the puzzles:

PuzzleId FEN Moves Rating RatingDeviation Popularity NbPlays Themes GameUrl OpeningFamily OpeningVariation
P9tbW r1bq1r2/pppp1pkp/2n3pN/2b1P3/P7/6Q1/1PP2PPP/RNB2RK1 b - - 3 12 d7d6 c1g5 f7f6 e5f6 1934 89 104 42 crushing opening short https://lichess.org/Wot0bma8/black#24 Ruy_Lopez Ruy_Lopez_Open_Berlin_Defense
ZTa65 7r/pp1kn1Rp/3p4/4p3/1n2P3/2NPP1P1/PPP4P/6K1 b - - 0 17 b4c2 c3d5 h8e8 d5f6 d7d8 f6e8 1446 75 103 1203 crushing endgame fork long https://lichess.org/4R1f08Mm/black#34 Italian_Game Italian_Game_Giuoco_Pianissimo
nlayx r2q1rk1/p3npbp/2p3p1/1p2Nb2/3Pp3/4P2P/PP2BPPB/R2Q1RK1 b - - 1 15 f7f6 d1b3 g8h8 e5f7 f8f7 b3f7 1429 86 105 46 crushing fork long middlegame https://lichess.org/jj2XO4xp/black#30 Modern_Defense Modern_Defense_Other_variations
ptOrF 3r4/1p6/p1n1b3/2P1k1N1/1P1pp1P1/P3P1K1/B7/5R2 b - - 0 46 e6a2 f1f5 1445 160 106 57 endgame mate mateIn1 oneMove https://lichess.org/EpN14kb3/black#92 nan nan
rTsjo 2rqk2r/3bbpp1/p2ppn1p/8/1n1NPPPP/2N1B3/1PPQB3/2KR3R w k - 0 15 g4g5 c8c3 g5f6 d8a5 d2c3 b4a2 c1d2 a2c3 2355 78 103 83 middlegame https://lichess.org/yedDQT52#29 Sicilian_Defense Sicilian_Defense_Scheveningen_Variation
uo1zm r3kb1r/ppqn1pp1/2p1p3/7p/3P2nB/P1N2B1P/1PP2PP1/R2Q1RK1 w kq - 1 14 c3e4 c7h2 808 83 129 101 mate mateIn1 oneMove opening https://lichess.org/phxVvBqe#27 Scandinavian_Defense Scandinavian_Defense_Classical_Variation
xB5aH 2k5/ppp2ppp/8/8/1PKB4/3R2P1/q1P3QP/3r4 w - - 0 24 d3b3 a2a6 c4c3 a6a1 1645 202 200 7 crushing endgame short https://lichess.org/68NIJbqI#47 nan nan
ynV70 8/p4k2/2p5/5q2/4R3/2Q2Prr/PP3K2/3R4 w - - 2 31 d1d7 f5d7 e4f4 f7g8 c3c4 g8g7 2365 130 106 23 crushing defensiveMove endgame hangingPiece long https://lichess.org/snTg0Omv#61 nan nan

Also, the documentation on the website seems to be a little off. It says that
"Popularity is a number between 100 (best) and -100 (worst).
It is calculated as (upvotes - downvotes)/(upvotes + downvotes), although ..."
However, I think there is a missing factor of 100 in that formula (otherwise popularity would be between 1 and -1)

It is unclear how this affects operation, if at all, because I do not know what "popularity" is used for.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions