finds.dev

venmo/business-rules

Python DSL for setting up business intelligence rules that can be configured without code

View on GitHub

★ 989PythonMITupdated Aug 2024

// the take

A lightweight Python rule engine from Venmo that lets non-engineers define conditional business logic in JSON, with a Python DSL for declaring the available variables and actions. The core idea is clean: developers expose typed variables and actions via decorators, and rules get built by a UI and stored as JSON data rather than code. Fits small-to-medium automation problems where you want product/ops teams to configure logic without deploying code.

The decorator-based variable/action definition is genuinely ergonomic — the diff between 'code you write' and 'config non-engineers touch' is a clean API boundary. The `export_rule_data()` introspection method is a thoughtful feature; the backend tells the frontend exactly what's available, so the UI can't construct invalid rules. The operator set for `select_multiple` is surprisingly complete (`shares_at_least_one_element_with` etc.) for what looks like a small library. Test coverage exists and the CI is still running as of 2024.

The project is effectively unmaintained — 989 stars but last meaningful activity was years ago, with the 2024 push likely just dependency bumps. No support for nested condition groups beyond the flat `all`/`any` split, which breaks down fast on real-world business logic that has 3+ levels of nesting. The companion UI library (business-rules-ui) is a separate repo that looks even more abandoned, so you're writing your own frontend anyway. No async support — `run_all` is synchronous and blocking, which is a problem if your variable methods hit databases or external services.

We read the README, the directory tree and a key source file in June 2026. Nobody pays to be listed. How we judge →

// at a glance

Stars
989
Forks
267
Language
Python
License
MIT
Last commit
13 Aug 2024

// nearby

If business-rules isn't quite it.

All repos →