Skip to main content

Equitable Capital Optimization AI

CI Live App PyPI Citation Google Scholar Python License

A reproducible research prototype for predictive capital-readiness analysis, model explainability, fairness auditing, and equity-aware capital-allocation simulation for underserved U.S. entrepreneurial ecosystems.

The project is inspired by:

An AI-Powered Framework for Equitable Capital Optimization: Leveraging Predictive Intelligence to Empower Underserved Entrepreneurial Ecosystems in the U.S.

Related publication: ResearchGate

Live demo

Public research dashboard: Launch the Streamlit application

The live application provides an interactive demonstration of capital-readiness scoring, local model explanation, fairness auditing, and equity-aware allocation simulation using reproducible synthetic business data. No login or API key is required.

Why this project exists

Access to capital is not only a prediction problem. It is also an allocation, transparency, and measurement problem. This repository separates those concerns into four independently testable components:

Component Purpose
Predictive modeling Estimate funding-success probability from business and market features
Explainability Show how applicant-level features influence the model locally
Fairness auditing Compare outcomes across structural-access contexts
Capital allocation Compare efficiency-only and equity-aware funding scenarios

Responsible-use boundary

Research and educational use only.

This project must not be used to make real lending, credit, investment, employment, housing, insurance, benefits, or eligibility decisions.

The predictive model intentionally excludes protected personal characteristics. Structural context indicators are used for research auditing and allocation simulation, not as protected-trait proxies for real-world underwriting.

Architecture

Synthetic Business Data
          |
          v
   Feature Pipeline
          |
          v
  Random Forest Model
      /          \
     v            v
Readiness      Local
 Scores      Explanation
   |              |
   v              |
Fairness Audit    |
   |              |
   +-------> Research Dashboard
   |
   v
Allocation Simulator
   |
   +-------> Research Dashboard

See Architecture and Methodology.

Key capabilities

  • Reproducible synthetic U.S. small-business/startup data generation
  • Scikit-learn preprocessing and Random Forest classification pipeline
  • Holdout evaluation with ROC-AUC, accuracy, precision, recall, F1, and Brier score
  • Reproducible multi-model benchmark across Logistic Regression, Random Forest, Extra Trees, and HistGradientBoosting
  • Capital Readiness Score derived from predicted funding-success probability
  • Global feature-importance reporting
  • Applicant-level local sensitivity explanations
  • Structural-context fairness audit and selection-rate comparison
  • Efficiency-only and equity-aware capital-allocation simulation
  • Interactive Streamlit research dashboard
  • Live browser for official SBA state and metropolitan small-business datasets
  • Interactive U.S. state choropleths for synthetic research indicators and official SBA state measures
  • Automated tests and linting in GitHub Actions
  • Model card, citation metadata, contribution guide, and security policy

Python package

The reusable research code lives in the equitable_capital Python package.

After a release is published to PyPI, install it with:

pip install equitable-capital-optimization-ai

Example:

from equitable_capital import (
    allocate_capital,
    fairness_audit,
    generate_synthetic_startups,
    train_model,
)

data = generate_synthetic_startups()
result = train_model(data)
audit = fairness_audit(result.scored_data)

For local development, install the repository in editable mode:

pip install -e ".[dev]"

Reproducible examples

The repository includes five Jupyter notebooks that walk through the research workflow from prediction to fairness, allocation, public U.S. data, and geographic visualization:

  1. Capital Readiness Analysis
  2. Fairness and Opportunity Audit
  3. Equity-Aware Capital Allocation
  4. Official U.S. Small-Business Data Context
  5. Geographic Visualization

See the examples guide for local setup and research-use notes.

Quick start

git clone https://github.com/sakera023/equitable-capital-optimization-ai.git
cd equitable-capital-optimization-ai
python -m venv .venv

Activate the environment.

Windows

.venv\Scripts\activate

macOS/Linux

source .venv/bin/activate

Install and run:

pip install -r requirements.txt
streamlit run app.py

Development checks:

pip install -r requirements-dev.txt
ruff check src tests app.py
python -m pytest -q

Repository structure

.
├── app.py
├── pyproject.toml
├── requirements.txt
├── requirements-dev.txt
├── Makefile
├── src/
│   └── equitable_capital/
│       ├── __init__.py
│       ├── allocation.py
│       ├── config.py
│       ├── data.py
│       ├── explainability.py
│       ├── fairness.py
│       ├── modeling.py
│       ├── benchmark.py
│       ├── geographic.py
│       └── public_data.py
├── scripts/
│   └── run_benchmarks.py
├── benchmarks/
│   └── reference_summary.csv
├── tests/
├── examples/
│   ├── 01_capital_readiness.ipynb
│   ├── 02_fairness_audit.ipynb
│   ├── 03_equitable_allocation.ipynb
│   ├── 04_public_us_data_context.ipynb
│   └── 05_geographic_visualization.ipynb
├── docs/
├── .github/
├── CITATION.cff
├── CITATION.md
├── codemeta.json
├── ADOPTION.md
├── CONTRIBUTING.md
├── SECURITY.md
├── CHANGELOG.md
└── LICENSE

Data design

The predictive model uses synthetic business-level data by default. This avoids exposing private financial records, makes the project reproducible, and prevents the demonstration from implying real-world applicant-level predictive validity.

Predictive features include revenue, growth, cash runway, employees, operating history, debt-service coverage, digital adoption, market demand, management capacity, requested capital, industry, and state.

Official U.S. public-data layer

The live application also provides a separate browser for authoritative aggregate small-business statistics from the U.S. Small Business Administration Office of Advocacy:

