GetIt.jpg

  This extension adds a lot of functionalities to your lichess web site. It has so many useful and powerful features! I am very proud of it. The extension is always going to be free, ad-free, donation links free, etc. Yet the only way for it to do what YOU want is feedback. Any feedback! Praise, curses, bug reports, feature requests, use stories, anything. The more you tell me, the more I can improve on this!

  LiChess Tools (ver. 1.9.5) adds the following features to lichess:

  • play ALL variations in Interactive lesson study chapters!
    • computer is going to play a random move (configurable probability), so you don't need to create a chapter for every small variation
  • merge multiple PGNs in analysis import
    • I merged 1000 PGNs with 25000 moves and it worked!
  • automatically open/hide/convert to menu the Friends box at page load
    • having the friends box as a menu item is really neat
  • sound alert when one of your friends starts playing a game
    • also reading the type of game, so you know if you even want to look at it
  • ability to randomly play one of the next moves (with configurable probability in comments i.e. prc:66) with Ctrl-RightArrow
    • also go back with Ctrl-Left for convenience
  • highlights for the last move of variations (special case for the ones that have no comment and do not end in checkmate) in the analysis/study board
    • you immediately see not only where a variation starts, but also where it ends
  • highlights for the transpositions to the current move in the analysis/study board
    • you won't ever have to worry that you are analyzing the exact same variation but in a different order
  • changing the shortcut for playing the next best computer move from Space to Shift-Space
    • always annoyed me when I accidentally pressed the key
  • a minimum chess engine level
    • if it is idle in a lower state, it runs until it gets to that level
  • sticky Interactive lesson Preview mode
    • you can now play chapter after chapter without hassle
  • use keyboard shortcuts (i, m, b, Alt-i, Alt-m, Alt-b) for inaccuracies, mistakes and blunders
  • show player country flags next to their names
    • if they have their country specified in the profile
  • say verdicts aloud in practice mode
    • this is more of a gimmick, that's why it's disabled by default
  • show the order of circles and arrows in a study/analysis.
    • this is great when you want to understand the order of moves/hints
  • push TV game URLs in browser history and/or a new menu item to open the last viewed TV game
  • show opening name in TV and mini games
  • show history section in user TV (just like for category TV)
  • quick button to switch to your user and back in personal opening explorer
  • ability to remove players from the list in personal opening explorer
    • this was requested on the lichess forum and was implemented in the same day
  • copy to clipboard branch and continuations from a certain position in analysis/study
    • you can now just pick a variation, copy it in its own chapter, with just a few clicks
  • available languages: English and Romanian
    • ask for more! I will provide you with the English sentences and the context and you can tell me how it is in your language
  • now the options for the extension are in the lichess Preferences section
    • complete integration. The extension popup has no functional role anymore
    • this also means that I will be able to port this to other browsers with minimal effort. Ask if you want this!
  • move options from transpositions to the current position
    • soon the Extended Interactive Lessons will also be able to choose moves following from the same position, but in a different branch
  • automatically evaluate last moves in every variation and store it as a comment
  • show chapter names from Event tag in studies, if the chapter name seems to be default (i.e. Chapter 1)
  • set colors to study comments
  • study chapter navigation controls, including random chapter button

  I couldn't wait to share it with you guys. I will be happy for any feedback, suggestions or help.

  I've started a series of use case blog posts, they might show you how to use the extension in real life:

Here are some screenshots, but they don't really tell you the story. You just have to try it.

More power to Studies

Options are now in the lichess Preferences

A lot of new options for lichess TV

Copy variation PGN directly from move list

Examples

I wrote a detailed post on how to build and use Interactive lessons, but there were always some annoying issues with the analysis board that I am striving to fix.

First, you had to add a chapter for each line. If you have a complex PGN with multiple lines you would have to split it into many small chapters. Not anymore! You can just play every variation in the chapter. For the possible moves that you have, all will be considered valid. For the possible moves of the opponent, one will be chosen at random. You can specify probabilities with the prc: notation that also works with the Ctrl-Right feature.

All the moves available in the PGN will be considered good, all others bad. For the moment I just assume that if you see a blunder on your move, you should not continue on that path, unless you want to see what's wrong with it.

