Algorithm Search⌘K

Algorithmcore

Bottom-up enumerative synthesis

Also called observational equivalence pruning.

Enumerates programs of growing size from smaller ones and keeps one program per distinct output vector on the examples.

Time
O(k b^2) binary rules onlyO(k b^3) worst case with if-then-else
Space
O(k b) all
Where
b = the number of kept programs; k = the number of examples
Properties
deterministiciterative
Origin
Abhishek Udupa, Arun Raghavan, Jyotirmoy V. Deshmukh, Sela Mador Haim, Milo M. K. Martin, Rajeev Alur, Aws Albarghouthi, Sumit Gulwani, Zachary Kincaid, 2013

Bottom-up enumerative synthesis finds a program from input-output examples by building all programs of a grammar in order of size. Programs of size ss are built from kept programs of smaller sizes, so nothing is built twice. The key step is observational equivalence: two programs that give the same outputs on all example inputs are interchangeable inside any larger program, so only the first one is kept. The first program that gives the wanted outputs has the least size. It is the simplest complete method for programming by example and for syntax-guided synthesis, where it serves as the synthesizer inside CEGIS.

In plain words

Say you want a formula in x and y that gives 2 for the pair (1, 2) and 3 for (3, 1). Start with the smallest formulas: x, y, 0 and 1. Combine them with plus, minus and times to get the formulas with three symbols, then combine again, and so on. Stop at the first formula that gives the wanted answers.

Many formulas act the same on the examples. On these two pairs, "x + 0", "0 + x" and "x times 1" all give 1 and 3, just like x itself. Any larger formula that uses one of them gives the same answers as the one that uses x. So keep only the first formula for each list of answers and forget the rest. This cuts the search a lot, and it still finds a shortest formula.

The problem

Input. A grammar with sorts, a start sort, examples (i1,o1),…,(ik,ok)(i_1, o_1), \ldots, (i_k, o_k), and a size bound maxsize.

Output. A program PP of the start sort with [ ⁣[P] ⁣](ij)=oj[\![P]\!](i_j) = o_j for all jj and of least size, or "none" if no such program has size at most maxsize.

The grammar on this page and in the code has two sorts:

  • I::=x∣y∣0∣1∣I+I∣I−I∣I×I∣ite(B,I,I)I ::= x \mid y \mid 0 \mid 1 \mid I + I \mid I - I \mid I \times I \mid \mathrm{ite}(B, I, I)
  • B::=I≤IB ::= I \le I

The size of a program is its number of nodes, so x+yx + y has size 3 and ite(x≤y,y,x)(x \le y, y, x) has size 6. The vector of a program is the tuple of its outputs on i1,…,iki_1, \ldots, i_k.

The algorithm

  1. SYNTHESIZE(examples, maxsize)
  2. 1seen[T] ← ∅ for each sort T ▷ the vectors of the kept programs
  3. 2for s = 1, 2, …, maxsize do
  4. 3for each program P = r(Q1, …, Qm) of size s, with kept parts Q1, …, Qm, of sort T do
  5. 4v ← Fr(vec(Q1), …, vec(Qm)) ▷ the outputs of P on the example inputs
  6. 5if v ∈ seen[T] then continue ▷ observationally equivalent to a kept program
  7. 6seen[T] ← seen[T] ∪ {v}; keep P with its vector v
  8. 7if T is the start sort and v = (o1, …, ok) then return P
  9. 8return none

Building by size (lines L2 and L3). For a binary rule, a program of size ss has parts of sizes s1s_1 and s−1−s1s - 1 - s_1. The loop goes over all splits and over all kept programs of these sizes. For ite, it goes over the sizes of the condition and of the two branches. The parts are always smaller, so they were kept in an earlier round.

Vectors (line L4). The algorithm never runs a whole program. It stores the vector of each kept program and computes the vector of a new program from the vectors of its parts, one example at a time: the vector of P+QP + Q is the sum of the two vectors, and the vector of ite(B,P,Q)(B, P, Q) takes the entry of PP where BB is true and of QQ where it is false. This needs a semantics where the value of an operator depends only on the values of its arguments on the same input.

Pruning (lines L5 and L6). A hash set of vectors, one for each sort, finds a duplicate in expected constant time per vector. The first program with a vector is kept. Since rounds go by size, it is a smallest program with that vector.

Example

