Searcharxiv⌕ Search

arXiv subjects

Animesh Agarwal

Publications and source records attributed to Animesh Agarwal.

At least 19 recordsLinked to original sources

From Scores to Safe Sets: Exact Safety--Constrained Decoding for Medication Recommendation

Recent generative medication recommendation systems ultimately produce sets of drugs, but drug--drug interaction (DDI) constraints depend on the set as a whole. A natural post-hoc approach is to first predict medications and then locally repair interacting pairs by removing one drug at a time. We ask whether this local repair step itself introduces avoidable error. Using fixed medication scores from FLAME's frozen classifier on MIMIC-III, we compare increasingly strong local repair strategies with an exact global decoder while holding the scores, output size, and DDI constraint fixed. The global decoder jointly selects the highest-scoring feasible medication set using mixed-integer linear programming. Across validation and test splits, global decoding consistently achieves higher Jaccard similarity than greedy repair, degree-aware repair, and degree-aware repair strengthened with exhaustive 1-swap local search. Its advantage is small under loose DDI constraints and becomes larger as the constraint tightens; on the test split it reaches +0.0064 Jaccard over the strongest local baseline at the strict DDI operating point. The finding also holds across a fine accuracy--DDI sweep at matched realized DDI exposure and under three score representations. At the strict setting, global decoding retains more true-positive medications while removing more false positives. These results show that medication recommendation is not only a representation-learning problem: even with a frozen clinical model, how its scores are converted into a constrained medication set can materially affect the final prediction.

cs.AI↗

Verification Turns Capability Gaps into Routing Decisions: Small Language Models for Clinical Documentation

Clinical note generation from doctor--patient dialogue is high-volume and hallucination-intolerant: a fabricated laboratory value can create patient-safety risk, not a quality regression. We ask whether an agentic \emph{verification} architecture, rather than generator scale, can make a small language model viable here. Holding a four-evaluator verification stack and refinement policy fixed and swapping only the generator between a 4B-parameter model with a QLoRA adapter and a frontier baseline, the small model reaches $0.984$ claim-level factual entailment against $0.992$ and comes within $3.3$ points on completeness, generating entirely on-device. Its deficit is confined to \emph{inter-section structural fidelity}---arrangement rather than clinical comprehension, and the axis on which it also falls furthest below the corpus's reference notes. Because that deficit is an explicit verifier decision rather than a silent quality difference, it becomes a routing policy: run the small model by default, escalate what the verifier rejects. Measured end to end, that it achieved a similiar verified-rate acceptance to the frontier-only acceptance in this test set ($99.6\%$ vs.\ $98.4\%$ over $250$ encounters) while routing $62$, documenting three quarters without a frontier \emph{generation} call. Ablating the loop separates architecture from scale: unrefined, the small model is accepted on $26.8\%$ of encounters and the frontier model on $74.8\%$, so verification does the most work where the generator is weakest. We also contribute section-scoped refinement, which preserves unflagged sections by construction rather than instruction, and find the baseline is not uniformly stronger---its provider refused two trauma-related transcripts the on-device model handled and certified, one facet of a provider dependency a served adapter does not carry.

cs.AI↗

LearnActCoder: Role-Aware Error Memory for Adaptive Clinical Coding Agents

Clinical coding agents repeatedly encounter the same failure modes, including unsupported codes, missed documented conditions, specificity errors, and procedure-coding convention mismatches. We introduce Learn-Then-Act, an inference-time adaptation framework that converts errors from a small labeled LEARN batch into a structured Mistake Knowledge Database (MistakeKDB). False-negative lessons are routed to a recall-oriented Coder, while false-positive lessons are routed to a precision-oriented Judge. We instantiate the framework in LearnActCoder, a Coder-Judge clinical coding pipeline with lookup-table grounding where available. On 150 matched MIMIC-III notes, structured MistakeKDB improves CPT F1 by 5.9 percentage points, while raw-example and reflection-style memories remain near the no-memory baseline; the ICD-9 improvement is not significant. On a matched MIMIC-IV cohort, memory shifts ICD-10 coding toward higher precision at a recall cost, leaving F1 statistically unchanged. Applying the same memory to 1,000 held-out MIMIC-III notes maintains a stable ICD operating point, providing scale/stability evidence. Overall, the results are consistent with structured, feedback-derived error memory being useful for adapting clinical coding behavior across cases without weight updates or changes to the underlying workflow. Absolute CPT/HCPCS performance remains low, and the system is evaluated retrospectively rather than in clinical deployment.

