Deterministic rules engine
The OpenTax rules engine is a collection of pure TypeScript functions organized by tax year (e.g., src/rules/2025/). Each function takes typed inputs and returns typed outputs with no side effects, no network calls, and no randomness.
Given the same inputs, the engine always produces the same outputs. This property is critical for tax computation: you should be able to run the engine today and next month and get identical results. It also makes the engine straightforward to test — every function can be unit-tested in isolation.