Take the examples (1,2)↦2(1, 2) \mapsto 2 and (3,1)↦3(3, 1) \mapsto 3, so the wanted vector is (2,3)(2, 3).

  • Size 1. The four leaves have the vectors x=(1,3)x = (1, 3), y=(2,1)y = (2, 1), 0=(0,0)0 = (0, 0) and 1=(1,1)1 = (1, 1). All four are kept.
  • Size 3. There are 48 programs of sort II with 3 nodes. They have 22 distinct vectors, and 4 of these are the vectors of the leaves: x+0x + 0, 0+x0 + x, x−0x - 0, x×1x \times 1 and 1×x1 \times x all have the vector of xx, and 12 programs, from x−xx - x to 0×10 \times 1, have the vector of 00. So 18 are new. The vector (2,3)(2, 3) comes first from x×yx \times y, and the search returns it.

This is the trap of programming by example: x×yx \times y is the smallest program that fits, but on (2,2)(2, 2) it gives 4. If the user wanted the maximum, the examples did not say so.

A third example. Add (2,2)↦2(2, 2) \mapsto 2. The wanted vector is now (2,3,2)(2, 3, 2).

size kept programs of sort II kept programs of sort BB all programs of sort II
1 4 0 4
3 18 6 48
5 77 0 1,152
6 hit 0 256

No program of size at most 5 fits. At size 6 the search builds ite(B,P,Q)(B, P, Q) with a condition of size 3 and two leaves, and the first hit is ite(x≤y,y,x)(x \le y, y, x), the maximum. Over three examples a condition has at most 23=82^3 = 8 vectors, and only 6 of them occur, so 6 conditions are kept out of 16. In all, the search builds 665 programs of both sorts before it returns. Without line L5 it builds 1,625. Adding the examples (3,5)↦5(3, 5) \mapsto 5 and (5,3)↦5(5, 3) \mapsto 5 gives the same program and the same counts. With no hit at all, an exhaustive run up to size 7 builds 4,500 programs with pruning and 47,940 without.

Correctness

The proof is in proofs/correctness.md. The main lemma states that after round ss, for every program PP of size at most ss there is a kept program of the same sort, no larger, with the same vector. It holds by induction on PP: replace each part by its kept twin, which is no larger and has the same vector. The new program has the same vector as PP by compositionality, and either it is kept or a program with its vector was kept before. So if a correct program of size rr exists, a kept program with the wanted vector exists after round rr, and line L7 returned it. The first return is therefore a smallest correct program, and "none" means that no program of size at most maxsize fits. The same proof works for any cost that is a positive integer weight per rule, summed over the nodes.

Proof: Bottom-up search with observational equivalence returns a smallest programfull

Setting. A grammar has a finite set of sorts and a finite set of rules. A rule rr of arity m≥0m \ge 0 builds a program of sort TT from programs P1,…,PmP_1, \ldots, P_m of fixed sorts T1,…,TmT_1, \ldots, T_m. The size of r(P1,…,Pm)r(P_1, \ldots, P_m) is 1+∑i∣Pi∣1 + \sum_i |P_i|. The examples have inputs i1,…,iki_1, \ldots, i_k and wanted outputs o1,…,oko_1, \ldots, o_k. The vector of a program PP is vec(P)=([ ⁣[P] ⁣](i1),…,[ ⁣[P] ⁣](ik))\mathrm{vec}(P) = ([\![P]\!](i_1), \ldots, [\![P]\!](i_k)). The semantics is compositional: for each rule rr there is a function FrF_r with vec(r(P1,…,Pm))=Fr(vec(P1),…,vec(Pm))\mathrm{vec}(r(P_1, \ldots, P_m)) = F_r(\mathrm{vec}(P_1), \ldots, \mathrm{vec}(P_m)). This holds when each operator is a function of the values of its arguments on the same input, as for ++, −-, ×\times, ≤\le and ite. Line numbers refer to the pseudocode on the page.

At size ss, line L3 builds r(Q1,…,Qm)r(Q_1, \ldots, Q_m) for every rule rr and every tuple of kept programs of the right sorts with 1+∑i∣Qi∣=s1 + \sum_i |Q_i| = s. Line L4 computes its vector by FrF_r from the stored vectors of the parts. Line L5 drops it if a kept program of the same sort has the same vector. Otherwise line L6 keeps it and line L7 returns it if its sort is the start sort and its vector is (o1,…,ok)(o_1, \ldots, o_k). The parts of a program of size ss have sizes below ss, so they were kept at earlier rounds.

Lemma: every vector is kept at its least size

