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
27 changes: 27 additions & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Agent instructions

Before making changes, read and follow [CONTRIBUTING.md](CONTRIBUTING.md) and
[AI_POLICY.md](AI_POLICY.md). CONTRIBUTING.md defines the development setup,
code style, typing, testing, commit-message, and pull request conventions.

## Working in the repository

- Inspect the working tree before editing. Preserve existing work and do not
overwrite or revert unrelated changes. When committing, stage only files
relevant to the requested task.
- Keep changes focused. Follow existing interfaces and helpers, and avoid
unrelated refactors. Add dependencies or abstractions only when they address
a concrete need within the task.
- Keep generated lock files, local environments, caches, and generated outputs
out of commits unless explicitly requested. Preserve existing local files.

## Scientific correctness and validation

- Identify changes that affect sampling distributions, RNG behavior, dtype or
device handling, functional-state purity, or checkpoint compatibility. Explain
intentional behavior changes and support them with appropriate tests.
- Follow CONTRIBUTING.md for validation. Report the checks actually run and their
results, including failures, skipped backends, and checks that could not be
completed. Do not describe skipped checks as passing.
- Do not bypass hooks or disable checks to make a commit succeed. Address the
failure, or report the blocker when it cannot be resolved within the task.
26 changes: 26 additions & 0 deletions AI_POLICY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# Usage of Generative AI

The ORNG maintainers welcome contributions, including those developed with the assistance of generative AI tools. However, the use of such tools does not change our expectations for contributor responsibility, engagement, or code quality. The following apply to all contributions.

1. **Human ownership and accountability**
We require that:
- Contributors are responsible for all submitted content, regardless of whether generative AI tools were used.
- Contributors must be able to explain and justify all changes during review.
- Contributors are responsible for ensuring all submitted code complies with ORNG's licensing requirements, regardless of whether generative AI tools were used.
- Contributors must remain the clear human owner of the contribution. Pull requests submitted primarily by automated systems or where no accountable human author is evident may be closed at the maintainers' discretion.

2. **Engagement**
The pull request process is collaborative and iterative. Contributors are expected to actively engage with reviewer feedback themselves. Contributors are expected to understand the changes they are proposing, not act as a message courier for a third party.

3. **Consistency with ORNG conventions and existing style**
Contributions should follow ORNG's existing conventions for code structure, testing, documentation, and communication style. In the context of generative AI, this particularly means ensuring comments, documentation, and proposed interfaces are accurate, concise, and consistent with the rest of the project.

4. **Scientific and technical correctness**
ORNG is scientific software and contributors are expected to validate any AI-assisted contributions carefully, particularly where changes affect algorithms, numerical behaviour, performance, APIs, or scientific results.

5. **Maintainer discretion**
Maintainers may close or decline pull requests that are low quality, excessively burdensome to review, appear to lack meaningful human oversight, or otherwise are not in the best interests of the project.

> **Note:**
>
> This policy is informed by similar guidance adopted in the Scientific Python ecosystem, including Astropy, Matplotlib, and scikit-learn.
69 changes: 69 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
# Changelog

Notable changes to ORNG are documented in this file.

The format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).
Historical entries below summarise stable releases; changes from prereleases
are included in the corresponding stable release.

## [Unreleased]

### Added

- Pixi development environments for NumPy, JAX, CPU PyTorch, and CUDA CuPy,
with test, lint, formatting, and type-check tasks used locally and in CI.
([#17](https://github.com/sequince-dev/orng/pull/17))
- Contribution guidelines, an AI contribution policy, agent instructions,
and a changelog.

## [0.2.1] - 2026-09-10

### Fixed

- Use supported CuPy Generator methods for `RandomGenerator.choice`.
([#16](https://github.com/sequince-dev/orng/pull/16))

## [0.2.0] - 2026-08-06

### Added

- Detached, versioned RNG checkpoints through `state_dict`, `load_state_dict`,
and `from_state_dict`.
([#14](https://github.com/sequince-dev/orng/pull/14))
- Access to backend-native RNG state through `state` and `set_state`.
([#15](https://github.com/sequince-dev/orng/pull/15))

## [0.1.0] - 2026-06-04

First stable release, including the following functionality developed during
the prereleases.

### Added

- A unified random-number generation interface for NumPy, PyTorch, CuPy, and JAX,
supporting `random`, `uniform`, `normal`, `choice`, and `gamma`.
- A functional API returning `(sample, next_state)`, with pure state handling
and an optional mutable fast path for stateful backends.
([#8](https://github.com/sequince-dev/orng/pull/8),
[#10](https://github.com/sequince-dev/orng/pull/10))
- Optional `dtype` arguments in the functional API.
([#11](https://github.com/sequince-dev/orng/pull/11))
- Citation guidelines in the README.
([#13](https://github.com/sequince-dev/orng/pull/13))

### Deprecated

- `ArrayRNG` in favour of `RandomGenerator`.
([#9](https://github.com/sequince-dev/orng/pull/9))

### Fixed

- Normal sampling with the CuPy backend.
([#5](https://github.com/sequince-dev/orng/pull/5))
- The deprecation warning for `ArrayRNG`.
([#12](https://github.com/sequince-dev/orng/pull/12))

[Unreleased]: https://github.com/sequince-dev/orng/compare/v0.2.1...HEAD
[0.2.1]: https://github.com/sequince-dev/orng/compare/v0.2.0...v0.2.1
[0.2.0]: https://github.com/sequince-dev/orng/compare/v0.1.0...v0.2.0
[0.1.0]: https://github.com/sequince-dev/orng/releases/tag/v0.1.0
Loading
Loading