Agent skill · NVIDIA
doca-argp
Use this skill for hands-on DOCA Arg Parser CLI work on a shipped sample or new DOCA-using app — adding / removing / renaming flags; wiring `doca_argp_init` → register params → `doca_argp_start` → `doca_argp_destroy` in order; picking a parameter type from the full public enum (`DOCA_ARGP_TYPE_STRING`, `_INT`, `_BOOLEAN`, `_DEVICE`, `_DEVICE_REP`, `_DOUBLE` — six values, not three); preserving the standard `--device` / `--representor` / `--json` (`-j`; real flag is `--json`, NOT `--json-config`) / `--sdk-log-level` surface; or debugging `DOCA_ERROR_BAD_STATE` / `INVALID_VALUE` / `NOT_SUPPORTED` / `IO_FAILED` from `doca_argp_*`. Trigger on implicit phrasings: "add a custom flag to a DOCA sample", "should I use getopt here", "BAD_STATE registering a new param", "my JSON config key is rejected", or "my sample's --json is ignored". Refuse and route elsewhere for variadic-flag / subcommand / shell-completion features, DOCA Core context, or DOCA Log internals.
What it needs
About 7k tokens when loaded.
What this skill does
DOCA Arg Parser Where to start: This skill assumes DOCA is already installed and the user is doing hands-on CLI work on a DOCA sample or new DOCA-using app. Open TASKS.md if the user wants to do something (configure / build / modify / run / test / debug); open CAPABILITIES.md when the question is what can the Arg Parser express on this version. If the user has not installed DOCA yet, route to doca-setup first. If the user is about to rewrite a sample's CLI with getopt / argparse / custom parsing instead of reusing the Arg Parser, read the load-bearing rule in CAPABILITIES.md ## Capabilities and modes before any code change. Example questions this skill answers well The CLASSES of Arg Parser questions this skill is built to answer, each with one worked example. The agent should treat the class as the load-bearing piece — the worked example is a single instance. "How do I add a new flag to a DOCA sample without breaking the standard CLI?" — worked example: "add --my-flag to /opt/mellanox/doca/samples/docadma/dmalocalcopy/ so the sample still accepts --device <PCI> and --sdk-log-level <level> the same way it did before". Answered by the reuse-the-Arg-Parser rule in CAPABILITIES.md ## Capabilities and modes the register-before-start workflow in TASKS.md ## modify. "Why does docaargpparamset return BADSTATE on my second call?" — worked example: "registering a new param after docaargpstart has already parsed argv". Answered by the lifecycle order in CAPABILITIES.md ## Capabilities and modes the error-taxonomy row in CAPABILITIES.md ## Error taxonomy for DOCAERRORBADSTATE. "Can I drive a sample from a JSON file instead of a long command line?" — worked example: "point a sample at ./my-config.json so the operator does not have to type out ten flags every time". Answered by the --json <path> integration in CAPABILITIES.md ## Capabilities and modes the JSON-config-file workflow in TASKS.md ## modify and TASKS.md ## run. …
How to use it
Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:
@skills NVIDIA/doca-argp