In-browser AI Analysis

Can we have the option to run Katago within OGS to analyze positions?

Compared to using a tool such as Katrain, or Lizzie with a suitable backend, the advantage is largely one of convenience. Not only would the user not need to install such a tool, but it’s much faster to analyze a game played on OGS within OGS then it is to load them into another program. I for one have never desired to install stockfish when it can already be run on lichess.

The primary concern is about performance. Web Assembly aims to offer native speed, but testing will need to be done to see how close to native performance can be achieved. I’m furthermore unsure if it will be possible for user’s to leverage their graphics cards, or if the feature will be CPU only.

Lastly, and importantly, I would personally like to offer to implement and maintain this feature. To ensure that the feature can in fact be implemented I’ve spent some time getting Katago to compile to WASM, and have Katago running within my browser.

So what do y’all think? Let me know.


Site supporters can already analyse full games with katago

1 Like

Currently, OGS does already offer game analysis via KataGo within the OGS interface. However, this is perk for supporters. This analysis feature involves analyzing games with KataGo running on OGS servers, which provides significant compute power to give strong analysis.

However, what you seem to be describing is different, by suggesting that KataGo analysis could be essentially run on the user’s hardware via executing the engine within the browser. If this could be entirely implemented in front-end changes, this might be feasible as a community-led project, since the front-end code is open-source.

Do you have a prototype working already? What type of performance are you getting compared outside of browser execution? Can you benchmark operations/playouts per second?


Hi yebellz, thank you for your reply! I don’t have performance statistics yet, but I’m planning to benchmark both versions and see how they compare. I’ll send you the results from that once its done. As for a prototype, if the performance seemed promising enough I was planning to begin integrating it into the OGS frontend. Perhaps I’ve misunderstood, but it sounds like you’re suggesting creating a standalone gui that could set up board positions, and analyze them. Is this something you’d like to see?

1 Like

No, I’m not suggesting that