https://github.com/verse-lab/ego
EGraphs in OCaml
https://github.com/verse-lab/ego
egraphs equality-saturation ocaml
Last synced: about 1 month ago
JSON representation
EGraphs in OCaml
- Host: GitHub
- URL: https://github.com/verse-lab/ego
- Owner: verse-lab
- License: gpl-3.0
- Created: 2021-08-31T03:42:22.000Z (about 4 years ago)
- Default Branch: master
- Last Pushed: 2024-01-20T00:50:19.000Z (almost 2 years ago)
- Last Synced: 2025-03-28T02:12:20.806Z (8 months ago)
- Topics: egraphs, equality-saturation, ocaml
- Language: OCaml
- Homepage: https://verse-lab.github.io/ego/ego/index.html
- Size: 271 KB
- Stars: 65
- Watchers: 5
- Forks: 7
- Open Issues: 2
-
Metadata Files:
- Readme: readme.md
- License: LICENSE
Awesome Lists containing this project
- awesome-egraphs - ego
README
# Ego - EGraphs in OCaml
Ego (EGraphs OCaml) is an OCaml library that provides generic equality
saturation using EGraphs.
The design of Ego loosely follows the design of Rust's egg library,
providing a flexible interface to run equality saturation extended
with custom user-defined analyses.
```ocaml
(* create an egraph *)
let graph = EGraph.init ()
(* add expressions *)
let expr1 = EGraph.add_sexp graph [%s ((a << 1) / 2)]
(* Convert to graphviz *)
let g : Odot.graph = EGraph.to_dot graph
```