Claim. Assume that the search has finished round ss without a return. Then for every program PP of sort TT with ∣P∣≤s|P| \le s there is a kept program QQ of sort TT with ∣Q∣≤∣P∣|Q| \le |P| and vec(Q)=vec(P)\mathrm{vec}(Q) = \mathrm{vec}(P).

Proof. By induction on ∣P∣|P|. Let P=r(P1,…,Pm)P = r(P_1, \ldots, P_m). Each PiP_i is smaller than PP, so by induction there is a kept QiQ_i of sort TiT_i with ∣Qi∣≤∣Pi∣|Q_i| \le |P_i| and vec(Qi)=vec(Pi)\mathrm{vec}(Q_i) = \mathrm{vec}(P_i). (For a leaf, m=0m = 0 and there is nothing to do.) Let R=r(Q1,…,Qm)R = r(Q_1, \ldots, Q_m). Its size is s′=1+∑i∣Qi∣≤∣P∣s' = 1 + \sum_i |Q_i| \le |P|, so round s′s' has finished, and line L3 built RR in that round from the kept QiQ_i. By compositionality, vec(R)=Fr(vec(Q1),…)=Fr(vec(P1),…)=vec(P)\mathrm{vec}(R) = F_r(\mathrm{vec}(Q_1), \ldots) = F_r(\mathrm{vec}(P_1), \ldots) = \mathrm{vec}(P). If line L6 kept RR, take Q=RQ = R. If line L5 dropped it, a program QQ of sort TT with the same vector was kept before, in round s′s' or earlier, so ∣Q∣≤s′≤∣P∣|Q| \le s' \le |P|. □\square

Theorem

SYNTHESIZE(examples, maxsize) returns a program of the start sort that meets all examples and has the least size among all such programs, if one of size at most maxsize exists. It returns "none" exactly when no such program exists.

Proof. Soundness. Line L7 returns PP only if vec(P)=(o1,…,ok)\mathrm{vec}(P) = (o_1, \ldots, o_k), and the vector computed at line L4 is the true vector by compositionality, so PP meets every example.

Least size. Say line L7 returns PP in round ss, and some program RR of the start sort with ∣R∣<s|R| < s meets the examples. Round ∣R∣|R| finished without a return. By the lemma there is a kept QQ of the start sort with ∣Q∣≤∣R∣|Q| \le |R| and vec(Q)=(o1,…,ok)\mathrm{vec}(Q) = (o_1, \ldots, o_k). When line L6 kept QQ, line L7 returned it, in a round before ss. This is a contradiction.

Completeness. Say a program RR with ∣R∣≤|R| \le maxsize meets the examples, and the search returns nothing in rounds 1,…,∣R∣1, \ldots, |R|. The lemma after round ∣R∣|R| gives a kept QQ with the wanted vector, and line L7 returned QQ when it was kept. This is a contradiction. So a return happens, and by the first two parts it is a smallest correct program. If no correct program of size at most maxsize exists, line L7 never fires and line L8 returns "none". □\square

Remarks

No pruning. Without line L5 the search keeps every program, so it builds all programs in order of size, and the first hit is again of least size. With and without pruning the answer has the same size, but it can be a different program of that size.

Other cost models. The proof uses only two facts about size: the cost of r(P1,…,Pm)r(P_1, \ldots, P_m) is larger than the cost of each PiP_i, and it does not grow when a part is replaced by a part of no larger cost. So the theorem holds for every cost of the form w(r)+∑ic(Pi)w(r) + \sum_i c(P_i) with positive integer rule weights w(r)w(r), with rounds over the cost values instead of the sizes.

Where it fails. If the semantics is not compositional, two programs with the same vector can behave differently inside a larger program, and pruning can drop the only part of the right answer. This happens with side effects, with a state that the vector does not record, and with recursion through the program being built, where the value of a call depends on the whole program and not on the vector of the part.

Complexity

Let bb be the number of kept programs and kk the number of examples. A binary rule combines O(b2)O(b^2) pairs of kept programs, and ite combines O(b3)O(b^3) triples. Each new vector costs O(k)O(k) time to compute and to look up in the hash set, in expectation. So the time is O(kb2)O(k b^2) for binary rules and O(kb3)O(k b^3) in the worst case with ite. The space is O(kb)O(k b) for the kept vectors.

The number bb is at most the number of distinct vectors. If each output can take VV values, that is at most VkV^k, and for a Boolean sort it is at most 2k2^k. It is also at most the number of programs, which grows exponentially with the size: the grammar above has 4, 48, 1,152 and 34,560 programs of sort II with 1, 3, 5 and 7 nodes. Pruning makes bb much smaller, but the search stays exponential in the size of the answer.

