lila README

The project's README from github.com/lichess-org/lila. As one markdown file: README.md.

lichess.org

Crowdin Mastodon Bluesky Discord Ask DeepWiki

Lichess homepage

Lila (li[chess in sca]la) is a free online chess game server focused on realtime gameplay and ease of use.

It features a search engine, computer analysis distributed with fishnet, tournaments, simuls, forums, teams, tactic trainer, a mobile app, and a shared analysis board. The UI is available in more than 140 languages thanks to the community.

Lichess is written in Scala 3, and relies on a modified Play 2.8 framework. scalatags is used for templating. Pure chess logic is contained in the scalachess submodule. The server is fully asynchronous, making heavy use of Scala Futures and Pekko streams. WebSocket connections are handled by a separate server that communicates using redis. Lichess talks to Stockfish deployed in an AI cluster of donated servers. It uses MongoDB to store more than 12 billion games, which are indexed by elasticsearch. HTTP requests and WebSocket connections can be proxied by nginx. The web client is written in TypeScript and snabbdom, using Sass to generate CSS. All rated games are published in a free PGN database. Browser testing done with Browserstack. Proxy detection done with IP2Proxy database. Software builds and CI/CD done with Depot. Please help us translate Lichess with Crowdin.

See lichess.org/source for a list of repositories.

Join us on Discord for more info. Use GitHub issues for bug reports and feature requests.

Installation

./lila.sh # thin wrapper around sbt
run

The Wiki describes how to setup a development environment.

HTTP API

Feel free to use the Lichess API in your applications and websites.

Supported browsers

Name Version Notes
Firefox 115+ Full support (recommended)
Chromium / Chrome 112+ Full support
Edge 111+ Full support
Opera 97+ Reasonable support
Safari 16.2+ Reasonable support

Older browsers will not work. For your own sake, please upgrade. Security and performance, think about it!

License

Lila is licensed under the GNU Affero General Public License 3 or any later version at your choice. See copying for details.

Production architecture (as of July 2022)

Lichess production server architecture diagram

Credits

See lichess.org/thanks and the contributors here:

GitHub contributors

Competence development program

Lichess would like to support its contributors in their competence development by covering costs of relevant training materials and activities. This is a small way to further empower contributors who have given their time to Lichess and to enable or improve additional contributions to Lichess in the future. For more information, including how to apply, check Competence Development for Lichess contributors.

lila (lichess-org/lila)

Searching Database…

18.8K ·GitHub
这是什么?Lichess(lila)是 lichess.org 背后的免费、无广告的开源在线国际象棋服务器,主打实时对弈和使用便捷。
这是 lichess.org 网站本身,还是可以接入我自己应用的库?它是驱动 lichess.org 的真实服务器代码——一个完整的实时国际象棋服务器,不是库。它依赖的纯国际象棋规则放在单独的 scalachess 子模块里。
我能自己跑一份吗?没有快速安装的办法:Wiki 里介绍的是如何搭建完整的开发环境,构建工具链要求 Node 24+ 和 pnpm 12+。
在我的浏览器里能用吗?只支持较新的浏览器:Firefox 115+(推荐)、Chrome 112+、Edge 111+、Opera 97+ 或 Safari 16.2+。更旧的版本无法使用。
代码真的可以随便用吗,还是有什么限制?采用 GNU Affero GPL 3 或任意更高版本,可自行选择——这是一个强 copyleft 许可证,契合它永久免费、非公益为使命的定位。
为什么一切都免费?谁来付钱?Lichess 以非营利方式运营,永久免费、无广告、开源正是这个项目的宗旨。连分析用的服务器集群都跑在捐赠的服务器上。
网站支持多少种语言?超过 140 种,这要感谢社区通过 Crowdin 为 Lichess 做翻译。
对局中的走子怎么这么快就传到对手那里?实时对弈通过 WebSocket 实现,由一台单独的专用服务器处理,它通过 Redis 与主服务器通信。
Size
702 MB
Stars
18.8K
Age
14y
Commits · 90 Days