nvidia/test-python-binding
Build and test the NeMo Relay Python binding and worker plugin SDK; use for python/nemo_relay, python/plugin, or crates/python changes
npx skills add https://github.com/NVIDIA/NeMo-Relay --skill test-python-binding
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 when the change is primarily in python/nemo_relay,
python/plugin, python/tests, crates/python, or Python-facing
docs/examples.
uv run ruff format python python/plugin.pytest first when you know the affected area.just test-python-plugin when the Python worker SDK changed.just test-python before review.cargo fmt --all, just test-rust, and
cargo clippy --workspace --all-targets -- -D warnings.
just build-python when you want an explicit build-only pass.just build-python-plugin when the Python worker SDK changed.nemo-relay-python.
@pytest.mark.asyncio to any test. Async tests are automatically detected and run by the async runner; the decorator is unnecessary clutter.-> None return type annotation to test functions. This is not a common convention in pytest and adds unnecessary verbosity.unittest.mock.MagicMock or unittest.mock.AsyncMock, with the spec constructor argument when necessary.mock, not fake.conftest.py file. @pytest.fixture(name="<fixture_name>"[, scope="<scope>"])
def <fixture_name>_fixture() -> <return_type>:
...
Only specify the scope argument when the value is something other than "function".
pytest.mark.parametrize over creating individual tests fordifferent input types.
# Focused test loop
uv run pytest -k "<pattern>"
# Focused Python worker plugin SDK suite
just test-python-plugin
# Format Python files
uv run ruff format python python/plugin
# Full Python suite
just test-python
# Required when the Python change also touched Rust code
cargo fmt --all
just test-rust
cargo clippy --workspace --all-targets -- -D warnings
# Rebuild the editable package plus native extension
just build-python
# Rebuild/install the Python worker plugin SDK
just build-python-plugin
# Native extension crate when crates/python changed
cargo test -p nemo-relay-python
crates/core, crates/adaptive, or shared runtime semantics changed,also use validate-change.
python/plugin or worker protocol behavior changed, also usemaintain-dynamic-plugins.
contribute-docsplus targeted command checks.
pyproject.tomlcrates/python/Cargo.tomlcrates/python/README.mdpython/nemo_relay/README.mdpython/plugin/pyproject.tomlpython/plugin/src/nemo_relay_pluginpython/tests/plugindocs/getting-started/quick-start/python.mdxdocs/contribute/testing-and-docs.mdxvalidate-changeTake nvidia/test-python-binding from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.