CLI and usability in other projects.
Right now (as far as I can tell) MarkovJunior is basically a cool proof of concept. It isn't really usable as a library or for practical use in another game. The primary way you interact with MJ is by adding a model to the models folder and running the exe. This will produce an image or .vox that the user can then look at or import into another project.
I would like to use MJ as a library for procedural generation in other games. I am making this issue to see if you would accept a PR that would expose an API surface for such a thing, and if you had any input as to what that might look like. I imagine the user would give a path to a model file, and then MJ would spit out a 2d/3d array of characters.
I agree, it's just a question of finding time to update the project.
I will probably not accept such a PR (because I want to enable MJ as a library myself), but I will link it from the README.
Fair enough! Would you mind outlining things you'd expose in an API? Right now the only functionality I care about is
filepath -> MJ -> 3d array of chars
I'm sure there's 100 other things but I am curious as to your thoughts on what that would look like.
For a library, you generally don't want to force specific use-cases like "only read inputs from a file" unless the inherent nature of the library requires it. Ideally a general Markov Junior library should have a data representation of the inputs and outputs, then perhaps a separate ability to read/write those data structures through a stream for convenience.