I’ve pushed a working prototype of PyStan 3 to https://github.com/stan-dev/pystan-next . The plan is for this code to eventually replace https://github.com/stan-dev/pystan.
The main design difference between PyStan 3 and previous versions is that PyStan 3 is pure-Python. There’s no C++ code. All the heavy lifting (e.g., model compilation) is handled by httpstan. It’s all permissively licensed, respecting the result of a vote of pystan devs.
I’ll aim to align the user-facing API with RStan3’s and gradually port every test from pystan to pystan-next.
Some notable statistics:
PyStan 2: 5,625 lines of code, excluding tests
PyStan 3 and httpstan: 1,669 lines of code, excluding tests
The reduction in lines of code is achieved thanks to the stan::services
C++ API. For example, thanks to the work on the C++ API the file stan_fit.hpp
(1,559 LOC) is no longer needed.