{"id":18894514,"url":"https://github.com/developerpaul123/byte-knight","last_synced_at":"2025-07-14T11:07:56.729Z","repository":{"id":253607025,"uuid":"834151322","full_name":"DeveloperPaul123/byte-knight","owner":"DeveloperPaul123","description":"A UCI compliant chess engine, written in Rust.","archived":false,"fork":false,"pushed_at":"2025-07-01T14:31:51.000Z","size":18306,"stargazers_count":12,"open_issues_count":10,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-07-08T16:11:49.210Z","etag":null,"topics":["chess","chess-ai","chess-ai-bot","chess-ai-engine","chess-bot","chess-engine","chess-engines","chess-game"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/DeveloperPaul123.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-07-26T14:25:49.000Z","updated_at":"2025-07-01T14:31:54.000Z","dependencies_parsed_at":"2025-01-16T14:08:09.868Z","dependency_job_id":"4fde7f96-6bf6-4df2-a91c-b06e4950df83","html_url":"https://github.com/DeveloperPaul123/byte-knight","commit_stats":null,"previous_names":["developerpaul123/byte-knight"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/DeveloperPaul123/byte-knight","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeveloperPaul123%2Fbyte-knight","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeveloperPaul123%2Fbyte-knight/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeveloperPaul123%2Fbyte-knight/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeveloperPaul123%2Fbyte-knight/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DeveloperPaul123","download_url":"https://codeload.github.com/DeveloperPaul123/byte-knight/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeveloperPaul123%2Fbyte-knight/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265281177,"owners_count":23739868,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["chess","chess-ai","chess-ai-bot","chess-ai-engine","chess-bot","chess-engine","chess-engines","chess-game"],"created_at":"2024-11-08T08:22:43.554Z","updated_at":"2025-07-14T11:07:56.721Z","avatar_url":"https://github.com/DeveloperPaul123.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003ccenter\u003e\u003ch1\u003e byte-knight \u003c/h1\u003e\u003c/center\u003e\n\n[![codecov](https://codecov.io/gh/DeveloperPaul123/byte-knight/graph/badge.svg?token=USEPKU8K4G)](https://codecov.io/gh/DeveloperPaul123/byte-knight)\n\n`byte-knight` is a UCI compliant chess engine written in Rust. It started as a port of the chess engine I submitted for Sebatian Lague's [Chess Engine Challenge](https://github.com/DeveloperPaul123/Leonidas) where it placed in the top 32 out of 600+ entries.\n\nYou can challenge `byte-knight` yourself on [Lichess](https://lichess.org/@/byte-knight)!\n\n# Overview\n\n`byte-knight` is my first \"real\" Rust project. I'm a long time [C++ developer](https://github.com/DeveloperPaul123?tab=repositories\u0026q=\u0026type=source\u0026language=c%2B%2B\u0026sort=stargazers) and have been itching to learn Rust. I really enjoyed participating in the chess challenge a while back and thought that writing a new chess engine from scratch would be a good way to learn the language.\n\n`byte-knight` is a command line chess engine and does not come with any sort of user interface. There are many [chess GUIs](https://www.chessprogramming.org/GUI) out there that you can use like [cutechess](https://github.com/cutechess/cutechess).\n\nNew features are tested via my [OpenBench](https://github.com/AndyGrant/OpenBench) [intance](https://developerpaul123.pythonanywhere.com) using [SPRT](https://github.com/jw1912/SPRT/blob/main/SPRT.md#how-sprt-actually-works) testing.\n\n# Features\n\n## Board/Game Representation\n\n- Bitboard board representation\n- Magic bitboards for sliding piece attacks\n- Zobrist hashing with board state history\n- Legal move generator\n\n## Search\n\n- [Iterative deepening](https://www.chessprogramming.org/Iterative_Deepening)\n- [Negamax](https://www.chessprogramming.org/Negamax) with alpha/beta pruning\n- [Quiescence search](https://www.chessprogramming.org/Quiescence_Search)\n- [Transposition Table](https://www.chessprogramming.org/Transposition_Table)\n- [Principle variation search](https://www.chessprogramming.org/Principal_Variation_Search)\n- [Aspiration windows](https://www.chessprogramming.org/Aspiration_Windows)\n- [Reverse futility pruning](https://www.chessprogramming.org/Reverse_Futility_Pruning)\n- [Late Move Reductions](https://www.chessprogramming.org/Late_Move_Reductions)\n- [Internal Iterative Reductions](https://www.chessprogramming.org/Internal_Iterative_Reductions)\n- [Null Move Pruning](https://www.chessprogramming.org/Null_Move_Pruning)\n- [Late Move Reductions](https://www.chessprogramming.org/Late_Move_Reductions)\n- [Time control](https://www.chessprogramming.org/Time_Management)\n  - Basic hard/soft limits\n- Move ordering\n  - [MVV/LVA](https://www.chessprogramming.org/MVV-LVA) with transposition table priority\n  - [History heuristic](https://www.chessprogramming.org/History_Heuristic) with history gravity\n\n## Evaluation\n\n- Piece square tables with tapered evaluation using [PeSTO](https://www.chessprogramming.org/PeSTO%27s_Evaluation_Function) values.\n  - Project includes an HCE tuner based on [jw1912/hce-tuner](https://github.com/jw1912/hce-tuner)\n\n## UCI\n\n[UCI](https://www.chessprogramming.org/UCI) is a standard protocol for chess engines. `byte-knight` implements the following commands:\n\n- `uci`\n- `ucinewgame`\n- `isready`\n- `position \u003cfen\u003e moves \u003cmove list\u003e`\n- `go`\n  - `depth \u003cdepth\u003e`\n  - `nodes \u003cnodes\u003e`\n  - `wtime \u003cwtime\u003e btime \u003cbtime\u003e winc \u003cwinc\u003e binc \u003cbinc\u003e`\n- `stop`\n- `quit`\n\n## Other Commands\n\nTo see all commands that `byte-knight` supports, type:\n\n```bash\nbyte-knight help\n```\n\nTo see all options for a given command, type `byte-knight \u003ccmd\u003e --help`.\n\n- `bench` - This runs a fixed depth search on a variety of positions. This is used by [OpenBench](https://github.com/AndyGrant/OpenBench) for scaling based on engine performance.\n\n## UCI Options\n\n| Name | Value Range | Default | Description |\n| ---- | ----------- | ------- | ----------- |\n| Hash | [1 - 1024] | 16      | Set the TT table size in MB |\n| Threads | [1]      | 1       | How many threads to use in search |\n\n# Build and Run\n\nClone the repo and run:\n\n```bash\ncargo run --release\n```\n\n# Development Dependencies\n\nTo run the full suite of supported tests, benchmarks and other development dependencies, you will need the following tools (in addition to Rust and Cargo):\n- [just](https://github.com/casey/just)\n- Rust llvm-profdata component\n  - Install with `rustup component add llvm-tools-preview`\n- [grcov](https://github.com/mozilla/grcov) (Used to generate code coverage reports)\n- [lcov](https://github.com/linux-test-project/lcov) (Required for `genhtml` to create HTML reports from `lcov` data)\n\n# License\n\nThe project is licensed under the GPL license. See [LICENSE](LICENSE) for more details.\n\n# Credits\n\nThanks/acknowledgement for those who have inspired and helped with this project:\n\n- Sebastian Lague for his chess YouTube vidoes and for hosting a fun coding challenge.\n- The [Chess Programming Wiki](https://www.chessprogramming.org/Main_Page) for all the free information. Thank you to all the various authors.\n- Analog-Hors for some excellent write ups on chess, especially regarding magic numbers.\n- Many members of the Engine Programming discord for helping see how little I really know.\n- [Danny Hammer](https://github.com/dannyhammer/toad) for providing feedback, for helping me with troubleshooting my engine and for writing the `chessie` and `uci-parser` crates. Thanks for inspiring some of the techniques and methods used in `byte-knight`.\n- [Marcel Vanthoor](https://github.com/mvanthoor/rustic) for his Rustic engine and associated [book](https://rustic-chess.org).\n- Everyone at [pyrobench](https://pyronomy.pythonanywhere.com) for donating CPU time as well as helping me when I get stuck.\n\n# Author\n\n| [\u003cimg src=\"https://avatars0.githubusercontent.com/u/6591180?s=460\u0026v=4\" width=\"100\"\u003e\u003cbr\u003e\u003csub\u003e@DeveloperPaul123\u003c/sub\u003e](https://github.com/DeveloperPaul123) |\n|:----:|\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdeveloperpaul123%2Fbyte-knight","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdeveloperpaul123%2Fbyte-knight","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdeveloperpaul123%2Fbyte-knight/lists"}