Skip to main content

Equitable Capital Optimization AI

CI Python Streamlit 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

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

flowchart LR
    A[Synthetic Business Data] --> B[Feature Pipeline]
    B --> C[Random Forest Model]
    C --> D[Capital Readiness Score]
    C --> E[Local Explanation]
    D --> F[Fairness Audit]
    D --> G[Allocation Simulator]
    F --> H[Research Dashboard]
    G --> H
    E --> H

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
  • 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
  • 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]"

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
├── tests/
├── docs/
├── .github/
├── CITATION.cff
├── CONTRIBUTING.md
├── SECURITY.md
├── CHANGELOG.md
└── LICENSE

Data design

The repository uses synthetic data by default. This avoids exposing private financial records, makes the project reproducible, and prevents the demonstration from implying real-world 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.

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 gradient-boosted model benchmarks, probability calibration, SHAP, temporal/geographic validation, county-level opportunity maps, Census/SBA/CDFI public-data integrations, constrained optimization, and uncertainty analysis.

See Research Roadmap.

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.

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.2.0.tar.gz (14.5 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.2.0.tar.gz.

File metadata

File hashes

Hashes for equitable_capital_optimization_ai-0.2.0.tar.gz
Algorithm Hash digest
SHA256 6f5dbaeca075e697aa40fe6f4bbb8ea34f3ff86ff19f50f31710cc7155c296db
MD5 4fa67110946dcfc350929842e69a4b26
BLAKE2b-256 a9f07ff480c44f573be4598284249e288f0e9b5f3666334e7e52d8669181d69b

See more details on using hashes here.

Provenance

The following attestation bundles were made for equitable_capital_optimization_ai-0.2.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.2.0-py3-none-any.whl.

File metadata

File hashes

Hashes for equitable_capital_optimization_ai-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 8e82e848d91ed5caf661824ce35b00df4dc8b8e96f0255d3d2fa64c113312cc4
MD5 a245b1ef80e0e0354cde61dbe8383a3d
BLAKE2b-256 dba408e3cc09e6dcbdc057d1791d221ddef837a9cd606b9ee990ec2978587f75

See more details on using hashes here.

Provenance

The following attestation bundles were made for equitable_capital_optimization_ai-0.2.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

0.4.0

2 files

This release

0.2.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