Test ffi surface
Build and test the NeMo Relay FFI surface; use this for crates/ffi changes, header generation, or ABI-facing validationFrom its SKILL.md
npx -y skills add NVIDIA/NeMo-Relay --skill test-ffi-surfaceAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
What its file declares
Copied from the file, not written here
The file declares its own license as Apache-2.0. That is the author’s claim about this one file, and it is not the same thing as the license GitHub reports for the repository, which is listed with the other numbers below.
SKILL.md
1.7 KB, as published. Nobody here has run it
Build And Test FFI Surface
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 when the change is primarily in crates/ffi, the generated
header, or ABI-facing behavior consumed by Go or external native callers.
Default Path
- Rebuild the FFI crate in release mode so the shared library and header stay in sync.
- Run
cargo fmt --allbecause FFI work is Rust work. - Run
just test-rust. - Run
cargo clippy --workspace --all-targets -- -D warnings. - Check the generated header diff when any exported symbol or type changed.
- If downstream consumers changed too, run their binding-specific skills next.
Common Commands
# Rebuild the shared library with the repo wrapper used by FFI consumers
just build-go
# Required Rust validation
cargo fmt --all
just test-rust
cargo test -p nemo-relay-ffi
cargo clippy --workspace --all-targets -- -D warnings
# Review header drift if the FFI surface changed
git diff -- crates/ffi/nemo_relay.h
When To Escalate
- If Go behavior changed, also use
test-go-binding. - If the FFI change reflects shared runtime semantics rather than a pure bridge
change, also use
validate-change.
References
crates/ffi/Cargo.tomlcrates/ffi/build.rscrates/ffi/cbindgen.tomlcrates/ffi/nemo_relay.hjust build-go.pre-commit-config.yamlREADME.mdvalidate-change