Inverse Reinforcement Learning with Switching Rewards and History Dependency for Characterizing Animal Behaviors
ELVIA analysis
Independent review pending
Two demonstrated errors affect the published inference and learning derivation for SWIRL. The forward initialization omits the first action likelihood, yielding an incorrect sequence likelihood and terminal hidden-mode posterior in an admissible finite soft-MDP example. The printed M-step then descends a positive expected log joint that must be maximized; a legal initial-mode-prior subproblem gives a strict decrease even for a small step. Both findings support Major because they concern the central EM procedure. The inspected release includes the first emission and minimizes a negative expected log joint, which is explicit counterevidence against attributing these defects to the historical empirical results. Scientific adjudication remains pending.
Problem 1. The forward boundary omits the first action likelihood
MajorEvidence and reasoning
Problem statement
Kind: paraphrase.
Location: PDFp14 AppendixA2, forward definition, initialization and terminal formulas; jointp13.
Text: alpha_t is the joint through action t, but is set to the initial mode prior alone.
Finite three-state, two-action, two-mode model; historyL1; temperature1. Initial state certain; mode prior(); identity mode kernel permitted by stated assumptions. :a-> absorb; state-only rewards Derived optimal soft policies give first action probabilities() and terminal action probability.5.
Proof
Assessment: Major. Appendix A.2, p. 14, defines but initializes The recursion starts with the current action likelihood at The stated terminal likelihood is and the terminal posterior uses
By the displayed formula, the required initialization is A common initial-state factor can be dropped from normalized mode posteriors if handled consistently, but a mode-dependent action probability cannot. The example below sets eliminating that possible distraction.
Use three states two actions two modes history length discount and entropy temperature one. The initial state is and the initial modes have probability each. From action reaches deterministically and action reaches Both and are absorbing under either action. The hidden-mode kernel is the identity at every state.
This kernel is a valid state-independent special case of the stated state-conditioned model; no strict-positivity or irreducibility premise is imposed in the paper. It also makes the mode-specific policy optimal for the full process, removing any separate question about anticipated future mode changes.
Set Rewards are bounded, real and state-only. At an absorbing state entropy-regularized optimal value is At the difference between the two mode-A action values is with the opposite sign in mode B. The Boltzmann policy therefore has and each action at or has probability in either mode. These emissions are derived from the paper’s soft-policy construction, rather than assigned arbitrarily.
The independent parent script constructs the soft values and action probabilities and checks their Bellman residuals. The reported maximum residual is zero at the used floating precision, below the auxiliary calculation independently confirms the construction.
Observe The environment transition factor is one. Exact joint weights are and hence The printed initialization gives Even applying the subsequent recurrence correctly gives Thus the sequence likelihood doubles and the terminal mode-A posterior differs by This calculation uses only the unambiguous terminal condition; it does not depend on the separate problematic backward boundary expression on the same page.
With the displayed formula, and restoring the enumerated likelihood and posterior exactly. These fractions are independently evaluated with exact rational arithmetic in the independent output cited above.
The E-step posterior weights determine reward fitting, hidden-mode transition fitting, and the inferred behavioral segmentation in main Eqs. (1)–(4) and Appendix A.1 Eqs. (5)–(7). The printed recurrence therefore fails at a central inference step for an allowed model. This supports Major even though the omission is short and a correct intended factorization is available elsewhere.
A reinterpretation of as a pre-emission message would require the recursion to multiply the first action before proceeding; the printed formulas do not do that. The joint on p. 13 is internal counterevidence about intended correctness, not a validation of the conflicting boundary formula.
The inspected release is correct on this point: `gw5/swirl/swirl_func.py`, lines – initializes log-forward values as `log(pi0) + log_likes[0]`. Lines – use the next emission in the backward scan; lines – construct normalized marginals and wire the E-step. Analogous first-emission terms occur in the inspected labyrinth and spontaneous-behavior routes. No released or historical run is claimed to omit the first action.
A consistent backward recursion from the displayed formula is The printed p. 14 expression instead uses current-action and shifted state-conditioning indices, with a separate self-referential first-boundary line. Correcting all boundaries and indices to the joint resolves the specification. The forward correction is verified exactly on the finite case; no empirical performance repair or complete implementation rerun is certified.
Possible revision
Initialize with p(s1)p(z1)pi_z(a1|); align backward indices with the joint.
Problem 2. The M-step descends a positive expected log joint
MajorEvidence and reasoning
Problem statement
Kind: paraphrase.
Location: PDFp12 Algorithm1 and AppendixA1 Eqs5–7; p13argmax.
Text: is expected log joint to maximize, but update is theta<-theta-eta gradG.
Positive step eta and nonzero gradient. Use exact E-step posteriorq= independent ofP1error. Initial mode prior is learned parameter; other components heldfixed forscalarblock.
Proof
Assessment: Major. Appendix A.1, p. 12, defines with positive expected log-policy, log-prior and log-transition terms. Both prose and Algorithm 1 then prescribe gradient descent: Appendix A.2, p. 13, correctly specifies the M-step target as These directions conflict.
For and sufficiently small positive The printed step therefore decreases the maximization target. Even generalized EM seeks an increase rather than necessarily an exact maximizer; the sign does not implement that weaker requirement either.
Use the exact posterior in Problem Problem 1 (#prob:forward), so this finding is independent of its erroneous E-step. The paper includes among the learned parameters. Holding the remaining model components fixed, parameterize where is logistic. For posterior the varying part of is At and The exact maximizer is Parent independent arithmetic gives:
printed descent | ascent
|
|
|
Every descent value is below while ascent increases it. The small-step example avoids dependence on an excessive learning rate. The block calculation is one valid optimization subproblem, and the preceding differential argument supplies the general sign conclusion. Actual values and source bindings are in .
Possible revision
Use ascent onG or descent on explicitly defined-G.
Supporting record & provenance
Work status
Current version
Version 1
Minhao Liu · Initial report · Version 1
Independent review pending
Original claim and review scope
This work presents the first IRL model to incorporate history-dependent policies and rewards to advance our understanding of complex, naturalistic decision-making in animals.
{'label': 'PMLR 267 / ICML 2025 published proceedings version', 'publisher_publication_date': '2025/10/06', 'pages': '29608-29625', 'landing_url': 'https://proceedings.mlr.press/v267/ke25b.html', 'pdf_url': 'https://raw.githubusercontent.com/mlresearch/v267/main/assets/ke25b/ke25b.pdf', 'accessed_utc': '2026-10-24T14:10:19.850554+00:00'}; Abstract, PDF p. 1
Actual review scope
The recorded inspection concerns these source locations: Retained report, Problem 1: Problem 1 (The forward initialization omits a mode-dependent first emission).; Retained report, Problem 2: Problem 2 (Algorithm 1 descends the auxiliary function it must maximize).