human
Here's a good function header given the following:
I wrote the below code

    class Node:
        def ht(self):
            return reduce((lambda x, y: (x + y)), [x.ht() for x in self.before], 1)
    nodes = {}
    for (expr, v) in Omega:
        n = Node()
        n.before = []
        n.var = v
        n.expr = expr
        nodes[v] = n
    for (_, v) in Omega:
        if (v in rewrites):
            n = nodes[v]
            r = rewrites[v]
            for (_, v2) in Omega:
                if r.has(v2):
                    n.before.append(nodes[v2])
    return nodes

What's a good function header?
assistant
#Here's a good function header.

def build_expression_tree(Omega, rewrites):