You can also use Ctrl-Right in any analysis mode to move to one of the following moves. An extra option is to specify the probability that a move will get played. Let's say you created a PGN of the games of your nemesis, and they play 10% e4 and 90% d4. In your PGN add prc:10 and prc:90, respectively, to the comments on moves e4 and d4. It's that easy! And it works for any other analysis mode.

A good complement for the features above is the ability to import multiple PGNs and merge them into one. Now you can do that by simply pasting the entire text and importing it in the analysis PGN text area. I've improved the performance and fixed a few bugs in v1.7.4 which makes it possible to work with HUGE study chapters. The v1.8 feature automatically commenting last moves in every variation is also very useful in this scenario.

Another annoyance was that you opened one chapter to train, clicked on Preview and after that chapter, when selecting a next chapter, you would have to press Preview again. And again. And again. Now you have the option of "sticky Preview". The setting will stay put until you change it. Soon I will do the same with the threat mode.

Finally, you are working on a repertoire that is very complex. Your PGN has reached impressive sizes. Only now it is harder and harder to use it because you can't determine where the lines end. If you are like me, you like to continue a variation until mate or until there is a decisive advantage, which you will add as a comment. Now the last move of every variation will be slightly brighter and ending in a superscript L and, if not commented or ending in a mate, it will also be underlined with red.

You are looking at one of your games and you want to quickly cycle between inaccuracies, mistakes and blunders. Now you can do it with the keyboard. There is a separate extension for this, made by another guy, but I think mine is implemented better.

Finally, you want to relax, watch chess TV and you think you saw a great move somewhere. But suddenly one player resigns and before you realize it and click on the Analysis board button, the game switches to another. Now you can specify how long to wait before it switches and if you want the same for when watching a particular user TV. (The time feature has been removed, because it was hacky)

So what you do is any one of these options:

  • open the Watch menu and click on Last Viewed Game
    • this will take you to the last game you saw end
    • if you are already on the last game and you click on the menu item again, it takes you to the previous one
  • use one of the two games in the history area under the board
    • public TV already has this, but the extension adds the same thing to user TV
  • go back with the browser back button
    • note that there is a bug in Brave and perhaps other browsers where if you click on the Back button it takes you to the previous visited link, not a game, but if you long press you see the entire list of games and can choose one

Good luck using my extension. I am sure I am going to be tinkering with it a bit. Let me know of any problems you have with it.

Other ideas

