计划执行与检查节点
executing-plans
按既定实施计划完成工作,保持过程检查和反馈。
extend-primitives【效率与协作】Route custom primitive authoring, staged VJP/JVP closures, deprecated wrapper compatibility, and gradient checking.
独立 GitHub 快照 · 自动分类 · 以原作者文档为准
Use this sub-skill when a user needs to make a new primitive differentiable or extend an existing primitive with custom reverse- or forward-mode rules.
primitive-based authoring of custom primitives.defvjp, defjvp, defvjp_argnums, and defjvp_argnums closures..defvjp, .defgrad, and .defvjp_is_zero wrappers.check_grads and combo_check.autograd/extend.py, autograd/core.py, autograd/test_util.py, docs/updateguide.md, docs/tutorial.md, examples/define_gradient.py, tests/test_wrappers.py
references/api-reference.mdreferences/workflows.mdreferences/troubleshooting.mdscripts/custom_primitive_smoke.pyautograd.extend.primitive.defvjp_argnums / defjvp_argnums when one cached calculation should serve several argnums.None only when a rule is intentionally zeroed; omit the argnum entirely when you want the missing-path NotImplementedError.check_grads; use combo_check when several positional or keyword combinations need coverage.Run python scripts/custom_primitive_smoke.py before handing off a draft.
differentiation-core for operator semantics and derivative wrappers.numpy-scipy-primitives for primitives that wrap ndarray or SciPy behavior.