Properties

  • Least size. The result is a smallest program that fits, for the grammar and the cost model. It is not always the intended one.
  • Complete up to the bound. If a program of size at most maxsize fits, the search finds one.
  • Needs only the examples. It never calls a solver. In a CEGIS loop the verifier adds a new example after each wrong guess, and the search starts again with a finer equivalence.
  • Deterministic. The order of rules and parts fixes which program of the least size is returned.

Variants and improvements

  • Top-down enumeration. Expand the grammar from the start symbol and prune partial programs that cannot fit. Pruning by vectors does not apply directly, because the parts of a partial program are not complete. Type-directed synthesis is a top-down method.
  • Divide and conquer. The EUSolver of Alur, Radhakrishna and Udupa enumerates small terms that each fit some of the examples, and joins them with conditions learned as a decision tree.
  • Goal graphs. Escher (Albarghouthi et al. 2013) splits a wanted vector into the parts where a condition is true and false, and searches for the branches as separate goals. It also allows recursion by looking up the values of recursive calls in the examples.
  • Equivalence by rewriting. Instead of vectors, a search can keep one term per class of terms that are equal by rewrite rules, as equality saturation does. This keeps terms that are equal for all inputs, not just on the examples.
  • Weighted grammars. Give each rule a cost, or a probability learned from a corpus, and enumerate in order of cost.

When to use it

Use it when the programs are small expressions over a fixed grammar, the examples are cheap to evaluate, and the semantics is compositional. It is the default synthesizer inside CEGIS for SyGuS tasks over integers and bit vectors, and a good baseline for any new synthesis problem. For strings with a known structure, a version space algebra such as the one in string transformation synthesis holds all fitting programs at once. For large programs or deep conditionals, use a solver or a top-down method with stronger pruning.

Pitfalls

  • The examples decide the answer. Two examples gave x×yx \times y for a maximum. The smallest fitting program is often wrong, so add examples, ask the user about an input where two kept programs disagree, or use a verifier.
  • Exponential growth. Each round can multiply the number of programs. Doubling the size bound does not double the time; it can make the search run out of memory.
  • Non-compositional operators. Pruning is correct only if the value of an operator depends on the values of its arguments on the same input. Programs with side effects, a hidden state, or recursive calls to the program being built break this.
  • Errors and exceptions. If a program fails on an input, its vector must record the failure as a value, such as a special marker. Dropping such programs is safe only if no operator can recover from the failure.
  • Floating point. Two programs can give values that differ in the last bit and still mean the same function. Exact equality of vectors keeps both; rounding can merge two different functions.
  • Equivalence on the examples only. Two kept programs can differ on other inputs. Pruning one of them is safe for the search, because the examples are the specification, but a new example can make them differ, and then the search must start again.

Implementations

Each implementation follows the pseudocode above. A comment @line links a line of code to a line of the pseudocode. Point at a line of the pseudocode to see the matching code. The build runs the native tests of each language.

bottom_up_enumerative_synthesis.pyI0RawGitHub
# SPDX-License-Identifier: MIT
# Part of https://algorithm.tamnd.com/bottom-up-enumerative-synthesis/. The authors are listed in prov/Q97T2A.jsonl.
"""Bottom-up enumerative synthesis with observational equivalence.

The grammar has two sorts:
    I ::= x | y | 0 | 1 | I + I | I - I | I * I | ite(B, I, I)
    B ::= I <= I
Programs are trees: "x", "y", "0", "1", (op, p, q) with op in "+", "-", "*",
("<=", p, q) and ("ite", b, p, q). The size of a program is its number of
nodes. An input is a pair (x, y) of ints.

synthesize(examples, max_size) builds programs by size from smaller ones. It
computes the vector of outputs of each new program on the example inputs from
the vectors of its parts. With prune=True it keeps a program only if no kept
program of its sort has the same vector (observational equivalence). It returns
the first program whose vector equals the wanted outputs, which is a program of
least size, together with the number of programs it built.
"""

LEAVES = ("x", "y", "0", "1")
INT_OPS = ("+", "-", "*")


def evaluate(p, inp):
    """The value of program p on the input pair inp."""
    if p == "x":
        return inp[0]
    if p == "y":
        return inp[1]
    if p == "0":
        return 0
    if p == "1":
        return 1
    op = p[0]
    if op == "ite":
        return evaluate(p[2], inp) if evaluate(p[1], inp) else evaluate(p[3], inp)
    a, b = evaluate(p[1], inp), evaluate(p[2], inp)
    if op == "+":
        return a + b
    if op == "-":
        return a - b
    if op == "*":
        return a * b
    if op == "<=":
        return a <= b
    raise ValueError(f"unknown operator {op!r}")