Here is a list of ideas that I am not sure I want to implement or are just too new. The green ones are already implemented! The struck out ones will not be unless someone insists. If you feel you want them, give me a shout.

  • Studies/Analysis
    • key/button for random chapter (also after finishing an interactive lesson) (v1.9.5 adds navigation controls under the chapter list) 
      • I had the idea of a random chapter link, so you can embed it yourself in the comments. This can't be implemented at client level.
      • also many people order their lessons so they would not appreciate a random chapter button
      • an idea is to place such a button not at the end of the interactive lesson, but as a control in the chapter list itself, under the Add new chapter one, like a music player with a shuffle button
    • the default probability of a next move should be calculated based on all the following branches (v1.8 takes into account all variations for 8 ply)
    • use Game Explorer to determine the probability of a move in a study chapter PGN
      • maybe even insert/update prc: comments.
    • show score (good/total moves) at the end of interactive lesson (v1.5.3)
    • sticky Threat mode (x)
    • sticky analysis moves on reload
    • automatically analyze with browser chess engine all the uncommented branch end moves in the PGN until a certain depth and write the evaluation as comment (v1.8)
    • mark moves in Game Explorer for:
      • most successful move
      • most gambit move
      • most forcing move
  •  Transpositions
    • a button to show all transpositions in a PGN (moves that reach the same moves as others in the PGN) not only those for the currently selected move
    • a way to determine transpositions to moves in other chapters of the study
    • changing the arrow keys functionality to continue from a last move in a variation to transposition which has following moves
    • showing following moves from transpositions to the current position (v1.7.3)
    • make Interactive Lesson be able to choose from transposition moves as well
  • Shapes
    • show numbers on arrows and/or circles to show their order (useful when you want to express a plan and the order of moves is relevant) (v1.5.4)
    • additional shapes?
  • Friend playing alert
    • make only one sound alert regardless of how many lichess windows are open (v1.6.1)
    • disable alert for some types of games (like bullet or chess960) (v1.8.4)
    • also say the type of game they play (like "wgraif playing blitz") (v1.6.3)
    • select beep/voice for alerts
    • use the time controls vs the Event tag to determine type of game (also allowing for translation) (v1.8.4)
    • use notifications that work even when the LiChess page is not open and add a lot of extra functionality to the friend alert feature
      • There is a very nice extension for this called LiNotify. It does a lot for friend alerts and I doubt I would replicate their good work. Try to use that for extra alert features.
  • Friends
    • show a list of people following you
    • alert or notification when people follow you
    • tag friends to different groups and allow different settings for the groups (perhaps interact with LiTags)
  • Fix LiChess bugs
    • "next chapter" button in a study doesn't always follow the chapter order if you manually reorder chapters in the study
      • it happened once and then I couldn't reproduce it anymore. Maybe it's not real.
    • chess engine still on when entering Preview mode in Interactive Lessons, even if not visible (v1.5.3) 
    • if you premove in Practice mode or move too fast, you start to get verdicts for the computer move
      • I really tried to fix this, but the functions called (makeComment, comment) are private and I could not replace them. Anyway, practice mode is a mess! 
    • the output of the game explorer API contains duplicate JSON output (try changing the current move in the FEN parameter and see the difference)
      • that's purely a server bug, cannot be solved by LiChess Tools.
    • when you finish an Interactive Lesson and you press the Analysis Board button, the wrong moves you tried to make are in the PGN, but if you try to do anything with them, the PGN resets and they disappear
      • fixed by LiChess Tools v1.5.3. If LiChess developers want to know how to fix it, it's that setGamebookOverride() functions differently from setGamebookOverride('analyse').
  • Move speed alert
    • alerts when you take too long for a move
      • there is at least another extension for this, but for Chess.com, where Levy Rozman and Hikaru Nakamura soundbites are thrown at you if you are too slow :)
      • I don't really think people would use sound options too much, so how about a configurable system that would make your clock puff up or something when you take too long?
  • go to game analysis after your games (or maybe the one you are watching) end (useful to force you to analyse your games instead of stubbornly hunting for a win)
    • I find this a bit too forcing, but then again, you could disable it
    • Also there is another extension that does this
  • Search games
    • download all of a user's games from a certain position, search games based on specific moves, certain positions, certain fragments of positions
      • This requires a lot of hacking, since the LiChess APIs do not expose this functionality. I am afraid that would be tantamount to abusing those APIs.
  • Game explorer
    • Use game explorer to make all first N moves for M levels from the current position (perhaps also automatically add prc: comments)
  • Import games
    • since analysis PGNs have a maximum number of moves before they don't accept more, import just "first N" moves when import/merging PGNs in enhanced import.
      • limit for PGN import removed in v1.7.4
    • when merging games, find a way to calculate the percentage of that move and automatically add prc: comments
    • add easy filtering options for importing, like particular variations, specific tag, etc., in Analysis Import 
  • TV
    • specify the time between switching to a new game in TV mode
      • v1.6 removes this functionality on account of it being hacky and unstable
    • instead of delaying switching from a game to another, how about a history back/forward mechanism?
      • the game URL in put browser history, accessible by the back button (v1.5.5)
        • note that the Brave browser has a bug that requires you to long press the Back button to see the list of games
      • a menu item in the Watch section goes to the last viewed game (v1.5.7)
      • user TV should have a history section like the category one (last two games by the user as mini games) (v1.6.1)
    • how about an extended TV feature, where you can filter and sort which games to watch, or watch only your friends' games, you can switch if you don't like the current one, etc?
      • really, I am thinking of leaving TV as it is unless someone comes with a good reason to tinker with it more
    • add Game Explorer interface to TV games
      • I think this might overload the system.
    • show opening name in TV game (v1.5.7) and in mini game popups (v1.5.8)
    • double click on squares to add their coordinates to chat
      • could use the arrows and circles mechanism to translate them into text when created
    • option to bookmark game and see the game link (v1.6.6)
  • Forum
    • get notifications for replies to subscribed forum posts
    • get list of subscribed forum posts
  • General
    • global on/off extension button that doesn't involve disabling it from the browser extensions page 
    • a low API call mode in which calls are throttled or not made (maybe set it automatically when receiving 429)
    • add all texts and voice messages injected into LiChess website to a siteI18n object that can be used to translate them according to language and use the current language for voice prompts (v1.6)
      • I will not do the translating myself, I expect users that care about this to come with their own texts (see the JavaScript object lichessTools.siteI18n) 
    • an event log that you can open with a click
      • sometimes people don't want distractions like alerts and other stuff, but want to see what happened while they were away
    • a focus mode button (do not disturb with alerts while this is on)
      • maybe set it to on automatically when playing
    • move options to the lichess site Preferences (v1.7)
    • add more languages (Romanian v1.7)
    • ability to save Preferences in incognito mode, too
      • this was added in v1.8.8, but you have to specifically check the preference that enables this.
      • the data will be saved as the private notes of your first lichess game.
  • Requests from people
    • challenge log - a log of who all I challenged and who challenged me for a game will be a nice touch
    • hide/show/move friends box - a menu item that allows that? Drag the box around?
      • now you can also choose to hide the friends box (v1.5.8)
      • idea to move the friends box as a menu item (v1.6.4)
    • a game source tab for yourself in game explorer (v1.5.8)
    • remove some player names from the list in personal Opening Explorer (v1.5.8)
    • right click on a variation to copy it to another chapter (or as a PGN) (v1.6.1)
    • option to rename/reorder study tags
      • there are no APIs to change topics for studies you don't have open. I don't think I can do anything.
    • add Stockfish analysis to live TV games (could enable cheating)
    • option to disable rematch requests from other players
      • something similar: don't receive rematch requests a configurable amount of time after playing them
    • show possible game continuations from the correct move in Learn From Your Mistakes
    • bug fix: import a game as a study chapter, rename the chapter, then save the study PGN. The Event pgn tag does not change
      • this may actually be construed as a feature not a bug. The imported chapter will have the original Site PGN tag, which can be edited in the Tags section. New chapters have no such tag and create it from the chapter title.
    • import PGNs in studies with the content of the Event tag as the chapter name, if present
      • tried it and it works for one PGN, but if you paste more, all other chapters are going to be generated with default names. Tried various things, but tags are not easily accessible. In the end, it's easier to just select the chapter, copy the event tag name and edit it into the chapter name.
      • v1.8.10 adds the ability to display the chapter names based on their Even tags, but it doesn't change their names as far as lichess is concerned. It's just a display gimmick.
    • chat improvements:
      • automatic replies to standard texts (that are already configurable from the settings to be sent automatically)
    • bookmark puzzles and forum posts (similar to how you can do it for your own chess games)
      • TV games can be bookmarked now (v1.6.6). Unfortunately you can only bookmark a valid game, not puzzles or other random things. I could create a local mechanism (browser local storage) to bookmark everything else, or a dedicated server for this, but both seem overkill and yet not enough.
    • allow your friends to watch what you are watching or to set up a viewing for multiple people of the same game
    • a resize handle for the analysis move list in order to better visualize branches (would work great on very large screens)
    • allow study creators to decide if the order of the chapters is random and how (a new Next Random Chapter button would be added to the existing one or replace it altogether)
      • maybe a way to set up the next chapter in the current one?
    • a workaround for the max 64 chapter limit for a study (user had 1000 puzzles that he had had to split into multiple studies)
      • tried to make it work, but there are too many limitations and I don't want to butcher lichess
    • add codes to comments to make them look differently (like class names or specific colors) (v1.9)
    • some people might get discouraged by the final score in the Extended Interactive Lessons, so can it be disabled by a preference? (v1.9.3)
  • Bugs to fix
    • copying the PGN from a move when the game started from a specific FEN position gives you an unusable PGN. It should retrieve not only the moves, but also the initial FEN position as a PGN tag. (v1.6.6)
    • sometimes the voice for the friend playing announcement is not heard, only the beep.
    • the first White move in an Extended Interactive Lesson is always from the main line, ignoring branches when playing as Black. (v1.8)
    • highlighting stops if moving between study chapters (v1.8.2)
    • write a comment for an interactive lesson move that is yours and then click Preview, the comment is not shown and the computer makes the next move (v1.9.3)

