Skip to content

Contributing

Iman edited this page Jun 21, 2026 · 1 revision

Contributions are welcome. This page summarizes the process — the full details are in CONTRIBUTING.md in the repository.


Where to start

Look for issues labeled good first issue.

Three categories of contributions that don't require understanding the full leakage-detection design:

Documentation

  • A sensor-domain worked example (equivalent to examples/ogdc_leakage_case/ for finance)
  • Docstring Examples sections in each audit_* function
  • Translations or clarifications in this wiki Edge-case tests
  • All-NaN columns across every module
  • Single-row DataFrames across every module
  • Additional boundary conditions not currently covered New domain presets
  • domain="crypto" — 24/7 trading with no weekend gaps, historically high volatility
  • domain="iot" — sub-second frequencies, variable sensor reliability
  • domain="healthcare" — irregular sampling, clinically meaningful anomaly thresholds

The contribution workflow

  1. Fork the repository
  2. Create a branch: git checkout -b fix/your-description (use fix/, feat/, docs/, test/ prefixes)
  3. Make your change — if you touch tsauditor/ source code, add or update tests in tests/
  4. Run the full suite locally: pytest -q — all 93 tests must pass
  5. Push your branch and open a PR against main
  6. Fill in the PR template (summary, files changed, testing done)
  7. CI runs automatically across Python 3.9–3.14 on Linux, Windows, and macOS

Adding a new issue code

If your contribution introduces a new check, two files need updating:

1. The detection module — return an Issue object with your new code following the existing naming pattern (PRF* for profiler, ANO* for anomaly, LEK* for leakage).

2. tsauditor/report/remediation.py — add an entry to the _REMEDIATIONS dictionary:

"YOUR_CODE": (
    "A short sentence telling the user what to check or do. "
    "Use {target} where the column name or 'the dataset' should appear."
),

The {target} placeholder is automatically replaced with "column 'X'" or "the dataset" depending on whether the issue is column-level or dataset-level. Other keys from the issue's evidence dict can also be referenced as placeholders.


Reporting bugs

Use the Bug Report issue template. Include:

  • Your Python version and OS
  • tsauditor version (python -c "import tsauditor; print(tsauditor.__version__)")
  • A minimal reproduction snippet — synthetic data that triggers the issue is fine

Proposing features

Use the Feature Request template. For anything touching the leakage/ module, include statistical reasoning for the proposed approach — that module is the project's core research contribution and is held to a higher bar than the profiler or anomaly modules.


Questions

Open a GitHub Discussion if you're unsure whether something is a bug, a feature request, or just a question.

Clone this wiki locally