cs.AI↗

Tabular Population Priors as Structured Retrieval for EHR Medication Set Prediction

Medication prediction from electronic health records is a fixed vocabulary structured prediction problem, yet recent clinical RAG systems often treat it like open ended case based reasoning: retrieve similar patient admissions and ask an LLM to infer a medication set. This retrieval object is indirect the model receives retrieved patient records while the target is a discrete set of medication class labels. We propose a more task aligned retrieval object: a tabular population prior ranked medication class candidates from a sparse condition medication co occurrence table estimated from training admissions. Using PACERAG as a fixed downstream pipeline and replacing only its patient retriever, this drop in swap improves F1 from 0.303 to 0.338 (+11.5% relative) and Jaccard from 0.218 to 0.237 on 1,004 heldout MIMIC IV admissions, with no additional LLM calls and no inference time patient index. A non LLM top k baseline reaches F1=0.248, confirming the prior is predictive before LLM integration. Aggregate population statistics can provide a more task aligned, efficient, and auditable retrieval source than patient level nearest neighbors for fixed vocabulary EHR set prediction.

cs.AI↗

A Multi-Agent Pipeline for Source-Grounded Synthetic Note Generation from Longitudinal Structured EHR

Structured EHR is abundant but sparse, coded, and difficult to use directly for note-centric clinical modeling. We present MedNotes, a multi-agent synthetic data generation pipeline that converts longitudinal structured EHR into source-grounded clinical note representations under explicit quality control. MedNotes treats structured-data-to-text synthesis as a closed-loop agentic process: a generator proposes a note, evaluator agents diagnose factual, coverage, structural, and hallucination-related failures, and a router accepts, revises, or rejects the draft. On 1,485 EHRSHOT encounters, MedNotes achieves a 91.4% pass rate, with mean factual accuracy of 0.980, completeness of 99.1%, structural fidelity of 0.761, and 0.028 critical hallucinations per encounter. Iterative refinement improves acceptance from 69.4% to 91.4%. The resulting synthetic corpus improves downstream CPT prediction and paragraph-level section prediction when combined with limited real data.

cs.CL↗

Structured Evidence Routing for Incident Risk Prediction from Multimodal Longitudinal EHRs

Incident risk prediction from longitudinal electronic health records (EHRs) is challenging because relevant signals are multimodal, weak in isolation, and distributed across irregular patient histories. We propose structured evidence routing, a router-predictor-reviewer workflow that separates full-record access from disease-specific assessment. The router organizes the complete pre-index EHR into a compact summary and targeted evidence slices; the predictor uses this evidence to form an evidence-linked risk assessment, which the reviewer critiques. For comparison with supervised EHRSHOT baselines, we pair the routed evidence summaries with a supervised classifier readout. Across five 1-year incident diagnosis tasks, our method reaches the AUROC range of established supervised EHRSHOT baselines and remains competitive on AUPRC, while exposing a patient-specific evidence trail. Internal pre-readout ablations further suggest that routing, laboratory evidence, task guidance, and review each contribute to performance.

cs.AI↗

Arbitrarily accurate representation of atomistic dynamics via Markov Renewal Processes

Atomistic simulations with methods such as molecular dynamics are extremely powerful tools to understand nanoscale dynamical behavior. The resulting trajectories, by the virtue of being embedded in a high-dimensional configuration space, can however be difficult to analyze and interpret. This makes low-dimensional representations, especially in terms of discrete jump processes, extremely valuable. This simplicity however usually comes at the cost of accuracy, as tractable representations often entail simplifying assumptions that are not guaranteed to be realized in practice. In this paper, we describe a discretization scheme for continuous trajectories that enables an arbitrarily accurate representation in terms of a Markov Renewal Process over a discrete state space. The accuracy of the model converges exponentially fast as a function of a continuous parameter that has the interpretation of a local correlation time of the dynamics.

cond-mat.stat-mech↗

Computing Long Timescale Biomolecular Dynamics using Quasi-Stationary Distribution Kinetic Monte Carlo (QSD-KMC)