Q&A

Q: Can you publish your extension code on GitHub?
A: Yes, I could. Probably I will be starting with version 2, which will be a rewrite of a version 1 that has been in use for a while and that people have given me feedback for. As much as I like sharing my code, I really don't want to have to deal with all the GitHub complications right now.

Q: If your code is not on GitHub, it doesn't exist! Also, I looked at your code and it sucks balls!
A: That's not a question. And I agree. But right now I am focusing on features, not quality control. Wait for V2.

Q: How do we contact you with new ideas, bug reports and general roasting of your coding skills?
A: Use this post. This is my personal blog and my preferred method of communication. On top-right you can see a lot of links to various methods of direct communication with me, although I would prefer thoughtful feedback to remain documented here, as comments.

Q: I am addicted to LiChess Tools and I am afraid later on you will fill it with ads, premium features and EULAs that allow you to remove my kidneys. Can you address my fear?
A: Like everything on this blog, it will always remain free. And not free as in "until someone else buys it" or free as in "watch videos and it's free" or free as in "I will fill your screen with junk", but completely utterly free. Like LiChess, I guess. Also, it doesn't connect to any external services or capture any user data. For now! Muhahahaha! Later on it might need some external services for extra features that you ask for, but I hope it doesn't.

Q: How long did it take you to write this?
A: Mostly a week. Following the 80/20 rule, now I have to work at least one more month to make it good.

