meander

Jimmy Miller 2021-10-29T14:31:32.011100Z

And with all that explanation, this example might be a bit clearer for people as well. An abstract machine interpreter for the lambda calculus. https://github.com/noprompt/meander/blob/epsilon/examples/cek.clj

2021-10-29T20:56:19.011500Z

@noprompt just out of curiosity, how is work progressing on zeta?

Richie 2021-11-06T00:13:07.031300Z

Thanks.

noprompt 2021-10-29T22:03:36.011600Z

It is progressing but I’m no longer pushing to the zeta branch and I’ve scaled back the amount of time I’m investing in it. After a few different failed iterations to get a unified interface for both compilation and interpretation, I’ve gone back to just having the two separate. All that failed work has come at a cost to my motivation. Plus, working solo gets old after awhile. Compounding all of that has been some really demotivating shit at work. The project is still important to me — I think about it practically everyday — but I’m low on motivation and help.

noprompt 2021-10-29T22:05:34.011900Z

To be totally transparent: the project is not dead.

noprompt 2021-10-29T22:10:59.012200Z

To be doubly transparent: I could use a hand. If I need to write down what is needed to complete the next version in the form of tickets, semantics, etc. then I can do that.

Carlo 2021-10-29T22:28:01.012500Z

Hey this is one of my favorite projects, so I'm more than up to lend a hand. The only issue (which might very well be a deal-breaker if you want to scale down your time investment) is that I don't want to work in solitude - I do that at work already. But, if you want to pair on the weekends, I'm up for it 🙂

noprompt 2021-10-29T22:58:45.012700Z

Pairing on the weekend is difficult for me right now because my kids are still young and its difficult to block out time for that sort of thing. However, I think I could make room for a monthly meet up to discuss the project, make tickets, etc.

noprompt 2021-10-29T23:17:39.014200Z

Could something like that work?

Richie 2021-10-31T03:13:35.014700Z

Can you suggest reading material related to the work? Foundational material? You pointed me at SECD and CEK which both have wikipedia articles with handfuls of citations (which is an intimidating starting point). That is an application of meander that I had not considered. My current plan is to try to use it for everything and experience what works and what doesn't. I'm nowhere near being able to contribute ideas or code to the project but I'm sympathetic. I'd like to see myself contribute examples and docs in the future but I'm not making a commitment.

Ivan 2021-11-06T07:22:12.031600Z

Thanks 👍

Richie 2021-11-04T23:05:36.026100Z

@noprompt What literature motivated you and influenced meander?

noprompt 2021-11-05T02:20:10.026300Z

It was less the literature and more my experiences with programming. But if I had to pick something it'd be the literature connected to Small Step Interpreters, and Operational Semantics (connected to the stuff I mentioned about abstract interpreters in the Github discussion). At the time I'd been really interested in programming languages for a while but I had never encountered anything like the CESK machine. I was really blown away that languages could be interpreted that way. That is what sparked me to start on what would eventually become the rewrite macro.

noprompt 2021-11-05T02:21:29.026500Z

This was the article that started it: https://matt.might.net/articles/cesk-machines/ Then this paper: https://matt.might.net/papers/vanhorn2010abstract.pdf Then this book: https://mitpress.mit.edu/books/semantics-engineering-plt-redex

noprompt 2021-11-05T02:27:02.026800Z

Later on, I found out that, in general, I was actually interested in the topic of "term rewriting" and found a lot of inspiration in the languages Maude, TXL, and Stratego. Books on the topic are incredibly dry and, I'll admit, I found some of the material dense and struggled with it. But even if I didn't always grasp everything, I'm confident I came away with the main ideas. Sometimes that required a lot digging around on the internet. Sometimes it just meant retracing my steps until the light went off or I gave up and moved on.

2021-10-29T23:11:45.013200Z

(m/rewrites
  (:doxa/db #:doxa{:db {}})
  (m/and
   {?t2 {?document {:document/id (m/some ?document-id) ,
                    :project (m/or [_ (m/some :foo)]
                                   (m/scan [_ :foo]))}}}
   {?t1 {?bucket {:opsUnmergedField/id (m/some ?bucket-id) ,
                  :document (m/or [_ (m/some ?document)]
                                  (m/scan [_ (m/some ?document)]))}}})
  true)
why is it not compiling?

2021-10-29T23:12:55.013700Z

usually when it returns

Unable to resolve symbol: T__40212 in this context
it means that the order is wrong, but here I cannot come to anything

noprompt 2021-11-04T16:48:49.015100Z

I've been working on this issue. I figured out where the problem is and am close to fixing.

👍 1
2021-10-29T23:14:57.014100Z

after deleting the (m/or from : project, there is no longer any problem

Richie 2021-10-29T03:15:16.009300Z

Hey, I don't want this to go under the radar and I think it's worth everyone's time. noprompt gave me a truly eye opening solution to the problem I posed. https://github.com/noprompt/meander/discussions/216#discussioncomment-1555041

👍 3
Lucy Wang 2021-10-31T01:42:56.014400Z

I just contributed (for fun) an implementation based on an explicit state machine here https://github.com/noprompt/meander/discussions/216#discussioncomment-1563336

noprompt 2021-10-31T22:21:36.014900Z

I love it! Thanks for contributing. 🙂