{"id":21931489,"url":"https://github.com/banditml/banditml","last_synced_at":"2025-06-28T04:32:52.637Z","repository":{"id":57413880,"uuid":"371112910","full_name":"banditml/banditml","owner":"banditml","description":"A lightweight contextual bandit \u0026 reinforcement learning library designed to be used in production Python services.","archived":false,"fork":false,"pushed_at":"2021-06-04T21:16:26.000Z","size":202,"stargazers_count":66,"open_issues_count":1,"forks_count":10,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-03-29T12:11:22.396Z","etag":null,"topics":["bandits","contextual-bandits","neural-networks","personalization","pytorch","reinforcement-learning"],"latest_commit_sha":null,"homepage":"","language":"Python","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/banditml.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"COPYING","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-05-26T17:11:18.000Z","updated_at":"2024-11-24T02:52:07.000Z","dependencies_parsed_at":"2022-09-12T03:11:18.283Z","dependency_job_id":null,"html_url":"https://github.com/banditml/banditml","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/banditml%2Fbanditml","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/banditml%2Fbanditml/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/banditml%2Fbanditml/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/banditml%2Fbanditml/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/banditml","download_url":"https://codeload.github.com/banditml/banditml/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248952353,"owners_count":21188427,"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":["bandits","contextual-bandits","neural-networks","personalization","pytorch","reinforcement-learning"],"created_at":"2024-11-28T23:14:05.573Z","updated_at":"2025-04-19T19:18:51.008Z","avatar_url":"https://github.com/banditml.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://banditml.com\" target=\"_blank\"\u003e\n    \u003cimg src=\"https://gradient-app-bucket-public.s3.amazonaws.com/static/images/logo.png\" alt=\"Bandit ML\" height=\"140\"\u003e\n  \u003c/a\u003e\n\u003c/p\u003e\n\n[![PyPI version](https://badge.fury.io/py/banditml.svg)](https://badge.fury.io/py/banditml) [![](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/ambv/black)\n\n\n# What's banditml?\n\n[banditml](https://github.com/banditml/banditml) is a lightweight contextual bandit \u0026 reinforcement learning library designed to be used in production Python services. This library is developed by [Bandit ML](https://www.banditml.com) and ex-authors of Facebook's applied reinforcement learning platform, [Reagent](https://github.com/facebookresearch/ReAgent).\n\nSpecifically, this repo contains:\n- Feature engineering \u0026 preprocessing\n- Model implementations\n- Model training workflows\n- Model serving code for Python services\n\n## Supported models\n\nModels supported:\n\n- Contextual Bandits (small datasets)\n  - [x] Linear bandit w/ ε-greedy exploration\n  - [x] Random forest bandit w/ ε-greedy exploration\n  - [x] Gradient boosted decision tree bandit w/ ε-greedy exploration\n- Contextual Bandits (medium datasets)\n  - [x] Neural bandit with ε-greedy exploration\n  - [x] Neural bandit with UCB-based exploration [(via. dropout exploration)](https://arxiv.org/abs/1506.02142)\n  - [x] Neural bandit with UCB-based exploration [(via. mixture density networks)](https://publications.aston.ac.uk/id/eprint/373/1/NCRG_94_004.pdf)\n- Reinforcement Learning (large datasets)\n  - [ ] [Deep Q-learning with ε-greedy exploration](https://www.cs.toronto.edu/~vmnih/docs/dqn.pdf)\n  - [ ] [Quantile regression DQN with UCB-based exploration](https://arxiv.org/abs/1710.10044)\n  - [ ] [Soft Actor-Critic](https://arxiv.org/abs/1801.01290)\n\n\u003cb\u003e4\u003c/b\u003e feature types supported:\n* \u003cb\u003eNumeric:\u003c/b\u003e standard floating point features\n  * e.g. `{totalCartValue: 39.99}`\n* \u003cb\u003eCategorical:\u003c/b\u003e low-cardinality discrete features\n  * e.g. `{currentlyViewingCategory: \"men's jeans\"}`\n* \u003cb\u003eID list:\u003c/b\u003e high-cardinality discrete features\n  * e.g. `{productsInCart: [\"productId022\", \"productId109\"...]}`\n  * Handled via. learned embedding tables\n* \u003cb\u003e\"Dense\" ID list:\u003c/b\u003e high-cardinality discrete features, manually mapped to dense feature vectors\n  * e.g `{productId022: [0.5, 1.3, ...], productId109: [1.9, 0.1, ...], ...}`\n\n## Docs\n\n```\npip install banditml\n```\n\n[Get started](DOCS.md)\n\n## License\n\nGNU General Public License v3.0 or later\n\nSee [COPYING](COPYING) to see the full text.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbanditml%2Fbanditml","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbanditml%2Fbanditml","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbanditml%2Fbanditml/lists"}