Q: You should write a tutorial on how to use it. Could you make a video of it?
A: I am not a video person. I hope that this post can convey the basic ways in which to use the extension and that the extension itself can be used without the need of a tutorial. Let's work together to make this clear and easy to use for everyone instead.

Q: Your Extended Interactive Lesson feature is all I had ever wanted from life! But when I am editing the study, I get the same interface as normal studies. Can you fix it?
A: Some parts of LiChess are easy to change, some not so much. Anything related to rendering is a mess to hook to. Additionally, I wouldn't want to have studies that can only be edited and used with my extension.

Q: So how do I mark the good branches from the bad variations?
A: Any branch that is not in the study will be bad. Same as a normal Interactive Lesson. As for the ones that you want to explore specifically, use the annotations (Mistake, Blunder, Brilliant Move, etc) and comments. You can even explore the bad branches in Preview mode this way and learn why they would be bad.

Q: Can you add features to show me what moves to make while playing?
A: LiChess Tools is not a cheating tool.

Q: But can you add some features that don't involve cheating for the games that I am playing/watching?
A: Most of the features of LiChess Tools are analysis oriented because analysis is much better exposed than the game code. Because there are a lot of private variables that are not made accessible, it's difficult to selectively change parts of the game interface and any features would have to brutally copy paste and replace some legitimate code bits. I am afraid that until that changes on LiChess, I will not touch that part, mostly because that means I would have to keep score on what they change on the web site and update my extension accordingly.

Q: How about changing the way LiChess looks?
A: I am not a good visual designer, nor do I do a lot of work on web frontend. There are some extensions that are doing that and perhaps you should ask those people for help instead. Also, I am avoiding as much as possible changes to the visual elements of the website specifically because it might interfere with some such extension or custom CSS tool. BTW, if you are working on something like that and find LiChess Tools is interfering with your stuff, let me know. We can figure things out. 

Q: OK, you're my new hero. How can I help?
A: Contact me and let's talk. I despise doing anything UI design related, as evidenced by this blog and the extension popup, so maybe you can help there. Also, not a specialist in browser extensions, so any improvements and/or help with other browsers would be welcome.

Q: Yeah, but I can't code. How can I help?
A: Help me by making this extension well known. I don't want "marketing". Just let people know and if they like it, they will use it. Can't use it if they don't know about it, though, and I am always afraid people think I am spamming them when I try to advertise my work.

Q: I use LiChess in my own language and the new features are jarring in English
A: I've implemented the translation mechanism, but I need the texts for the various languages. If you provide them, I will make them available. See the JavaScript object lichessTools.siteI18n for the texts requiring translation.

Q: Chrome sucks! Microsoft sold out! Can you make this work for my favorite browser?
A: Short answer: no. Long answer: if I had assistance with extension code and testing, perhaps. I want to help people, so the more the merrier, but I also don't have a lot of resources to maintain code on a browser I don't use.

A: That's not my bug, it comes from LiChess. They have bugs, too.
Q: How could you possibly have answered before I asked the question?

Q: Did you actually think people were going to read this far down?
A: No.

Q: I told about this to all my friends, I came with feedback and constructive criticism and it feels like you ignored me. What gives?
A: For sure I want to take everything into consideration and act on requests as fast as possible, but it might be that I am caught up with something else. I thoroughly intend to give the extension as much attention as possible, so maybe make sure I got your message, first.

Hope it helps!

Comments

Be the first to post a comment

Post a comment