Differentiation core

From VectorSpaceLab/AREX-Skill · View interactive version

Differentiation core is an AI agent skill from the GitHub repository VectorSpaceLab/AREX-Skill. Routes scalar and array differentiation, higher-order derivatives, and gradient checking for Autograd's core AD operators.

How to use this skill

Skill file

Differentiation Core

Use this sub-skill when a task is about Autograd's core differentiation operators: scalar gradients, Jacobians, directional derivatives, Hessians, VJP/JVP pullbacks, generalized Gauss-Newton products, complex holomorphic derivatives, checkpointing, or numerical gradient checks.

Trigger examples

Read first

Boundary routing

How to choose an operator

Core rules

Typical route

  1. Start with grad for a scalar loss.
  2. If the output is vector-valued, switch to jacobian or elementwise_grad.
  3. If you need both the value and the gradient, use value_and_grad.
  4. If you need a directional derivative, use deriv or make_jvp.
  5. If you need a pullback from output cotangents, use make_vjp.
  6. If you need curvature information, use hessian or a Hessian-vector product helper.
  7. If the function is complex-valued and holomorphic, use holomorphic_grad.
  8. If the function is deep and memory-bound, wrap it with checkpoint.
  9. Validate the chosen operator with check_grads before trusting a new workflow.

Reliability notes

What this sub-skill does not cover

Fastest sanity check

Run scripts/differentiation_smoke.py when you need a quick end-to-end check that the bundled differentiation guidance still matches the installed package.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.