Feynman–Kac SMC Procedure
- Feynman–Kac SMC is a particle method that approximates evolving measures defined by Markov processes using sequential importance weighting and resampling.
- The procedure integrates Markov kernels, potential functions, and resampling to maintain sample diversity and control estimator variance in dynamic models.
- Recent advancements include vectorized implementations and adaptations for discrete diffusion, probabilistic programming, and generative modeling to enhance scalability and flexibility.
The Feynman–Kac Sequential Monte Carlo (SMC) procedure constitutes a principled class of particle methods for approximating evolving measures defined via Feynman–Kac models. These models describe distributions of trajectories of Markov processes, reweighted by potentials, which arise in diverse settings including probabilistic programming semantics, nonconservative PDEs, diffusion models for generative modeling, and stochastic control. The SMC methodology is built upon the recursive structure of the Feynman–Kac flow, combining forward simulation of particles with sequential importance weighting and resampling to control variance and maintain sample diversity. Modern computational variants, including vectorized implementations and recent extensions to discrete diffusion and product-of-experts inference, further enhance the flexibility and scalability of the core procedure.
1. Abstract Feynman–Kac Flow and Model Specification
The Feynman–Kac model specifies a sequence of probability distributions over a measurable state space , constructed via the following ingredients:
- An initial distribution on ;
- For : transition Markov kernels and potential (or weight) functions .
The recursion defining the Feynman–Kac flow at each step is
where is the Boltzmann–Gibbs update operator acting on measures. The sequence corresponds to the marginal distributions of a Feynman–Kac path measure on ,
This general formalism encompasses both continuous and discrete time models, with appropriate modifications to the Markov kernels and weights in each case (Boreale et al., 17 Sep 2025, Lecavil et al., 2016, Jasra, 2013, Hasan et al., 15 Jan 2026).
2. Sequential Monte Carlo Approximation
Sequential Monte Carlo approximates the Feynman–Kac flow by simulating a population of weighted particles :
- Initialization: , .
- For :
- Propagation: .
- Importance Weight Update: .
- Normalization: .
- Resampling: If effective sample size falls below a threshold, resample particles proportionally to their weights, and reset all .
For a test function , the estimator of the target expectation is given by
Under mild regularity, this estimator is consistent: as , (Boreale et al., 17 Sep 2025, Jasra, 2013).
Pseudocode Outline
1 2 3 4 5 6 7 8 9 |
Input: η₀, {Mₙ}, {Gₙ}, number of particles N Initialize: X₀ᶦ ∼ η₀, w₀ᶦ ← 1/N for i=1,…,N for n = 1 to N: for i = 1 to N: Xₙᶦ ∼ Mₙ(Xₙ₋₁ᶦ,·) w̃ₙᶦ ← wₙ₋₁ᶦ * Gₙ(Xₙᶦ) Normalize: wₙᶦ ← w̃ₙᶦ / sumⱼ w̃ₙʲ If ESS < threshold: Resample, set wₙᶦ ← 1/N Output: {Xₙᶦ, wₙᶦ} |
3. Algorithmic Variants and Vectorization
Recent developments enable highly efficient, parallel implementations of the Feynman–Kac SMC procedure. In the context of probabilistic program graphs, vectorized particle filters (VPF) propagate the states of all particles synchronously:
- Store (particle states), (weights).
- All particle transitions, weight updates, and resampling steps are performed via array/tensor operations, exploiting SIMD parallelism and minimizing explicit loops over particles.
- This fine-grained parallelism is particularly suited to GPUs and modern high-performance hardware (Boreale et al., 17 Sep 2025).
In the discrete setting, such as discrete diffusion or masked sequence models, both propagation and weighting steps rely on vectorized lookups and updates involving the model's logits and potential modifications (product-of-experts, temperature scaling, reward tilting) (Hasan et al., 15 Jan 2026).
4. Theoretical Guarantees: Consistency and Central Limit Theorems
Under appropriate drift, minorization, boundedness, and integrability conditions on the Markov kernels and potential functions, rigorous convergence rates and variance bounds are available:
- Weak Consistency: For any bounded , the estimator converges almost surely: as .
- Central Limit Theorem: , with explicit formula for the asymptotic variance (Jasra, 2013).
- Linear-in-Time Variance: For additive functionals, under weaker than classical assumptions, the variance grows at most linearly in (Jasra, 2013).
- In the presence of feedback terms through empirical measures (e.g., McKean-Vlasov interactions or kernel smoothing for nonconservative PDEs), the SMC estimator remains consistent with suitable mollification as long as and smoothing parameter at compatible rates (Lecavil et al., 2016).
5. Specializations and Contemporary Extensions
Continuous and Discrete Potentials
- Continuous-time SDE settings: Feynman–Kac SMC targets stochastic differential equations with weighted trajectories using discretized Euler–Maruyama proposals and exponentiated incremental weights (Lecavil et al., 2016, Skreta et al., 4 Mar 2025).
- Discrete models: The discrete Feynman–Kac SMC formalism targets Markov jump processes and discrete diffusion processes, with incremental weights derived from ratios of model marginals or external reward tilts (Hasan et al., 15 Jan 2026).
Inference-Time Control via Potentials
- Annealing: Adjust potentials to sample from .
- Product-of-Experts: Modify weights to sample from with multiple models.
- Reward-tilting: Bias sampling using external reward functions.
- These techniques are implemented by modifying the per-step potential function and path measure as prescribed by the Feynman–Kac theory (Skreta et al., 4 Mar 2025, Hasan et al., 15 Jan 2026).
6. Applications in Probabilistic Programming, PDEs, and Generative Modeling
The Feynman–Kac SMC framework is foundational across several domains:
- Probabilistic Program Inference: SMC algorithms consistent with the Feynman–Kac semantics of probabilistic programs over arbitrary measures and unbounded loops, with vectorized implementations for high-throughput inference (Boreale et al., 17 Sep 2025).
- Semilinear and Nonconservative PDEs: Solution of nonlinear parabolic equations via weighted particle systems, with convergence guarantees for empirical (kernel-smoothed) marginals under propagation-of-chaos arguments (Lecavil et al., 2016).
- Score-Based Diffusion and Guidance: Amortized annealed sampling, product-of-experts composition, and classifier-free guidance all arise as modifications of Feynman–Kac SMC with appropriate potential increments (Skreta et al., 4 Mar 2025).
- Discrete Diffusion and Reward-Guided Generation: Controlling discrete generation at inference time, combining LLM outputs, reward guidance for protein design, and physical systems such as Ising models (Hasan et al., 15 Jan 2026).
7. Implementation and Practical Considerations
- Resampling Schedule: Monitoring and resampling when necessary prevents particle degeneracy and maintains approximation fidelity.
- Parallelization: Array-based and SIMD/SIMT primitives enable efficient scaling of the SMC algorithm to large particle populations.
- Numerical Stability: Tracking log-weights mitigates underflow; choice of in smoothing controls bias-variance tradeoff in estimator convergence (Lecavil et al., 2016, Boreale et al., 17 Sep 2025).
- Oracle Requirements: Discrete implementations require only ratios of model marginals, readily accessible in denoising diffusion models (Hasan et al., 15 Jan 2026).
The flexibility and universality of the Feynman–Kac SMC procedure ensure its central role in inference, simulation, and control within probabilistic modeling, stochastic analysis, and machine learning (Boreale et al., 17 Sep 2025, Lecavil et al., 2016, Skreta et al., 4 Mar 2025, Hasan et al., 15 Jan 2026, Jasra, 2013).