The application resolves the current official workbook through the SBA open-data CKAN catalog at runtime, so the repository does not need to store a stale government-data copy. Public aggregate statistics are displayed for geographic and economic context; they are not mixed into the synthetic applicant-level model.

See Public U.S. Data Layer for provenance and research-use notes.

Documented case studies

Three documented synthetic case studies show how the platform can be used as a research workflow rather than only as a software demo:

  1. Rural Small-Business Capital Access
  2. Low-Income Metropolitan Entrepreneurship
  3. Growth-Stage Small Business With Constrained Capital

Each case study connects capital-readiness analysis, explainability, fairness diagnostics, geographic/public-data context, and allocation scenarios while clearly separating synthetic applicant-level outputs from official aggregate statistics.

See the case study index.

Geographic visualization

The live dashboard includes a dedicated Geographic Insights tab with interactive U.S. state choropleths for synthetic research indicators such as average Capital Readiness Score, Structural Barrier Index, requested capital, predicted success, and synthetic business count.

When the official SBA state workbook is loaded, the U.S. Public Data tab can also detect state-level numeric fields and render an official-data choropleth for the selected measure.

See Geographic Visualization for methodology and interpretation limits.

Model benchmark

A reproducible five-split benchmark compares four model families under a common preprocessing and evaluation protocol.

Reference findings on the synthetic research dataset:

  • Logistic Regression produced the strongest mean ROC-AUC and lowest Brier score.
  • Random Forest produced the strongest mean accuracy, recall, and F1 at the 0.50 threshold.
  • More complex models did not automatically outperform the simpler baselines.

See the full Model Benchmark Report and the machine-readable reference results.

Run the benchmark locally with:

python scripts/run_benchmarks.py

Model evaluation

The application reports ROC-AUC, accuracy, precision, recall, F1 score, and Brier score. These metrics evaluate the synthetic demonstration only.

Fairness and equity analysis

A structural barrier index is built from contextual variables such as low-income area, rural area, limited finance access, and digital adoption.

The index is reserved for post-model fairness diagnostics and research simulation of equity-aware allocation policies. It is not included in the predictive training features.

Reproducibility

The synthetic data generator and model pipeline use explicit random seeds. Tests verify data ranges, prediction bounds, allocation-budget constraints, and fairness-audit outputs. CI runs on every push and pull request.

Research roadmap

Planned extensions include probability calibration, SHAP, repeated cross-validation, temporal/geographic validation, county-level opportunity maps, Census and CDFI public-data integrations, constrained optimization, and uncertainty analysis.

See Research Roadmap.

Academic citation and research metadata

The repository includes:

  • CITATION.cff for GitHub's Cite this repository feature;
  • CITATION.md with a recommended software citation and BibTeX;
  • codemeta.json for machine-readable research-software metadata;
  • links to the associated publication and Google Scholar profile; and
  • versioned package metadata on PyPI.

No DOI is claimed unless and until a verified DOI is minted by a research-software archive.

Citation

If you use the software, cite the repository metadata in CITATION.cff. If you use the associated research concept, cite the publication separately and clearly distinguish research findings from this software prototype.

External use and contribution

Genuine outside use is encouraged and documented transparently.

See ADOPTION.md for ways to use the software, report research or teaching use, and provide verifiable feedback. The repository also includes contribution-oriented issues for public-data integration, county-level mapping, calibration research, and verified adoption feedback.

External-use claims should be based on real activity such as citations, forks with substantive work, pull requests, reproducible issue reports, teaching use, or documented organizational testing—not artificial stars or fabricated testimonials.

Contributing

See CONTRIBUTING.md.

Security

Do not publish secrets, private financial information, or real applicant records in issues or pull requests. See SECURITY.md.

License

MIT License. See LICENSE.

Maintainer

Sakera Begum

Download files

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

Source Distribution

equitable_capital_optimization_ai-0.4.0.tar.gz (24.9 kB view details)

Uploaded Source

Built Distribution

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

File details

Details for the file equitable_capital_optimization_ai-0.4.0.tar.gz.

File metadata

File hashes

Hashes for equitable_capital_optimization_ai-0.4.0.tar.gz
Algorithm Hash digest
SHA256 e1eb2b07daee8a4eec6e6a66e7ff52a8dc2043df7e7be1cd7d6511562d2fb5e2
MD5 51e186433af9e133ccdd371af0bf1fcb
BLAKE2b-256 53a47bf0126a3166f3daa888f00f5f69fac94c6e5735841616c1454396b6060c

See more details on using hashes here.

Provenance

The following attestation bundles were made for equitable_capital_optimization_ai-0.4.0.tar.gz:

Publisher: release.yml on sakera023/equitable-capital-optimization-ai

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

File details

Details for the file equitable_capital_optimization_ai-0.4.0-py3-none-any.whl.

File metadata

File hashes

Hashes for equitable_capital_optimization_ai-0.4.0-py3-none-any.whl
Algorithm Hash digest
SHA256 e5fdd00464ddc04493ca464cda87d6d9ee89f1879ad3a7e2229bffdbfc4d80c6
MD5 6cf5d13284ffb0d87bad11cdc02924a6
BLAKE2b-256 c6e66a003f795b1ac991873cd22683837b2f3612a357438506c23c989c6652f7

See more details on using hashes here.

Provenance

The following attestation bundles were made for equitable_capital_optimization_ai-0.4.0-py3-none-any.whl:

Publisher: release.yml on sakera023/equitable-capital-optimization-ai

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

0.4.0 This release

2 files

0.2.0

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