Skip to content

Framework adapters: Stan / PyMC / NumPyro → Simulator protocol #80

@jc-macdonald

Description

@jc-macdonald

Problem

Users must write a custom class implementing the Simulator protocol for every probabilistic programming framework. Boilerplate is similar across Stan, PyMC, and NumPyro.

Proposed

Thin adapter classes that wrap a model + data into a Simulator:

  • StanSimulator(model_code, data_fn, observables)
  • PyMCSimulator(model_fn, data_fn, observables)
  • NumPyroSimulator(model_fn, data_fn, observables)

Each takes a function mapping grid config → model data dict, runs inference, and extracts observables from posteriors.

Notes

These should live in optional extras (trade-study[stan], etc.) and use deferred imports. Low priority — power users write their own adapters.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3-lowNice to havefeatureNew feature or enhancement

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions