Skip to main content

CreditSetu

General-purpose, explainable credit intelligence engine for thin-file and alternative-data lending. Score customers on behavioral transaction data — including customers with no bureau score at all — using three composable engines (Intent, Capacity, Guardrail), SHAP-backed explanations, and regulator-style adverse action reason codes.

This is the library package. For the full project — a reference FastAPI service, a React dashboard, synthetic demo data, and deployment docs — see the GitHub repository.

Install

pip install creditsetu

That pulls in only pandas, numpy, scikit-learn, lightgbm, pydantic, and pyyaml — enough to fit models and score customers. SHAP explainability and ruptures-based life-event detection are opt-in and degrade gracefully if skipped:

pip install "creditsetu[explain]"   # + SHAP feature attributions / adverse action reasons
pip install "creditsetu[intent]"    # + ruptures change-point life-event detection
pip install "creditsetu[full]"      # both

Usage

from app.pipeline import CreditIntelligencePipeline
from app.scoring_profile import ScoringProfile

# Currency, guardrail thresholds, product catalog, weights — all policy,
# no code changes needed to adapt this to a different institution/market.
profile = ScoringProfile(name="acme", org_name="Acme Lending", currency_symbol="$")
pipeline = CreditIntelligencePipeline(profile=profile)

# Fit on your own historical data — customers_df needs a
# `true_repayment_capacity` column, ideally a real `is_stressed` column too.
pipeline.fit(customers_df, transactions_df)

# Score one customer...
result = pipeline.score_customer(customer, customer_transactions_df)

# ...or a whole batch, vectorized end-to-end.
scores_df = pipeline.score_batch(customers_df, transactions_df)

Data contractcustomer is a dict needing at least customer_id and bureau_score (None is a first-class value, not an edge case — that's the point). transactions is a DataFrame with date, amount, type (credit/debit), category, counterparty, is_bounce.

Full details live in the package's pipeline.py module docstring, and the complete architecture/evaluation writeup is in the GitHub README.

License

MIT

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

creditsetu-1.0.0.tar.gz (63.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

creditsetu-1.0.0-py3-none-any.whl (68.7 kB view details)

Uploaded Python 3

File details

Details for the file creditsetu-1.0.0.tar.gz.

File metadata

  • Download URL: creditsetu-1.0.0.tar.gz
  • Upload date:
  • Size: 63.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for creditsetu-1.0.0.tar.gz
Algorithm Hash digest
SHA256 83f21b8d176b796345cd32b05b3730e3f6db085431e6b6c108184c708a43e334
MD5 6170c06ce7a8b7cf3fda87a46bb98cc3
BLAKE2b-256 66920ce708673143384de750ec1502df00dd2ea1d6d0fa24dea770f06f0603c1

See more details on using hashes here.

Provenance

The following attestation bundles were made for creditsetu-1.0.0.tar.gz:

Publisher: publish-pypi.yml on adarshcod30/CreditSetu

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file creditsetu-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: creditsetu-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 68.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for creditsetu-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 8ea5cf32dd9d878a22c215fda0d03d68580c28caa4065fc950b301ed474919f9
MD5 bf5d07ecf54d98c7777af2cb4f160f67
BLAKE2b-256 a3cf63b827ecfcdcadfd323562fa142dac8c45385a30fad2deb816108826605c

See more details on using hashes here.

Provenance

The following attestation bundles were made for creditsetu-1.0.0-py3-none-any.whl:

Publisher: publish-pypi.yml on adarshcod30/CreditSetu

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

This release

1.0.0 This release

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page