Validate a Change
Companion Guidance
Use karpathy-guidelines alongside this skill for implementation or review
work. Keep changes scoped, surface assumptions, and define focused validation
before editing.
Use this skill to choose the smallest validation set that still covers the
surfaces touched by a change.
Mandatory Rules
- Format changed files with the language-native formatter before the final
test pass.
- If Rust code changed, run
cargo fmt --all -- --check and just test-rust.
- If Python code or a Python-facing adapter changed, run
just test-python.
- If the TypeScript adapter contract or one of its source schemas changed, run
just test-typescript.
- If
crates/fabric-core changed in a way exposed through Python, run both the
Rust and Python suites.
- If the PyO3 bridge or package metadata changed, run
just build-python and
cargo check -p fabric-python --locked.
- If public configuration types changed, confirm the schema snapshot tests in
just test-rust pass and review generated schema diffs.
- If an adapter or integration changed, run its focused tests.
- If a Cargo or Python manifest or lockfile changed, run
uv run --no-project python scripts/licensing/license_diff.py --base-ref origin/main,
review the transitive license changes, then run the attributions-rust and
attributions-python pre-commit hooks.
- If the TypeScript manifest or npm lockfile changed, inspect the complete npm
dependency tree and license fields, confirm the package still has zero
production dependencies, run the
attributions-node pre-commit hook, and run
its package and audit checks.
- If documentation or examples changed, run
just docs when practical and
verify documented commands against the current repository.
- If code changes alter APIs, commands, paths, packaging behavior, telemetry
semantics, or documented best practices, update dependent maintainer skills in
the same branch. Because the consumer skills under
skills/ restate SDK guide,
Pydantic model, and Rust type details, update them in parity whenever those
surfaces change.
Start With the Change Shape
- Rust core, CLI, or shared runtime semantics changed
Run Rust formatting and tests. Add Python tests when the behavior is exposed through the SDK, and run relevant tests for CLI behavior.
- Python SDK or PyO3 binding changed
Use
python-tests, run focused pytest tests first, then run
just test-python. Rebuild with just build-python when native code or
packaging changed.
- Adapter behavior changed
Run the focused adapter tests under
tests/adapters, then just test-python.
- Harbor integration changed
Run
tests/test_harbor_runner.py, then just test-python.
- Schema or public contract changed
Run the Rust, Python, and TypeScript suites and review changes under
schemas/, the checked-in Python adapter-contract representations, generated
TypeScript sources, and generated API references.
- Documentation-only change
Use
contribute-docs and review-doc-style. Run just docs for docs-site or
generated-reference changes.
- CI or packaging changed
Use
maintain-ci or maintain-packaging, then run the recipes and checks
whose behavior changed.
Core Validation Matrix
just test-rust
just test-python
just test-typescript
Common Targeted Commands
# Rust
just build-rust
just test-rust
cargo fmt --all -- --check
cargo check -p fabric-python --locked
# Python and native extension
just build-python
just test-python
uv run --no-sync pytest -k "<pattern>"
# TypeScript adapter contract
just build-typescript
just test-typescript
just pack-typescript
# Documentation
just docs
# Dependency licenses
uv run --no-project python scripts/licensing/license_diff.py --base-ref origin/main
uv run pre-commit run --all-files attributions-rust
uv run pre-commit run --all-files attributions-python
uv run pre-commit run --all-files attributions-node
# Justfile and patch hygiene
just --fmt --check
git diff --check
Hygiene Checks
Before review or handoff:
- Verify README and docs entry points still match current package names and
paths.
- Verify examples use current
just recipes and public commands.
- Call out checks that were not run and why.
- Run
git diff --check.
References
- Python test guidance:
python-tests
- Build and test recipes:
justfile
- Python CI:
.github/workflows/ci_python.yml
- Rust CI:
.github/workflows/ci_rust.yml
- TypeScript CI:
.github/workflows/ci_typescript.yml
- Documentation CI:
.github/workflows/fern-docs.yml
- Public Python contract:
docs/python-sdk-contract.md
- Public adapter contract:
schemas/SCHEMA.md
1---2name: validate-change3description: Choose and run the right NeMo Fabric validation matrix for a change instead of using one fixed test list4license: Apache-2.05---678# Validate a Change910## Companion Guidance1112Use `karpathy-guidelines` alongside this skill for implementation or review13work. Keep changes scoped, surface assumptions, and define focused validation14before editing.1516Use this skill to choose the smallest validation set that still covers the17surfaces touched by a change.1819## Mandatory Rules2021- Format changed files with the language-native formatter before the final22 test pass.23- If Rust code changed, run `cargo fmt --all -- --check` and `just test-rust`.24- If Python code or a Python-facing adapter changed, run `just test-python`.25- If the TypeScript adapter contract or one of its source schemas changed, run26 `just test-typescript`.27- If `crates/fabric-core` changed in a way exposed through Python, run both the28 Rust and Python suites.29- If the PyO3 bridge or package metadata changed, run `just build-python` and30 `cargo check -p fabric-python --locked`.31- If public configuration types changed, confirm the schema snapshot tests in32 `just test-rust` pass and review generated schema diffs.33- If an adapter or integration changed, run its focused tests.34- If a Cargo or Python manifest or lockfile changed, run35 `uv run --no-project python scripts/licensing/license_diff.py --base-ref origin/main`,36 review the transitive license changes, then run the `attributions-rust` and37 `attributions-python` pre-commit hooks.38- If the TypeScript manifest or npm lockfile changed, inspect the complete npm39 dependency tree and license fields, confirm the package still has zero40 production dependencies, run the `attributions-node` pre-commit hook, and run41 its package and audit checks.42- If documentation or examples changed, run `just docs` when practical and43 verify documented commands against the current repository.44- If code changes alter APIs, commands, paths, packaging behavior, telemetry45 semantics, or documented best practices, update dependent maintainer skills in46 the same branch. Because the consumer skills under `skills/` restate SDK guide,47 Pydantic model, and Rust type details, update them in parity whenever those48 surfaces change.4950## Start With the Change Shape5152- **Rust core, CLI, or shared runtime semantics changed**53 Run Rust formatting and tests. Add Python tests when the behavior is exposed through the SDK, and run relevant tests for CLI behavior.54- **Python SDK or PyO3 binding changed**55 Use `python-tests`, run focused pytest tests first, then run56 `just test-python`. Rebuild with `just build-python` when native code or57 packaging changed.58- **Adapter behavior changed**59 Run the focused adapter tests under `tests/adapters`, then `just test-python`.60- **Harbor integration changed**61 Run `tests/test_harbor_runner.py`, then `just test-python`.62- **Schema or public contract changed**63 Run the Rust, Python, and TypeScript suites and review changes under64 `schemas/`, the checked-in Python adapter-contract representations, generated65 TypeScript sources, and generated API references.66- **Documentation-only change**67 Use `contribute-docs` and `review-doc-style`. Run `just docs` for docs-site or68 generated-reference changes.69- **CI or packaging changed**70 Use `maintain-ci` or `maintain-packaging`, then run the recipes and checks71 whose behavior changed.7273## Core Validation Matrix7475```bash76just test-rust77just test-python78just test-typescript79```8081## Common Targeted Commands8283```bash84# Rust85just build-rust86just test-rust87cargo fmt --all -- --check88cargo check -p fabric-python --locked8990# Python and native extension91just build-python92just test-python93uv run --no-sync pytest -k "<pattern>"9495# TypeScript adapter contract96just build-typescript97just test-typescript98just pack-typescript99100# Documentation101just docs102103# Dependency licenses104uv run --no-project python scripts/licensing/license_diff.py --base-ref origin/main105uv run pre-commit run --all-files attributions-rust106uv run pre-commit run --all-files attributions-python107uv run pre-commit run --all-files attributions-node108109# Justfile and patch hygiene110just --fmt --check111git diff --check112```113114## Hygiene Checks115116Before review or handoff:117118- Verify README and docs entry points still match current package names and119 paths.120- Verify examples use current `just` recipes and public commands.121- Call out checks that were not run and why.122- Run `git diff --check`.123124## References125126- Python test guidance: `python-tests`127- Build and test recipes: `justfile`128- Python CI: `.github/workflows/ci_python.yml`129- Rust CI: `.github/workflows/ci_rust.yml`130- TypeScript CI: `.github/workflows/ci_typescript.yml`131- Documentation CI: `.github/workflows/fern-docs.yml`132- Public Python contract: `docs/python-sdk-contract.md`133- Public adapter contract: `schemas/SCHEMA.md`