Credit scoring as a pure functional pipeline. Clojure was chosen here because scoring is fundamentally a data transformation problem — threading macros make the pipeline read like a specification.
Clojure 1.11, Ring, Reitit, next.jdbc, HikariCP (JVM interop)
Customer number → hash-based factor derivation → weighted scoring → score clamping [300-850] → limit determination → exclusion check. The entire pipeline is deterministic and side-effect free. Database persistence and caching happen outside the pipeline.
Atom-based in-memory cache with 5-minute TTL. PostgreSQL fallback for cache misses beyond TTL.
Post-disbursement scoring: on-time repayment (+5), late payment (-10), loan completion (+25), top-up approval (+10).
lein uberjar