It is a challenge to obtain an accurate model of the state-to-state dynamics of a complex biological system from molecular dynamics (MD) simulations. In recent years, Markov State Models have gained immense popularity for computing state-to-state dynamics from a pool of short MD simulations. However, the assumption that the underlying dynamics on the reduced space is Markovian induces a systematic bias in the model, especially in biomolecular systems with complicated energy landscapes. To address this problem, we have devised a new approach we call quasi-stationary distribution kinetic Monte Carlo (QSD-KMC) that gives accurate long time state-to-state evolution while retaining the entire time resolution even when the dynamics is highly non-Markovian. The proposed method is a kinetic Monte Carlo approach that takes advantage of two concepts: (i) the quasi-stationary distribution and (ii) dynamical corrections theory. Implementation of QSD-KMC imposes stricter requirements on the lengths of the trajectories than in a Markov State Model approach, as the trajectories must be long enough to dephase. However, the QSD-KMC model produces state-to-state trajectories that are statistically indistinguishable from an MD trajectory mapped onto the discrete set of states, for an arbitrary choice of state decomposition. Furthermore, the aforementioned concepts can be used to construct a Monte Carlo approach to optimize the state boundaries regardless of the initial choice of states. We demonstrate the QSD-KMC method on two one-dimensional model systems, one of which is a driven nonequilibrium system, and on two well-characterized biomolecular systems.

physics.chem-ph↗

Molecular dynamics of open systems: construction of a mean-field particle reservoir

The simulation of open molecular systems requires explicit or implicit reservoirs of energy and particles. Whereas full atomistic resolution is desired in the region of interest, there is some freedom in the implementation of the reservoirs. Here, we construct a combined, explicit reservoir by interfacing the atomistic region with regions of point-like, non-interacting particles (tracers) embedded in a thermodynamic mean field. The tracer molecules acquire atomistic resolution upon entering the atomistic region and equilibrate with this environment, while atomistic molecules become tracers governed by an effective mean-field potential after crossing the atomistic boundary. The approach is extensively tested on thermodynamic, structural, and dynamic properties of liquid water. Conceptual and numerical advantages of the procedure as well as new perspectives are highlighted and discussed.

physics.comp-ph↗

Adaptive Resolution Molecular Dynamics Technique: Down to the Essential

We investigate the role of the thermodynamic (TD) force, as an essential and sufficient technical ingredient for an efficient and accurate adaptive resolution algorithm. Such a force applied in the coupling region of an adaptive resolution Molecular Dynamics (MD) set-up, assures thermodynamic equilibrium between atomistically resolved and coarse-grained regions, allowing the proper exchange of molecules. We numerically prove that indeed for systems as relevant as liquid water and 1,3-dimethylimidazolium chloride ionic liquid, the combined action of the TD force and thermostat allows for computationally efficient and numerically accurate simulations, beyond the current capabilities of adaptive resolution set-ups, which employ switching functions in the coupling region.

physics.comp-ph↗

Computational Efficiency and Amdahl's law for the Adaptive Resolution Simulation Technique

We discuss the computational performance of the adaptive resolution technique in molecular simulation when it is compared with equivalent full coarse-grained and full atomistic simulations. We show that an estimate of its efficiency, within $10-15\%$ accuracy, is given by the Amdahl's Law adapted to the specific quantities involved in the problem. The derivation of the predictive formula is general enough that it may be applied to the general case of molecular dynamics approaches where a reduction of degrees of freedom in a multiscale fashion occurs.

physics.comp-ph↗

Grand-Canonical Adaptive Resolution Centroid Molecular Dynamics: Implementation and Application

We have implemented the Centroid Molecular Dynamics scheme (CMD) into the Grand Canonical-like version of the Adaptive Resolution Simulation Molecular Dynamics (GC-AdResS) method. We have tested the implementation on two different systems, liquid parahydrogen at extreme thermodynamic conditions and liquid water at ambient conditions; the reproduction of structural as well as dynamical results of reference systems are highly satisfactory. The capability of performing GC-AdResS CMD simulations allows for the treatment of a system characterized by some quantum features and open boundaries. This latter characteristic not only is of computational convenience, allowing for equivalent results of much larger and computationally more expensive systems, but also suggests a tool of analysis so far not explored, that is the unambiguous identification of the essential (quantum) degrees of freedom required for a given property.

physics.comp-ph↗

Path Integral Molecular Dynamics within the Grand Canonical-like Adaptive Resolution Technique: Simulation of Liquid Water

