{"id":20804948,"url":"https://github.com/lichess-org/lila-db-seed","last_synced_at":"2025-05-07T04:21:08.742Z","repository":{"id":37102679,"uuid":"364169976","full_name":"lichess-org/lila-db-seed","owner":"lichess-org","description":"Sample database data for lila development","archived":false,"fork":false,"pushed_at":"2025-04-04T20:52:03.000Z","size":9139,"stargazers_count":22,"open_issues_count":0,"forks_count":18,"subscribers_count":7,"default_branch":"master","last_synced_at":"2025-05-05T14:22:26.070Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lichess-org.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","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}},"created_at":"2021-05-04T07:08:57.000Z","updated_at":"2025-04-21T12:18:38.000Z","dependencies_parsed_at":"2023-02-10T05:45:15.079Z","dependency_job_id":"ed065c41-9a6e-42c6-8449-943399bb373d","html_url":"https://github.com/lichess-org/lila-db-seed","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lichess-org%2Flila-db-seed","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lichess-org%2Flila-db-seed/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lichess-org%2Flila-db-seed/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lichess-org%2Flila-db-seed/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lichess-org","download_url":"https://codeload.github.com/lichess-org/lila-db-seed/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252811001,"owners_count":21807886,"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":[],"created_at":"2024-11-17T19:12:33.253Z","updated_at":"2025-05-07T04:21:08.727Z","avatar_url":"https://github.com/lichess-org.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Database data for development on lichess-org/lila\n\n\u003e [!NOTE]\n\u003e If you use [lila-gitpod](https://github.com/lichess-org/lila-gitpod) or [lila-docker](https://github.com/lichess-org/lila-docker) for your dev environment, this repo is already included and you can configure it during setup.\n\n### This will get you the bare minimum of puzzles and game data:\n\n```bash\nmongorestore dump\n```\n\n# Or...\n\n### Use spamdb to fully populate your database:\n\n[python3.9+](https://www.python.org/) is required. If you don't have python3, use your package manager or the [downloads page](https://www.python.org/downloads/) to install it, then install the necessary packages:\n\n```sh\npython -m ensurepip --upgrade\n# not strictly necessary but recommended, use a virtual environment\npython3 -m venv venv --upgrade-deps \u0026\u0026 source venv/bin/activate\n# install required packages\npip3 install -r spamdb/requirements.txt\n```\n\nThe `lila-db-seed/spamdb/spamdb.py` script will generate semi-realistic dummy data that is useful for testing and makes your dev instance a lot more colorful. Usage help:\n\n```bash\nspamdb/spamdb.py --help\n```\n\nUsually, the script will generate a new set of data from inputs in the provided arguments as well as the `spamdb/data` directory. This data will be merged into your running mongodb instance at `127.0.0.1:27071/lichess` by default. To customize connection details use the `--uri` argument. Set the password for your users with the `--password` flag (otherwise they will default to \"password\"). Set the default background in user prefs with `--user-bg` (default is dark mode, use 400 for transparency). For other options see `spamdb.py --help`.\n\n### Use `--su-password` to give the special (admin) users different passwords than the default if your dev instance will be exposed to others.\n\n### Creating lichess database indexes\n\n`lila-db-seed/spamdb/spamdb.py` does not create the indexes in lichess database. In case you need them, you can use https://github.com/lichess-org/lila/blob/master/bin/mongodb/indexes.js\n\n```bash\nmongosh --quiet lichess indexes.js\n```\n\n## Seed Elasticsearch\n\nTo push this data to elasticsearch, you can use the CLI tools from [lila-search](https://github.com/lichess-org/lila-search). See the CLI commands in the [lila-search README](https://github.com/lichess-org/lila-search?tab=readme-ov-file#cli-tool).\n\n## Special users:\n\n-   superadmin - ROLE_SUPER_ADMIN # check out the mod UI if you haven't seen it, very cool!\n-   admin - ROLE_ADMIN\n-   shusher - ROLE_SHUSHER\n-   hunter - ROLE_CHEAT_HUNTER\n-   puzzler - ROLE_PUZZLE_CURATOR\n-   api - ROLE_API_HOG (this guy is useful for api testing, both server and clients)\n-   troll - marked as troll\n-   bot0 thru bot9 - marked as bot\n-   kid - they're just children, how could you checkmate children?\n-   wwwwwwwwwwwwwwwwwwww - 20 W's in visible username, WGM title, and a patron to test ui for extremely wide usernames.\n\n## Normal users:\n\nThe normal users have all the data. This includes notifications, ratings, follows, game histories, activity, timelines, blogs, forums, teams, tournaments. See the full list in spamdb/data/uids.txt\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flichess-org%2Flila-db-seed","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flichess-org%2Flila-db-seed","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flichess-org%2Flila-db-seed/lists"}