def size(p):
    if isinstance(p, str):
        return 1
    return 1 + sum(size(q) for q in p[1:])


def show(p):
    if isinstance(p, str):
        return p
    if p[0] == "ite":
        return f"ite({show(p[1])}, {show(p[2])}, {show(p[3])})"
    return f"({show(p[1])} {p[0]} {show(p[2])})"


def _leaf_vector(t, inputs):
    return tuple(evaluate(t, i) for i in inputs)


def synthesize(examples, max_size, prune=True):
    """(a smallest program meeting the examples or None, number of programs built)."""
    inputs = [i for i, _ in examples]
    target = tuple(o for _, o in examples)
    ints = {}   # size -> list of (program, vector) of sort I
    bools = {}  # size -> list of (program, vector) of sort B
    seen_int = set()  # @line L1
    seen_bool = set()
    built = 0

    def keep(bank, seen, s, prog, vec):
        nonlocal built
        built += 1
        if prune and vec in seen:  # @line L5
            return False
        seen.add(vec)  # @line L6
        bank.setdefault(s, []).append((prog, vec))
        return True

    for s in range(1, max_size + 1):  # @line L2
        new_ints = []
        if s == 1:
            for t in LEAVES:
                new_ints.append((t, _leaf_vector(t, inputs)))
        else:
            for s1 in range(1, s - 1):  # @line L3
                s2 = s - 1 - s1
                for p, u in ints.get(s1, ()):
                    for q, v in ints.get(s2, ()):
                        for op in INT_OPS:
                            if op == "+":
                                w = tuple(a + b for a, b in zip(u, v))  # @line L4
                            elif op == "-":
                                w = tuple(a - b for a, b in zip(u, v))
                            else:
                                w = tuple(a * b for a, b in zip(u, v))
                            new_ints.append(((op, p, q), w))
                        keep(bools, seen_bool, s, ("<=", p, q), tuple(a <= b for a, b in zip(u, v)))
            for sb in range(3, s - 1):
                for b, bv in bools.get(sb, ()):
                    for s1 in range(1, s - sb - 1):
                        s2 = s - 1 - sb - s1
                        for p, u in ints.get(s1, ()):
                            for q, v in ints.get(s2, ()):
                                w = tuple(x if c else z for c, x, z in zip(bv, u, v))
                                new_ints.append((("ite", b, p, q), w))
        for prog, vec in new_ints:
            if keep(ints, seen_int, s, prog, vec) and vec == target:  # @line L7
                return prog, built
    return None, built  # @line L8
test_bottom_up_enumerative_synthesis.py 104 lines
# SPDX-License-Identifier: MIT
# Part of https://algorithm.tamnd.com/bottom-up-enumerative-synthesis/. The authors are listed in prov/Q97T2A.jsonl.

import random

from bottom_up_enumerative_synthesis import LEAVES, evaluate, size, synthesize


def programs_of_size(s, sort="I", memo={}):
    """Brute force: every program of the given sort with exactly s nodes."""
    key = (s, sort)
    if key in memo:
        return memo[key]
    out = []
    if sort == "I":
        if s == 1:
            out = list(LEAVES)
        for s1 in range(1, s - 1):
            for p in programs_of_size(s1):
                for q in programs_of_size(s - 1 - s1):
                    for op in ("+", "-", "*"):
                        out.append((op, p, q))
        for sb in range(3, s - 1):
            for s1 in range(1, s - sb - 1):
                for b in programs_of_size(sb, "B"):
                    for p in programs_of_size(s1):
                        for q in programs_of_size(s - 1 - sb - s1):
                            out.append(("ite", b, p, q))
    else:
        for s1 in range(1, s - 1):
            for p in programs_of_size(s1):
                for q in programs_of_size(s - 1 - s1):
                    out.append(("<=", p, q))
    memo[key] = out
    return out


def brute_min_size(examples, max_size):
    for s in range(1, max_size + 1):
        for p in programs_of_size(s):
            if all(evaluate(p, i) == o for i, o in examples):
                return s
    return None


def meets(p, examples):
    return all(evaluate(p, i) == o for i, o in examples)


def test_counts():
    assert [len(programs_of_size(s)) for s in range(1, 8)] == [4, 0, 48, 0, 1152, 256, 34560]