Quantum effects due to the spatial delocalization of light atoms are treated in molecular simulation via the path integral technique. Among several methods, Path Integral (PI) Molecular Dynamics (MD) is nowadays a powerful tool to investigate properties induced by spatial delocalization of atoms; however computationally this technique is very demanding. The abovementioned limitation implies the restriction of PIMD applications to relatively small systems and short time scales. One possible solution to overcome size and time limitation is to introduce PIMD algorithms into the Adaptive Resolution Simulation Scheme (AdResS). AdResS requires a relatively small region treated at path integral level and embeds it into a large molecular reservoir consisting of generic spherical coarse grained molecules. It was previously shown that the realization of the idea above, at a simple level, produced reasonable results for toy systems or simple/test systems like liquid parahydrogen. Encouraged by previous results, in this paper we show the simulation of liquid water at room conditions where AdResS, in its latest and more accurate Grand-Canonical-like version (GC-AdResS), is merged with two of the most relevant PIMD techniques available in literature. The comparison of our results with those reported in literature and/or with those obtained from full PIMD simulations shows a highly satisfactory agreement.

physics.chem-ph↗

Molecular Dynamics in a Grand Ensemble: Bergmann-Lebowitz model and Adaptive Resolution Simulation

This article deals with the molecular dynamics simulation of open systems that can exchange energy and matter with a reservoir; the physics of the reservoir and its interactions with the system are described by the model introduced by Bergmann and Lebowitz.Despite its conceptual appeal, the model did not gain popularity in the field of molecular simulation and, as a consequence, did not play a role in the development of open system molecular simulation techniques, even though it can provide the conceptual legitimation of simulation techniques that mimic open systems. We shall demonstrate that the model can serve as a tool to devise both numerical procedures and conceptual definitions of physical quantities that cannot be defined in a straightforward way by systems with a fixed number of molecules. In particular, we discuss the utility of the Bergmann-Lebowitz (BL) model for the calculation of equilibrium time correlation functions within the Grand Canonical Adaptive Resolution method (GC-AdResS) and report numerical results for the case of liquid water.

physics.comp-ph↗

Adaptive Resolution Simulation in Equilibrium and Beyond

In this paper, we investigate the equilibrium statistical properties of both the force and potential interpolations of adaptive resolution simulation (AdResS) under the theoretical framework of grand-canonical like AdResS (GC-AdResS). The thermodynamic relations between the higher and lower resolutions are derived by considering the absence of fundamental conservation laws in mechanics for both branches of AdResS. In order to investigate the applicability of AdResS method in studying the properties beyond the equilibrium, we demonstrate the accuracy of AdResS in computing the dynamical properties in two numerical examples: The velocity auto-correlation of pure water and the conformational relaxation of alanine dipeptide dissolved in water. Theoretical and technical open questions of the AdResS method are discussed in the end of the paper.

physics.chem-ph↗

Chemical potential of liquids and mixtures via Adaptive Resolution Simulation

We employ the adaptive resolution approach AdResS, in its recently developed Grand Canonical-like version (GC-AdResS) [Wang et al. Phys.Rev.X 3, 011018 (2013)], to calculate the excess chemical potential, $μ^{ex}$, of various liquids and mixtures. We compare our results with those obtained from full atomistic simulations using the technique of thermodynamic integration and show a satisfactory agreement. In GC-AdResS the procedure to calculate $μ^{ex}$ corresponds to the process of standard initial equilibration of the system; this implies that, independently of the specific aim of the study, $μ^{ex}$, for each molecular species, is automatically calculated every time a GC-AdResS simulation is performed.

cond-mat.stat-mech↗

The excess equimolar radius of liquid drops

The curvature dependence of the surface tension is related to the excess equimolar radius of liquid drops, i.e., the deviation of the equimolar radius from that defined with the macroscopic capillarity approximation. Based on the Tolman [J. Chem. Phys. 17, 333 (1949)] approach and its interpretation by Nijmeijer et al. [J. Chem. Phys. 96, 565 (1991)], the surface tension of spherical interfaces is analysed in terms of the pressure difference due to curvature. In the present study, the excess equimolar radius, which can be obtained directly from the density profile, is used instead of the Tolman length. Liquid drops of the truncated-shifted Lennard-Jones fluid are investigated by molecular dynamics simulation in the canonical ensemble, with equimolar radii ranging from 4 to 33 times the Lennard-Jones size parameter sigma. In these simulations, the magnitudes of the excess equimolar radius and the Tolman length are shown to be smaller than sigma/2. Other methodical approaches, from which mutually contradicting findings have been reported, are critically discussed, outlining possible sources of inaccuracy.

cond-mat.soft↗