AlgebraicJulia / AlgebraicJulia/Catlab.jl
Using Catlab CCC as an implementation of Lambda Calculus
- 主要语言
- Julia
- 星标
- 724
- 派生
- 73
- PR 合并指标
- 30 天内没有已合并 PR
描述
@epatters, what would it take to get Catlab to support CCC as a syntax for lambda calculus? I think we need at least:
1. Presentations of FreeCCC as the basis of a lisp like language (done)
2. An instance type for holding programs
3. An interpreter that can run those programs based on their functorial semantics in **Set**
4. Graphical syntax for displaying `ev` `curry` and `hom(A,B)` in graphviz/tikz/compose
5. `@program` to recognize `ev, curry, hom` terms
It looks like the `examples/CompAlg` is a good place to start. We could extend the `Formula` type to include lambda abstraction terms `λ(A::Type,f::Function{A→B→C})` and then give it a primitive operator `call(f,x)` for the `ev(::Hom(A,B), ::A)` terms of CCC
I think the [JuliaInterpreter](https://juliadebug.github.io/JuliaInterpreter.jl/stable/) would be a good framework for a runtime for evaluating julia code dynamically, it short circuits the julia compiler and allows you to execute julia code naively in julia. This is used in the Debugger because julia's JIT implementation spends more time JIT-ing than running in the context of a debugger.
I think once we have CCC ⟺ λ-calculus then we can take an instances in Turing.jl programs as an example of PPL programs as models of CCC in Stoch. [Darren Wilkinson]( http://www.bristol.ac.uk/media-library/sites/jean-golding-institute/documents/A%20compositional%20approach%20to%20statistical%20computing,%20machine%20learning%20and%20probabilistic%20programming.pdf) seems to be exploring PPL and FP ideas and is a serious Theory of Math Bio researcher.
What do you think?
贡献指南
评估
这个 Issue 还没有评估数据。