Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/native-backend-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: ["3.11", "3.12"]
python-version: ["3.11", "3.12", "3.13", "3.14"]

steps:
- name: Check out repo
Expand Down
7 changes: 4 additions & 3 deletions docs/api_status.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
This page summarizes the public NNS Python API surface, known gaps, guarded paths,
and design boundaries.

NNS Python is an alpha, parity-focused Python port of installed R NNS 13.0,
NNS Python is a stable, parity-focused Python port of installed R NNS 13.0,
implemented natively in Python on top of NumPy and SciPy. It does not
wrap R, call the R package at runtime, or depend on compiled R/C++ shims. The
goal is public input/output compatibility where R behavior is stable,
Expand Down Expand Up @@ -81,7 +81,7 @@ invariant, and property coverage.
- Stochastic exact stream parity is not expected. Stochastic paths use NumPy RNG
and are tested structurally/statistically.
- Plotting side effects from R APIs are generally ignored; NNS Python returns data.
- Stochastic-dominance performance work stays pure NumPy for alpha. The current
- Stochastic-dominance performance work stays pure NumPy for now. The current
implementation mirrors R's sorted-column/prefix-sum algorithm and adds
Python-specific guard pruning, kept-only active-set scans for degree 2/3 and
degree-1 continuous calls, and an exact order-statistic matrix for large
Expand Down Expand Up @@ -115,7 +115,8 @@ examples include:

## Release-Relevant Caveats

- NNS Python is alpha. The public API is parity-focused but not declared stable.
- The public API is stable and parity-focused. Behavior is not expected to break
across minor releases.
- This is not full R parity yet.
- `dy_d` scalar and vectorized point/distribution modes are covered on focused
fixtures. Multi-row mixed derivative point matrices intentionally use
Expand Down
12 changes: 7 additions & 5 deletions docs/conventions.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,12 @@

## Build

NNS Python is currently a pure-Python/NumPy/SciPy port. The earlier native extension
scaffolding was removed after the core port demonstrated pure NumPy/SciPy parity
and competitive performance. Reintroduce native code only as a deliberate future
change backed by benchmarks.
NNS Python is a Python-native NumPy/SciPy port with optional private native
acceleration through `nns._nnscore` where available. Source builds use
`scikit-build-core` and `nanobind` to compile the extension; published wheels
should be preferred when available. Public APIs keep Python implementations and
explicit fallback behavior, so native code remains a deliberate,
benchmark-backed implementation detail rather than a public API.

## Degree-Zero Boundary

Expand Down Expand Up @@ -90,7 +92,7 @@ data-frame grouping or filtering. R remains faster on some large finance
fixtures because its C++ path walks merged sorted thresholds in tight parallel
loops with minimal temporaries; NNS Python instead uses NumPy order-statistic blocks,
`searchsorted`, contiguous column storage, and early-exit scans to stay
dependency-light and pure Python for alpha.
dependency-light and pure Python.

`nns_cdf` maps to R's `NNS.CDF` deterministic non-plotting paths. It is a
partial-moment distribution wrapper rather than a textbook ECDF: `degree = 0`
Expand Down
Loading