def test_random_targets():
    rng = random.Random(11)
    pool = [p for s in range(1, 8) for p in programs_of_size(s)]
    for t in range(14):
        target = rng.choice(pool)
        examples = []
        for _ in range(rng.randint(2, 4)):
            inp = (rng.randint(-3, 3), rng.randint(-3, 3))
            examples.append((inp, evaluate(target, inp)))
        want = brute_min_size(examples, 7)
        assert want is not None and want <= size(target)
        found, built = synthesize(examples, 7)
        assert found is not None and meets(found, examples)
        assert size(found) == want
        if t % 2 == 0:
            plain, built_plain = synthesize(examples, 7, prune=False)
            assert plain is not None and meets(plain, examples)
            assert size(plain) == want
            assert built <= built_plain


def test_random_outputs():
    # Outputs not made by a program: the synthesizer and the brute force agree, also on "none".
    rng = random.Random(12)
    for _ in range(12):
        examples = [((rng.randint(-3, 3), rng.randint(-3, 3)), rng.randint(-9, 9)) for _ in range(3)]
        want = brute_min_size(examples, 6)
        found, _ = synthesize(examples, 6)
        if want is None:
            assert found is None
        else:
            assert found is not None and meets(found, examples) and size(found) == want
        plain, _ = synthesize(examples, 6, prune=False)
        assert (plain is None) == (want is None)
        if plain is not None:
            assert size(plain) == want


def test_maximum():
    examples = [((1, 2), 2), ((3, 1), 3), ((2, 2), 2), ((3, 5), 5), ((5, 3), 5)]
    found, _ = synthesize(examples, 7)
    assert size(found) == 6
    for a in range(-4, 5):
        for b in range(-4, 5):
            assert evaluate(found, (a, b)) == max(a, b)


def test_underspecified():
    found, _ = synthesize([((1, 2), 2), ((3, 1), 3)], 7)
    assert size(found) == 3
    assert evaluate(found, (2, 2)) == 4

History

Udupa, Raghavan, Deshmukh, Mador-Haim, Martin and Alur (2013) used enumeration by size with pruning of expressions that agree on the concrete examples in TRANSIT, a tool for completing cache coherence protocols. In the same year Albarghouthi, Gulwani and Kincaid built Escher, which searches forward over values with observational equivalence and adds goal graphs for conditionals and recursion. Alur and others (2013) defined syntax-guided synthesis, and the enumerative solver based on this pruning won the first SyGuS competition in 2014. The survey of Gulwani, Polozov and Singh (2017) describes bottom-up and top-down enumeration as one of the main search methods of program synthesis.

References

  1. Abhishek Udupa, Arun Raghavan, Jyotirmoy V. Deshmukh, Sela Mador-Haim, Milo M. K. Martin and Rajeev Alur, TRANSIT, specifying protocols with concolic snippets, Programming Language Design and Implementation (PLDI 2013), pp. 287-296, the enumeration of expressions by size with pruning of expressions that agree on the concrete examples
  2. Aws Albarghouthi, Sumit Gulwani and Zachary Kincaid, Recursive program synthesis, Computer Aided Verification (CAV 2013), pp. 934-950, the Escher algorithm, forward search over values with observational equivalence and goal graphs for conditionals
  3. Rajeev Alur, Rastislav Bodík, Garvit Juniwal, Milo M. K. Martin, Mukund Raghothaman, Sanjit A. Seshia, Rishabh Singh, Armando Solar-Lezama, Emina Torlak and Abhishek Udupa, Syntax-guided synthesis, Formal Methods in Computer-Aided Design (FMCAD 2013), the enumerative solver with observational equivalence inside the CEGIS loop
  4. Sumit Gulwani, Oleksandr Polozov and Rishabh Singh, Program Synthesis, Foundations and Trends in Programming Languages 4(1-2), 2017, chapter 4, enumerative search, bottom-up and top-down enumeration and the pruning of equivalent programs

Where this leads

About this page

The build computes these levels from the evidence in the repository. Each row says what the next level needs. Read what the levels mean.

LadderLevelWhat the next level needs
Human proofH1 sketch
  • a full proof of time.binary rules only
  • a full proof of time.with if-then-else
  • a full proof of space.all
LeanL0 no Lean part
  • name a Lean module in the lean field (07)
Code (python)I0 not checked yet
  • the tests did not run in this build
VisualV0 none
  • add viz/scene.ts or a figure (10)
WritingW2 basic
  • a scene preset for the example