BioJulia/Automa.jl

Generic state machine library?

Closed this issue · 3 comments

I want to represent a state machine that has nothing to do with bytes or parsing. I thought I might use Automa.NFA and graphviz to draw it because I like the graph in the readme. Currently Automa.NFA uses Edges which uses ByteSet which is UInt64.

Do you think Automa would be good as a generic library for finite state machines, supporting non-string/byte types?

For example, FSL js library demos modeling a traffic light.

I don't know, but I doubt it. This package was really intended to replace Ragel, and is geared explicitly to parsing (the reason it's in BioJulia is because there are a bunch of unique and fiddly biological data file formats).

I don't know the field well, but with a bit of googling, I found this, which seems promising. Sometimes searching on JuliaHub can be a better place to start. For example, here's a search through package documentation for "state machine". If none of that is fruitful, I'd suggest opening a topic on discourse

I think that is unlikely. All the interesting parts about Automa are the parts that pertain to the code generation, which is closely tied to reading bytes. The part in Automa related to graphs is quite simple and bare-bones. You would be better off implementing it yourself, or using an existing graph library like Graphs.

I'll close this issue as solved. You're welcome to re-open or open another.

Sounds good, I'll look at other solutions. Cheers.