Siderite / lichessTools

Browser extension that turbocharges the lichess.org site with extra functionalities
MIT License
23 stars 5 forks source link

Demote variation context menu #252

Closed Siderite closed 11 months ago

Siderite commented 1 year ago

In order to arrange lines in PGNs, the current options are only "promote variation" and "make mainline" (apparently they may do exactly the same thing according to user).

It should be working like this:

Dboingue commented 1 year ago

Kudos. Finally. what else.. ok precisions and background from five years of user adaptation to software. But your set of 3 functions is the solution, in the context where indentation is now happening without user intervention when n=2. It is more about describing current problems further, than replying to your proposal, which I find perfect as at the level it is verbalized.

(apparently they may do exactly the same thing according to user).

They only do the same thing in studies. They act differently as they should, in all other analysis contexts or features.

I think having a set of context menus that only reorder branches one notch at a time (promote and demote), using the (optional!) mainline branch post branching point as a 0th index, and only reached by a mainline, would accomplish exactly the same thing in those contexts and in study. Most of the time the concept of make mainline is lost to study users, as it needs to have habitual nested variations needs. and a certain use type of studies is that there are mainlines and all other branches are caveats to it.

However during the study act of analysis, one is actively exploring and creating variations. sometimes beyond the existing mainline.. and in game correspondence at each move beyond mainline, as what is mainline when searching for candidate moves and exploring their variations.

This can get complicated to explain to people having never tried to play with bushy variations in contrast with only variations with respect to a immutable mainline premise. So, who does that the most? correspondence users, in-game.

I should also bring up the fact that demote already exist but it only acts on mainline. I have a little dance in non-study analysis features for reordering to represent my current thinking evaluation of each sibling branches. (since 2019, it has become second nature, but I lose patience and gain neck pain in studies... for the recursive dance is multiplied... because of the underreported bug within lichess obvious intention for that context menu distinct choices.

I have some hypotheses to the "etiology" of that bug (i.e. the abhorrence of void where the mainline continuation branch should be, that is unique to study chapters and likely the reason that is does not seem to bother many).

I was writing somethings and realized that your bullets were it.. congratulations for having gotten my previous conversation sharing elsewhere. It is good to be understood once in a few years.

I like 0th notch for mainline.. as it can still be part of ordering ... although in correspondence, it would be close to sending the move.. Also, it needing to create deeper branching, lichess requires it to happen from mainline..

I think that your indentation feature allows decoupling the demote function from the indentation 2D visual feature.

Dboingue commented 1 year ago

I am curious about your ideas of where in lichess layers and modification entry points, could such solution be implemented parallel to lichess own mechanisms.. I suspect extension would override some JavaScript. I am just curious from afar.

This is not just about styling. And in study, there might be some surprise about how the server is handling chapter variations internally, that might affect the variation manipulation context menu. This is an hypothesis of why the study has not evolved like the standalone, post-game and in-game analysis modes, as is manifest in that context menu conflation of 2 distinct choices. That server and local analysis internal data structures are different, and no-one dares touching the foundational study.

perhaps the import export mechanism through PGN, it tangled with such internal data structure. And if the PGN data structure implementation is not flexible enough to handle empty variations as RAV would enable, having a variation manipulation that has to go throught that older partial PGN implementation would keep interference with the intent of the manipulation.

In slow machines, I can see the 2 step process of a lower notch sibling under "promotion" user choice of context menu, spend some time at notch1, and then slip (in study only, I repeat, study) to be mainline. I think whether the mainline continuation sibling was there or not. I think making an explicit index for sibling would help. but that is guessing something i like to do.

Dboingue commented 1 year ago

I hope the above is on topic. and readable. I can improve upon request and hints to what might need it.

Siderite commented 1 year ago

Perhaps an option like "reorder", and you get to drag and/or click on up/down little buttons (or keys) to move the variation in real time. I would certainly enjoy this more.

Dboingue commented 12 months ago

I replied to list from my email.. how long before it comes here. so i can edit it.. reread myself. some typos are annoying some might be critical to meaning.. i will wait.. a day..

concise keywords:
transversal tree navigation or reordering

2 things that seem to be outside most digital or online chess tools using tree data structures. In chess it translates to the hand-move sequence dominating the logical aspect of thinking, while the activity of playing is primarily a visual thinking one.

anything to improve what is missing.. for navigation (which is not the same as reordering, for whatever reason) see chesstree.net for arrow button in both depth and width directions.. I have not seen other places doing that. There might be local proprietary software that might do it. But not online. The depth first motto, is still the assumption, and constraint.

shift-? menu. I am not clear on whether it does transversal navigation, or it did not look intuitive.. and seemed to require lots of hand eye coordination, away from the chess thinking which could look a position across diverging branches not just as distinct hand move sequences, but also at board vision level the board evolution.

The mainline continuation at branching node versus blob of variations sibling to it, where each line is a whole new distinct "path", is dismissing all the "continuity" through divergence that the real sequences are doing, on the board. Being able to move smoothly in transversal, might unclog those sinuses where things don't seem to connect anymore..

The branches all descend from the same full position information. some information exist in the transversal direction. being able to move in that direction both a perception and evaluation level, and as is your post talking about, when ready to make some decision, or partial ones, then reorder or just placing where we want. does not always have to be about evaluation.

Why do I bring navigation? because that is faster activity than ordering, which might be the result or some partial thinking. shift-? might be crowded. if it does make transversal a peripheral task allowing eye on board most of time, then there might be some interest in your dragging by mouse solution.

A slower time scale process. where eye on board for inspection, is less needed if knowing where one is and was. ok. i might just delete the other reply.. seems this one has less typos... and more principled organization.

I am not concise because this is not just about a feature. but a set of features that can work with each other. or break if not conceived together.

I have seen enough features elements and their intent (more that as there are many to figure out), to see that things like bookmarking branches can synergize with transversal nav. and sibling notch grain level of branch manipulation. call it reordering. idea: mainline could have index 0. and the blob of variations start at 1. This would be the ordering kept by machine. It can have many human thinking motivations.

Siderite commented 11 months ago

Unfortunately there is no good API to enable this. You can only promote with a parameter of "toMainline" true or false. This has to be part of the PGN editor (https://github.com/Siderite/lichessTools/issues/210) or implemented on the server side by Lichess.