I’d like to start a refactor of the type system and its architecture that we’re using in stanc3. Right now we’re essentially just using a flattened type environment hash map that we copied from the Stan 2 compiler. @enetsee has brought up the idea of refactoring this such that distributions are a first class concept in a new type system, and based on those conversations and a bunch of further thought around what we’re working on adding to the language, I think that’s an important step to take really soon as it could make current and impending projects much easier. I’d like to take those ideas a step further and hopefully also deal with bijectors in the same way, as well as come up with a system for something like “computational contravariance” that will let us deal with GPU, sparse, and possibly “parallel” matrices and collections in a smart and well-founded way.
I know a lot of the issues I’d like to solve, but the details of how to solve them are very much up in the air. I’d love to have a meeting to talk more about this. I think the only required attendee is @enetsee, but I think @Matthijs and @rybern would be really great to have along if they’re not busy.
@enetsee as for timing do you want to use the discussion section of one of the stanc3 meetings this week for this topic? I feel like it’ll kind of be an architectural planning meeting with some drawings, haha.