Skip to content

Latest commit

 

History

History
53 lines (37 loc) · 2.58 KB

File metadata and controls

53 lines (37 loc) · 2.58 KB

Contributing

Scope

Contributions should help answer a concrete credit-risk or fraud-modeling question. This repository is not a catalogue of every class-imbalance algorithm.

Do not submit customer data, production thresholds, internal rules, model weights, credentials, proprietary pseudocode, or third-party binaries without explicit redistribution permission.

Local setup

python -m pip install -e ".[dev]"
python -m pytest -q
python -m ruff check .
python scripts/check_repository.py
python -m build
python scripts/smoke_wheel.py

Code expectations

  • Public identifiers and docstrings use English.
  • Business examples may use concise Chinese comments when they clarify the Chinese credit context.
  • Stable numerical functions must reject non-finite values and ambiguous labels rather than silently coercing them.
  • Sampling belongs inside a training pipeline; validation, test, and OOT partitions remain untouched.
  • New stable behavior requires exact-value, invalid-input, and invariant tests.
  • A D implementation must name its H source, document deliberate semantic changes, and add characterization or golden tests before refactoring.
  • Do not copy or modernize Q material until its source and license are resolved.

Documentation expectations

Separate these layers explicitly:

  1. sample population and label observability;
  2. training intervention;
  3. ranking;
  4. probability interpretation;
  5. decision and portfolio effect.

Historical claims should be preserved with modern applicability notes, not silently rewritten as if they were current conclusions.

Identity and provenance

  • Maintainer-authored commits in the 2026 preservation update use the author and committer identity Ma Xiao.
  • Do not rewrite published historical authors or use .mailmap to make modern work appear historical.
  • Keep H files byte-preserved. Put translations, corrections, and modern qualifications in D documents instead of editing the original.
  • Record each new H-to-D relationship in docs/history/provenance.md and update legacy/MANIFEST.md when the asset status changes.

Git hygiene

Keep rules, code, tests, Chinese docs, English docs, legacy governance, packaging, and CI in separate commits. Do not mix line-ending normalization or third-party-binary removal into content edits.

Do not use git add . or git add -A; review and stage explicit paths by theme. The current phase 1-3 authorization covers the selected branch push and a draft pull request only. A default-branch merge, tag, Release, PyPI upload, deployment, rebase, force-push, or history rewrite requires separate authorization.