Cross-Partial Nash Compatibility Regularizer
Implementation & benchmark of arXiv:2607.19928 — Continuous-Time Reinforcement Learning for $N$-Player Stochastic Differential Games with Exploratory Policies
Source paper: Continuous-Time Reinforcement Learning for $N$-Player Stochastic Differential Games with Exploratory Policies arXiv:2607.19928 ⓘ · analyzed Aug 30, 2026
AI-generated research hypothesis, automatically tested. Not peer-reviewed.
Idea description
Add an integrability penalty to a multi-agent critic so that the players' entropy-regularized Gibbs best responses can be represented by one coherent joint policy. The penalty detects whether the learned action-value functions define a conservative joint action field, preventing independent agents from learning mutually incompatible conditional policies.
Formulas
Mathematical statement
For players i=1,...,N with continuous scalar actions u_i and learned q-functions q_i(x,u_1,...,u_N), the entropy-regularized conditional best response has the Gibbs form π_i(u_i|u_{-i},x) proportional to exp(q_i(x,u)/γ), where γ>0 is the exploration temperature and u_{-i} denotes all actions except u_i. Define the action field F_i(x,u)=∂q_i(x,u)/∂u_i. A necessary compatibility condition for these conditionals to arise from one differentiable joint energy Φ is the conservative-field identity ∂F_i/∂u_j=∂F_j/∂u_i for every i≠j, equivalently ∂²q_i/(∂u_j∂u_i)=∂²q_j/(∂u_i∂u_j). Penalize violations with L_compat=E[Σ_{i<j}(∂²q_i/(∂u_j∂u_i)-∂²q_j/(∂u_i∂u_j))²]. On a simply connected action domain, a zero residual makes the field conservative, so a scalar joint Gibbs energy can be constructed.
Implementation notes
Integrate this into the centralized critic of a continuous-control multi-agent algorithm such as MADDPG, MASAC, or MAPPO. The critic should expose q_i(x,u_1,...,u_N) for every player, with action inputs kept differentiable. For each minibatch of states and joint actions, compute first derivatives g_i=autograd.grad(q_i,u_i,create_graph=True); compute h_ij=autograd.grad(g_i,u_j,create_graph=True); accumulate the squared residual (h_ij-h_ji)^2 over i<j; and add lambda_compat times this quantity to the critic loss. Use Hutchinson probes for high-dimensional vector actions: estimate the mixed-Jacobian discrepancy with random Rademacher vectors rather than materializing every Hessian entry. Pseudocode is: sample batch B; evaluate q_i; for each i compute g_i=dq_i/du_i; for each pair compute h_ij=d g_i/du_j and h_ji=d g_j/du_i; Lc=sum(norm(h_ij-h_ji)^2); update critic on L_RL+lambda Lc; update actors normally using their critics. The mathematical quantity is the cross-partial residual; lambda, action smoothing, and whether to apply the penalty only near replay actions are empirical choices. First test on a two-agent, two-dimensional-action particle-navigation or HalfCheetah coordination task against MADDPG/MASAC. Track critic Bellman error, variance of actor gradients, achieved return, and the empirical residual. Success means lower gradient variance and higher return at equal environment interactions, without a substantial increase in critic wall-clock cost.
Verification
Stage 1 · Toy mechanism gate: Passed ✓
Stage 2 · Mechanism transferred to benchmark: Confirmed ✓
Stage 2 · Practical benchmark result: Significant win ✓
Methodology: 8 paired seeds, permutation test (p<0.05) against a learning-rate-tuned baseline. How verification works
Stage 1 — Mechanism check agent confidence 9/10
Built and numerically verified an autograd cross-partial compatibility regularizer for a two-agent centralized-critic toy problem. The autograd residual matched an independent finite-difference calculation to 2.0e-12; the residual followed the predicted 2/(1+4λ) law across the lambda sweep, and the Gibbs incompatibility squared followed the predicted 1/γ² law exactly. Regularization reduced the residual from 2.0 to 0.4 at λ=1, while critic fitting loss increased from approximately 0 to 0.64 because the deliberately incompatible target critics cannot both be preserved under a conservative-field constraint; this confirms the mechanism, but not an RL return improvement.
- Agent confidence
- 9/10
- Baseline
- lambda=0: absolute cross-partial residual 2.0000; critic fit loss 1.87e-18
- Finite difference check
- Autograd residual 2.000000000000 versus finite-difference residual 2.000000000002; absolute error 2.0e-12
- Gamma prediction
- Observed squared Gibbs mismatch exactly matched 4/gamma^2 for gamma in {0.25, 0.5, 1, 2, 4}
- Idea
- lambda=1: absolute cross-partial residual 0.4000; critic fit loss 0.6400; predicted residual 0.4000
- Lambda prediction
- Observed relative error at most 1.4e-9 for lambda in {0, 0.05, 0.25, 0.5, 1, 2, 5}
Limitations: This is a controlled two-agent scalar-action critic-fitting MVP, not a full MADDPG, MASAC, or environment experiment. It does not measure environment return, actor-gradient variance, replay-buffer sample efficiency, Hutchinson estimation, or wall-clock overhead in a high-dimensional neural critic.
How to run: python3 experiment.py
Stage 2 — Benchmark vs. tuned baseline (arXiv:2607.19928)
Beats the tuned baseline by 18.4% (p=0.0081, wins 8 / 8 paired seeds; metric: lower is better).
- Benchmark
- Multi_agent_critic_compatibility
- Model
- smooth_mlp_tiny
- Paired seeds
- 8
- Baseline mean
- 0.0181
- Idea mean
- 0.0147
- Effect (Δ)
- -0.0033 (−18.4%; negative = idea better)
- Wins
- 8 / 8 paired seeds
- p-value
- 0.0081 (permutation test, 20 000 shuffles)
- Smallest detectable effect
- ±11.3%
- Mechanism
- Confirmed ✓
- Practical effect
- Helps
- Baseline tuning
- swept over 3 configs
The custom task is a fast centralized-critic regression proxy with two scalar interaction coordinates, not a full multi-agent RL simulator. No environment return, actor-gradient variance, replay sample efficiency, high-dimensional Hutchinson estimation, or wall-clock comparison against MADDPG/MASAC was tested. The smooth tanh MLP was necessary because ReLU second derivatives made the penalty identically inactive.
How to run: python3 bench_run.py
Verdict computed by deterministic test code from paired-seed statistics — not by the language model.
Stage 2 — Benchmark latest Worked ✓
Agent confidence: 8/10
The registered custom benchmark track completed the full 8-seed paired protocol with a tuned baseline and shared learning-rate search space. The compatibility-regularized smooth MLP achieved lower test MSE than the baseline on all 8 seeds, with a significant paired improvement; the trained-network cross-partial residual also fell substantially, confirming the predicted mechanism. This remains a centralized-critic regression proxy rather than an end-to-end multi-agent RL return evaluation.
- Baseline
- lr=0.006; test MSE mean 0.0180528023, std 0.0030102786
- Idea
- lr=0.006, lambda=0.05; test MSE mean 0.0147398898, std 0.0021974917
- Mechanism residual
- baseline 0.2295021936; idea 0.0556863118; confirmed=true
- Paired delta
- -0.0033129125
- Permutation p value
- 0.0081
Benchmark result
Beats the tuned baseline by 18.4% (p=0.0081, wins 8 / 8 paired seeds; metric: lower is better).
- Benchmark
- Multi_agent_critic_compatibility
- Model
- smooth_mlp_tiny
- Paired seeds
- 8
- Baseline mean
- 0.0181
- Idea mean
- 0.0147
- Effect (Δ)
- -0.0033 (−18.4%; negative = idea better)
- Wins
- 8 / 8 paired seeds
- p-value
- 0.0081 (permutation test, 20 000 shuffles)
- Smallest detectable effect
- ±11.3%
- Mechanism
- Confirmed ✓
- Practical effect
- Helps
- Baseline tuning
- swept over 3 configs
The custom task is a fast centralized-critic regression proxy with two scalar interaction coordinates, not a full multi-agent RL simulator. No environment return, actor-gradient variance, replay sample efficiency, high-dimensional Hutchinson estimation, or wall-clock comparison against MADDPG/MASAC was tested. The smooth tanh MLP was necessary because ReLU second derivatives made the penalty identically inactive.
How to run: python3 bench_run.py
Artifacts
- bench_report.json 3.7 KB View Raw
- bench_run.py 6.3 KB View Raw
- compat_track.py 1.0 KB View Raw
- experiment.py 4.6 KB View Raw
- report.md 1.8 KB View
- report_bench_2026-08-31T125413.md 4.3 KB View
- results.json 3.6 KB View Raw