Hi, I noticed you’ve submitted 14 stories to Lobsters and - by my count - 11 of them are linking to your site or content related to your site. It’d be cool if you could review the guidelines around self-promotion and engage with the broader community a bit more.
I think this project does a good job showing the rich algebraic structure (compositionality) of the simple Mealy machine-like type: Bot m s i o = s -> i -> ListT m (o, s), however I feel it’s selling itself short by saying it’s a “toolkit for building chat bots” though.
To me something like this is how message passing/“actors”/distributed systems should be built. (I’ve written about this at length elsewhere, in particular see the section on “Correctness of behaviours” where I use a type similar to Bot above).
Except for simulation testing being easier to implement, as explained in the above link, there are several other aspects which become a lot more manageable when one expresses the system in terms of smaller building blocks such as Bot, for example:
Pipelining: run several bots in parallel with queues connecting them, i.e. all code is serial but we get parallelism for
“free” (see Clojure’s new async.flow library which essentially adopts a Mealy machine as it’s base building block);
Hot-code reloading: swap out a bot without losing it’s state, bonus points for being able to upgrade the state and/or inputs to a richer type (being able to serialise bots, perhaps using something like Conal Elliott’s compiling to categories, would be useful);
Durable computations and elasticity would also be easier if we could serialise computations/Bots;
Supervisor trees a la Erlang: bots that can restart other bots, potentially respecting some particular order to ensure that the system recovers as a whole.
Of course all of the above can be done in any programming language, but I think the effort involved doing this for arbitrary functions rather than smaller composable building blocks is massive.
Hi, I noticed you’ve submitted 14 stories to Lobsters and - by my count - 11 of them are linking to your site or content related to your site. It’d be cool if you could review the guidelines around self-promotion and engage with the broader community a bit more.
I think this project does a good job showing the rich algebraic structure (compositionality) of the simple Mealy machine-like type:
Bot m s i o = s -> i -> ListT m (o, s), however I feel it’s selling itself short by saying it’s a “toolkit for building chat bots” though.To me something like this is how message passing/“actors”/distributed systems should be built. (I’ve written about this at length elsewhere, in particular see the section on “Correctness of behaviours” where I use a type similar to
Botabove).Except for simulation testing being easier to implement, as explained in the above link, there are several other aspects which become a lot more manageable when one expresses the system in terms of smaller building blocks such as
Bot, for example:async.flowlibrary which essentially adopts a Mealy machine as it’s base building block);Bots;Of course all of the above can be done in any programming language, but I think the effort involved doing this for arbitrary functions rather than smaller composable building blocks is massive.